protected override int GetOriginalPriority(string name) { EntityParent.MonsterRankType monsterRank = this.GetEntity().MonsterRank; if (monsterRank != EntityParent.MonsterRankType.Elite) { if (monsterRank != EntityParent.MonsterRankType.Boss) { if (DataReader <ActionMonster> .Get(name) != null) { return(DataReader <ActionMonster> .Get(name).priority); } Debug.LogError("ActionMonster 不存在 " + name); } else { if (DataReader <ActionBoss> .Get(name) != null) { return(DataReader <ActionBoss> .Get(name).priority); } Debug.LogError("ActionBoss 不存在 " + name); } } else { if (DataReader <ActionElite> .Get(name) != null) { return(DataReader <ActionElite> .Get(name).priority); } Debug.LogError("ActionElite 不存在 " + name); } return(0); }
public override void InitActionPriorityTable() { base.ActionPriorityTable.Clear(); EntityParent.MonsterRankType monsterRank = this.GetEntity().MonsterRank; if (monsterRank != EntityParent.MonsterRankType.Elite) { if (monsterRank != EntityParent.MonsterRankType.Boss) { for (int i = 0; i < DataReader <ActionMonster> .DataList.get_Count(); i++) { base.ActionPriorityTable.Add(DataReader <ActionMonster> .DataList.get_Item(i).action, DataReader <ActionMonster> .DataList.get_Item(i).priority); } } else { for (int j = 0; j < DataReader <ActionBoss> .DataList.get_Count(); j++) { base.ActionPriorityTable.Add(DataReader <ActionBoss> .DataList.get_Item(j).action, DataReader <ActionBoss> .DataList.get_Item(j).priority); } } } else { for (int k = 0; k < DataReader <ActionElite> .DataList.get_Count(); k++) { base.ActionPriorityTable.Add(DataReader <ActionElite> .DataList.get_Item(k).action, DataReader <ActionElite> .DataList.get_Item(k).priority); } } }