summary refs log tree commit diff stats
path: root/tools
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2021-01-31 08:42:36 -0500
committerKelly Rauchenberger <fefferburbia@gmail.com>2021-01-31 08:42:36 -0500
commit3fc3a14a94ed7c3942c1e430b4628b22512cce34 (patch)
tree6956a845ca12be342c260e9a297e466e8e4cf5be /tools
parent83debbc91b05d53af31925f122cfe70dbe893eb6 (diff)
downloadtanetane-3fc3a14a94ed7c3942c1e430b4628b22512cce34.tar.gz
tanetane-3fc3a14a94ed7c3942c1e430b4628b22512cce34.tar.bz2
tanetane-3fc3a14a94ed7c3942c1e430b4628b22512cce34.zip
Fixed Flint sprite weirdness
Diffstat (limited to 'tools')
-rw-r--r--tools/sprite_dumper/main.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/sprite_dumper/main.cpp b/tools/sprite_dumper/main.cpp index 46599e5..79e3df0 100644 --- a/tools/sprite_dumper/main.cpp +++ b/tools/sprite_dumper/main.cpp
@@ -266,6 +266,7 @@ struct Sprite {
266}; 266};
267 267
268struct SpriteSheet { 268struct SpriteSheet {
269 int spriteindex = 0;
269 int gfxPtr; 270 int gfxPtr;
270 std::vector<Sprite> sprites; 271 std::vector<Sprite> sprites;
271 272
@@ -274,8 +275,8 @@ struct SpriteSheet {
274 int maxHeight = 0; 275 int maxHeight = 0;
275 std::vector<FrameOutput> frames; 276 std::vector<FrameOutput> frames;
276 277
278 const Palette& palette = palettes.GetPalette(spriteindex);
277 for (int i=0; i<sprites.size(); i++) { 279 for (int i=0; i<sprites.size(); i++) {
278 const Palette& palette = palettes.GetPalette(i);
279 FrameOutput f = sprites[i].render(m3, palette, gfxPtr); 280 FrameOutput f = sprites[i].render(m3, palette, gfxPtr);
280 281
281 if (f.width > maxWidth) maxWidth = f.width; 282 if (f.width > maxWidth) maxWidth = f.width;
@@ -324,6 +325,7 @@ public:
324 if (sheetAddr == -1) continue; 325 if (sheetAddr == -1) continue;
325 326
326 SpriteSheet ss; 327 SpriteSheet ss;
328 ss.spriteindex = i;
327 ss.gfxPtr = GetGfxPointer(m3, i); 329 ss.gfxPtr = GetGfxPointer(m3, i);
328 330
329 m3.Seek(sheetAddr); 331 m3.Seek(sheetAddr);