mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-11 00:52:19 +00:00
26 lines
661 B
C#
26 lines
661 B
C#
using QSB.WorldSync;
|
|
using UnityEngine.Networking;
|
|
|
|
namespace QSB.Messaging
|
|
{
|
|
public class WorldObjectMessage : PlayerMessage
|
|
{
|
|
public SyncObjects ObjectType { get; set; }
|
|
public int ObjectID { get; set; }
|
|
|
|
public override void Deserialize(NetworkReader reader)
|
|
{
|
|
base.Deserialize(reader);
|
|
ObjectType = (SyncObjects)reader.ReadInt32();
|
|
ObjectID = reader.ReadInt32();
|
|
}
|
|
|
|
public override void Serialize(NetworkWriter writer)
|
|
{
|
|
base.Serialize(writer);
|
|
writer.Write((int)ObjectType);
|
|
writer.Write(ObjectID);
|
|
}
|
|
}
|
|
}
|