1
This commit is contained in:
parent
e50e2c4d36
commit
51f7d3eefa
@ -107,6 +107,16 @@ void Entity::BroadcastFullState(Room* room)
|
||||
|
||||
void Entity::BroadcastDeleteState(Room* room)
|
||||
{
|
||||
#if 1
|
||||
room->TouchHumanList
|
||||
(
|
||||
a8::XParams(),
|
||||
[this] (Human* hum, a8::XParams& param) -> bool
|
||||
{
|
||||
hum->RemoveObjects(this);
|
||||
return true;
|
||||
});
|
||||
#else
|
||||
std::set<GridCell*> tmp_grids;
|
||||
room->grid_service->GetAllCells(room, grid_id_, tmp_grids);
|
||||
room->grid_service->TouchAllLayerHumanList
|
||||
@ -117,6 +127,7 @@ void Entity::BroadcastDeleteState(Room* room)
|
||||
{
|
||||
hum->RemoveObjects(this);
|
||||
});
|
||||
#endif
|
||||
}
|
||||
|
||||
void Entity::RemoveFromAroundPlayers(Room* room)
|
||||
|
@ -309,8 +309,8 @@ void Hero::BeKill(int killer_id, const std::string& killer_name, int weapon_id)
|
||||
hero->delete_frameno = hero->room->GetFrameNo();
|
||||
std::vector<Human*> watch_list;
|
||||
hero->room->GetPartObjectWatchList(hero, watch_list);
|
||||
if (watch_list.empty()) {
|
||||
|
||||
if (!watch_list.empty()) {
|
||||
abort();
|
||||
}
|
||||
},
|
||||
&xtimer_attacher.timer_list_);
|
||||
|
Loading…
x
Reference in New Issue
Block a user