quantum-space-buddies/QSB/ModelShip/Messages/CrashModelShipMessage.cs

17 lines
434 B
C#
Raw Normal View History

2022-08-28 04:56:28 +00:00
using QSB.Messaging;
using QSB.WorldSync;
namespace QSB.ModelShip.Messages;
internal class CrashModelShipMessage : QSBMessage
{
public CrashModelShipMessage() { }
public override void OnReceiveRemote()
{
var crashBehaviour = QSBWorldSync.GetUnityObject<ModelShipCrashBehavior>();
crashBehaviour._crashEffect.Play();
crashBehaviour.gameObject.GetComponent<OWAudioSource>().PlayOneShot(AudioType.TH_ModelShipCrash);
}
}