Question by
Deimantas69 · Apr 22, 2017 at 09:20 PM ·
c#networkingnetworksynccommand
syncvar not changing after command
When I execute a [command] from the client it doesn't update the syncvar that i'm targetting it also doesnt fire the hook
my code looks something like this:
[SyncVar(hook = "onHChange")]
public int h = 100;
[Command]
CmdOnHChange(int _h) {
h = _h;
}
I invoke this from a button.
Does anyone have a clue why this might be happening?
Comment