示例#1
0
        private void UpdateIfIAmRoomOwner(AtRoomUpdatingEvent e)
        {
            var syncData = new ShellsSyncData
            {
                TypeMarker           = typeMarker,
                ShellIdsCreatedAtNow = roomOwnerShellIds
            };

            var syncDataBytes = syncData.SerializeByMessagePack();

            observable.Publish(new SendMessageCommand(syncDataBytes));
        }
        private void SendMessage(AtRoomUpdatingEvent e)
        {
            var syncData = new ShellSyncData
            {
                Guid     = ShellGuid,
                Position = Position,
                Rotation = Rotation
            };

            var syncDataBytes = syncData.SerializeByMessagePack();

            observable.Publish(new SendMessageCommand(syncDataBytes));
        }