summary refs log tree commit diff stats
path: root/src/game.cpp
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2021-02-10 17:53:49 -0500
committerKelly Rauchenberger <fefferburbia@gmail.com>2021-02-10 17:53:49 -0500
commit2afa279d4c7780e4d43749d73891c9a7d46f4472 (patch)
tree3454fc185c7f852d0dab917f57d2f59fe5d2283e /src/game.cpp
parent715d97bb52794d2bf2472b820ae64e9d6301b333 (diff)
downloadtanetane-2afa279d4c7780e4d43749d73891c9a7d46f4472.tar.gz
tanetane-2afa279d4c7780e4d43749d73891c9a7d46f4472.tar.bz2
tanetane-2afa279d4c7780e4d43749d73891c9a7d46f4472.zip
Fixed running sound looping infinitely after running into map change
Diffstat (limited to 'src/game.cpp')
-rw-r--r--src/game.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/game.cpp b/src/game.cpp index 530068c..dc3a5ba 100644 --- a/src/game.cpp +++ b/src/game.cpp
@@ -13,13 +13,13 @@ int Game::emplaceSprite(std::string alias) {
13} 13}
14 14
15void Game::clearSprites() { 15void Game::clearSprites() {
16 sprites_.clear();
17 spriteIds_.clear();
18 spritesByAlias_.clear();
19
20 for (std::unique_ptr<System>& system : systems_) { 16 for (std::unique_ptr<System>& system : systems_) {
21 system->clearSpriteCache(); 17 system->clearSpriteCache();
22 } 18 }
19
20 sprites_.clear();
21 spriteIds_.clear();
22 spritesByAlias_.clear();
23} 23}
24 24
25void Game::loadMap(std::string filename, std::string warpPoint) { 25void Game::loadMap(std::string filename, std::string warpPoint) {