#include <gamedata.h>
Public Member Functions | |
bool | loadInitialState (Common::ReadStream &stream) |
void | saveLoadWithSerializer (Common::Serializer &sz) override |
Public Attributes | |
uint8 | _active |
uint8 | _firstFrame |
uint8 | _randomFrame |
uint8 | _numFrames |
uint8 | _roomFrameLSB |
uint8 | _jumpChance |
uint8 | _currentFrame |
uint16 | _x |
uint8 | _y |
uint16 | _width |
uint8 | _height |
uint16 | _WX |
uint8 | _roomFrameMSB |
uint8 | _SP |
An animated image in the scene.
Object frames consist of surfaces carved out of room frames (starting from _roomFrame up until _roomFrame + _numFrames - 1) based on the object's rectangle. They are stored in the shared object frame space that each object occupies a continuous part of from the beginning.
By using the term "frame" alone we will be referring to an object frame, not a room frame.
For details regarding animation playback, see objectanimationtask.cpp.
bool MutationOfJB::Object::loadInitialState | ( | Common::ReadStream & | stream | ) |
Load initial state from game data file.
stream | Stream for reading. |
|
overridevirtual |
uint8 MutationOfJB::Object::_active |
Controls whether the animation is playing.
uint8 MutationOfJB::Object::_firstFrame |
Number of the first frame this object has in the shared object frame space (FA register).
For the first object, it is equal to 1. For any subsequent object, it is equal to (_firstFrame + _numFrames) of the previous object.
uint8 MutationOfJB::Object::_randomFrame |
The frame that is jumped to randomly based on _jumpChance (FR register).
uint8 MutationOfJB::Object::_numFrames |
Number of animation frames (NA register).
uint8 MutationOfJB::Object::_roomFrameLSB |
Low 8 bits of the 16-bit starting room frame (FS register). This is in the room frame space.
uint8 MutationOfJB::Object::_jumpChance |
Chance (1 in x) of the animation jumping to _randomFrame.
uint8 MutationOfJB::Object::_currentFrame |
Current animation frame (CA register).
uint16 MutationOfJB::Object::_x |
X coordinate of the object rectangle (XX register).
uint8 MutationOfJB::Object::_y |
Y coordinate of the object rectangle (YY register).
uint16 MutationOfJB::Object::_width |
Width of the object rectangle (XL register).
uint8 MutationOfJB::Object::_height |
Height of the object rectangle (YL register).
uint16 MutationOfJB::Object::_WX |
A general-purpose register for use in scripts. Nothing to do with animation.
uint8 MutationOfJB::Object::_roomFrameMSB |
High 8 bits of the 16-bit starting room frame (WY register). This is in the room frame space.
uint8 MutationOfJB::Object::_SP |
Unknown. TODO: Figure out what this does.