aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorStrangerke2013-10-26 23:42:44 +0200
committerStrangerke2013-10-26 23:42:44 +0200
commit1828f5edc8fadec79f639537492856fee9bfe7a6 (patch)
tree781b62b9ad8e386c40ddcc404943be26d1ca23d1 /engines
parenta6f7b638a1c42624ad9a4517406f131452d97524 (diff)
downloadscummvm-rg350-1828f5edc8fadec79f639537492856fee9bfe7a6.tar.gz
scummvm-rg350-1828f5edc8fadec79f639537492856fee9bfe7a6.tar.bz2
scummvm-rg350-1828f5edc8fadec79f639537492856fee9bfe7a6.zip
TSAGE: Fix CID 1002381 to 1002384, get rid of a couple of magic values
Diffstat (limited to 'engines')
-rw-r--r--engines/tsage/ringworld2/ringworld2_logic.cpp25
1 files changed, 23 insertions, 2 deletions
diff --git a/engines/tsage/ringworld2/ringworld2_logic.cpp b/engines/tsage/ringworld2/ringworld2_logic.cpp
index 96a145a74a..6cf3589ae5 100644
--- a/engines/tsage/ringworld2/ringworld2_logic.cpp
+++ b/engines/tsage/ringworld2/ringworld2_logic.cpp
@@ -1355,6 +1355,7 @@ SceneArea::SceneArea(): SceneItem() {
_insideArea = false;
_savedCursorNum = CURSOR_NONE;
_cursorState = 0;
+ _cursorNum = CURSOR_NONE;
}
void SceneArea::synchronize(Serializer &s) {
@@ -1407,6 +1408,8 @@ void SceneArea::setDetails(const Rect &bounds, CursorType cursor) {
SceneExit::SceneExit(): SceneArea() {
_moving = false;
_destPos = Common::Point(-1, -1);
+
+ _sceneNumber = 0;
}
void SceneExit::synchronize(Serializer &s) {
@@ -1724,6 +1727,12 @@ void AnimationSlice::load(Common::File &f) {
AnimationSlices::AnimationSlices() {
_pixelData = NULL;
+
+ _dataSize = 0;
+ _dataSize2 = 0;
+ _slices->_sliceOffset = 0;
+ _slices->_drawMode = 0;
+ _slices->_secondaryIndex = 0;
}
AnimationSlices::~AnimationSlices() {
@@ -1789,6 +1798,18 @@ AnimationPlayer::AnimationPlayer(): EventHandler() {
_sliceHeight = 1;
_field58 = 1;
_endAction = NULL;
+
+ _sliceCurrent = nullptr;
+ _sliceNext = nullptr;
+ _field38 = 0;
+ _objectMode = ANIMOBJMODE_1;
+ _dataNeeded = 0;
+ _playbackTick = 0;
+ _playbackTickPrior = 0;
+ _position = 0;
+ _nextSlicesPosition = 0;
+ _frameDelay = 0;
+ _gameFrame = 0;
}
AnimationPlayer::~AnimationPlayer() {
@@ -2028,7 +2049,7 @@ void AnimationPlayer::drawFrame(int sliceIndex) {
// Unlock the screen surface
R2_GLOBALS._screenSurface.unlockSurface();
- if (_objectMode == 42) {
+ if (_objectMode == ANIMOBJMODE_42) {
_screenBounds.expandPanes();
// Copy the drawn frame to the back surface
@@ -2097,7 +2118,7 @@ void AnimationPlayer::close() {
// Close the resource file
_resourceFile.close();
- if (_objectMode != 42) {
+ if (_objectMode != ANIMOBJMODE_42) {
// flip screen in original
}