public void Login(string email, string password, Action <PlayerActionResponse> onSuccess) { var body = new LoginRequest { email = email, password = password }; serverAPI.DoPost("/auth/login", body, onSuccess); }
private void StartExpedition() { Debug.Log("Start Button clicked"); loading = true; startButton.interactable = false; startButtonText.enabled = false; loadingIndicator.enabled = true; var team = new Team { type = TEAM_TYPE, vehicleId = vehicleAvatarPrefab.Vehicle.id, hero1Id = hero1?.id, hero2Id = hero2?.id, hero3Id = hero3?.id, hero4Id = hero4?.id }; serverAPI.DoPost($"/expedition/{expedition.id}/start", team, response => { Destroy(gameObject); }); }
public void ClaimDaily(int day, Action <PlayerActionResponse> onSuccess = null) { serverAPI.DoPost($"/oddjob/daily/{day}", null, onSuccess); }
public void StartMission(StartMissionRequest request, Action <PlayerActionResponse> onSuccess = null) { serverAPI.DoPost("/battle/mission", request, onSuccess); }
public void ChangeMapTo(long mapId, Action <PlayerActionResponse> onSuccess = null) { var mapKnown = PlayerMaps.Find(m => m.mapId == mapId) != null; serverAPI.DoPost($"/map/{mapId}/{(mapKnown ? "current" : "discover")}", null, onSuccess); }
public void ClaimTask(TaskCluster cluster, Action <PlayerActionResponse> onSuccess = null) { serverAPI.DoPost($"/tasks/claim/{cluster.id}", null, onSuccess); }
public void Claim(InboxMessage message, Action <PlayerActionResponse> onSuccess = null) { serverAPI.DoPost($"/inbox/claim/{message.id}", null, onSuccess); }
public void FinishPlayerExpedition(PlayerExpedition playerExpedition, Action <PlayerActionResponse> onSuccess = null) { serverAPI.DoPost($"/expedition/{playerExpedition.id}/finish", null, onSuccess); }
public void Breakdown(List <long> gearIds, Action <PlayerActionResponse> onSuccess = null) { serverAPI.DoPost("/forge/breakdown", new Breakdown { gearIds = gearIds, silent = true }, onSuccess); }