1
This commit is contained in:
parent
e68ec41ac8
commit
8e974d5de9
@ -1071,7 +1071,7 @@ void CallFuncBuff::RangeHoldBuff()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
owner->room->xtimer.SetIntervalWpEx
|
auto check_timer = owner->room->xtimer.SetIntervalWpEx
|
||||||
(
|
(
|
||||||
SERVER_FRAME_RATE,
|
SERVER_FRAME_RATE,
|
||||||
[this, context, on_enter, on_stay, on_leave, check_cb]
|
[this, context, on_enter, on_stay, on_leave, check_cb]
|
||||||
@ -1086,8 +1086,9 @@ void CallFuncBuff::RangeHoldBuff()
|
|||||||
event_handlers_.push_back(owner->GetTrigger()->AddListener
|
event_handlers_.push_back(owner->GetTrigger()->AddListener
|
||||||
(
|
(
|
||||||
kDieEvent,
|
kDieEvent,
|
||||||
[this, context] (const a8::Args& args) mutable
|
[this, context, check_timer] (const a8::Args& args) mutable
|
||||||
{
|
{
|
||||||
|
owner->room->xtimer.Delete(check_timer);
|
||||||
for (auto& pair : context->in_human_infos) {
|
for (auto& pair : context->in_human_infos) {
|
||||||
for (int buff_uniid : pair.second.buff_uniids) {
|
for (int buff_uniid : pair.second.buff_uniids) {
|
||||||
if (pair.second.c.Get()) {
|
if (pair.second.c.Get()) {
|
||||||
@ -1095,6 +1096,7 @@ void CallFuncBuff::RangeHoldBuff()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
context->in_human_infos.clear();
|
||||||
}
|
}
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user