This commit is contained in:
aozhiwei 2023-03-17 22:06:55 +08:00
parent a9b23fbf6f
commit 61b624b06d

View File

@ -142,14 +142,12 @@ void CondAddBuff::ProcBulletEnd()
void CondAddBuff::ProcDisengageBattle()
{
#if 0
const float disengate_time = meta->GetBuffParam2(this);
auto context = A8_MAKE_ANON_STRUCT_SHARED
(
);
std::get<0>(*context.get()) = 0;
a8::XTimerWp timer = owner->room->xtimer.SetIntervalWpEx
(
disengate_time * SERVER_FRAME_RATE,
@ -157,12 +155,11 @@ void CondAddBuff::ProcDisengageBattle()
{
if (a8::TIMER_EXEC_EVENT == event) {
if (!owner->dead) {
#if 0
if (std::get<0>(*context.get()) == 0) {
std::get<0>(*context.get()) = 1;
#if 0
owner->AddEnergyShield(meta->_number_meta->shield() * owner->GetMaxHP());
#endif
}
#endif
}
}
},
@ -175,6 +172,7 @@ void CondAddBuff::ProcDisengageBattle()
return;
}
owner->room->xtimer.ResetTimer(timer);
#if 0
if (std::get<0>(*context.get()) == 1) {
for (int buff_uniid : std::get<1>(*context.get())) {
owner->RemoveBuffByUniId(buff_uniid);
@ -182,6 +180,7 @@ void CondAddBuff::ProcDisengageBattle()
std::get<0>(*context.get()) = 0;
std::get<1>(*context.get()).clear();
}
#endif
};
owner->GetTrigger()->AddListener
@ -194,7 +193,6 @@ void CondAddBuff::ProcDisengageBattle()
kReceiveDmgEvent,
cb
);
#endif
}
void CondAddBuff::ProcLimitTimeKillTarget()