EntityStatistic
A class in Root.Township, Alta.Profiling.Networking.
Network profiling stats for one entity: bytes sent, split by entity message type and by behaviour. Used by the networking profiler.
- Listed in Networking and servers
- Inherits or implements
NetworkingStatistic - Derived types
EntityStatistics
Constructors
| Member | What it is |
|---|---|
EntityStatistic(string name) | Creates an EntityStatistic from name. |
Fields
4 private and internal fields
| Member | What it is |
|---|---|
private SerializedBehaviourStatistics behaviourStatistics | Bytes sent per behaviour on this entity. Backing field for BehaviourStatistics. |
private string entityName | Name of the entity being measured. Backing field for EntityName. |
private bool isExpanded | Whether the entry is expanded in the profiler view. |
private EntityMessageStatistics messageStatistics | Bytes sent per entity message type. Backing field for MessageStatistics. |
Properties
| Member | What it is |
|---|---|
SerializedBehaviourStatistics BehaviourStatistics { get; } | Byte counts per serialized behaviour name. |
string EntityName { get; } | The name this statistic was created with. |
EntityMessageStatistics MessageStatistics { get; } | Byte counts per entity message type. |
Methods
| Member | What it is |
|---|---|
override string GetSummary(float statisticDuration) | A one-line summary with the entity name padded to 60 characters, then the base stats. |
void RegisterBehaviourSend(string behaviourName, int byteCount) | Records bytes sent by a named behaviour of this entity. |
void RegisterMessageSend(EntityMessageType messageType, int byteCount) | Records bytes sent for one entity message type. |
override void ResetStatisticTotals() | Resets the totals, including the per message and per behaviour ones. |
override void UpdateValuePerFrame() | Rolls the per frame byte totals, including the per message and per behaviour ones. |
override void UpdateValuePerLastSecond() | Rolls the last second byte totals, including the per message and per behaviour ones. |
Used in
Members of other types that take, return or hold a EntityStatistic: