aboutsummaryrefslogtreecommitdiff
path: root/saga/actor.cpp
diff options
context:
space:
mode:
authorEugene Sandulenko2005-01-02 20:29:27 +0000
committerEugene Sandulenko2005-01-02 20:29:27 +0000
commit63be4b64350f72463965c2716e1e0cc43ade2f98 (patch)
treec3050c46246a59cb3786d471a917a1475fa52e80 /saga/actor.cpp
parent6738870568a08788acd26a5a02ee64d07600095b (diff)
downloadscummvm-rg350-63be4b64350f72463965c2716e1e0cc43ade2f98.tar.gz
scummvm-rg350-63be4b64350f72463965c2716e1e0cc43ade2f98.tar.bz2
scummvm-rg350-63be4b64350f72463965c2716e1e0cc43ade2f98.zip
o Started putting all panels stuff in order. Still incomplete
o Proper detection for Mac Wyrmkeep CD o Support for wyrmkeep logos svn-id: r16415
Diffstat (limited to 'saga/actor.cpp')
-rw-r--r--saga/actor.cpp41
1 files changed, 26 insertions, 15 deletions
diff --git a/saga/actor.cpp b/saga/actor.cpp
index 6caa325189..42eaf5ca2a 100644
--- a/saga/actor.cpp
+++ b/saga/actor.cpp
@@ -446,8 +446,11 @@ void Actor::handleActions(int msec, bool setup) {
//todo: dragon stuff
+ if (actor->index == 2)
+ debug(9, "Action: %d Flags: %x", actor->currentAction, actor->flags);
+
switch(actor->currentAction) {
- case kActionWait: {
+ case kActionWait:
if (!setup && (actor->flags & kFollower)) {
followProtagonist(actor);
if (actor->currentAction != kActionWait)
@@ -484,9 +487,10 @@ void Actor::handleActions(int msec, bool setup) {
}
}
actor->actionCycle++;
- } break;
+ break;
+
case kActionWalkToPoint:
- case kActionWalkToLink: {
+ case kActionWalkToLink:
// tiled stuff
if (_vm->_scene->getMode() == SCENE_MODE_ISO) {
//todo: it
@@ -568,12 +572,14 @@ void Actor::handleActions(int msec, bool setup) {
}
actor->frameNumber = frameRange->frameIndex + actor->actionCycle;
- } break;
- case kActionWalkDir: {
+ break;
+
+ case kActionWalkDir:
debug(9,"kActionWalkDir not implemented");
//todo: do it
- } break;
- case kActionSpeak: {
+ break;
+
+ case kActionSpeak:
actor->actionCycle++;
actor->cycleWrap(64);
@@ -594,14 +600,14 @@ void Actor::handleActions(int msec, bool setup) {
}
actor->frameNumber = frameRange->frameIndex + state;
- } break;
+ break;
case kActionAccept:
case kActionStoop:
break;
case kActionCycleFrames:
- case kActionPongFrames: {
+ case kActionPongFrames:
if (actor->cycleTimeCount > 0) {
actor->cycleTimeCount--;
break;
@@ -647,17 +653,19 @@ void Actor::handleActions(int msec, bool setup) {
} else {
actor->frameNumber = frameRange->frameIndex + state;
}
- } break;
- case kActionFall: {
+ break;
+
+ case kActionFall:
debug(9,"kActionFall not implemented");
//todo: do it
- } break;
- case kActionClimb: {
+ break;
+
+ case kActionClimb:
debug(9,"kActionClimb not implemented");
//todo: do it
- } break;
+ break;
}
}
@@ -705,6 +713,9 @@ void Actor::calcActorScreenPosition(ActorData *actor) {
actor->screenPosition.x = (actor->location.x / ACTOR_LMULT);
actor->screenPosition.y = (actor->location.y / ACTOR_LMULT) - actor->location.z;
}
+
+ if (actor->index == 2)
+ debug(9, "act: %d. x: %d y: %d", actor->index, actor->screenPosition.x, actor->screenPosition.y);
}
void Actor::createDrawOrderList() {
@@ -946,7 +957,7 @@ bool Actor::actorWalkTo(uint16 actorId, const ActorLocation &toLocation) {
bool extraEndNode;
actor = getActor(actorId);
-
+
if (actor == _protagonist) {
_vm->_scene->setDoorState(2, 0xff);
_vm->_scene->setDoorState(3, 0);