/// <summary> /// Received a list of available cities from the login server. /// </summary> public void _OnCityList(NetworkClient Client, ProcessedPacket packet) { if (OnLoginProgress != null) { if (OnLoginStatus != null) { UIPacketHandlers.OnCityInfoResponse(packet); OnLoginProgress(new ProgressEvent(EventCodes.PROGRESS_UPDATE) { Done = 5, Total = 5 }); OnLoginStatus(new LoginEvent(EventCodes.LOGIN_RESULT) { Success = true }); } else { //TODO: Error handling... } } else { //TODO: Error handling... } }
public void _OnCityServerOffline(NetworkClient Client, ProcessedPacket Packet) { UIPacketHandlers.OnCityServerOffline(Client, Packet); if (OnCityServerOffline != null) { OnCityServerOffline(); } }
/// <summary> /// Received token from login server. /// </summary> public void _OnCityToken(NetworkClient Client, ProcessedPacket Packet) { if (OnCityToken != null) { UIPacketHandlers.OnCityToken(Client, Packet); OnCityToken(PlayerAccount.CurrentlyActiveSim.ResidingCity); } else { //TODO: Error handling... } }
public void _OnLoginNotifyCity(NetworkClient Client, ProcessedPacket packet) { if (OnLoginNotifyCity != null) { UIPacketHandlers.OnLoginNotifyCity(Client, packet); OnLoginNotifyCity(); } else { //TODO: Error handling... } }
public void _OnPlayerJoinedSession(NetworkClient Client, ProcessedPacket Packet) { LotTileEntry TileEntry = UIPacketHandlers.OnPlayerJoinedSession(Client, Packet); if (TileEntry.lotid != 0) { if (OnPlayerJoined != null) { OnPlayerJoined(TileEntry); } } }
public void _OnCharacterCreationStatus(NetworkClient Client, ProcessedPacket Packet) { if (OnCharacterCreationStatus != null) { CharacterCreationStatus CCStatus = UIPacketHandlers.OnCharacterCreationStatus(Client, Packet); OnCharacterCreationStatus(CCStatus); } else { //TODO: Error handling... } }
public void _OnRetireCharacterStatus(NetworkClient Client, ProcessedPacket Packet) { if (OnCharacterRetirement != null) { string GUID = UIPacketHandlers.OnCharacterRetirement(Client, Packet); OnCharacterRetirement(GUID); } else { //TODO: Error handling... } }
/// <summary> /// Lot purchase was successful, server sent correct amount of money for player's character's account. /// </summary> public void _OnLotPurchaseSuccessful(NetworkClient Client, ProcessedPacket Packet) { int Money = UIPacketHandlers.OnLotPurchaseSuccessful(Client, Packet); if (OnLotPurchaseSuccessful != null) { OnLotPurchaseSuccessful(Money); } else { //TODO: Error handling... } }
/// <summary> /// City server sent the cost of a lot. /// </summary> public void _OnLotCost(NetworkClient Client, ProcessedPacket Packet) { LotTileEntry Entry = UIPacketHandlers.OnLotCostResponse(Client, Packet); if (OnLotCost != null) { OnLotCost(Entry); } else { //TODO: Error handling... } }
public void _OnNewCity(NetworkClient Client, ProcessedPacket Packet) { UIPacketHandlers.OnNewCityServer(Client, Packet); if (OnNewCityServer != null) { OnNewCityServer(); } else { //TODO: Error handling... } }
/// <summary> /// Progressing to city server (received from login server). /// </summary> public void _OnCharacterCreationProgress(NetworkClient Client, ProcessedPacket Packet) { Log.LogThis("Received OnCharacterCreationProgress!", eloglevel.info); if (OnCharacterCreationProgress != null) { CharacterCreationStatus CCStatus = UIPacketHandlers.OnCharacterCreationProgress(Client, Packet); OnCharacterCreationProgress(CCStatus); } else { //TODO: Error handling... } }
/// <summary> /// Response from city server. /// </summary> public void _OnCityTokenResponse(NetworkClient Client, ProcessedPacket Packet) { Log.LogThis("Received OnCityTokenResponse!", eloglevel.info); if (OnCityTransferProgress != null) { CityTransferStatus Status = UIPacketHandlers.OnCityTokenResponse(Client, Packet); OnCityTransferProgress(Status); } else { //TODO: Error handling... } }
public void _OnLoginFailureCity(NetworkClient Client, ProcessedPacket Packet) { Log.LogThis("Received OnLoginFailureCity!", eloglevel.info); if (OnLoginFailureCity != null) { UIPacketHandlers.OnLoginFailResponse(ref NetworkFacade.Client, Packet); OnLoginFailureCity(); } else { //TODO: Error handling... } }
public void _OnLoginSuccess(NetworkClient Client, ProcessedPacket packet) { if (OnLoginProgress != null) { UIPacketHandlers.OnLoginSuccessResponse(ref NetworkFacade.Client, packet); OnLoginProgress(new ProgressEvent(EventCodes.PROGRESS_UPDATE) { Done = 3, Total = 5 }); } else { //TODO: Error handling... } }
public void _OnTimeOfDay(NetworkClient Client, ProcessedPacket Packet) { DateTime CurrentTime = UIPacketHandlers.OnNewTimeOfDay(Client, Packet); NetworkFacade.ServerTime = CurrentTime; if (OnNewTimeOfDay != null) { OnNewTimeOfDay(CurrentTime); } else { //TODO: Error handling... } }
/// <summary> /// Received list of characters for account from login server. /// </summary> public void _OnCharacterList(NetworkClient Client, ProcessedPacket packet) { if (OnLoginProgress != null) { OnLoginProgress(new ProgressEvent(EventCodes.PROGRESS_UPDATE) { Done = 4, Total = 5 }); UIPacketHandlers.OnCharacterInfoResponse(packet, NetworkFacade.Client); } else { //TODO: Error handling... } }
public void _OnInvalidVersion(NetworkClient Client, ProcessedPacket packet) { if (OnLoginStatus != null) { UIPacketHandlers.OnInvalidVersionResponse(ref NetworkFacade.Client, packet); OnLoginStatus(new LoginEvent(EventCodes.LOGIN_RESULT) { Success = false, VersionOK = false }); } else { //TODO: Error handling... } }
/// <summary> /// An attempt to buy a lot failed, usually because player was out of money. /// </summary> public void _OnLotBuyFailed(NetworkClient Client, ProcessedPacket Packet) { UIPacketHandlers.OnLotPurchaseFailed(Client, Packet); if (OnLotPurchaseFailed != null) { OnLotPurchaseFailed(new TransactionEvent(EventCodes.TRANSACTION_RESULT) { Success = false }); } else { //TODO: Error handling... } }
public void _OnPlayerRecvdLetter(NetworkClient Client, ProcessedPacket Packet) { UIPacketHandlers.OnPlayerReceivedLetter(Client, Packet); }
public void _OnPlayerLeftSession(NetworkClient Client, ProcessedPacket Packet) { UIPacketHandlers.OnPlayerLeftSession(Client, Packet); }