public TaskBase RequestWorldStartDataLogic() { NormalTask normalTask = new NormalTask(delegate() { this.IsBattleRecoverable = false; this.isRecoverSuccessWebAPI = false; ClassSingleton <QuestData> .Instance.RespDataWD_DungeonStart = null; return(null); }); GameWebAPI.WorldStartDataLogic request = new GameWebAPI.WorldStartDataLogic { OnReceived = delegate(GameWebAPI.ReceiveQuestResume response) { if (response.startId != null) { this.isRecoverSuccessWebAPI = true; ClassSingleton <QuestData> .Instance.RespDataWD_DungeonStart = response; string text = string.Empty; DkLog.W("response.userDungeonTicketId : " + response.userDungeonTicketId, false); if (string.IsNullOrEmpty(response.userDungeonTicketId)) { string @string = PlayerPrefs.GetString("userDungeonTicketId", string.Empty); if (!string.IsNullOrEmpty(@string)) { text = @string; DkLog.W("ticketid : " + text, false); } PlayerPrefs.SetString("userDungeonTicketId", string.Empty); } else { text = response.userDungeonTicketId; } DkLog.W("SetRetryData(response.worldDungeonId, ticketid) : " + text, false); this.SetRetryData(response.worldDungeonId, text); } } }; normalTask.Add(new APIRequestTask(request, true)); normalTask.Add(new NormalTask(delegate() { if (this.CheckSaveFile()) { return(this.CheckJsonBySaveData()); } this.ValidateForPopup(false); return(null); })); return(normalTask); }
protected virtual void ServerRequest() { NormalTask normalTask = new NormalTask(APIUtil.Instance().RequestHomeData()); normalTask.Add(new NormalTask(new Func <IEnumerator>(this.StartEvent))); base.StartCoroutine(normalTask.Run(null, null, null)); }