[Scummvm-cvs-logs] CVS: scummvm/saga ihnm_introproc.cpp,1.36,1.37
Torbjörn Andersson
eriktorbjorn at users.sourceforge.net
Sun Jan 2 08:12:20 CET 2005
Update of /cvsroot/scummvm/scummvm/saga
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3502
Modified Files:
ihnm_introproc.cpp
Log Message:
Use events to start the remaining animations. It's not necessary, but it's
more consistent that way.
Index: ihnm_introproc.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/ihnm_introproc.cpp,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -d -r1.36 -r1.37
--- ihnm_introproc.cpp 2 Jan 2005 14:36:00 -0000 1.36
+++ ihnm_introproc.cpp 2 Jan 2005 16:11:19 -0000 1.37
@@ -140,7 +140,14 @@
_vm->_anim->setFrameTime(0, IHNM_INTRO_FRAMETIME);
_vm->_anim->setFlag(0, ANIM_ENDSCENE);
- _vm->_anim->play(0, 0);
+
+ event.type = ONESHOT_EVENT;
+ event.code = ANIM_EVENT;
+ event.op = EVENT_PLAY;
+ event.param = 0;
+ event.time = 0;
+
+ q_event = _vm->_events->chain(q_event, &event);
break;
default:
break;
@@ -186,10 +193,6 @@
_vm->_anim->setCycles(0, -1);
- // The "Dreamer's Guild" animation has to be started by an
- // event, or the first frame will be drawn before the palette
- // fades down.
- //
// Unlike the original, we keep the logo spinning during the
// palette fades. We don't have to, but I think it looks better
// that way.
@@ -275,7 +278,7 @@
event.op = EVENT_PLAY;
event.time = 0;
- q_event = _vm->_events->queue(&event);
+ q_event = _vm->_events->chain(q_event, &event);
// Background for intro scene is the first frame of the intro
// animation; display it but don't set palette
@@ -299,7 +302,13 @@
q_event = _vm->_events->chain(q_event, &event);
- _vm->_anim->play(0, 0);
+ event.type = ONESHOT_EVENT;
+ event.code = ANIM_EVENT;
+ event.op = EVENT_PLAY;
+ event.param = 0;
+ event.time = 0;
+
+ q_event = _vm->_events->chain(q_event, &event);
// Queue end of scene after a while
// TODO: I've increased the delay so the speech won't start
@@ -331,9 +340,7 @@
case SCENE_BEGIN:
_vm->_anim->setCycles(0, -1);
- // The "hate" animation also needs to be started from an event,
- // or the first frame will be drawn too early.
-
+ // Start "hate" animation
event.type = ONESHOT_EVENT;
event.code = ANIM_EVENT;
event.op = EVENT_PLAY;
More information about the Scummvm-git-logs
mailing list