mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-01 03:32:38 +00:00
17 lines
555 B
C#
17 lines
555 B
C#
using QSB.Messaging;
|
|
using QSB.Player;
|
|
using QSB.WorldSync;
|
|
|
|
namespace QSB.Audio.Messages;
|
|
|
|
|
|
public class PlayerMovementAudioFootstepMessage : QSBMessage<(AudioType audioType, float pitch, uint userID)>
|
|
{
|
|
public PlayerMovementAudioFootstepMessage(AudioType audioType, float pitch, uint userID) : base((audioType, pitch, userID)) { }
|
|
|
|
public override bool ShouldReceive => QSBWorldSync.AllObjectsReady;
|
|
|
|
public override void OnReceiveRemote() =>
|
|
QSBPlayerManager.GetPlayer(Data.userID)?.AudioController?.PlayFootstep(Data.audioType, Data.pitch);
|
|
}
|