diff --git a/QSB/Anglerfish/Messages/AnglerDataMessage.cs b/QSB/Anglerfish/Messages/AnglerDataMessage.cs index a8f53153..f51638ab 100644 --- a/QSB/Anglerfish/Messages/AnglerDataMessage.cs +++ b/QSB/Anglerfish/Messages/AnglerDataMessage.cs @@ -16,7 +16,7 @@ namespace QSB.Anglerfish.Messages public AnglerDataMessage(QSBAngler qsbAngler) { - Value = qsbAngler.AttachedObject._currentState; + Data = qsbAngler.AttachedObject._currentState; TargetId = TargetToId(qsbAngler.TargetTransform); LocalDisturbancePos = qsbAngler.AttachedObject._localDisturbancePos; } @@ -39,7 +39,7 @@ namespace QSB.Anglerfish.Messages { WorldObject.TargetTransform = IdToTarget(TargetId); WorldObject.AttachedObject._localDisturbancePos = LocalDisturbancePos; - WorldObject.AttachedObject.ChangeState(Value); + WorldObject.AttachedObject.ChangeState(Data); } private static uint TargetToId(Transform transform) diff --git a/QSB/Animation/NPC/Messages/NpcAnimationMessage.cs b/QSB/Animation/NPC/Messages/NpcAnimationMessage.cs index 2009ae26..5e9896db 100644 --- a/QSB/Animation/NPC/Messages/NpcAnimationMessage.cs +++ b/QSB/Animation/NPC/Messages/NpcAnimationMessage.cs @@ -5,11 +5,11 @@ namespace QSB.Animation.NPC.Messages { internal class NpcAnimationMessage : QSBWorldObjectMessage { - public NpcAnimationMessage(bool start) => Value = start; + public NpcAnimationMessage(bool start) => Data = start; public override void OnReceiveRemote() { - if (Value) + if (Data) { WorldObject.StartConversation(); } diff --git a/QSB/Animation/Player/Messages/AnimationTriggerMessage.cs b/QSB/Animation/Player/Messages/AnimationTriggerMessage.cs index 5c385faa..7e5cab08 100644 --- a/QSB/Animation/Player/Messages/AnimationTriggerMessage.cs +++ b/QSB/Animation/Player/Messages/AnimationTriggerMessage.cs @@ -6,7 +6,7 @@ namespace QSB.Animation.Player.Messages { internal class AnimationTriggerMessage : QSBMessage { - public AnimationTriggerMessage(string name) => Value = name; + public AnimationTriggerMessage(string name) => Data = name; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; @@ -23,7 +23,7 @@ namespace QSB.Animation.Player.Messages return; } - animationSync.VisibleAnimator.SetTrigger(Value); + animationSync.VisibleAnimator.SetTrigger(Data); } } } \ No newline at end of file diff --git a/QSB/Animation/Player/Messages/PlayerSuitMessage.cs b/QSB/Animation/Player/Messages/PlayerSuitMessage.cs index 52dffcc8..f7c3f7fa 100644 --- a/QSB/Animation/Player/Messages/PlayerSuitMessage.cs +++ b/QSB/Animation/Player/Messages/PlayerSuitMessage.cs @@ -21,14 +21,14 @@ namespace QSB.Animation.Player.Messages } } - public PlayerSuitMessage(bool on) => Value = on; + public PlayerSuitMessage(bool on) => Data = on; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - player.SuitedUp = Value; + player.SuitedUp = Data; if (!player.IsReady) { @@ -36,14 +36,14 @@ namespace QSB.Animation.Player.Messages } var animator = player.AnimationSync; - animator.SetSuitState(Value); + animator.SetSuitState(Data); } public override void OnReceiveLocal() { - QSBPlayerManager.LocalPlayer.SuitedUp = Value; + QSBPlayerManager.LocalPlayer.SuitedUp = Data; var animator = QSBPlayerManager.LocalPlayer.AnimationSync; - animator.InSuitedUpState = Value; + animator.InSuitedUpState = Data; } } } \ No newline at end of file diff --git a/QSB/CampfireSync/Messages/CampfireStateMessage.cs b/QSB/CampfireSync/Messages/CampfireStateMessage.cs index 8599c867..123fd4b5 100644 --- a/QSB/CampfireSync/Messages/CampfireStateMessage.cs +++ b/QSB/CampfireSync/Messages/CampfireStateMessage.cs @@ -5,8 +5,8 @@ namespace QSB.CampfireSync.Messages { internal class CampfireStateMessage : QSBWorldObjectMessage { - public CampfireStateMessage(Campfire.State state) => Value = state; + public CampfireStateMessage(Campfire.State state) => Data = state; - public override void OnReceiveRemote() => WorldObject.SetState(Value); + public override void OnReceiveRemote() => WorldObject.SetState(Data); } } \ No newline at end of file diff --git a/QSB/ClientServerStateSync/Messages/ClientStateMessage.cs b/QSB/ClientServerStateSync/Messages/ClientStateMessage.cs index 734db935..c491b57b 100644 --- a/QSB/ClientServerStateSync/Messages/ClientStateMessage.cs +++ b/QSB/ClientServerStateSync/Messages/ClientStateMessage.cs @@ -10,10 +10,10 @@ namespace QSB.ClientServerStateSync.Messages /// internal class ClientStateMessage : QSBMessage { - public ClientStateMessage(ClientState state) => Value = state; + public ClientStateMessage(ClientState state) => Data = state; public override void OnReceiveLocal() - => ClientStateManager.Instance.ChangeClientState(Value); + => ClientStateManager.Instance.ChangeClientState(Data); public override void OnReceiveRemote() { @@ -24,7 +24,7 @@ namespace QSB.ClientServerStateSync.Messages } var player = QSBPlayerManager.GetPlayer(From); - player.State = Value; + player.State = Data; } } } \ No newline at end of file diff --git a/QSB/ClientServerStateSync/Messages/ServerStateMessage.cs b/QSB/ClientServerStateSync/Messages/ServerStateMessage.cs index 3474b1d0..6853497e 100644 --- a/QSB/ClientServerStateSync/Messages/ServerStateMessage.cs +++ b/QSB/ClientServerStateSync/Messages/ServerStateMessage.cs @@ -7,10 +7,10 @@ namespace QSB.ClientServerStateSync.Messages /// internal class ServerStateMessage : QSBMessage { - public ServerStateMessage(ServerState state) => Value = state; + public ServerStateMessage(ServerState state) => Data = state; public override void OnReceiveLocal() => OnReceiveRemote(); public override void OnReceiveRemote() - => ServerStateManager.Instance.ChangeServerState(Value); + => ServerStateManager.Instance.ChangeServerState(Data); } } \ No newline at end of file diff --git a/QSB/ConversationSync/Messages/EnterRemoteDialogueMessage.cs b/QSB/ConversationSync/Messages/EnterRemoteDialogueMessage.cs index 73e054ac..c0a7295b 100644 --- a/QSB/ConversationSync/Messages/EnterRemoteDialogueMessage.cs +++ b/QSB/ConversationSync/Messages/EnterRemoteDialogueMessage.cs @@ -6,9 +6,9 @@ namespace QSB.ConversationSync.Messages internal class EnterRemoteDialogueMessage : QSBWorldObjectMessage { public EnterRemoteDialogueMessage(int dialogueIndex) - => Value = dialogueIndex; + => Data = dialogueIndex; public override void OnReceiveRemote() - => WorldObject.RemoteEnterDialogue(Value); + => WorldObject.RemoteEnterDialogue(Data); } } \ No newline at end of file diff --git a/QSB/DeathSync/Messages/PlayerDeathMessage.cs b/QSB/DeathSync/Messages/PlayerDeathMessage.cs index f7b0f867..c41d1e48 100644 --- a/QSB/DeathSync/Messages/PlayerDeathMessage.cs +++ b/QSB/DeathSync/Messages/PlayerDeathMessage.cs @@ -13,7 +13,7 @@ namespace QSB.DeathSync.Messages public PlayerDeathMessage(DeathType type) { - Value = type; + Data = type; NecronomiconIndex = Necronomicon.GetRandomIndex(type); } @@ -40,7 +40,7 @@ namespace QSB.DeathSync.Messages { var player = QSBPlayerManager.GetPlayer(From); var playerName = player.Name; - var deathMessage = Necronomicon.GetPhrase(Value, NecronomiconIndex); + var deathMessage = Necronomicon.GetPhrase(Data, NecronomiconIndex); if (deathMessage != null) { DebugLog.ToAll(string.Format(deathMessage, playerName)); diff --git a/QSB/ElevatorSync/Messages/ElevatorMessage.cs b/QSB/ElevatorSync/Messages/ElevatorMessage.cs index 2e6a0152..480dc658 100644 --- a/QSB/ElevatorSync/Messages/ElevatorMessage.cs +++ b/QSB/ElevatorSync/Messages/ElevatorMessage.cs @@ -5,8 +5,8 @@ namespace QSB.ElevatorSync.Messages { public class ElevatorMessage : QSBWorldObjectMessage { - public ElevatorMessage(bool isGoingUp) => Value = isGoingUp; + public ElevatorMessage(bool isGoingUp) => Data = isGoingUp; - public override void OnReceiveRemote() => WorldObject.RemoteCall(Value); + public override void OnReceiveRemote() => WorldObject.RemoteCall(Data); } } \ No newline at end of file diff --git a/QSB/EyeOfTheUniverse/EyeStateSync/Messages/EyeStateMessage.cs b/QSB/EyeOfTheUniverse/EyeStateSync/Messages/EyeStateMessage.cs index 369ee43d..c6ec7f8e 100644 --- a/QSB/EyeOfTheUniverse/EyeStateSync/Messages/EyeStateMessage.cs +++ b/QSB/EyeOfTheUniverse/EyeStateSync/Messages/EyeStateMessage.cs @@ -20,16 +20,16 @@ namespace QSB.EyeOfTheUniverse.EyeStateSync.Messages } } - private EyeStateMessage(EyeState state) => Value = state; + private EyeStateMessage(EyeState state) => Data = state; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; - public override void OnReceiveLocal() => QSBPlayerManager.LocalPlayer.EyeState = Value; + public override void OnReceiveLocal() => QSBPlayerManager.LocalPlayer.EyeState = Data; public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - player.EyeState = Value; + player.EyeState = Data; } } } \ No newline at end of file diff --git a/QSB/GeyserSync/Messages/GeyserMessage.cs b/QSB/GeyserSync/Messages/GeyserMessage.cs index 26de47e3..bd8e79c5 100644 --- a/QSB/GeyserSync/Messages/GeyserMessage.cs +++ b/QSB/GeyserSync/Messages/GeyserMessage.cs @@ -5,8 +5,8 @@ namespace QSB.GeyserSync.Messages { public class GeyserMessage : QSBWorldObjectMessage { - public GeyserMessage(bool state) => Value = state; + public GeyserMessage(bool state) => Data = state; - public override void OnReceiveRemote() => WorldObject.SetState(Value); + public override void OnReceiveRemote() => WorldObject.SetState(Data); } } \ No newline at end of file diff --git a/QSB/JellyfishSync/Messages/JellyfishRisingMessage.cs b/QSB/JellyfishSync/Messages/JellyfishRisingMessage.cs index 34e849ee..f23f8e9b 100644 --- a/QSB/JellyfishSync/Messages/JellyfishRisingMessage.cs +++ b/QSB/JellyfishSync/Messages/JellyfishRisingMessage.cs @@ -5,8 +5,8 @@ namespace QSB.JellyfishSync.Messages { public class JellyfishRisingMessage : QSBWorldObjectMessage { - public JellyfishRisingMessage(bool isRising) => Value = isRising; + public JellyfishRisingMessage(bool isRising) => Data = isRising; - public override void OnReceiveRemote() => WorldObject.SetIsRising(Value); + public override void OnReceiveRemote() => WorldObject.SetIsRising(Data); } } \ No newline at end of file diff --git a/QSB/Messaging/QSBMessage.cs b/QSB/Messaging/QSBMessage.cs index 8b2d270e..7a37a60a 100644 --- a/QSB/Messaging/QSBMessage.cs +++ b/QSB/Messaging/QSBMessage.cs @@ -45,63 +45,20 @@ namespace QSB.Messaging public override string ToString() => GetType().Name; } - public abstract class QSBMessage : QSBMessage + public abstract class QSBMessage : QSBMessage { - protected T Value; + protected D Data; public override void Serialize(NetworkWriter writer) { base.Serialize(writer); - writer.Write(Value); + writer.Write(Data); } public override void Deserialize(NetworkReader reader) { base.Deserialize(reader); - Value = reader.Read(); + Data = reader.Read(); } } - - public abstract class QSBMessage : QSBMessage - { - protected T Value1; - protected U Value2; - - public override void Serialize(NetworkWriter writer) - { - base.Serialize(writer); - writer.Write(Value1); - writer.Write(Value2); - } - - public override void Deserialize(NetworkReader reader) - { - base.Deserialize(reader); - Value1 = reader.Read(); - Value2 = reader.Read(); - } - } - - public abstract class QSBMessage : QSBMessage - { - protected T Value1; - protected U Value2; - protected V Value3; - - public override void Serialize(NetworkWriter writer) - { - base.Serialize(writer); - writer.Write(Value1); - writer.Write(Value2); - writer.Write(Value3); - } - - public override void Deserialize(NetworkReader reader) - { - base.Deserialize(reader); - Value1 = reader.Read(); - Value2 = reader.Read(); - Value3 = reader.Read(); - } - } -} \ No newline at end of file +} diff --git a/QSB/Messaging/QSBWorldObjectMessage.cs b/QSB/Messaging/QSBWorldObjectMessage.cs index 848cd2d7..aa63b78b 100644 --- a/QSB/Messaging/QSBWorldObjectMessage.cs +++ b/QSB/Messaging/QSBWorldObjectMessage.cs @@ -41,20 +41,20 @@ namespace QSB.Messaging } } - public abstract class QSBWorldObjectMessage : QSBWorldObjectMessage where T : IWorldObject + public abstract class QSBWorldObjectMessage : QSBWorldObjectMessage where T : IWorldObject { - protected V Value; + protected D Data; public override void Serialize(NetworkWriter writer) { base.Serialize(writer); - writer.Write(Value); + writer.Write(Data); } public override void Deserialize(NetworkReader reader) { base.Deserialize(reader); - Value = reader.Read(); + Data = reader.Read(); } } -} \ No newline at end of file +} diff --git a/QSB/MeteorSync/Messages/FragmentDamageMessage.cs b/QSB/MeteorSync/Messages/FragmentDamageMessage.cs index 03df1832..6523de75 100644 --- a/QSB/MeteorSync/Messages/FragmentDamageMessage.cs +++ b/QSB/MeteorSync/Messages/FragmentDamageMessage.cs @@ -5,8 +5,8 @@ namespace QSB.MeteorSync.Messages { public class FragmentDamageMessage : QSBWorldObjectMessage { - public FragmentDamageMessage(float damage) => Value = damage; + public FragmentDamageMessage(float damage) => Data = damage; - public override void OnReceiveRemote() => WorldObject.AddDamage(Value); + public override void OnReceiveRemote() => WorldObject.AddDamage(Data); } } \ No newline at end of file diff --git a/QSB/OrbSync/Messages/OrbDragMessage.cs b/QSB/OrbSync/Messages/OrbDragMessage.cs index b5ddc32a..32e89cee 100644 --- a/QSB/OrbSync/Messages/OrbDragMessage.cs +++ b/QSB/OrbSync/Messages/OrbDragMessage.cs @@ -5,8 +5,8 @@ namespace QSB.OrbSync.Messages { public class OrbDragMessage : QSBWorldObjectMessage { - public OrbDragMessage(bool isDragging) => Value = isDragging; + public OrbDragMessage(bool isDragging) => Data = isDragging; - public override void OnReceiveRemote() => WorldObject.SetDragging(Value); + public override void OnReceiveRemote() => WorldObject.SetDragging(Data); } } \ No newline at end of file diff --git a/QSB/OrbSync/Messages/OrbSlotMessage.cs b/QSB/OrbSync/Messages/OrbSlotMessage.cs index 23b7b296..c04afc40 100644 --- a/QSB/OrbSync/Messages/OrbSlotMessage.cs +++ b/QSB/OrbSync/Messages/OrbSlotMessage.cs @@ -10,7 +10,7 @@ namespace QSB.OrbSync.Messages public OrbSlotMessage(int slotIndex, bool playAudio) { - Value = slotIndex; + Data = slotIndex; _playAudio = playAudio; } @@ -26,6 +26,6 @@ namespace QSB.OrbSync.Messages _playAudio = reader.Read(); } - public override void OnReceiveRemote() => WorldObject.SetSlot(Value, _playAudio); + public override void OnReceiveRemote() => WorldObject.SetSlot(Data, _playAudio); } } \ No newline at end of file diff --git a/QSB/Player/Messages/EnterLeaveMessage.cs b/QSB/Player/Messages/EnterLeaveMessage.cs index 13476056..79a4f251 100644 --- a/QSB/Player/Messages/EnterLeaveMessage.cs +++ b/QSB/Player/Messages/EnterLeaveMessage.cs @@ -34,7 +34,7 @@ namespace QSB.Player.Messages public EnterLeaveMessage(EnterLeaveType type, int objectId = -1) { - Value = type; + Data = type; ObjectId = objectId; } @@ -57,7 +57,7 @@ namespace QSB.Player.Messages public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - switch (Value) + switch (Data) { case EnterLeaveType.EnterMoon: player.IsInMoon = true; @@ -80,7 +80,7 @@ namespace QSB.Player.Messages ShipManager.Instance.RemovePlayerFromShip(player); break; default: - DebugLog.ToConsole($"Warning - Unknown EnterLeaveType : {Value}", MessageType.Warning); + DebugLog.ToConsole($"Warning - Unknown EnterLeaveType : {Data}", MessageType.Warning); break; } } diff --git a/QSB/Player/Messages/PlayerEntangledMessage.cs b/QSB/Player/Messages/PlayerEntangledMessage.cs index 0a730a89..00e41638 100644 --- a/QSB/Player/Messages/PlayerEntangledMessage.cs +++ b/QSB/Player/Messages/PlayerEntangledMessage.cs @@ -8,46 +8,46 @@ namespace QSB.Player.Messages // almost a world object message, but supports null (-1) as well internal class PlayerEntangledMessage : QSBMessage { - public PlayerEntangledMessage(int objectId) => Value = objectId; + public PlayerEntangledMessage(int objectId) => Data = objectId; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; public override void OnReceiveLocal() { var player = QSBPlayerManager.LocalPlayer; - if (Value == -1) + if (Data == -1) { player.EntangledObject = null; return; } - var quantumObject = Value.GetWorldObject(); + var quantumObject = Data.GetWorldObject(); player.EntangledObject = quantumObject; } public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - if (Value == -1) + if (Data == -1) { player.EntangledObject = null; return; } - var quantumObject = Value.GetWorldObject(); + var quantumObject = Data.GetWorldObject(); player.EntangledObject = quantumObject; } public override void Serialize(NetworkWriter writer) { base.Serialize(writer); - writer.Write(Value); + writer.Write(Data); } public override void Deserialize(NetworkReader reader) { base.Deserialize(reader); - Value = reader.Read(); + Data = reader.Read(); } } } \ No newline at end of file diff --git a/QSB/Player/Messages/PlayerKickMessage.cs b/QSB/Player/Messages/PlayerKickMessage.cs index 82ae3f54..be3229bf 100644 --- a/QSB/Player/Messages/PlayerKickMessage.cs +++ b/QSB/Player/Messages/PlayerKickMessage.cs @@ -15,7 +15,7 @@ namespace QSB.Player.Messages public PlayerKickMessage(uint playerId, KickReason reason) { PlayerId = playerId; - Value = reason; + Data = reason; } public override void Serialize(NetworkWriter writer) @@ -57,8 +57,8 @@ namespace QSB.Player.Messages return; } - DebugLog.ToAll($"Kicked from server. Reason : {Value}"); - MenuManager.Instance.OnKicked(Value); + DebugLog.ToAll($"Kicked from server. Reason : {Data}"); + MenuManager.Instance.OnKicked(Data); } } } \ No newline at end of file diff --git a/QSB/Player/Messages/PlayerReadyMessage.cs b/QSB/Player/Messages/PlayerReadyMessage.cs index ac60b625..391ab8a0 100644 --- a/QSB/Player/Messages/PlayerReadyMessage.cs +++ b/QSB/Player/Messages/PlayerReadyMessage.cs @@ -6,7 +6,7 @@ namespace QSB.Player.Messages { public class PlayerReadyMessage : QSBMessage { - public PlayerReadyMessage(bool ready) => Value = ready; + public PlayerReadyMessage(bool ready) => Data = ready; public override void OnReceiveRemote() { @@ -22,14 +22,14 @@ namespace QSB.Player.Messages private void HandleServer() { - DebugLog.DebugWrite($"[SERVER] Get ready event from {From} (ready = {Value})", MessageType.Success); - QSBPlayerManager.GetPlayer(From).IsReady = Value; + DebugLog.DebugWrite($"[SERVER] Get ready event from {From} (ready = {Data})", MessageType.Success); + QSBPlayerManager.GetPlayer(From).IsReady = Data; new PlayerInformationMessage().Send(); } private void HandleClient() { - DebugLog.DebugWrite($"[CLIENT] Get ready event from {From} (ready = {Value})", MessageType.Success); + DebugLog.DebugWrite($"[CLIENT] Get ready event from {From} (ready = {Data})", MessageType.Success); if (!QSBPlayerManager.PlayerExists(From)) { DebugLog.ToConsole( @@ -38,7 +38,7 @@ namespace QSB.Player.Messages return; } - QSBPlayerManager.GetPlayer(From).IsReady = Value; + QSBPlayerManager.GetPlayer(From).IsReady = Data; } } } \ No newline at end of file diff --git a/QSB/QuantumSync/Messages/MoveSkeletonMessage.cs b/QSB/QuantumSync/Messages/MoveSkeletonMessage.cs index 429c702f..4ee6ed7a 100644 --- a/QSB/QuantumSync/Messages/MoveSkeletonMessage.cs +++ b/QSB/QuantumSync/Messages/MoveSkeletonMessage.cs @@ -5,8 +5,8 @@ namespace QSB.QuantumSync.Messages { internal class MoveSkeletonMessage : QSBWorldObjectMessage { - public MoveSkeletonMessage(int index) => Value = index; + public MoveSkeletonMessage(int index) => Data = index; - public override void OnReceiveRemote() => WorldObject.MoveSkeleton(Value); + public override void OnReceiveRemote() => WorldObject.MoveSkeleton(Data); } } \ No newline at end of file diff --git a/QSB/QuantumSync/Messages/MultiStateChangeMessage.cs b/QSB/QuantumSync/Messages/MultiStateChangeMessage.cs index 5ca3695b..4c373f81 100644 --- a/QSB/QuantumSync/Messages/MultiStateChangeMessage.cs +++ b/QSB/QuantumSync/Messages/MultiStateChangeMessage.cs @@ -7,7 +7,7 @@ namespace QSB.QuantumSync.Messages { internal class MultiStateChangeMessage : QSBWorldObjectMessage { - public MultiStateChangeMessage(int stateIndex) => Value = stateIndex; + public MultiStateChangeMessage(int stateIndex) => Data = stateIndex; public override void OnReceiveRemote() { @@ -17,7 +17,7 @@ namespace QSB.QuantumSync.Messages return; } - WorldObject.ChangeState(Value); + WorldObject.ChangeState(Data); } } } \ No newline at end of file diff --git a/QSB/QuantumSync/Messages/QuantumAuthorityMessage.cs b/QSB/QuantumSync/Messages/QuantumAuthorityMessage.cs index c59d024b..ccf4869a 100644 --- a/QSB/QuantumSync/Messages/QuantumAuthorityMessage.cs +++ b/QSB/QuantumSync/Messages/QuantumAuthorityMessage.cs @@ -6,7 +6,7 @@ namespace QSB.QuantumSync.Messages { public class QuantumAuthorityMessage : QSBWorldObjectMessage { - public QuantumAuthorityMessage(uint authorityOwner) => Value = authorityOwner; + public QuantumAuthorityMessage(uint authorityOwner) => Data = authorityOwner; public override bool ShouldReceive { @@ -25,16 +25,16 @@ namespace QSB.QuantumSync.Messages // if Obj==Message then No // Obj - return (WorldObject.ControllingPlayer == 0 || Value == 0) - && WorldObject.ControllingPlayer != Value; + return (WorldObject.ControllingPlayer == 0 || Data == 0) + && WorldObject.ControllingPlayer != Data; } } - public override void OnReceiveLocal() => WorldObject.ControllingPlayer = Value; + public override void OnReceiveLocal() => WorldObject.ControllingPlayer = Data; public override void OnReceiveRemote() { - WorldObject.ControllingPlayer = Value; + WorldObject.ControllingPlayer = Data; if (WorldObject.ControllingPlayer == 00 && WorldObject.IsEnabled) { // object has no owner, but is still active for this player. request ownership diff --git a/QSB/QuantumSync/Messages/QuantumShuffleMessage.cs b/QSB/QuantumSync/Messages/QuantumShuffleMessage.cs index 9978851d..443541a0 100644 --- a/QSB/QuantumSync/Messages/QuantumShuffleMessage.cs +++ b/QSB/QuantumSync/Messages/QuantumShuffleMessage.cs @@ -5,8 +5,8 @@ namespace QSB.QuantumSync.Messages { internal class QuantumShuffleMessage : QSBWorldObjectMessage { - public QuantumShuffleMessage(int[] indexArray) => Value = indexArray; + public QuantumShuffleMessage(int[] indexArray) => Data = indexArray; - public override void OnReceiveRemote() => WorldObject.ShuffleObjects(Value); + public override void OnReceiveRemote() => WorldObject.ShuffleObjects(Data); } } \ No newline at end of file diff --git a/QSB/QuantumSync/Messages/SetIsQuantumMessage.cs b/QSB/QuantumSync/Messages/SetIsQuantumMessage.cs index 2eed0a4c..28d4bb93 100644 --- a/QSB/QuantumSync/Messages/SetIsQuantumMessage.cs +++ b/QSB/QuantumSync/Messages/SetIsQuantumMessage.cs @@ -5,8 +5,8 @@ namespace QSB.QuantumSync.Messages { public class SetIsQuantumMessage : QSBWorldObjectMessage { - public SetIsQuantumMessage(bool isQuantum) => Value = isQuantum; + public SetIsQuantumMessage(bool isQuantum) => Data = isQuantum; - public override void OnReceiveRemote() => WorldObject.SetIsQuantum(Value); + public override void OnReceiveRemote() => WorldObject.SetIsQuantum(Data); } } \ No newline at end of file diff --git a/QSB/RespawnSync/Messages/PlayerRespawnMessage.cs b/QSB/RespawnSync/Messages/PlayerRespawnMessage.cs index f6b297d8..325dda8e 100644 --- a/QSB/RespawnSync/Messages/PlayerRespawnMessage.cs +++ b/QSB/RespawnSync/Messages/PlayerRespawnMessage.cs @@ -6,19 +6,19 @@ namespace QSB.RespawnSync.Messages { internal class PlayerRespawnMessage : QSBMessage { - public PlayerRespawnMessage(uint playerId) => Value = playerId; + public PlayerRespawnMessage(uint playerId) => Data = playerId; public override void OnReceiveLocal() => OnReceiveRemote(); public override void OnReceiveRemote() { - if (Value == QSBPlayerManager.LocalPlayerId) + if (Data == QSBPlayerManager.LocalPlayerId) { RespawnManager.Instance.Respawn(); ClientStateManager.Instance.OnRespawn(); } - RespawnManager.Instance.OnPlayerRespawn(QSBPlayerManager.GetPlayer(Value)); + RespawnManager.Instance.OnPlayerRespawn(QSBPlayerManager.GetPlayer(Data)); } } } \ No newline at end of file diff --git a/QSB/RoastingSync/Messages/EnterExitRoastingMessage.cs b/QSB/RoastingSync/Messages/EnterExitRoastingMessage.cs index bd28a403..937dd499 100644 --- a/QSB/RoastingSync/Messages/EnterExitRoastingMessage.cs +++ b/QSB/RoastingSync/Messages/EnterExitRoastingMessage.cs @@ -37,7 +37,7 @@ namespace QSB.RoastingSync.Messages private EnterExitRoastingMessage(int objectId, bool roasting) { ObjectId = objectId; - Value = roasting; + Data = roasting; } public override void Serialize(NetworkWriter writer) @@ -56,15 +56,15 @@ namespace QSB.RoastingSync.Messages public override void OnReceiveRemote() { - if (Value && ObjectId == -1) + if (Data && ObjectId == -1) { DebugLog.ToConsole($"Error - Null campfire supplied for start roasting event!", MessageType.Error); return; } var player = QSBPlayerManager.GetPlayer(From); - player.RoastingStick.SetActive(Value); - player.Campfire = Value + player.RoastingStick.SetActive(Data); + player.Campfire = Data ? ObjectId.GetWorldObject() : null; } diff --git a/QSB/RoastingSync/Messages/MarshmallowEventMessage.cs b/QSB/RoastingSync/Messages/MarshmallowEventMessage.cs index 667671e4..cec5a98f 100644 --- a/QSB/RoastingSync/Messages/MarshmallowEventMessage.cs +++ b/QSB/RoastingSync/Messages/MarshmallowEventMessage.cs @@ -10,7 +10,7 @@ namespace QSB.RoastingSync.Messages { internal class MarshmallowEventMessage : QSBMessage { - public MarshmallowEventMessage(MarshmallowMessageType type) => Value = type; + public MarshmallowEventMessage(MarshmallowMessageType type) => Data = type; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; @@ -23,7 +23,7 @@ namespace QSB.RoastingSync.Messages return; } - switch (Value) + switch (Data) { case MarshmallowMessageType.Burn: player.Marshmallow.Burn(); diff --git a/QSB/SatelliteSync/Messages/SatelliteProjectorMessage.cs b/QSB/SatelliteSync/Messages/SatelliteProjectorMessage.cs index 11c0dfde..85e9aeda 100644 --- a/QSB/SatelliteSync/Messages/SatelliteProjectorMessage.cs +++ b/QSB/SatelliteSync/Messages/SatelliteProjectorMessage.cs @@ -4,11 +4,11 @@ namespace QSB.SatelliteSync.Messages { internal class SatelliteProjectorMessage : QSBMessage { - public SatelliteProjectorMessage(bool usingProjector) => Value = usingProjector; + public SatelliteProjectorMessage(bool usingProjector) => Data = usingProjector; public override void OnReceiveRemote() { - if (Value) + if (Data) { SatelliteProjectorManager.Instance.RemoteEnter(); } diff --git a/QSB/SatelliteSync/Messages/SatelliteProjectorSnapshotMessage.cs b/QSB/SatelliteSync/Messages/SatelliteProjectorSnapshotMessage.cs index d3449275..dc293616 100644 --- a/QSB/SatelliteSync/Messages/SatelliteProjectorSnapshotMessage.cs +++ b/QSB/SatelliteSync/Messages/SatelliteProjectorSnapshotMessage.cs @@ -4,8 +4,8 @@ namespace QSB.SatelliteSync.Messages { internal class SatelliteProjectorSnapshotMessage : QSBMessage { - public SatelliteProjectorSnapshotMessage(bool forward) => Value = forward; + public SatelliteProjectorSnapshotMessage(bool forward) => Data = forward; - public override void OnReceiveRemote() => SatelliteProjectorManager.Instance.RemoteTakeSnapshot(Value); + public override void OnReceiveRemote() => SatelliteProjectorManager.Instance.RemoteTakeSnapshot(Data); } } \ No newline at end of file diff --git a/QSB/ShipSync/Messages/Component/ComponentRepairTickMessage.cs b/QSB/ShipSync/Messages/Component/ComponentRepairTickMessage.cs index 04fa243e..597e9840 100644 --- a/QSB/ShipSync/Messages/Component/ComponentRepairTickMessage.cs +++ b/QSB/ShipSync/Messages/Component/ComponentRepairTickMessage.cs @@ -5,8 +5,8 @@ namespace QSB.ShipSync.Messages.Component { internal class ComponentRepairTickMessage : QSBWorldObjectMessage { - public ComponentRepairTickMessage(float repairFraction) => Value = repairFraction; + public ComponentRepairTickMessage(float repairFraction) => Data = repairFraction; - public override void OnReceiveRemote() => WorldObject.RepairTick(Value); + public override void OnReceiveRemote() => WorldObject.RepairTick(Data); } } \ No newline at end of file diff --git a/QSB/ShipSync/Messages/FlyShipMessage.cs b/QSB/ShipSync/Messages/FlyShipMessage.cs index 74c8a9a7..5821644d 100644 --- a/QSB/ShipSync/Messages/FlyShipMessage.cs +++ b/QSB/ShipSync/Messages/FlyShipMessage.cs @@ -24,17 +24,17 @@ namespace QSB.ShipSync.Messages } } - private FlyShipMessage(bool flying) => Value = flying; + private FlyShipMessage(bool flying) => Data = flying; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; - public override void OnReceiveLocal() => SetCurrentFlyer(From, Value); + public override void OnReceiveLocal() => SetCurrentFlyer(From, Data); public override void OnReceiveRemote() { - SetCurrentFlyer(From, Value); + SetCurrentFlyer(From, Data); var shipCockpitController = GameObject.Find("ShipCockpitController").GetComponent(); - if (Value) + if (Data) { shipCockpitController._interactVolume.DisableInteraction(); } diff --git a/QSB/ShipSync/Messages/HatchMessage.cs b/QSB/ShipSync/Messages/HatchMessage.cs index 4355ba93..d26c41a4 100644 --- a/QSB/ShipSync/Messages/HatchMessage.cs +++ b/QSB/ShipSync/Messages/HatchMessage.cs @@ -5,13 +5,13 @@ namespace QSB.ShipSync.Messages { internal class HatchMessage : QSBMessage { - public HatchMessage(bool open) => Value = open; + public HatchMessage(bool open) => Data = open; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; public override void OnReceiveRemote() { - if (Value) + if (Data) { ShipManager.Instance.HatchController.OpenHatch(); } diff --git a/QSB/ShipSync/Messages/Hull/HullChangeIntegrityMessage.cs b/QSB/ShipSync/Messages/Hull/HullChangeIntegrityMessage.cs index 4e99330b..abe411ec 100644 --- a/QSB/ShipSync/Messages/Hull/HullChangeIntegrityMessage.cs +++ b/QSB/ShipSync/Messages/Hull/HullChangeIntegrityMessage.cs @@ -5,8 +5,8 @@ namespace QSB.ShipSync.Messages.Hull { internal class HullChangeIntegrityMessage : QSBWorldObjectMessage { - public HullChangeIntegrityMessage(float integrity) => Value = integrity; + public HullChangeIntegrityMessage(float integrity) => Data = integrity; - public override void OnReceiveRemote() => WorldObject.ChangeIntegrity(Value); + public override void OnReceiveRemote() => WorldObject.ChangeIntegrity(Data); } } \ No newline at end of file diff --git a/QSB/Tools/FlashlightTool/Messages/PlayerFlashlightMessage.cs b/QSB/Tools/FlashlightTool/Messages/PlayerFlashlightMessage.cs index c77c1b24..23b4d3f5 100644 --- a/QSB/Tools/FlashlightTool/Messages/PlayerFlashlightMessage.cs +++ b/QSB/Tools/FlashlightTool/Messages/PlayerFlashlightMessage.cs @@ -20,16 +20,16 @@ namespace QSB.Tools.FlashlightTool.Messages } } - private PlayerFlashlightMessage(bool on) => Value = on; + private PlayerFlashlightMessage(bool on) => Data = on; public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - player.FlashlightActive = Value; - player.FlashLight?.UpdateState(Value); + player.FlashlightActive = Data; + player.FlashLight?.UpdateState(Data); } public override void OnReceiveLocal() => - QSBPlayerManager.LocalPlayer.FlashlightActive = Value; + QSBPlayerManager.LocalPlayer.FlashlightActive = Data; } } \ No newline at end of file diff --git a/QSB/Tools/ProbeLauncherTool/Messages/EquipProbeLauncherMessage.cs b/QSB/Tools/ProbeLauncherTool/Messages/EquipProbeLauncherMessage.cs index c22b15bf..6a17c59c 100644 --- a/QSB/Tools/ProbeLauncherTool/Messages/EquipProbeLauncherMessage.cs +++ b/QSB/Tools/ProbeLauncherTool/Messages/EquipProbeLauncherMessage.cs @@ -36,16 +36,16 @@ namespace QSB.Tools.ProbeLauncherTool.Messages } } - private EquipProbeLauncherMessage(bool equipped) => Value = equipped; + private EquipProbeLauncherMessage(bool equipped) => Data = equipped; public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - player.ProbeLauncherEquipped = Value; - player.ProbeLauncher?.ChangeEquipState(Value); + player.ProbeLauncherEquipped = Data; + player.ProbeLauncher?.ChangeEquipState(Data); } public override void OnReceiveLocal() => - QSBPlayerManager.LocalPlayer.ProbeLauncherEquipped = Value; + QSBPlayerManager.LocalPlayer.ProbeLauncherEquipped = Data; } } \ No newline at end of file diff --git a/QSB/Tools/ProbeLauncherTool/Messages/LaunchProbeMessage.cs b/QSB/Tools/ProbeLauncherTool/Messages/LaunchProbeMessage.cs index 535c8d77..8b28b2b6 100644 --- a/QSB/Tools/ProbeLauncherTool/Messages/LaunchProbeMessage.cs +++ b/QSB/Tools/ProbeLauncherTool/Messages/LaunchProbeMessage.cs @@ -5,8 +5,8 @@ namespace QSB.Tools.ProbeLauncherTool.Messages { internal class LaunchProbeMessage : QSBWorldObjectMessage { - public LaunchProbeMessage(bool playEffects) => Value = playEffects; + public LaunchProbeMessage(bool playEffects) => Data = playEffects; - public override void OnReceiveRemote() => WorldObject.LaunchProbe(Value); + public override void OnReceiveRemote() => WorldObject.LaunchProbe(Data); } } \ No newline at end of file diff --git a/QSB/Tools/ProbeLauncherTool/Messages/PlayerRetrieveProbeMessage.cs b/QSB/Tools/ProbeLauncherTool/Messages/PlayerRetrieveProbeMessage.cs index 2b52bc87..6954a594 100644 --- a/QSB/Tools/ProbeLauncherTool/Messages/PlayerRetrieveProbeMessage.cs +++ b/QSB/Tools/ProbeLauncherTool/Messages/PlayerRetrieveProbeMessage.cs @@ -6,14 +6,14 @@ namespace QSB.Tools.ProbeLauncherTool.Messages { internal class PlayerRetrieveProbeMessage : QSBMessage { - public PlayerRetrieveProbeMessage(bool playEffects) => Value = playEffects; + public PlayerRetrieveProbeMessage(bool playEffects) => Data = playEffects; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - player.ProbeLauncher.RetrieveProbe(Value); + player.ProbeLauncher.RetrieveProbe(Data); } } } \ No newline at end of file diff --git a/QSB/Tools/ProbeLauncherTool/Messages/RetrieveProbeMessage.cs b/QSB/Tools/ProbeLauncherTool/Messages/RetrieveProbeMessage.cs index 16fdf16d..9c8a6434 100644 --- a/QSB/Tools/ProbeLauncherTool/Messages/RetrieveProbeMessage.cs +++ b/QSB/Tools/ProbeLauncherTool/Messages/RetrieveProbeMessage.cs @@ -5,8 +5,8 @@ namespace QSB.Tools.ProbeLauncherTool.Messages { internal class RetrieveProbeMessage : QSBWorldObjectMessage { - public RetrieveProbeMessage(bool playEffects) => Value = playEffects; + public RetrieveProbeMessage(bool playEffects) => Data = playEffects; - public override void OnReceiveRemote() => WorldObject.RetrieveProbe(Value); + public override void OnReceiveRemote() => WorldObject.RetrieveProbe(Data); } } \ No newline at end of file diff --git a/QSB/Tools/ProbeTool/Messages/PlayerProbeEventMessage.cs b/QSB/Tools/ProbeTool/Messages/PlayerProbeEventMessage.cs index f12ed83d..0c48a3e3 100644 --- a/QSB/Tools/ProbeTool/Messages/PlayerProbeEventMessage.cs +++ b/QSB/Tools/ProbeTool/Messages/PlayerProbeEventMessage.cs @@ -6,7 +6,7 @@ namespace QSB.Tools.ProbeTool.Messages { internal class PlayerProbeEventMessage : QSBMessage { - public PlayerProbeEventMessage(ProbeEvent probeEvent) => Value = probeEvent; + public PlayerProbeEventMessage(ProbeEvent probeEvent) => Data = probeEvent; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; @@ -19,7 +19,7 @@ namespace QSB.Tools.ProbeTool.Messages } var probe = player.Probe; - probe.HandleEvent(Value); + probe.HandleEvent(Data); } } } \ No newline at end of file diff --git a/QSB/Tools/ProbeTool/Messages/ProbeStartRetrieveMessage.cs b/QSB/Tools/ProbeTool/Messages/ProbeStartRetrieveMessage.cs index fd98af46..0711c954 100644 --- a/QSB/Tools/ProbeTool/Messages/ProbeStartRetrieveMessage.cs +++ b/QSB/Tools/ProbeTool/Messages/ProbeStartRetrieveMessage.cs @@ -6,7 +6,7 @@ namespace QSB.Tools.ProbeTool.Messages { internal class ProbeStartRetrieveMessage : QSBMessage { - public ProbeStartRetrieveMessage(float duration) => Value = duration; + public ProbeStartRetrieveMessage(float duration) => Data = duration; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; @@ -19,7 +19,7 @@ namespace QSB.Tools.ProbeTool.Messages } var probe = player.Probe; - probe.OnStartRetrieve(Value); + probe.OnStartRetrieve(Data); } } } \ No newline at end of file diff --git a/QSB/Tools/SignalscopeTool/FrequencySync/Messages/IdentifyFrequencyMessage.cs b/QSB/Tools/SignalscopeTool/FrequencySync/Messages/IdentifyFrequencyMessage.cs index f3dc7465..a01b3e73 100644 --- a/QSB/Tools/SignalscopeTool/FrequencySync/Messages/IdentifyFrequencyMessage.cs +++ b/QSB/Tools/SignalscopeTool/FrequencySync/Messages/IdentifyFrequencyMessage.cs @@ -5,14 +5,14 @@ namespace QSB.Tools.SignalscopeTool.FrequencySync.Messages { public class IdentifyFrequencyMessage : QSBMessage { - public IdentifyFrequencyMessage(SignalFrequency frequency) => Value = frequency; + public IdentifyFrequencyMessage(SignalFrequency frequency) => Data = frequency; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; public override void OnReceiveRemote() { - PlayerData.LearnFrequency(Value); - var displayMsg = $"{UITextLibrary.GetString(UITextType.NotificationNewFreq)} {AudioSignal.FrequencyToString(Value, false)}"; + PlayerData.LearnFrequency(Data); + var displayMsg = $"{UITextLibrary.GetString(UITextType.NotificationNewFreq)} {AudioSignal.FrequencyToString(Data, false)}"; var data = new NotificationData(NotificationTarget.All, displayMsg, 10f); NotificationManager.SharedInstance.PostNotification(data); } diff --git a/QSB/Tools/SignalscopeTool/FrequencySync/Messages/IdentifySignalMessage.cs b/QSB/Tools/SignalscopeTool/FrequencySync/Messages/IdentifySignalMessage.cs index 59b2cc01..256badc6 100644 --- a/QSB/Tools/SignalscopeTool/FrequencySync/Messages/IdentifySignalMessage.cs +++ b/QSB/Tools/SignalscopeTool/FrequencySync/Messages/IdentifySignalMessage.cs @@ -5,15 +5,15 @@ namespace QSB.Tools.SignalscopeTool.FrequencySync.Messages { public class IdentifySignalMessage : QSBMessage { - public IdentifySignalMessage(SignalName name) => Value = name; + public IdentifySignalMessage(SignalName name) => Data = name; public override bool ShouldReceive => QSBWorldSync.AllObjectsReady; public override void OnReceiveRemote() { - PlayerData.LearnSignal(Value); + PlayerData.LearnSignal(Data); GlobalMessenger.FireEvent("IdentifySignal"); - var displayMsg = $"{UITextLibrary.GetString(UITextType.NotificationSignalIdentified)} {AudioSignal.SignalNameToString(Value)}"; + var displayMsg = $"{UITextLibrary.GetString(UITextType.NotificationSignalIdentified)} {AudioSignal.SignalNameToString(Data)}"; var data = new NotificationData(NotificationTarget.All, displayMsg, 10f); NotificationManager.SharedInstance.PostNotification(data); } diff --git a/QSB/Tools/SignalscopeTool/Messages/PlayerSignalscopeMessage.cs b/QSB/Tools/SignalscopeTool/Messages/PlayerSignalscopeMessage.cs index b483cc83..ca2ee7ea 100644 --- a/QSB/Tools/SignalscopeTool/Messages/PlayerSignalscopeMessage.cs +++ b/QSB/Tools/SignalscopeTool/Messages/PlayerSignalscopeMessage.cs @@ -20,16 +20,16 @@ namespace QSB.Tools.SignalscopeTool.Messages } } - private PlayerSignalscopeMessage(bool equipped) => Value = equipped; + private PlayerSignalscopeMessage(bool equipped) => Data = equipped; public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - player.SignalscopeEquipped = Value; - player.Signalscope?.ChangeEquipState(Value); + player.SignalscopeEquipped = Data; + player.Signalscope?.ChangeEquipState(Data); } public override void OnReceiveLocal() => - QSBPlayerManager.LocalPlayer.SignalscopeEquipped = Value; + QSBPlayerManager.LocalPlayer.SignalscopeEquipped = Data; } } \ No newline at end of file diff --git a/QSB/Tools/TranslatorTool/Messages/PlayerTranslatorMessage.cs b/QSB/Tools/TranslatorTool/Messages/PlayerTranslatorMessage.cs index 4464cece..a9398060 100644 --- a/QSB/Tools/TranslatorTool/Messages/PlayerTranslatorMessage.cs +++ b/QSB/Tools/TranslatorTool/Messages/PlayerTranslatorMessage.cs @@ -20,16 +20,16 @@ namespace QSB.Tools.TranslatorTool.Messages } } - private PlayerTranslatorMessage(bool equipped) => Value = equipped; + private PlayerTranslatorMessage(bool equipped) => Data = equipped; public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - player.TranslatorEquipped = Value; - player.Translator?.ChangeEquipState(Value); + player.TranslatorEquipped = Data; + player.Translator?.ChangeEquipState(Data); } public override void OnReceiveLocal() => - QSBPlayerManager.LocalPlayer.TranslatorEquipped = Value; + QSBPlayerManager.LocalPlayer.TranslatorEquipped = Data; } } \ No newline at end of file diff --git a/QSB/Tools/TranslatorTool/TranslationSync/Messages/SetAsTranslatedMessage.cs b/QSB/Tools/TranslatorTool/TranslationSync/Messages/SetAsTranslatedMessage.cs index c0e0d862..76f78b15 100644 --- a/QSB/Tools/TranslatorTool/TranslationSync/Messages/SetAsTranslatedMessage.cs +++ b/QSB/Tools/TranslatorTool/TranslationSync/Messages/SetAsTranslatedMessage.cs @@ -5,8 +5,8 @@ namespace QSB.Tools.TranslatorTool.TranslationSync.Messages { internal class SetAsTranslatedMessage : QSBWorldObjectMessage { - public SetAsTranslatedMessage(int textId) => Value = textId; + public SetAsTranslatedMessage(int textId) => Data = textId; - public override void OnReceiveRemote() => WorldObject.SetAsTranslated(Value); + public override void OnReceiveRemote() => WorldObject.SetAsTranslated(Data); } } \ No newline at end of file diff --git a/QSB/TornadoSync/Messages/TornadoFormStateMessage.cs b/QSB/TornadoSync/Messages/TornadoFormStateMessage.cs index d72cee3b..c7bf17b4 100644 --- a/QSB/TornadoSync/Messages/TornadoFormStateMessage.cs +++ b/QSB/TornadoSync/Messages/TornadoFormStateMessage.cs @@ -5,8 +5,8 @@ namespace QSB.TornadoSync.Messages { public class TornadoFormStateMessage : QSBWorldObjectMessage { - public TornadoFormStateMessage(bool formState) => Value = formState; + public TornadoFormStateMessage(bool formState) => Data = formState; - public override void OnReceiveRemote() => WorldObject.FormState = Value; + public override void OnReceiveRemote() => WorldObject.FormState = Data; } } \ No newline at end of file diff --git a/QSB/TriggerSync/Messages/TriggerInitialStateMessage.cs b/QSB/TriggerSync/Messages/TriggerInitialStateMessage.cs index dd8f7e94..65287d23 100644 --- a/QSB/TriggerSync/Messages/TriggerInitialStateMessage.cs +++ b/QSB/TriggerSync/Messages/TriggerInitialStateMessage.cs @@ -12,11 +12,11 @@ namespace QSB.TriggerSync.Messages public class TriggerInitialStateMessage : QSBWorldObjectMessage { public TriggerInitialStateMessage(IEnumerable occupants) => - Value = occupants.Select(x => x.PlayerId).ToArray(); + Data = occupants.Select(x => x.PlayerId).ToArray(); public override void OnReceiveRemote() { - var serverOccupants = Value.Select(QSBPlayerManager.GetPlayer).ToList(); + var serverOccupants = Data.Select(QSBPlayerManager.GetPlayer).ToList(); foreach (var added in serverOccupants.Except(WorldObject.Occupants)) { WorldObject.Enter(added); diff --git a/QSB/TriggerSync/Messages/TriggerMessage.cs b/QSB/TriggerSync/Messages/TriggerMessage.cs index d2c1d8e1..55504c16 100644 --- a/QSB/TriggerSync/Messages/TriggerMessage.cs +++ b/QSB/TriggerSync/Messages/TriggerMessage.cs @@ -6,14 +6,14 @@ namespace QSB.TriggerSync.Messages { public class TriggerMessage : QSBWorldObjectMessage { - public TriggerMessage(bool entered) => Value = entered; + public TriggerMessage(bool entered) => Data = entered; public override void OnReceiveLocal() => OnReceiveRemote(); public override void OnReceiveRemote() { var player = QSBPlayerManager.GetPlayer(From); - if (Value) + if (Data) { WorldObject.Enter(player); } diff --git a/QSB/ZeroGCaveSync/Messages/SatelliteNodeRepairTickMessage.cs b/QSB/ZeroGCaveSync/Messages/SatelliteNodeRepairTickMessage.cs index b79beca5..306161fc 100644 --- a/QSB/ZeroGCaveSync/Messages/SatelliteNodeRepairTickMessage.cs +++ b/QSB/ZeroGCaveSync/Messages/SatelliteNodeRepairTickMessage.cs @@ -5,8 +5,8 @@ namespace QSB.ZeroGCaveSync.Messages { internal class SatelliteNodeRepairTickMessage : QSBWorldObjectMessage { - public SatelliteNodeRepairTickMessage(float repairFraction) => Value = repairFraction; + public SatelliteNodeRepairTickMessage(float repairFraction) => Data = repairFraction; - public override void OnReceiveRemote() => WorldObject.RepairTick(Value); + public override void OnReceiveRemote() => WorldObject.RepairTick(Data); } } \ No newline at end of file