From d0c38dcaae779715f7fe50f56b77b69394bd1ed7 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Thu, 18 Jan 2024 16:16:03 +0800 Subject: [PATCH] 1 --- server/gameserver/buff/callfunc.cc | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/server/gameserver/buff/callfunc.cc b/server/gameserver/buff/callfunc.cc index 3d364ccb..7d6f86d7 100644 --- a/server/gameserver/buff/callfunc.cc +++ b/server/gameserver/buff/callfunc.cc @@ -25,6 +25,7 @@ #include "app.h" #include "bullet.h" #include "virtualbullet.h" +#include "shot.h" #include "mt/Buff.h" #include "mt/Equip.h" @@ -1408,6 +1409,18 @@ void CallFuncBuff::AccumulatePower() [this] (int event, const a8::Args* args) { if (a8::TIMER_EXEC_EVENT == event) { + const mt::Equip* equip_meta = mt::Equip::GetById(meta->GetBuffParam2(this)); + if (equip_meta) { + if (!owner->dead && owner->downed) { + InternalShot(owner, + owner->GetCurrWeapon()->meta, + equip_meta, + skill_meta, + 0, + owner->GetCurrWeapon()->weapon_uniid, + 0); + } + } } }, &xtimer_attacher);