Bring legacy CultNet into the schema-v0 fold

This commit is contained in:
Meta Vens 2026-05-06 11:50:10 +01:00
commit 0277ca79d9
31 changed files with 2635 additions and 6 deletions

View file

@ -18,5 +18,16 @@ namespace GameCult.Networking
{
peer.Send(MessageSerialization.Serialize(message), DeliveryMethod.ReliableOrdered);
}
/// <summary>
/// Serializes and sends a modern CultNet schema-v0 message using reliable ordered delivery.
/// </summary>
/// <typeparam name="T">The concrete schema-v0 message type.</typeparam>
/// <param name="peer">The peer to send through.</param>
/// <param name="message">The schema-v0 message to serialize and send.</param>
public static void SendCultNet<T>(this NetPeer peer, T message) where T : ICultNetSchemaMessage
{
peer.Send(CultNetSchemaMessageSerialization.Serialize(message), DeliveryMethod.ReliableOrdered);
}
}
}