Command input compression

I've got an issue with how Bolt commands work with compression, and wondered if anyone else knew of this and had a fix or workaround?

We have a "Move" vector for a virtual stick, passed in the command input from the client to the server, with compression.
It appears that the Move vector has indeed been passed compressed to the server, as the value is slightly different.
However, the Move vector passed to the client in ExecuteCommand was not compressed, as the value remained unchanged.

So the client and server are using slightly different values for the "Move" input, which is a problem.

Have I missed something?
Is there a setting to apply the same compression/decompression to the command input used locally?
Or do I need to do my own compression?

Comments

  • Compression will make it less accurate, there is no way to "undo" it once it arrives over the network. I haven't had an issue with deviations from input on floats and other compressed inputs but if the input is heavily compressed then it can definitely cause issues.

  • Hi stanchion,

    I don't want to undo it, I just want the server and client to run ExecuteCommand using the same inputs.
    So if the server is using compressed values, I want the local client to do the same.

    For example, i'm setting this in SimulateController:
    CLIENT: cmd.Input.Move.x = 0.0

    Then i'm getting back the following in ExecuteCommand:
    CLIENT: cmd.Input.Move.x = 0.0
    SERVER: cmd.Input.Move.x = -2.235174E-08

    When really the client should also be using -2.235174E-08 due to the compression artifacts.

    So what I mean is, can the compression that is applied to the command inputs sent to the server, also be applied to the command inputs used by the local client that created the command?

    If Bolt has no way of doing this then I will use my own compression.
  • I don't recommend using any compression for command inputs. There is no way to use your own compression with Bolt commands.
  • Okay, thanks.