From 1e5f9d3078f236f306b5d868bcd52f4e47f7b512 Mon Sep 17 00:00:00 2001 From: Peter Kohaut Date: Sun, 14 Jan 2018 12:12:06 +0100 Subject: BLADERUNNER: Added basic KIA interface Settings works Help works Clue database works Fixed code for inserting objects into scene Reorganization of few files Unification & code formatting of few older files --- engines/bladerunner/slice_animations.h | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) (limited to 'engines/bladerunner/slice_animations.h') diff --git a/engines/bladerunner/slice_animations.h b/engines/bladerunner/slice_animations.h index b5b60ef096..a34b6ec13e 100644 --- a/engines/bladerunner/slice_animations.h +++ b/engines/bladerunner/slice_animations.h @@ -36,12 +36,6 @@ namespace BladeRunner { class BladeRunnerEngine; -struct SlicePalette { - uint16 color555[256]; - Color256 color[256]; - -// uint16 &operator[](size_t i) { return color555[i]; } -}; class SliceAnimations { friend class SliceRenderer; @@ -55,6 +49,13 @@ class SliceAnimations { uint32 offset; }; + struct Palette { + uint16 color555[256]; + Color256 color[256]; + + // uint16 &operator[](size_t i) { return color555[i]; } + }; + struct Page { void *_data; uint32 _lastAccess; @@ -80,7 +81,7 @@ class SliceAnimations { uint32 _pageCount; uint32 _paletteCount; - Common::Array _palettes; + Common::Array _palettes; Common::Array _animations; Common::Array _pages; @@ -100,14 +101,14 @@ public: bool openCoreAnim(); bool openHDFrames(); - SlicePalette &getPalette(int i) { return _palettes[i]; }; - void *getFramePtr(uint32 animation, uint32 frame); + Palette &getPalette(int i) { return _palettes[i]; }; + void *getFramePtr(uint32 animation, uint32 frame); - int getFrameCount(int animation){ return _animations[animation].frameCount; } - float getFPS(int animation){ return _animations[animation].fps; } + int getFrameCount(int animation) const { return _animations[animation].frameCount; } + float getFPS(int animation) const { return _animations[animation].fps; } - Vector3 getPositionChange(int animation); - float getFacingChange(int animation); + Vector3 getPositionChange(int animation) const; + float getFacingChange(int animation) const; }; } // End of namespace BladeRunner -- cgit v1.2.3