Skip to main content

SceneEntityMessage

A static class in Root.Township, Alta.Networking.

Writes or reads which entity a message is about, by identifier. Other messages such as MoveMessage and DestroyMessage start with it.

Fields​

2 private and internal fields
MemberWhat it is
private static INetworkEntity entityBacking field for Entity.
private static uint entityIdentifierBacking field for EntityIdentifier.

Properties​

MemberWhat it is
static INetworkEntity Entity { get; }The entity of the current message; on read, looked up in the current scene (null if not spawned).
static uint EntityIdentifier { get; }The identifier of the current message's entity, 0 for none.

Methods​

MemberWhat it is
static void Serialize(IConnection connection, Stream stream)Writes or reads the identifier and, on read, looks up the entity.
static void Set(INetworkEntity entity)Sets the entity for the next message.