// Methods // Public interface public CPersistentPlayerData Clone() { CPersistentPlayerData clone = new CPersistentPlayerData( ID, Name ); IgnoreList.ShallowCopy( clone.IgnoreList ); return clone; }
// Construction public CGetPlayerDataPersistenceResponse( EPersistenceRequestID request_id, CPersistentPlayerData player_data ) : base(request_id, EPersistenceError.None) { PlayerData = player_data; }
private void Handle_Get_Player_Data_Request_Batch( List< CPersistenceRequest > request_list ) { foreach ( var request in request_list ) { CGetPlayerDataPersistenceRequest get_request = request as CGetPlayerDataPersistenceRequest; CPersistentPlayerData player_data = new CPersistentPlayerData( Temp_Compute_Persistence_ID( get_request.PlayerName ), get_request.PlayerName ); m_CurrentFrame.Add_Response( new CGetPlayerDataPersistenceResponse( get_request.RequestID, player_data ) ); } }
private void Register_Player_Data( CPersistentPlayerData player_data ) { if ( !m_PlayerDataByID.ContainsKey( player_data.ID ) ) { m_PlayerDataByID.Add( player_data.ID, player_data ); } }
public static void New_Player_Announce_To_Chat( CConnectedPlayer player, CPersistentPlayerData player_data, EMessageRequestID client_request_id ) { ESessionID session_id = player.SessionID; CAnnouncePlayerToChatServerRequest announce_request = new CAnnouncePlayerToChatServerRequest( session_id, player.PersistenceID, player.Name, player_data.IgnoreList ); announce_request.Handler = delegate( CResponseMessage response ) { On_Chat_Server_Announce_Response( response, session_id, client_request_id ); }; CServerMessageRouter.Send_Message_To_Chat_Server( announce_request ); }
public void Reset_Player_Data() { PlayerData = null; }
// Methods // Public interface public void On_Receive_Player_Data( CPersistentPlayerData player_data ) { PlayerData = player_data; }
// Construction public CClientHelloResponse( EMessageRequestID request_id, CPersistentPlayerData player_data ) : base(request_id) { PlayerData = player_data.Clone(); Reason = EConnectRefusalReason.None; }
private void On_Successful_Hello( CPersistentPlayerData player_data ) { CClientPersistentDataManager.Instance.On_Receive_Player_Data( player_data ); CClientPlayerInfoManager.Instance.Begin_Player_Listen( player_data.ID, EPlayerListenReason.Self ); Add_UI_Notification( new CUIScreenStateNotification( EUIScreenState.Chat_Idle ) ); }