diff options
author | Paul Gilbert | 2017-12-16 21:47:38 -0500 |
---|---|---|
committer | Paul Gilbert | 2017-12-16 21:47:38 -0500 |
commit | 58fb6a4f8e065054ad9f2bcaaff4414e62d87a84 (patch) | |
tree | ad43375963faa81248c2d9018c246f97ad0627d2 /engines | |
parent | 94f52c9f2b983087b1b895f8d9944211d1c258f2 (diff) | |
download | scummvm-rg350-58fb6a4f8e065054ad9f2bcaaff4414e62d87a84.tar.gz scummvm-rg350-58fb6a4f8e065054ad9f2bcaaff4414e62d87a84.tar.bz2 scummvm-rg350-58fb6a4f8e065054ad9f2bcaaff4414e62d87a84.zip |
XEEN: Fix loading correct sprites for map monsters
Diffstat (limited to 'engines')
-rw-r--r-- | engines/xeen/map.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/engines/xeen/map.cpp b/engines/xeen/map.cpp index b83083b801..3417db839a 100644 --- a/engines/xeen/map.cpp +++ b/engines/xeen/map.cpp @@ -1137,14 +1137,15 @@ void Map::load(int mapId) { // Load sprites for the monsters for (uint i = 0; i < _mobData._monsterSprites.size(); ++i) { - ArchiveType archiveType = - _mobData._monsterSprites[i]._spriteId == 91 && _vm->getGameID() == GType_WorldOfXeen ? + MonsterObjectData::SpriteResourceEntry &spr = _mobData._monsterSprites[i]; + ArchiveType archiveType = spr._spriteId == 91 && _vm->getGameID() == GType_WorldOfXeen ? ALTSIDE_ARCHIVE : GAME_ARCHIVE; + uint imgNumber = _monsterData[spr._spriteId]._imageNumber; - filename = Common::String::format("%03d.mon", _mobData._monsterSprites[i]._spriteId); + filename = Common::String::format("%03u.mon", imgNumber); _mobData._monsterSprites[i]._sprites.load(filename, archiveType); - filename = Common::String::format("%03d.att", _mobData._monsterSprites[i]._spriteId); + filename = Common::String::format("%03u.att", imgNumber); _mobData._monsterSprites[i]._attackSprites.load(filename, archiveType); } |