diff options
author | drumsetmonkey <abelleisle@roadrunner.com> | 2016-05-02 08:46:48 -0400 |
---|---|---|
committer | drumsetmonkey <abelleisle@roadrunner.com> | 2016-05-02 08:46:48 -0400 |
commit | 13cd55136ffd09afd9f4828a00716ed9f94f0e0b (patch) | |
tree | d7841da0e6c1b1e4c2c5dc0dd2b492e4fcaeee18 /src/world.cpp | |
parent | c61cbf691bee6dec791c3a161145ae16b448ac2b (diff) |
Sword
Diffstat (limited to 'src/world.cpp')
-rw-r--r-- | src/world.cpp | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/world.cpp b/src/world.cpp index a7c2fdf..0e4fd84 100644 --- a/src/world.cpp +++ b/src/world.cpp @@ -637,11 +637,13 @@ detect(Player *p) int l; // handle the player - std::thread(&World::singleDetect, this, p).detach(); + singleDetect(p); + //std::thread(&World::singleDetect, this, p).detach(); // handle other entities for (auto &e : entity) - std::thread(&World::singleDetect, this, e).detach(); + singleDetect(e); + //std::thread(&World::singleDetect, this, e).detach(); // handle particles for (auto &part : particles) { @@ -786,6 +788,16 @@ getLastMob(void) return mob.back(); } +std::vector<Entity*> World:: +getMobs(void) +{ + std::vector<Entity*> meme; + for (auto &m : mob) { + meme.push_back(m); + } + return meme; +} + /** * Get the interactable entity that is closest to the entity provided. */ |