24 lines
508 B
C#
Raw Normal View History

2021-12-24 21:14:23 -08:00
using QSB.Messaging;
using QSB.WorldSync;
2021-06-20 10:17:32 +01:00
using QuantumUNET.Transport;
namespace QSB.ShipSync.Messages
2021-06-20 10:17:32 +01:00
{
2021-12-24 21:14:23 -08:00
internal abstract class RepairTickMessage<T> : QSBWorldObjectMessage<T> where T: IWorldObject
2021-06-20 10:17:32 +01:00
{
2021-12-24 21:14:23 -08:00
protected float RepairFraction;
2021-06-20 10:17:32 +01:00
public override void Serialize(QNetworkWriter writer)
{
base.Serialize(writer);
2021-12-24 21:14:23 -08:00
writer.Write(RepairFraction);
2021-06-20 10:17:32 +01:00
}
2021-12-24 20:07:50 -08:00
public override void Deserialize(QNetworkReader reader)
{
base.Deserialize(reader);
2021-12-24 21:14:23 -08:00
RepairFraction = reader.ReadSingle();
2021-12-24 20:07:50 -08:00
}
2021-06-20 10:17:32 +01:00
}
}