/// <summary> /// 通过职业和种族, 获取英雄模型地址 /// </summary> public static string GetHeroModelAddress(ActorRace actorRace, ActorClass actorClass) { string rn = SwordUtil.GetRaceName(actorRace); string cn = SwordUtil.GetClassName(actorClass); return(GetHeroModelAddress(rn, cn)); }
public void SetData(ActorVO vo) { if (vo == null) { return; } NameTxt.text = vo.Name; LevelTxt.text = vo.Level.ToString(); RaceTxt.text = SwordUtil.GetRaceName(vo.RaceEnum); ClassTxt.text = SwordUtil.GetClassName(vo.ClassEnum); }
private void OnClickCreateBtn() { bool b = ValidDectecte(); if (!b) { Debug.LogError("Create Check Invalid"); return; } var heroName = NameTxt.text; var raceName = GetSelectedRaceName(); int raceValue = (int)SwordUtil.GetRaceEnum(raceName); var className = GetSelectedClassName(); int classValue = (int)SwordUtil.GetClassEnum(className); //创建角色和英雄, 并存储数据 ProxyPool.UserProxy.CreateCharacter(heroName, raceValue, classValue); ProxyPool.HeroProxy.CreateHero(heroName, raceValue, classValue); CApplicationManager.Instance.ChangeProcedure(Procedure_CharacterEntry.NAME); }