diff options
author | Stijn Buys <ingar@osirion.org> | 2013-11-10 22:23:50 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2013-11-10 22:23:50 +0000 |
commit | 8039544940b6145dcc8c63bcd4e06073ed61801e (patch) | |
tree | f3adf9eebb1ffe6a8c53e57c64546eeaa61a3517 /src/core/netserver.cc | |
parent | 3b75b41676bd2851b6d2b61d3e3213ee50078870 (diff) |
Renamed entity_destroyed to entity_died to prevent confusion with the Entity::Destroyed state,
fixed a potential memory leak.
Diffstat (limited to 'src/core/netserver.cc')
-rw-r--r-- | src/core/netserver.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/netserver.cc b/src/core/netserver.cc index 84ed76c..17fef86 100644 --- a/src/core/netserver.cc +++ b/src/core/netserver.cc @@ -356,7 +356,7 @@ void NetServer::client_frame(NetClient *client, unsigned long timestamp) for (Zone::Content::iterator it = zone->content().begin(); it != zone->content().end(); ++it) { Entity *entity = (*it); - if (!entity->entity_destroyed) { + if (!entity->died()) { send_entity_create(client, entity); } } @@ -381,7 +381,7 @@ void NetServer::client_frame(NetClient *client, unsigned long timestamp) Entity *entity = (*it).second; if (entity->zone() == zone) { - if (entity->entity_destroyed) { + if (entity->died()) { if (!entity->entity_created) { send_entity_delete(client, entity); } |