Photon Server API Documentation v5.0RC1

Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Properties | List of all members
Photon.LoadBalancing.MasterServer.GameApplication Class Reference
Inheritance diagram for Photon.LoadBalancing.MasterServer.GameApplication:

Public Member Functions

 GameApplication (string applicationId, string version, LoadBalancer< GameServerContext > loadBalancer)
 
virtual void OnClientConnected (MasterClientPeer peer)
 
virtual void OnClientDisconnected (MasterClientPeer peer)
 
bool GetOrCreateGame (string gameId, AppLobby lobby, byte maxPlayer, GameServerContext gameServer, out GameState gameState, out ErrorCode errorCode, out string errorMsg)
 
virtual bool TryCreateGame (string gameId, AppLobby lobby, byte maxPlayer, GameServerContext gameServer, out GameState gameState, out ErrorCode errorCode, out string errorMsg)
 
bool TryGetGame (string gameId, out GameState gameState)
 
void OnGameUpdateOnGameServer (UpdateGameEvent updateGameEvent, GameServerContext gameServer)
 
void OnGameRemovedOnGameServer (GameServerContext context, string gameId, byte removeReason)
 
bool RemoveGameByName (string gameId)
 
virtual void OnGameServerRemoved (GameServerContext gameServerContext)
 
void Dispose ()
 
virtual void OnBeginReplication (GameServerContext gameServerContext)
 
virtual void OnFinishReplication (GameServerContext gameServerContext)
 
virtual void OnStopReplication (GameServerContext gameServerContext)
 
virtual void OnSendChangedGameList (Hashtable gameList)
 
virtual void OnSendGameList (Hashtable gameList)
 
virtual void IncrementLobbiesCount ()
 
virtual void DecrementLobbiesCount ()
 
void AddToExcludedActors (string userId)
 
void RemoveFromExcludedActors (string userId)
 
bool IsActorExcluded (string userId)
 

Public Attributes

readonly string ApplicationId
 
readonly string Version
 
readonly LoadBalancer< GameServerContextLoadBalancer
 
readonly PlayerCache PlayerOnlineCache
 

Protected Member Functions

 GameApplication (PoolFiber fiber, PoolFiber playerCacheFiber, string applicationId, string version, LoadBalancer< GameServerContext > loadBalancer)
 
virtual void Dispose (bool dispose)
 

Protected Attributes

readonly PoolFiber fiber
 

Properties

LobbyFactory LobbyFactory [get, protected set]
 
LobbyStatsPublisher LobbyStatsPublisher [get, protected set]
 
PluginTraits PluginTraits [get, protected set]
 
int LobbiesCount [get]
 
int GamesCount [get]
 
LogCountGuard WrongJoinActivityGuard = new LogCountGuard(new TimeSpan(1, 0, 0)) [get]
 

Constructor & Destructor Documentation

◆ GameApplication() [1/2]

Photon.LoadBalancing.MasterServer.GameApplication.GameApplication ( string  applicationId,
string  version,
LoadBalancer< GameServerContext loadBalancer 
)
inline

◆ GameApplication() [2/2]

Photon.LoadBalancing.MasterServer.GameApplication.GameApplication ( PoolFiber  fiber,
PoolFiber  playerCacheFiber,
string  applicationId,
string  version,
LoadBalancer< GameServerContext loadBalancer 
)
inlineprotected

Member Function Documentation

◆ AddToExcludedActors()

void Photon.LoadBalancing.MasterServer.GameApplication.AddToExcludedActors ( string  userId)
inline

◆ DecrementLobbiesCount()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.DecrementLobbiesCount ( )
inlinevirtual

◆ Dispose() [1/2]

void Photon.LoadBalancing.MasterServer.GameApplication.Dispose ( )
inline

◆ Dispose() [2/2]

virtual void Photon.LoadBalancing.MasterServer.GameApplication.Dispose ( bool  dispose)
inlineprotectedvirtual

◆ GetOrCreateGame()

bool Photon.LoadBalancing.MasterServer.GameApplication.GetOrCreateGame ( string  gameId,
AppLobby  lobby,
byte  maxPlayer,
GameServerContext  gameServer,
out GameState  gameState,
out ErrorCode  errorCode,
out string  errorMsg 
)
inline

◆ IncrementLobbiesCount()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.IncrementLobbiesCount ( )
inlinevirtual

◆ IsActorExcluded()

bool Photon.LoadBalancing.MasterServer.GameApplication.IsActorExcluded ( string  userId)
inline

◆ OnBeginReplication()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.OnBeginReplication ( GameServerContext  gameServerContext)
inlinevirtual

◆ OnClientConnected()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.OnClientConnected ( MasterClientPeer  peer)
inlinevirtual

◆ OnClientDisconnected()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.OnClientDisconnected ( MasterClientPeer  peer)
inlinevirtual

◆ OnFinishReplication()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.OnFinishReplication ( GameServerContext  gameServerContext)
inlinevirtual

◆ OnGameRemovedOnGameServer()

void Photon.LoadBalancing.MasterServer.GameApplication.OnGameRemovedOnGameServer ( GameServerContext  context,
string  gameId,
byte  removeReason 
)
inline

◆ OnGameServerRemoved()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.OnGameServerRemoved ( GameServerContext  gameServerContext)
inlinevirtual

◆ OnGameUpdateOnGameServer()

void Photon.LoadBalancing.MasterServer.GameApplication.OnGameUpdateOnGameServer ( UpdateGameEvent  updateGameEvent,
GameServerContext  gameServer 
)
inline

◆ OnSendChangedGameList()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.OnSendChangedGameList ( Hashtable  gameList)
inlinevirtual

◆ OnSendGameList()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.OnSendGameList ( Hashtable  gameList)
inlinevirtual

◆ OnStopReplication()

virtual void Photon.LoadBalancing.MasterServer.GameApplication.OnStopReplication ( GameServerContext  gameServerContext)
inlinevirtual

◆ RemoveFromExcludedActors()

void Photon.LoadBalancing.MasterServer.GameApplication.RemoveFromExcludedActors ( string  userId)
inline

◆ RemoveGameByName()

bool Photon.LoadBalancing.MasterServer.GameApplication.RemoveGameByName ( string  gameId)
inline

◆ TryCreateGame()

virtual bool Photon.LoadBalancing.MasterServer.GameApplication.TryCreateGame ( string  gameId,
AppLobby  lobby,
byte  maxPlayer,
GameServerContext  gameServer,
out GameState  gameState,
out ErrorCode  errorCode,
out string  errorMsg 
)
inlinevirtual

◆ TryGetGame()

bool Photon.LoadBalancing.MasterServer.GameApplication.TryGetGame ( string  gameId,
out GameState  gameState 
)
inline

Member Data Documentation

◆ ApplicationId

readonly string Photon.LoadBalancing.MasterServer.GameApplication.ApplicationId

◆ fiber

readonly PoolFiber Photon.LoadBalancing.MasterServer.GameApplication.fiber
protected

◆ LoadBalancer

readonly LoadBalancer<GameServerContext> Photon.LoadBalancing.MasterServer.GameApplication.LoadBalancer

◆ PlayerOnlineCache

readonly PlayerCache Photon.LoadBalancing.MasterServer.GameApplication.PlayerOnlineCache

◆ Version

readonly string Photon.LoadBalancing.MasterServer.GameApplication.Version

Property Documentation

◆ GamesCount

int Photon.LoadBalancing.MasterServer.GameApplication.GamesCount
get

◆ LobbiesCount

int Photon.LoadBalancing.MasterServer.GameApplication.LobbiesCount
get

◆ LobbyFactory

LobbyFactory Photon.LoadBalancing.MasterServer.GameApplication.LobbyFactory
getprotected set

◆ LobbyStatsPublisher

LobbyStatsPublisher Photon.LoadBalancing.MasterServer.GameApplication.LobbyStatsPublisher
getprotected set

◆ PluginTraits

PluginTraits Photon.LoadBalancing.MasterServer.GameApplication.PluginTraits
getprotected set

◆ WrongJoinActivityGuard

LogCountGuard Photon.LoadBalancing.MasterServer.GameApplication.WrongJoinActivityGuard = new LogCountGuard(new TimeSpan(1, 0, 0))
get