public override void OnDeserialize(NetworkReader reader, bool initialState) { if (synchDirection == SyncDirection.ServerToClient) { CurrentStatus = Status.IsReading; //if (debug) Debug.Log ("OnSerialize initialState:" + initialState, this); bool missingData = false; if (observed != null) { PlayMakerUnetUtils.ReadStreamToFsmVars(this, observed.Fsm, NetworkSynchVariableLOT, reader, out missingData, false); } } }
public void Cmd_SerializeData(byte[] data) { if (isServer) { if (debug) { Debug.Log(this.name + ": Cmd_SerializeData-> ", this); } CurrentStatus = Status.IsReading; //if (debug) Debug.Log ("OnSerialize initialState:" + initialState, this); bool missingData = false; if (observed != null) { PlayMakerUnetUtils.ReadStreamToFsmVars(this, observed.Fsm, NetworkSynchVariableLOT, new NetworkReader(data), out missingData, true); } } }