diff options
author | Andrei Karas <akaras@inbox.ru> | 2010-06-11 22:23:43 +0300 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2010-06-12 10:59:56 -0600 |
commit | b02382703e49bb4d611d81dfc817b22c6294dcbd (patch) | |
tree | 332de92986116446913f9b24c2815044ba91717a /src/actorspritemanager.cpp | |
parent | ccafb75577f9ea8f86243d26e80fb60e56af12d1 (diff) | |
download | mana-b02382703e49bb4d611d81dfc817b22c6294dcbd.tar.gz mana-b02382703e49bb4d611d81dfc817b22c6294dcbd.tar.bz2 mana-b02382703e49bb4d611d81dfc817b22c6294dcbd.tar.xz mana-b02382703e49bb4d611d81dfc817b22c6294dcbd.zip |
Fix crash after die.
Signed-off-by: Jared Adams <jaxad0127@gmail.com>
Diffstat (limited to 'src/actorspritemanager.cpp')
-rw-r--r-- | src/actorspritemanager.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/actorspritemanager.cpp b/src/actorspritemanager.cpp index 04e17b47..ead469c2 100644 --- a/src/actorspritemanager.cpp +++ b/src/actorspritemanager.cpp @@ -95,6 +95,9 @@ FloorItem *ActorSpriteManager::createItem(int id, int itemId, int x, int y) void ActorSpriteManager::destroy(ActorSprite *actor) { + if (!actor || actor == player_node) + return; + mDeleteActors.push_back(actor); } |