rename PlayerSetIlluminatedMessage to SetPlayerIlluminatedMessage

This commit is contained in:
Mister_Nebula 2022-07-24 13:12:14 +01:00
parent 6b786b5828
commit e86da661b9
2 changed files with 6 additions and 6 deletions

View File

@ -3,9 +3,9 @@ using QSB.Player;
namespace QSB.EchoesOfTheEye.LightSensorSync.Messages;
internal class PlayerSetIlluminatedMessage : QSBMessage<(uint playerId, bool illuminated)>
internal class SetPlayerIlluminatedMessage : QSBMessage<(uint playerId, bool illuminated)>
{
public PlayerSetIlluminatedMessage(uint playerId, bool illuminated) : base((playerId, illuminated)) { }
public SetPlayerIlluminatedMessage(uint playerId, bool illuminated) : base((playerId, illuminated)) { }
public override void OnReceiveLocal() => OnReceiveRemote();
public override void OnReceiveRemote() =>

View File

@ -69,7 +69,7 @@ internal class LightSensorPatches : QSBPatch
if (isPlayerLightSensor)
{
qsbPlayerLightSensor._locallyIlluminated = true;
new PlayerSetIlluminatedMessage(qsbPlayerLightSensor.PlayerId, true).Send();
new SetPlayerIlluminatedMessage(qsbPlayerLightSensor.PlayerId, true).Send();
}
else
{
@ -117,7 +117,7 @@ internal class LightSensorPatches : QSBPatch
if (qsbPlayerLightSensor._locallyIlluminated)
{
qsbPlayerLightSensor._locallyIlluminated = false;
new PlayerSetIlluminatedMessage(qsbPlayerLightSensor.PlayerId, false).Send();
new SetPlayerIlluminatedMessage(qsbPlayerLightSensor.PlayerId, false).Send();
}
}
else
@ -185,12 +185,12 @@ internal class LightSensorPatches : QSBPatch
if (!locallyIlluminated && qsbPlayerLightSensor._locallyIlluminated)
{
qsbPlayerLightSensor._locallyIlluminated = true;
new PlayerSetIlluminatedMessage(qsbPlayerLightSensor.PlayerId, true).Send();
new SetPlayerIlluminatedMessage(qsbPlayerLightSensor.PlayerId, true).Send();
}
else if (locallyIlluminated && !qsbPlayerLightSensor._locallyIlluminated)
{
qsbPlayerLightSensor._locallyIlluminated = false;
new PlayerSetIlluminatedMessage(qsbPlayerLightSensor.PlayerId, false).Send();
new SetPlayerIlluminatedMessage(qsbPlayerLightSensor.PlayerId, false).Send();
}
}
else