aboutsummaryrefslogtreecommitdiff
path: root/saga/animation.cpp
diff options
context:
space:
mode:
authorEugene Sandulenko2004-12-22 13:09:47 +0000
committerEugene Sandulenko2004-12-22 13:09:47 +0000
commit2fb8a8e45369b000b9f36d2433425ca48f6d9d13 (patch)
tree7b0c6ad4c4e004a2d58302e2cc57f226be7c13a8 /saga/animation.cpp
parenteaa0f3b9740b81fff59792de55f335c149344c69 (diff)
downloadscummvm-rg350-2fb8a8e45369b000b9f36d2433425ca48f6d9d13.tar.gz
scummvm-rg350-2fb8a8e45369b000b9f36d2433425ca48f6d9d13.tar.bz2
scummvm-rg350-2fb8a8e45369b000b9f36d2433425ca48f6d9d13.zip
o Moved GAME_* to SagaEngine object
o Renamed GAME_ITE_* to GID_ITE_* o Renamed GID_ITE and GID_IHNM to GType_ITE and GType_IHNM svn-id: r16258
Diffstat (limited to 'saga/animation.cpp')
-rw-r--r--saga/animation.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/saga/animation.cpp b/saga/animation.cpp
index b92d81f296..4c01edf219 100644
--- a/saga/animation.cpp
+++ b/saga/animation.cpp
@@ -26,7 +26,6 @@
#include "saga/gfx.h"
#include "saga/console.h"
-#include "saga/game_mod.h"
#include "saga/events.h"
#include "saga/render.h"
@@ -89,7 +88,7 @@ int Anim::load(const byte *anim_resdata, size_t anim_resdata_len, uint16 *anim_i
new_anim->resdata = anim_resdata;
new_anim->resdata_len = anim_resdata_len;
- if (GAME_GetGameType() == GID_ITE) {
+ if (_vm->_gameType == GType_ITE) {
if (getNumFrames(anim_resdata, anim_resdata_len, &new_anim->n_frames) != SUCCESS) {
warning("Anim::load Couldn't get animation frame count");
return FAILURE;
@@ -176,7 +175,7 @@ int Anim::play(uint16 anim_id, int vector_time) {
return FAILURE;
}
- GAME_GetDisplayInfo(&disp_info);
+ _vm->getDisplayInfo(&disp_info);
_vm->_render->getBufferInfo(&buf_info);
display_buf = buf_info.bg_buf;
@@ -191,7 +190,7 @@ int Anim::play(uint16 anim_id, int vector_time) {
if (anim->play_flag) {
frame = anim->current_frame;
- if (GAME_GetGameType() == GID_ITE) {
+ if (_vm->_gameType == GType_ITE) {
result = ITE_DecodeFrame(anim->resdata, anim->resdata_len, anim->frame_offsets[frame - 1], display_buf,
disp_info.logical_w * disp_info.logical_h);
if (result != SUCCESS) {
@@ -346,7 +345,7 @@ int Anim::freeId(uint16 anim_id) {
return FAILURE;
}
- if (GAME_GetGameType() == GID_ITE) {
+ if (_vm->_gameType == GType_ITE) {
free(anim->frame_offsets);
anim->frame_offsets = NULL;
}
@@ -385,7 +384,7 @@ int Anim::getNumFrames(const byte *anim_resource, size_t anim_resource_len, uint
ah.unknown07 = readS.readByte();
ah.nframes = readS.readByte();
- if (GAME_GetGameType() == GID_IHNM) {
+ if (_vm->_gameType == GType_IHNM) {
*n_frames = ah.nframes;
}
@@ -618,7 +617,7 @@ int Anim::IHNM_DecodeFrame(byte *decode_buf, size_t decode_buf_len, const byte *
GAME_DISPLAYINFO di;
- GAME_GetDisplayInfo(&di);
+ _vm->getDisplayInfo(&di);
*nextf_p = NULL;