public void SaveJoinBattleList(int listId, int position, ArmyCardItem item) { List <SoldierInfo> soldierList = DataManager.GetInstance().GetPlayerUnits().soldiers; int soldierId = soldierList.Find(p => p.metaId == item.id).metaId; SendJoinBattleListC2S(listId, position, soldierId); }
public void OpenUnitUI() { armyManTran.gameObject.SetActive(true); combatDeckTran.gameObject.SetActive(true); instituteManTran.gameObject.SetActive(false); skillDeckTran.gameObject.SetActive(false); currentClickArmyItem = null; currentClickSkillItem = null; RefreshArmyItem(); }
private void OpenInstituteUI() { armyManTran.gameObject.SetActive(false); combatDeckTran.gameObject.SetActive(false); instituteManTran.gameObject.SetActive(true); skillDeckTran.gameObject.SetActive(true); currentClickArmyItem = null; currentClickSkillItem = null; SetClickSkillProp(); SetSkillDeck(); RefreshInstituteItem(); }
private void OnArmyItemClickCallBack(ArmyCardItem item) { currentClickArmyItem = null; foreach (ArmyCardItem ite in armyCard_Items) { ite.glowImage.gameObject.SetActive(false); } if (item.armyNumber <= 0) { return; } item.glowImage.gameObject.SetActive(true); currentClickArmyItem = item; }
private void OnCombatDeckItemClickCallBack(CombatDeckCardItem item) { if (currentClickArmyItem == null) { return; } foreach (ArmyCardItem ite in armyCard_Items) { ite.glowImage.gameObject.SetActive(false); } if (currentClickArmyItem.id != item.id) { controller.SaveJoinBattleList(currentListId, item.index, currentClickArmyItem); } currentClickArmyItem = null; }