Beispiel #1
0
 private static void OnChangeFovSuccess(MySyncCameraBlock syncObject, ref ChangeFovMsg message, MyNetworkClient sender)
 {
     //Don't change fov while someone is using it
     if (!syncObject.Entity.IsActive)
     {
         syncObject.Entity.OnChangeFov(message.Fov);
     }
 }
Beispiel #2
0
            public void SendNewFov(float fov)
            {
                var msg = new ChangeFovMsg();

                msg.EntityId = Entity.EntityId;
                msg.Fov      = fov;

                Sync.Layer.SendMessageToServer(ref msg, MyTransportMessageEnum.Request);
            }
Beispiel #3
0
 private static void OnChangeFovRequest(MySyncCameraBlock syncObject, ref ChangeFovMsg message, MyNetworkClient sender)
 {
     Sync.Layer.SendMessageToAllAndSelf(ref message, MyTransportMessageEnum.Success);
 }
Beispiel #4
0
 private static void OnChangeFovSuccess(MySyncCameraBlock syncObject, ref ChangeFovMsg message, MyNetworkClient sender)
 {
     //Don't change fov while someone is using it
     if (!syncObject.Entity.IsActive)
     {
         syncObject.Entity.OnChangeFov(message.Fov);
     }
 }
Beispiel #5
0
 private static void OnChangeFovRequest(MySyncCameraBlock syncObject, ref ChangeFovMsg message, MyNetworkClient sender)
 {
     Sync.Layer.SendMessageToAllAndSelf(ref message, MyTransportMessageEnum.Success);
 }
Beispiel #6
0
            public void SendNewFov(float fov)
            {
                var msg = new ChangeFovMsg();

                msg.EntityId = Entity.EntityId;
                msg.Fov = fov;

                Sync.Layer.SendMessageToServer(ref msg, MyTransportMessageEnum.Request);
            }