2020-02-23 18:31:38 +01:00
|
|
|
|
using QSB.Messaging;
|
|
|
|
|
using UnityEngine.Networking;
|
|
|
|
|
|
|
|
|
|
namespace QSB.Animation
|
|
|
|
|
{
|
2020-08-10 14:48:40 +01:00
|
|
|
|
public class AnimTriggerMessage : MessageBase
|
2020-02-23 18:31:38 +01:00
|
|
|
|
{
|
|
|
|
|
public short TriggerId;
|
|
|
|
|
public uint SenderId;
|
2020-07-28 01:14:32 +02:00
|
|
|
|
public float Value;
|
2020-02-23 18:31:38 +01:00
|
|
|
|
|
|
|
|
|
public override void Deserialize(NetworkReader reader)
|
|
|
|
|
{
|
2020-07-28 01:14:32 +02:00
|
|
|
|
Value = reader.ReadSingle();
|
2020-02-23 18:31:38 +01:00
|
|
|
|
TriggerId = reader.ReadInt16();
|
|
|
|
|
SenderId = reader.ReadPackedUInt32();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void Serialize(NetworkWriter writer)
|
|
|
|
|
{
|
2020-07-28 01:14:32 +02:00
|
|
|
|
writer.Write(Value);
|
2020-02-23 18:31:38 +01:00
|
|
|
|
writer.Write(TriggerId);
|
|
|
|
|
writer.Write(SenderId);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|