aboutsummaryrefslogtreecommitdiff
path: root/engines/mads/palette.h
diff options
context:
space:
mode:
Diffstat (limited to 'engines/mads/palette.h')
-rw-r--r--engines/mads/palette.h13
1 files changed, 9 insertions, 4 deletions
diff --git a/engines/mads/palette.h b/engines/mads/palette.h
index 5a563a5aa5..a28810e70b 100644
--- a/engines/mads/palette.h
+++ b/engines/mads/palette.h
@@ -55,14 +55,19 @@ struct RGB6 {
};
class PaletteUsage {
+public:
+ struct UsageEntry {
+ uint16 _palIndex;
+ int _sortValue;
+
+ UsageEntry(int palIndex) { _palIndex = palIndex; }
+ };
private:
MADSEngine *_vm;
- Common::Array<uint16> _data;
+ Common::Array<UsageEntry> _data;
int rgbMerge(RGB6 &palEntry);
- void prioritizeFromList(int lst[3]);
-
int getGamePalFreeIndex(int *palIndex);
int rgbFactor(byte *palEntry, RGB6 &pal6);
@@ -79,7 +84,7 @@ public:
*/
bool empty() const { return _data.size() == 0; }
- uint16 &operator[](int index) { return _data[index]; }
+ uint16 &operator[](int index) { return _data[index]._palIndex; }
/**
* Gets key entries from the passed palette