public void SetSynergyInfo(Tribe tribe) { var tribeDataSheet = DataBase.Instance.tribeDataSheet; if (tribeDataSheet.TryGetTribeData(tribe, out var tribeData)) { SetSynergyImage(tribeData.Image); SetSynergyNameText(SynergyService.GetNameByTribe(tribeData.Tribe)); SetSynergyInfoText(tribeData.Description); } var characterDataSheet = DataBase.Instance.characterDataSheet; var characterDataList = characterDataSheet.GetCharacterDataListByTribe(tribe); int index = 0; foreach (var characterData in characterDataList) { characterImageList[index].SetCharacterImage(characterData.Image); characterImageList[index].Disabled(); var characterList = InGameManager.instance.draggableCentral.uiCharacterArea.GetCharacterList(); foreach (var character in characterList) { if (character.characterInfo.id == characterData.Id) { characterImageList[index].Activate(); break; } } characterImageList[index].OnShow(); ++index; } for (int i = index; i < characterImageList.Count; ++i) { characterImageList[i].OnHide(); } }
public void SetOriginText(Origin origin) { var originStr = SynergyService.GetNameByOrigin(origin); originText.text = originStr; }
public void SetTribeText(Tribe tribe) { var tribeStr = SynergyService.GetNameByTribe(tribe); tribeText.text = tribeStr; }