RoomState
Defined in: packages/engine/src/stores/room.ts:24
Properties
Section titled “Properties”| Property | Type | Description |
|---|---|---|
bytesPerSecond |
number |
What those messages weighed over the last second. |
correctionMetres |
number |
The largest of those corrections, in metres. |
corrections |
number |
Times the room corrected her own hero over the last second: each a move the room ended more than correctionTolerance from where the client had it end. |
edits |
boolean |
Whether the room takes a devtools edit; false until the welcome says so, and once its socket closes. |
heroId |
string | null |
The client’s own hero, by the id the room’s dump keys her under; null until the welcome. |
interpolationMilliseconds |
number |
How far behind the room’s last snapshot the streamed entities are drawn, as the pings set it: one send interval before the first answer. |
players |
number |
Players in the room: the streamed entities with a name. |
roundTripMilliseconds |
number |
The time a ping takes to the room and back, the mean of the last few; 0 before the first answer. |
sendEdit |
(edit) => void |
Sends the room a devtools edit: the loop’s socket, which drops it until open. |
sendShot |
(shot) => void |
Sends the room a shot, naming the room’s step this page draws the streamed entities at: the loop’s socket, which drops it until open, and until the room has answered a ping since its welcome, since the clock names no step before then. |
snapshotsPerSecond |
number |
The room’s snapshots and deltas applied over the last second. |
status |
RoomStatus |
- |
stepMilliseconds |
number |
Milliseconds one step took, on average over the last second. |