mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-09 03:40:46 +00:00
27 lines
570 B
C#
27 lines
570 B
C#
namespace QuantumUNET.Messages
|
|
{
|
|
internal class QSBAnimationParametersMessage : QSBMessageBase
|
|
{
|
|
public QSBNetworkInstanceId netId;
|
|
public byte[] parameters;
|
|
|
|
public override void Deserialize(QSBNetworkReader reader)
|
|
{
|
|
netId = reader.ReadNetworkId();
|
|
parameters = reader.ReadBytesAndSize();
|
|
}
|
|
|
|
public override void Serialize(QSBNetworkWriter writer)
|
|
{
|
|
writer.Write(netId);
|
|
if (parameters == null)
|
|
{
|
|
writer.WriteBytesAndSize(parameters, 0);
|
|
}
|
|
else
|
|
{
|
|
writer.WriteBytesAndSize(parameters, parameters.Length);
|
|
}
|
|
}
|
|
}
|
|
} |