From 518ec95549f534f18f52ee584213956372b7d139 Mon Sep 17 00:00:00 2001 From: Felix Ableitner Date: Tue, 17 Sep 2013 23:06:17 +0200 Subject: [PATCH] Fixed weapons not stopping to fire after pickup. --- src/World.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/World.cpp b/src/World.cpp index cac8ef2..3c6652f 100755 --- a/src/World.cpp +++ b/src/World.cpp @@ -121,9 +121,9 @@ World::applyMovement(std::shared_ptr sprite, int elapsed) { void World::think(int elapsed) { for (auto it = mCharacters.begin(); it != mCharacters.end(); ) { - if ((*it)->getDelete() && (*it)->getCategory() != Sprite::CATEGORY_ACTOR) { + if ((*it)->getDelete()) { mCharacters.erase(it); - auto& d = mDrawables[(*it)->getCategory()]; + auto& d = mDrawables[Sprite::CATEGORY_ACTOR]; d.erase(std::find(d.begin(), d.end(), *it)); } else {