Struct screeps_api::websocket::types::room::RoomUpdate
[−]
[src]
pub struct RoomUpdate { pub game_time: Option<u32>, pub info: RoomUpdateInfo, pub objects: Vec<(String, Value)>, pub flags: Vec<Flag>, pub visual: Option<String>, pub users: Option<HashMap<String, RoomUpdateUserInfo>>, // some fields omitted }
Update for detailed room information.
Fields
game_time: Option<u32>
The game time when this update was created.
info: RoomUpdateInfo
Information on the room "mode".
objects: Vec<(String, Value)>
All room objects in the room, represented as serde_json::Value.
This would be parsed into a concrete enum for each type, but room updates by their nature are incremental - and this includes the "type" field.
These values can be applied as updates to the RoomObject
type.
flags: Vec<Flag>
All of the subscribed user's flags in this room.
This will always be present when there are flags, even if no flags have changed.
visual: Option<String>
The logged in user's visuals for this room.
Represented by a series of json objects separated by \n
.
TODO: parse this further.
users: Option<HashMap<String, RoomUpdateUserInfo>>
Detailed information on all users that have things in this room.
Trait Implementations
impl Clone for RoomUpdate
[src]
fn clone(&self) -> RoomUpdate
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more