feat(fight): 添加闪亮怪物判断条件并修复物品添加参数格式 - 在战斗逻辑中增加对闪亮怪物的判断,只有闪亮怪物击败后才能获得玄铁 - 修复物品添加时uint32类型转换的参数格式问题 - 添加effect_42技能效果的参数设置方法 - 引入随机数库用于效果持续
This commit is contained in:
@@ -175,7 +175,7 @@ func (Controller) OnPlayerFightNpcMonster(data1 *fight.FightNpcMonsterInboundInf
|
||||
|
||||
p.AddPetExp(foi.Winpet, int64(addexp))
|
||||
|
||||
if p.CanGetXUAN() {
|
||||
if monster.IsShiny() && p.CanGetXUAN() {
|
||||
xuan := 400686 + int64(xmlres.PetMAP[int(refPet.GetID())].Type)
|
||||
ok := p.ItemAdd(xuan, 1)
|
||||
if ok {
|
||||
@@ -192,7 +192,7 @@ func (Controller) OnPlayerFightNpcMonster(data1 *fight.FightNpcMonsterInboundInf
|
||||
count := int64(grand.Intn(2) + 1)
|
||||
ok := p.ItemAdd(item, count)
|
||||
if ok {
|
||||
items.ADDitem(uint32(item),uint32 (count))
|
||||
items.ADDitem(uint32(item), uint32(count))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user