Photon Plugins API Documentation
Properties | List of all members
Photon.Hive.Plugin.SerializableGameState Class Reference

A serializable snapshot of the room's full state. More...

Properties

int ActorCounter [get, set]
 Incremental counter internally used to save the number of the last joined actor. More...
 
List< SerializableActorActorList [get, set]
 A list of all actors inside the room (active or inactive). More...
 
Dictionary< string, object > Binary [get, set]
 Binary data of the room. More...
 
bool CheckUserOnJoin [get, set]
 Activates UserId checks on joining - allowing a users to be only once in the room. Default is deactivated for backwards compatibility, but we recommend to use in future. More...
 
Dictionary< string, object > CustomProperties [get, set]
 Custom properties visible to the lobby. More...
 
bool DeleteCacheOnLeave [get, set]
 Default: false. If true, server cleans up roomcache of leaving players (their cached events get removed). More...
 
int EmptyRoomTTL [get, set]
 TTL (Time To Live) of the room, when empty (no active actors), before it gets removed from server. Unless a player joins it meanwhile. More...
 
bool IsOpen [get, set]
 Defines whether game is open. it is not possible to join to closed game. More...
 
bool IsVisible [get, set]
 Defines whether game is visible in lobby or not. More...
 
string LobbyId [get, set]
 The name of the lobby this room belongs to. More...
 
int LobbyType [get, set]
 The type of the lobby this room belongs to. More...
 
ArrayList LobbyProperties [get, set]
 List of string keys of custom room properties visible to the lobby. More...
 
byte MaxPlayers [get, set]
 Maximum of players allowed inside the room. More...
 
int PlayerTTL [get, set]
 TTL (Time To Live) of inactive actors inside the room before they get removed. More...
 
bool SuppressRoomEvents [get, set]
 Default: false. If set to true, no room events are sent to the clients on join and leave. This allows lobby-like rooms with lots of users. More...
 
int Slice [get, set]
 Cache slice index. More...
 
Dictionary< string, object > DebugInfo [get, set]
 Readable form of the room data for debug purposes. More...
 
List< ExcludedActorInfoExcludedActors [get, set]
 A list of actors removed from the room and should not rejoin. More...
 
bool PublishUserId [get, set]
 Indicates whether or not UserId of actors should be sent to each other. More...
 
List< string > ExpectedUsers [get, set]
 TBD: Not used yet. More...
 

Detailed Description

A serializable snapshot of the room's full state.

Property Documentation

int Photon.Hive.Plugin.SerializableGameState.ActorCounter
getset

Incremental counter internally used to save the number of the last joined actor.

List<SerializableActor> Photon.Hive.Plugin.SerializableGameState.ActorList
getset

A list of all actors inside the room (active or inactive).

Dictionary<string, object> Photon.Hive.Plugin.SerializableGameState.Binary
getset

Binary data of the room.

bool Photon.Hive.Plugin.SerializableGameState.CheckUserOnJoin
getset

Activates UserId checks on joining - allowing a users to be only once in the room. Default is deactivated for backwards compatibility, but we recommend to use in future.

Note: Should be active for saved games.

Dictionary<string, object> Photon.Hive.Plugin.SerializableGameState.CustomProperties
getset

Custom properties visible to the lobby.

Dictionary<string, object> Photon.Hive.Plugin.SerializableGameState.DebugInfo
getset

Readable form of the room data for debug purposes.

bool Photon.Hive.Plugin.SerializableGameState.DeleteCacheOnLeave
getset

Default: false. If true, server cleans up roomcache of leaving players (their cached events get removed).

int Photon.Hive.Plugin.SerializableGameState.EmptyRoomTTL
getset

TTL (Time To Live) of the room, when empty (no active actors), before it gets removed from server. Unless a player joins it meanwhile.

  • 12000 milliseconds.
  • Cloud threshold is 300000.
  • Default OnPremise threshold is 60000.
List<ExcludedActorInfo> Photon.Hive.Plugin.SerializableGameState.ExcludedActors
getset

A list of actors removed from the room and should not rejoin.

List<string> Photon.Hive.Plugin.SerializableGameState.ExpectedUsers
getset

TBD: Not used yet.

bool Photon.Hive.Plugin.SerializableGameState.IsOpen
getset

Defines whether game is open. it is not possible to join to closed game.

bool Photon.Hive.Plugin.SerializableGameState.IsVisible
getset

Defines whether game is visible in lobby or not.

string Photon.Hive.Plugin.SerializableGameState.LobbyId
getset

The name of the lobby this room belongs to.

ArrayList Photon.Hive.Plugin.SerializableGameState.LobbyProperties
getset

List of string keys of custom room properties visible to the lobby.

int Photon.Hive.Plugin.SerializableGameState.LobbyType
getset

The type of the lobby this room belongs to.

byte Photon.Hive.Plugin.SerializableGameState.MaxPlayers
getset

Maximum of players allowed inside the room.

int Photon.Hive.Plugin.SerializableGameState.PlayerTTL
getset

TTL (Time To Live) of inactive actors inside the room before they get removed.

bool Photon.Hive.Plugin.SerializableGameState.PublishUserId
getset

Indicates whether or not UserId of actors should be sent to each other.

int Photon.Hive.Plugin.SerializableGameState.Slice
getset

Cache slice index.

bool Photon.Hive.Plugin.SerializableGameState.SuppressRoomEvents
getset

Default: false. If set to true, no room events are sent to the clients on join and leave. This allows lobby-like rooms with lots of users.