Exemple #1
0
 protected virtual void FixedUpdate()
 {
     if (Game.GetPlayer().ControllableEntity == this)
     {
         EntityMovement.MovementSnapshot snapshot = new EntityMovement.MovementSnapshot();
         snapshot.id       = GetId();
         snapshot.inputs   = GetMovementModule().GetInputs();
         snapshot.position = transform.position;
         snapshot.rotation = transform.eulerAngles.y;
         snapshot.time     = Network.GetServerTime();
         NetworkMessageResolve.NetworkMovementSnapshotRequest(snapshot);
     }
 }