diff options
author | Paul Gilbert | 2014-03-10 01:00:11 -0400 |
---|---|---|
committer | Paul Gilbert | 2014-03-10 01:00:11 -0400 |
commit | d295a1654547d4f3636ea6d64939a0a91c5b2c25 (patch) | |
tree | 36963470b3132a83436e4388565235c31cfa67f0 | |
parent | 9e69e64d3fc54a3d9e2065eb2af75950353c7f64 (diff) | |
download | scummvm-rg350-d295a1654547d4f3636ea6d64939a0a91c5b2c25.tar.gz scummvm-rg350-d295a1654547d4f3636ea6d64939a0a91c5b2c25.tar.bz2 scummvm-rg350-d295a1654547d4f3636ea6d64939a0a91c5b2c25.zip |
MADS: Properly hook up use of PaletteUsage::process
-rw-r--r-- | engines/mads/assets.cpp | 2 | ||||
-rw-r--r-- | engines/mads/assets.h | 2 | ||||
-rw-r--r-- | engines/mads/palette.cpp | 4 | ||||
-rw-r--r-- | engines/mads/scene_data.cpp | 4 | ||||
-rw-r--r-- | engines/mads/scene_data.h | 2 |
5 files changed, 7 insertions, 7 deletions
diff --git a/engines/mads/assets.cpp b/engines/mads/assets.cpp index 554cd9ad48..1a2d542c95 100644 --- a/engines/mads/assets.cpp +++ b/engines/mads/assets.cpp @@ -54,7 +54,7 @@ void SpriteAsset::load(Common::SeekableReadStream *stream, int flags) { _pixelSpeed = 0; _maxWidth = 0; _maxHeight = 0; - _field6 = -1; + _usageIndex = -1; Common::SeekableReadStream *spriteStream = sprite.getItemStream(0); _mode = spriteStream->readByte(); diff --git a/engines/mads/assets.h b/engines/mads/assets.h index c0d1feb883..31d46881ff 100644 --- a/engines/mads/assets.h +++ b/engines/mads/assets.h @@ -77,7 +77,7 @@ private: void load(Common::SeekableReadStream *stream, int flags); public: SpriteSetCharInfo *_charInfo; - int _field6; + int _usageIndex; public: /** * Constructor diff --git a/engines/mads/palette.cpp b/engines/mads/palette.cpp index 1303ea264a..d9eb3ffa93 100644 --- a/engines/mads/palette.cpp +++ b/engines/mads/palette.cpp @@ -553,8 +553,8 @@ void Palette::initGamePalette() { _vm->_game->_player._spritesStart + idx]; uint32 mask = 1; - if (asset->_field6) - mask <<= asset->_field6; + if (asset->_usageIndex) + mask <<= asset->_usageIndex; palMask = mask; } diff --git a/engines/mads/scene_data.cpp b/engines/mads/scene_data.cpp index 36efcb31de..eb4b221af9 100644 --- a/engines/mads/scene_data.cpp +++ b/engines/mads/scene_data.cpp @@ -500,8 +500,8 @@ void SceneInfo::load(int sceneId, int v1, const Common::String &resName, _vm->_palette->_paletteUsage.prioritize(artHeader._palette); } - _field4C = _vm->_palette->_paletteUsage.process(artHeader._palette, 0xF800); - if (_field4C > 0) { + _usageIndex = _vm->_palette->_paletteUsage.process(artHeader._palette, 0xF800); + if (_usageIndex > 0) { _vm->_palette->_paletteUsage.transform(artHeader._palette); for (uint i = 0; i < _palAnimData.size(); ++i) { diff --git a/engines/mads/scene_data.h b/engines/mads/scene_data.h index d2fd624512..67393fc75d 100644 --- a/engines/mads/scene_data.h +++ b/engines/mads/scene_data.h @@ -267,7 +267,7 @@ public: int _depthList[DEPTH_BANDS_SIZE]; int _field4A; - int _field4C; + int _usageIndex; Common::Array<RGB4> _palAnimData; SceneNodeList _nodes; public: |