Example #1
0
        public void SendShowOnScreenChangeRequest(byte show)
        {
            ChangeShowOnScreenMsg msg = new ChangeShowOnScreenMsg();

            msg.EntityId = m_block.EntityId;
            msg.Show     = show;

            Sync.Layer.SendMessageToServer(ref msg, MyTransportMessageEnum.Request);
        }
Example #2
0
        static void OnShowOnScreenSucess(ref ChangeShowOnScreenMsg msg, MyNetworkClient sender)
        {
            MyEntity entity = null;

            MyEntities.TryGetEntityById(msg.EntityId, out entity);
            MyTextPanel block = entity as MyTextPanel;

            if (block != null)
            {
                block.ShowTextFlag = (ShowTextOnScreenFlag)msg.Show;
            }
        }
Example #3
0
        static void OnShowOnScreenRequest(ref ChangeShowOnScreenMsg msg, MyNetworkClient sender)
        {
            MyEntity entity = null;

            MyEntities.TryGetEntityById(msg.EntityId, out entity);
            MyTextPanel block = entity as MyTextPanel;

            if (block != null)
            {
                block.ShowTextFlag = (ShowTextOnScreenFlag)msg.Show;
                Sync.Layer.SendMessageToAll(ref msg, MyTransportMessageEnum.Success);
            }
        }
        public void SendShowOnScreenChangeRequest(byte show)
        {
            ChangeShowOnScreenMsg msg = new ChangeShowOnScreenMsg();

            msg.EntityId = m_block.EntityId;
            msg.Show = show;

            Sync.Layer.SendMessageToServer(ref msg, MyTransportMessageEnum.Request);
        }
 static void OnShowOnScreenSucess(ref ChangeShowOnScreenMsg msg, MyNetworkClient sender)
 {
     MyEntity entity = null;
     MyEntities.TryGetEntityById(msg.EntityId, out entity);
     MyTextPanel block = entity as MyTextPanel;
     if (block != null)
     {
         block.ShowTextFlag = (ShowTextOnScreenFlag)msg.Show;
     }
 }
 static void OnShowOnScreenRequest(ref ChangeShowOnScreenMsg msg, MyNetworkClient sender)
 {
     MyEntity entity = null;
     MyEntities.TryGetEntityById(msg.EntityId, out entity);
     MyTextPanel block = entity as MyTextPanel;
     if (block != null)
     {
         block.ShowTextFlag = (ShowTextOnScreenFlag)msg.Show;
         Sync.Layer.SendMessageToAll(ref msg, MyTransportMessageEnum.Success);
     }
 }