public void CalculateExchangeAllForCoins(IBaseNetworkErrorHandler errorHandler)
    {
        APICall <CalculateExchangeForCoinsOperation> aPICall = clubPenguinClient.RewardApi.CalculateExchangeAllForCoins();

        aPICall.OnResponse += onCalculateExchangeAllForCoins;
        aPICall.OnError    += delegate(CalculateExchangeForCoinsOperation o, HttpResponse response)
        {
            NetworkErrorService.OnError(response, errorHandler);
        };
        aPICall.Execute();
    }
    public void GetLocalPlayerData(IBaseNetworkErrorHandler errorHandler)
    {
        APICall <GetLocalPlayerDataOperation> localPlayerData = clubPenguinClient.PlayerApi.GetLocalPlayerData();

        localPlayerData.OnResponse += localPlayerDataReturned;
        localPlayerData.OnError    += delegate(GetLocalPlayerDataOperation o, HttpResponse response)
        {
            Service.Get <EventDispatcher>().DispatchEvent(default(PlayerStateServiceErrors.PlayerProfileError));
            NetworkErrorService.OnError(response, errorHandler);
        };
        localPlayerData.Execute();
    }
Esempio n. 3
0
 private void onPostRoomPlayersError(PostRoomPlayersOperation operation, HttpResponse response)
 {
     Log.LogNetworkErrorFormatted(this, "onPostRoomPlayersError, status: {0}, body: {1}", response.StatusCode, response.Text);
     NetworkErrorService.OnError(response, errorHandler, onPostRoomPlayersErrorMapper);
 }
Esempio n. 4
0
 private void onFishingCastError(FishingCastOperation operation, HttpResponse response)
 {
     NetworkErrorService.OnError(response, errorHandler, onFishingCastErrorMapper);
 }
Esempio n. 5
0
 protected void handleCPResponseError(HttpResponse httpResponse)
 {
     NetworkErrorService.dispatchErrorEvent(httpResponse);
 }
 private void onRoomsFoundToJoinError(GetRoomsOperation operation, HttpResponse response)
 {
     NetworkErrorService.OnError(response, errorHandler);
 }