完备了
This commit is contained in:
parent
a4252de74d
commit
31839aa7ae
@ -2321,6 +2321,25 @@ void Room::ShuaGridRound(Human* target)
|
|||||||
grid_service->InView(target->grid_id, hum->GetPos().x, hum->GetPos().y)
|
grid_service->InView(target->grid_id, hum->GetPos().x, hum->GetPos().y)
|
||||||
) {
|
) {
|
||||||
EnableHuman(hum);
|
EnableHuman(hum);
|
||||||
|
xtimer.AddDeadLineTimerAndAttach
|
||||||
|
(
|
||||||
|
SERVER_FRAME_RATE * 10,
|
||||||
|
a8::XParams()
|
||||||
|
.SetSender(hum)
|
||||||
|
.SetParam1(10)
|
||||||
|
.SetParam2(VIEW_RANGE * 1.5)
|
||||||
|
.SetParam3(0),
|
||||||
|
[] (const a8::XParams& param)
|
||||||
|
{
|
||||||
|
Human* hum = (Human*)param.sender.GetUserData();
|
||||||
|
hum->room->CheckAutoDie(
|
||||||
|
hum,
|
||||||
|
param.param1,
|
||||||
|
param.param2,
|
||||||
|
param.param3
|
||||||
|
);
|
||||||
|
},
|
||||||
|
&hum->xtimer_attacher.timer_list_);
|
||||||
++count;
|
++count;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user