refactor(fight): 重构精灵特效类型枚举结构
This commit is contained in:
@@ -389,11 +389,22 @@ func (pet *PetInfo) RnadEffect() {
|
||||
}
|
||||
}
|
||||
|
||||
// 1是特性特质,<!-- Stat: 精灵特效Stat: 0: 无效(默认值), 1: 永久, 2: 有`有效次数'的特效 3: 爆发特效 4: 异能精灵特质,5特训,6魂印-->
|
||||
// 0: Boss特性
|
||||
// 1: 特性
|
||||
// 2: 能量珠
|
||||
// 3: 爆发特效
|
||||
// 4: 异能精灵特质
|
||||
// 5: 特训
|
||||
// 6: 魂印
|
||||
// 7 :繁殖加成
|
||||
// 8 :体力提升加成
|
||||
|
||||
// 繁殖加成,体力提升加成 ,这里是防止和其他重复所以定义不同类别,但是实际上,能量珠那些事调用不同id的effect实现
|
||||
// <!-- Stat: 精灵特效Stat: 0: 无效(默认值), 1: 永久, 2: 有`有效次数'的特效 3: 爆发特效 4: 异能精灵特质,5特训,6魂印-->
|
||||
func (pet *PetInfo) GetEffect(ptype int) (int, *PetEffectInfo, bool) {
|
||||
|
||||
return utils.FindWithIndex(pet.EffectInfo, func(item PetEffectInfo) bool {
|
||||
return gconv.Int(xmlres.EffectMAP[int(item.Idx)].Stat) == 1
|
||||
return item.Status == 1
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user