quantum-space-buddies/QSB/Audio/Messages/PlayerAudioControllerUpdateHazardDamageMessage.cs

13 lines
487 B
C#
Raw Normal View History

2022-10-05 00:00:03 -04:00
using QSB.Messaging;
using QSB.Player;
namespace QSB.Audio.Messages;
internal class PlayerAudioControllerUpdateHazardDamageMessage : QSBMessage<(uint userID, HazardVolume.HazardType latestHazardType)>
{
public PlayerAudioControllerUpdateHazardDamageMessage((uint userID, HazardVolume.HazardType latestHazardType) data) : base(data) { }
public override void OnReceiveRemote() =>
QSBPlayerManager.GetPlayer(Data.userID)?.AudioController.SetHazardDamage(Data.latestHazardType);
}