void Display_wer(List <RowEquipment> data, PackageController controller) { this.controller = controller; transform.DeleteAllChild(); for (int i = 0; i < data.Count; i++) { if (controller.EquipPos == "W") { if (data[i].type == 1) { GameObject cell = PrefabsTwo.Load("Prefabs/Wearequip", transform); cell.GetComponent <EquipCellView>().Display(data[i], controller); } } else { if (data[i].type == 0) { GameObject cell = PrefabsTwo.Load("Prefabs/Wearequip", transform); cell.GetComponent <EquipCellView>().Display(data[i], controller); } } } }
public void SettingClick() { ButtonSound.ButtonClickPlay(); PrefabsTwo.LoadUI("Prefabs/setting"); Destroy(gameObject); }
public void Onclick() { bool isOnTeam; if (controller.pos != 3) { isOnTeam = TeamModel.CheckIsOnTeamByHeroId(heroInfo); } else { isOnTeam = TeamModel.CheckIsOnTeamByPID(heroInfo); } if (isOnTeam) { //Instantiate(Resources.Load<GameObject>("Prefab/WarringMessage"),GameObject.Find("Canvas").transform); PrefabsTwo.Alert("该英雄在编队中,无法选中", null); return; } controller.selectHeroInfo = heroInfo; controller.SelectNum.text = "1"; for (int i = 0; i < transform.parent.childCount; i++) { if (transform.parent.GetChild(i).name.Substring(0, 9) == "LevelTeam") { continue; } transform.parent.GetChild(i).Find("Selected").gameObject.SetActive(false); } transform.Find("Selected").gameObject.SetActive(true); }
/// <summary> /// 返回建造页面 /// </summary> public void BackToBuild() { ButtonSound.ButtonClickPlay(); GameObject go = PrefabsTwo.LoadUI("Prefabs/Lottery"); Destroy(gameObject); }
public void OpenToRetire() { ButtonSound.ButtonClickPlay(); GameObject go = PrefabsTwo.LoadUI("Prefabs/RetireSelect"); go.GetComponent <FormationSelectController>().pos = 3; Destroy(gameObject); }
/// <summary> /// 返回编队页面 /// </summary> public void BackToFormation() { ButtonSound.ButtonClickPlay(); GameObject go = PrefabsTwo.LoadUI("Prefabs/FormationMain"); go.GetComponent <FormationMenuController>().type = type; Destroy(gameObject); }
public void EditFormation(RowHeroDate heroInfo, int type) { this.type = type; GameObject go = PrefabsTwo.LoadUI("Prefabs/FormationSelect"); go.GetComponent<FormationSelectController>().heroInfo = heroInfo; go.GetComponent<FormationSelectController>().type = type; Destroy(gameObject); }
public void PackegeOpen() { ButtonSound.ButtonClickPlay(); GameObject go = PrefabsTwo.LoadUI("Prefabs/Packege"); go.GetComponent <PackageController>().Choice = 1; go.GetComponent <PackageController>().ShowPackage(); Destroy(gameObject); }
public void EquipCellClick(RowEquipment data) { selectedData = data; GameObject go = PrefabsTwo.Load("Prefabs/equipInfo", transform); mesage = go; equipInfo = go.GetComponent <EquipInfoView>(); equipInfo.Display(selectedData, this); }
public void AddFormation(int pos,int type) { this.pos = pos; this.type = type; GameObject go = PrefabsTwo.LoadUI("Prefabs/FormationSelect"); go.GetComponent<FormationSelectController>().pos = pos; go.GetComponent<FormationSelectController>().type = type; Destroy(gameObject); }
void Display(List <RowEquipment> data, PackageController controller) { this.controller = controller; //Debug.Log("这啥"+JsonMapper.ToJson(data)); transform.DeleteAllChild(); for (int i = 0; i < data.Count; i++) { GameObject cell = PrefabsTwo.Load("Prefabs/equip", transform); cell.GetComponent <EquipCellView>().Display(data[i], controller); } }
public void OpenPackage(string pos) { GameObject go = PrefabsTwo.LoadUI("Prefabs/Packege"); go.GetComponent <PackageController>().Choice = 2; go.GetComponent <PackageController>().EquipPos = pos; go.GetComponent <PackageController>().EquipHero = Date; go.GetComponent <PackageController>().ShowPackage(); Destroy(gameObject); }
public void Formation() { ButtonSound.ButtonClickPlay(); PrefabsTwo.LoadUI("Prefabs/FormationMain"); Destroy(gameObject); }
public void ToPlayInfo(RowHeroDate heroInfo) { GameObject go = PrefabsTwo.LoadUI("Prefabs/PlayerInfo"); go.GetComponent<PlayerInfoView>().Str_DisPlay(heroInfo); }
public void OnClick() { Destroy(gameObject); PrefabsTwo.LoadUI("MainMenu"); }
public void PauseClick() { PrefabsTwo.LoadUI("BattleUI/pause"); }
public void BackToMain() { ButtonSound.ButtonClickPlay(); PrefabsTwo.LoadUI("MainMenu"); Destroy(gameObject); }
public void AttackClick() { ButtonSound.ButtonClickPlay(); PrefabsTwo.LoadUI("Prefabs/Fight"); Destroy(gameObject); }
public void BulidOpen() { ButtonSound.ButtonClickPlay(); PrefabsTwo.LoadUI("Prefabs/Lottery"); Destroy(gameObject); }
public void MissionOpen() { ButtonSound.ButtonClickPlay(); PrefabsTwo.LoadUI("Prefabs/Mission"); Destroy(gameObject); }
public void Chuanwu() { ButtonSound.ButtonClickPlay(); PrefabsTwo.LoadUI("Prefabs/chuanwu"); Destroy(gameObject); }