1
This commit is contained in:
parent
f76730f8aa
commit
f33b045769
@ -3305,15 +3305,11 @@ void Room::ForwardGasRing(int n)
|
|||||||
--n;
|
--n;
|
||||||
}
|
}
|
||||||
if (gas_data_.old_area_meta) {
|
if (gas_data_.old_area_meta) {
|
||||||
return;
|
|
||||||
auto boss_tuple = gas_data_.old_area_meta->GetBoss();
|
auto boss_tuple = gas_data_.old_area_meta->GetBoss();
|
||||||
if (boss_tuple && !IsGameOver()) {
|
if (boss_tuple && !IsGameOver()) {
|
||||||
const mt::Hero* hero_meta = mt::Hero::GetById(std::get<2>(*boss_tuple));
|
const mt::Hero* hero_meta = mt::Hero::GetById(std::get<2>(*boss_tuple));
|
||||||
if (hero_meta) {
|
if (hero_meta) {
|
||||||
int boss_uniid = AllocUniid();
|
int boss_uniid = AllocUniid();
|
||||||
#ifdef DEBUG
|
|
||||||
boss_uniid = GetOneAlivePlayer()->GetUniId();
|
|
||||||
#endif
|
|
||||||
NotifyNewsTicker
|
NotifyNewsTicker
|
||||||
(2,
|
(2,
|
||||||
{
|
{
|
||||||
@ -3326,19 +3322,22 @@ void Room::ForwardGasRing(int n)
|
|||||||
});
|
});
|
||||||
xtimer.SetTimeoutEx
|
xtimer.SetTimeoutEx
|
||||||
(SERVER_FRAME_RATE * std::get<1>(*boss_tuple),
|
(SERVER_FRAME_RATE * std::get<1>(*boss_tuple),
|
||||||
[this, boss_tuple, hero_meta] (int event, const a8::Args* args)
|
[this, boss_tuple, hero_meta, boss_uniid] (int event, const a8::Args* args)
|
||||||
{
|
{
|
||||||
if (a8::TIMER_EXEC_EVENT == event) {
|
if (a8::TIMER_EXEC_EVENT == event) {
|
||||||
#if 0
|
Hero* hero = CreateHero
|
||||||
CreateHero(nullptr,
|
(nullptr,
|
||||||
hero_meta,
|
hero_meta,
|
||||||
std::get<0>(*boss_tuple),
|
std::get<0>(*boss_tuple),
|
||||||
);
|
GlmHelper::UP,
|
||||||
#endif
|
666,
|
||||||
|
boss_uniid);
|
||||||
|
if (hero) {
|
||||||
|
batch_sync_->AddGlobalObject(hero);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
&xtimer_attacher_);
|
&xtimer_attacher_);
|
||||||
batch_sync_->AddGlobalObject(GetOneAlivePlayer());
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user