quantum-space-buddies/QSB/TimeSync/Messages/SetSecondsRemainingMessage.cs
2022-08-14 16:35:19 -07:00

14 lines
403 B
C#

using QSB.Messaging;
using QSB.Patches;
namespace QSB.TimeSync.Messages;
/// <summary>
/// sent from non-host to host
/// </summary>
public class SetSecondsRemainingMessage : QSBMessage<float>
{
public SetSecondsRemainingMessage(float secondsRemaining) : base(secondsRemaining) => To = 0;
public override void OnReceiveRemote() => QSBPatch.RemoteCall(() => TimeLoop.SetSecondsRemaining(Data));
}