diff options
author | Arnaud Boutonné | 2011-01-18 21:32:18 +0000 |
---|---|---|
committer | Arnaud Boutonné | 2011-01-18 21:32:18 +0000 |
commit | 6a586881af7764918e2bb4da039ce9c0b03fc2ed (patch) | |
tree | 985c73db25415e5cf39d4734195d178967a69d13 /engines | |
parent | 4ad14abef3ea125a1cbc4939b3c5ed57bd8d58ab (diff) | |
download | scummvm-rg350-6a586881af7764918e2bb4da039ce9c0b03fc2ed.tar.gz scummvm-rg350-6a586881af7764918e2bb4da039ce9c0b03fc2ed.tar.bz2 scummvm-rg350-6a586881af7764918e2bb4da039ce9c0b03fc2ed.zip |
HUGO: Rename objNumb to objIndex when used as an index
svn-id: r55316
Diffstat (limited to 'engines')
-rw-r--r-- | engines/hugo/game.h | 58 | ||||
-rw-r--r-- | engines/hugo/object.h | 8 | ||||
-rw-r--r-- | engines/hugo/object_v1d.cpp | 16 | ||||
-rw-r--r-- | engines/hugo/object_v1w.cpp | 20 | ||||
-rw-r--r-- | engines/hugo/object_v3d.cpp | 20 | ||||
-rw-r--r-- | engines/hugo/schedule.cpp | 58 | ||||
-rw-r--r-- | engines/hugo/schedule_v1d.cpp | 54 | ||||
-rw-r--r-- | engines/hugo/schedule_v2d.cpp | 78 |
8 files changed, 156 insertions, 156 deletions
diff --git a/engines/hugo/game.h b/engines/hugo/game.h index 1479bc4fb9..398d0459c0 100644 --- a/engines/hugo/game.h +++ b/engines/hugo/game.h @@ -305,7 +305,7 @@ struct act0 { // Type 0 - Schedule struct act1 { // Type 1 - Start an object action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int cycleNumb; // Number of times to cycle cycle_t cycle; // Direction to start cycling }; @@ -313,7 +313,7 @@ struct act1 { // Type 1 - Start an object struct act2 { // Type 2 - Initialise an object coords action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int x, y; // Coordinates }; @@ -337,21 +337,21 @@ struct act4 { // Type 4 - Set new backgrou struct act5 { // Type 5 - Initialise an object velocity action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int vx, vy; // velocity }; struct act6 { // Type 6 - Initialise an object carrying action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number bool carriedFl; // carrying }; struct act7 { // Type 7 - Initialise an object to hero's coords action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number }; struct act8 { // Type 8 - switch to new screen @@ -363,14 +363,14 @@ struct act8 { // Type 8 - switch to new sc struct act9 { // Type 9 - Initialise an object state action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number byte newState; // New state }; struct act10 { // Type 10 - Initialise an object path type action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int newPathType; // New path type int8 vxPath, vyPath; // Max delta velocities e.g. for CHASE }; @@ -378,7 +378,7 @@ struct act10 { // Type 10 - Initialise an o struct act11 { // Type 11 - Conditional on object's state action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number byte stateReq; // Required state uint16 actPassIndex; // Ptr to action list if success uint16 actFailIndex; // Ptr to action list if failure @@ -393,14 +393,14 @@ struct act12 { // Type 12 - Simple text box struct act13 { // Type 13 - Swap first object image with second action_t actType; // The type of action int timer; // Time to set off the action - int obj1; // Index of first object - int obj2; // 2nd + int objIndex1; // Index of first object + int objIndex2; // 2nd }; struct act14 { // Type 14 - Conditional on current screen action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The required object + int objIndex; // The required object int screenReq; // The required screen number uint16 actPassIndex; // Ptr to action list if success uint16 actFailIndex; // Ptr to action list if failure @@ -409,8 +409,8 @@ struct act14 { // Type 14 - Conditional on struct act15 { // Type 15 - Home in on an object action_t actType; // The type of action int timer; // Time to set off the action - int obj1; // The object number homing in - int obj2; // The object number to home in on + int objIndex1; // The object number homing in + int objIndex2; // The object number to home in on int8 dx, dy; // Max delta velocities }; // Note: Don't set a sequence at time 0 of a new screen, it causes @@ -418,28 +418,28 @@ struct act15 { // Type 15 - Home in on an o struct act16 { // Type 16 - Set curr_seq_p to seq action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int seqIndex; // The index of seq array to set to }; struct act17 { // Type 17 - SET obj individual state bits action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int stateMask; // The mask to OR with current obj state }; struct act18 { // Type 18 - CLEAR obj individual state bits action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int stateMask; // The mask to ~AND with current obj state }; struct act19 { // Type 19 - TEST obj individual state bits action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int stateMask; // The mask to AND with current obj state uint16 actPassIndex; // Ptr to action list (all bits set) uint16 actFailIndex; // Ptr to action list (not all set) @@ -459,7 +459,7 @@ struct act21 { // Type 21 - Gameover. Disa struct act22 { // Type 22 - Initialise an object to hero's coords action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number }; struct act23 { // Type 23 - Exit game back to DOS @@ -476,7 +476,7 @@ struct act24 { // Type 24 - Get bonus score struct act25 { // Type 25 - Conditional on bounding box action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The required object number + int objIndex; // The required object number int x1, y1, x2, y2; // The bounding box uint16 actPassIndex; // Ptr to action list if success uint16 actFailIndex; // Ptr to action list if failure @@ -491,19 +491,19 @@ struct act26 { // Type 26 - Play a sound struct act27 { // Type 27 - Add object's value to score action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // object number + int objIndex; // object number }; struct act28 { // Type 28 - Subtract object's value from score action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // object number + int objIndex; // object number }; struct act29 { // Type 29 - Conditional on object carried action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The required object number + int objIndex; // The required object number uint16 actPassIndex; // Ptr to action list if success uint16 actFailIndex; // Ptr to action list if failure }; @@ -525,14 +525,14 @@ struct act31 { // Type 31 - Exit special ma struct act32 { // Type 32 - Init fbg field of object action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number byte priority; // Value of foreground/background field }; struct act33 { // Type 33 - Init screen field of object action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int screenIndex; // Screen number }; @@ -567,8 +567,8 @@ struct act37 { // Type 37 - Set new screen struct act38 { // Type 38 - Position lips action_t actType; // The type of action int timer; // Time to set off the action - int lipsObjNumb; // The LIPS object - int objNumb; // The object to speak + int lipsObjIndex; // The LIPS object + int objIndex; // The object to speak byte dxLips; // Relative offset of x byte dyLips; // Relative offset of y }; @@ -596,7 +596,7 @@ struct act41 { // Type 41 - Conditional on struct act42 { // Type 42 - Text box with "take" string action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object taken + int objIndex; // The object taken }; struct act43 { // Type 43 - Prompt user for Yes or No @@ -629,7 +629,7 @@ struct act46 { // Type 46 - Init status.jum struct act47 { // Type 47 - Init viewx,viewy,dir action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object + int objIndex; // The object int16 viewx; // object.viewx int16 viewy; // object.viewy int16 direction; // object.dir @@ -638,7 +638,7 @@ struct act47 { // Type 47 - Init viewx,view struct act48 { // Type 48 - Set curr_seq_p to frame n action_t actType; // The type of action int timer; // Time to set off the action - int objNumb; // The object number + int objIndex; // The object number int seqIndex; // The index of seq array to set to int frameIndex; // The index of frame to set to }; diff --git a/engines/hugo/object.h b/engines/hugo/object.h index c8e1be7f75..922ae75d27 100644 --- a/engines/hugo/object.h +++ b/engines/hugo/object.h @@ -50,7 +50,7 @@ public: virtual void moveObjects() = 0; virtual void updateImages() = 0; - virtual void swapImages(int objNumb1, int objNumb2) = 0; + virtual void swapImages(int objIndex1, int objIndex2) = 0; bool isCarrying(uint16 wordIndex); bool findObjectSpace(object_t *obj, int16 *destx, int16 *desty); @@ -105,7 +105,7 @@ public: void moveObjects(); void updateImages(); - void swapImages(int objNumb1, int objNumb2); + void swapImages(int objIndex1, int objIndex2); }; class ObjectHandler_v1w : public ObjectHandler { @@ -115,7 +115,7 @@ public: void moveObjects(); void updateImages(); - void swapImages(int objNumb1, int objNumb2); + void swapImages(int objIndex1, int objIndex2); }; class ObjectHandler_v2d : public ObjectHandler_v1d { @@ -133,7 +133,7 @@ public: ~ObjectHandler_v3d(); void moveObjects(); - void swapImages(int objNumb1, int objNumb2); + void swapImages(int objIndex1, int objIndex2); }; } // End of namespace Hugo diff --git a/engines/hugo/object_v1d.cpp b/engines/hugo/object_v1d.cpp index fa0283665c..76b114f354 100644 --- a/engines/hugo/object_v1d.cpp +++ b/engines/hugo/object_v1d.cpp @@ -353,18 +353,18 @@ void ObjectHandler_v1d::moveObjects() { * the assumption for now that the first obj is always the HERO) to the object * number of the swapped image */ -void ObjectHandler_v1d::swapImages(int objNumb1, int objNumb2) { - debugC(1, kDebugObject, "swapImages(%d, %d)", objNumb1, objNumb2); +void ObjectHandler_v1d::swapImages(int objIndex1, int objIndex2) { + debugC(1, kDebugObject, "swapImages(%d, %d)", objIndex1, objIndex2); seqList_t tmpSeqList[MAX_SEQUENCES]; int seqListSize = sizeof(seqList_t) * MAX_SEQUENCES; - memmove(tmpSeqList, _objects[objNumb1].seqList, seqListSize); - memmove(_objects[objNumb1].seqList, _objects[objNumb2].seqList, seqListSize); - memmove(_objects[objNumb2].seqList, tmpSeqList, seqListSize); - _objects[objNumb1].currImagePtr = _objects[objNumb1].seqList[0].seqPtr; - _objects[objNumb2].currImagePtr = _objects[objNumb2].seqList[0].seqPtr; - _vm->_heroImage = (_vm->_heroImage == HERO) ? objNumb2 : HERO; + memmove(tmpSeqList, _objects[objIndex1].seqList, seqListSize); + memmove(_objects[objIndex1].seqList, _objects[objIndex2].seqList, seqListSize); + memmove(_objects[objIndex2].seqList, tmpSeqList, seqListSize); + _objects[objIndex1].currImagePtr = _objects[objIndex1].seqList[0].seqPtr; + _objects[objIndex2].currImagePtr = _objects[objIndex2].seqList[0].seqPtr; + _vm->_heroImage = (_vm->_heroImage == HERO) ? objIndex2 : HERO; } } // End of namespace Hugo diff --git a/engines/hugo/object_v1w.cpp b/engines/hugo/object_v1w.cpp index 685a3fee23..015c85ea8d 100644 --- a/engines/hugo/object_v1w.cpp +++ b/engines/hugo/object_v1w.cpp @@ -363,23 +363,23 @@ void ObjectHandler_v1w::moveObjects() { * the assumption for now that the first obj is always the HERO) to the object * number of the swapped image */ -void ObjectHandler_v1w::swapImages(int objNumb1, int objNumb2) { - debugC(1, kDebugObject, "swapImages(%d, %d)", objNumb1, objNumb2); +void ObjectHandler_v1w::swapImages(int objIndex1, int objIndex2) { + debugC(1, kDebugObject, "swapImages(%d, %d)", objIndex1, objIndex2); - saveSeq(&_objects[objNumb1]); + saveSeq(&_objects[objIndex1]); seqList_t tmpSeqList[MAX_SEQUENCES]; int seqListSize = sizeof(seqList_t) * MAX_SEQUENCES; - memmove(tmpSeqList, _objects[objNumb1].seqList, seqListSize); - memmove(_objects[objNumb1].seqList, _objects[objNumb2].seqList, seqListSize); - memmove(_objects[objNumb2].seqList, tmpSeqList, seqListSize); - restoreSeq(&_objects[objNumb1]); - _objects[objNumb2].currImagePtr = _objects[objNumb2].seqList[0].seqPtr; - _vm->_heroImage = (_vm->_heroImage == HERO) ? objNumb2 : HERO; + memmove(tmpSeqList, _objects[objIndex1].seqList, seqListSize); + memmove(_objects[objIndex1].seqList, _objects[objIndex2].seqList, seqListSize); + memmove(_objects[objIndex2].seqList, tmpSeqList, seqListSize); + restoreSeq(&_objects[objIndex1]); + _objects[objIndex2].currImagePtr = _objects[objIndex2].seqList[0].seqPtr; + _vm->_heroImage = (_vm->_heroImage == HERO) ? objIndex2 : HERO; // Make sure baseline stays constant - _objects[objNumb1].y += _objects[objNumb2].currImagePtr->y2 - _objects[objNumb1].currImagePtr->y2; + _objects[objIndex1].y += _objects[objIndex2].currImagePtr->y2 - _objects[objIndex1].currImagePtr->y2; } } // End of namespace Hugo diff --git a/engines/hugo/object_v3d.cpp b/engines/hugo/object_v3d.cpp index 4ca5b6a19e..1954830d81 100644 --- a/engines/hugo/object_v3d.cpp +++ b/engines/hugo/object_v3d.cpp @@ -248,23 +248,23 @@ void ObjectHandler_v3d::moveObjects() { * the assumption for now that the first obj is always the HERO) to the object * number of the swapped image */ -void ObjectHandler_v3d::swapImages(int objNumb1, int objNumb2) { - debugC(1, kDebugObject, "swapImages(%d, %d)", objNumb1, objNumb2); +void ObjectHandler_v3d::swapImages(int objIndex1, int objIndex2) { + debugC(1, kDebugObject, "swapImages(%d, %d)", objIndex1, objIndex2); - saveSeq(&_objects[objNumb1]); + saveSeq(&_objects[objIndex1]); seqList_t tmpSeqList[MAX_SEQUENCES]; int seqListSize = sizeof(seqList_t) * MAX_SEQUENCES; - memmove(tmpSeqList, _objects[objNumb1].seqList, seqListSize); - memmove(_objects[objNumb1].seqList, _objects[objNumb2].seqList, seqListSize); - memmove(_objects[objNumb2].seqList, tmpSeqList, seqListSize); - restoreSeq(&_objects[objNumb1]); - _objects[objNumb2].currImagePtr = _objects[objNumb2].seqList[0].seqPtr; - _vm->_heroImage = (_vm->_heroImage == HERO) ? objNumb2 : HERO; + memmove(tmpSeqList, _objects[objIndex1].seqList, seqListSize); + memmove(_objects[objIndex1].seqList, _objects[objIndex2].seqList, seqListSize); + memmove(_objects[objIndex2].seqList, tmpSeqList, seqListSize); + restoreSeq(&_objects[objIndex1]); + _objects[objIndex2].currImagePtr = _objects[objIndex2].seqList[0].seqPtr; + _vm->_heroImage = (_vm->_heroImage == HERO) ? objIndex2 : HERO; // Make sure baseline stays constant - _objects[objNumb1].y += _objects[objNumb2].currImagePtr->y2 - _objects[objNumb1].currImagePtr->y2; + _objects[objIndex1].y += _objects[objIndex2].currImagePtr->y2 - _objects[objIndex1].currImagePtr->y2; } } // End of namespace Hugo diff --git a/engines/hugo/schedule.cpp b/engines/hugo/schedule.cpp index 722c5a03cb..361352d95b 100644 --- a/engines/hugo/schedule.cpp +++ b/engines/hugo/schedule.cpp @@ -280,13 +280,13 @@ void Scheduler::loadActListArr(Common::File &in) { break; case START_OBJ: // 1 _actListArr[i][j].a1.timer = in.readSint16BE(); - _actListArr[i][j].a1.objNumb = in.readSint16BE(); + _actListArr[i][j].a1.objIndex = in.readSint16BE(); _actListArr[i][j].a1.cycleNumb = in.readSint16BE(); _actListArr[i][j].a1.cycle = (cycle_t) in.readByte(); break; case INIT_OBJXY: // 2 _actListArr[i][j].a2.timer = in.readSint16BE(); - _actListArr[i][j].a2.objNumb = in.readSint16BE(); + _actListArr[i][j].a2.objIndex = in.readSint16BE(); _actListArr[i][j].a2.x = in.readSint16BE(); _actListArr[i][j].a2.y = in.readSint16BE(); break; @@ -307,18 +307,18 @@ void Scheduler::loadActListArr(Common::File &in) { break; case INIT_OBJVXY: // 5 _actListArr[i][j].a5.timer = in.readSint16BE(); - _actListArr[i][j].a5.objNumb = in.readSint16BE(); + _actListArr[i][j].a5.objIndex = in.readSint16BE(); _actListArr[i][j].a5.vx = in.readSint16BE(); _actListArr[i][j].a5.vy = in.readSint16BE(); break; case INIT_CARRY: // 6 _actListArr[i][j].a6.timer = in.readSint16BE(); - _actListArr[i][j].a6.objNumb = in.readSint16BE(); + _actListArr[i][j].a6.objIndex = in.readSint16BE(); _actListArr[i][j].a6.carriedFl = (in.readByte() == 1) ? true : false; break; case INIT_HF_COORD: // 7 _actListArr[i][j].a7.timer = in.readSint16BE(); - _actListArr[i][j].a7.objNumb = in.readSint16BE(); + _actListArr[i][j].a7.objIndex = in.readSint16BE(); break; case NEW_SCREEN: // 8 _actListArr[i][j].a8.timer = in.readSint16BE(); @@ -326,19 +326,19 @@ void Scheduler::loadActListArr(Common::File &in) { break; case INIT_OBJSTATE: // 9 _actListArr[i][j].a9.timer = in.readSint16BE(); - _actListArr[i][j].a9.objNumb = in.readSint16BE(); + _actListArr[i][j].a9.objIndex = in.readSint16BE(); _actListArr[i][j].a9.newState = in.readByte(); break; case INIT_PATH: // 10 _actListArr[i][j].a10.timer = in.readSint16BE(); - _actListArr[i][j].a10.objNumb = in.readSint16BE(); + _actListArr[i][j].a10.objIndex = in.readSint16BE(); _actListArr[i][j].a10.newPathType = in.readSint16BE(); _actListArr[i][j].a10.vxPath = in.readByte(); _actListArr[i][j].a10.vyPath = in.readByte(); break; case COND_R: // 11 _actListArr[i][j].a11.timer = in.readSint16BE(); - _actListArr[i][j].a11.objNumb = in.readSint16BE(); + _actListArr[i][j].a11.objIndex = in.readSint16BE(); _actListArr[i][j].a11.stateReq = in.readByte(); _actListArr[i][j].a11.actPassIndex = in.readUint16BE(); _actListArr[i][j].a11.actFailIndex = in.readUint16BE(); @@ -349,41 +349,41 @@ void Scheduler::loadActListArr(Common::File &in) { break; case SWAP_IMAGES: // 13 _actListArr[i][j].a13.timer = in.readSint16BE(); - _actListArr[i][j].a13.obj1 = in.readSint16BE(); - _actListArr[i][j].a13.obj2 = in.readSint16BE(); + _actListArr[i][j].a13.objIndex1 = in.readSint16BE(); + _actListArr[i][j].a13.objIndex2 = in.readSint16BE(); break; case COND_SCR: // 14 _actListArr[i][j].a14.timer = in.readSint16BE(); - _actListArr[i][j].a14.objNumb = in.readSint16BE(); + _actListArr[i][j].a14.objIndex = in.readSint16BE(); _actListArr[i][j].a14.screenReq = in.readSint16BE(); _actListArr[i][j].a14.actPassIndex = in.readUint16BE(); _actListArr[i][j].a14.actFailIndex = in.readUint16BE(); break; case AUTOPILOT: // 15 _actListArr[i][j].a15.timer = in.readSint16BE(); - _actListArr[i][j].a15.obj1 = in.readSint16BE(); - _actListArr[i][j].a15.obj2 = in.readSint16BE(); + _actListArr[i][j].a15.objIndex1 = in.readSint16BE(); + _actListArr[i][j].a15.objIndex2 = in.readSint16BE(); _actListArr[i][j].a15.dx = in.readByte(); _actListArr[i][j].a15.dy = in.readByte(); break; case INIT_OBJ_SEQ: // 16 _actListArr[i][j].a16.timer = in.readSint16BE(); - _actListArr[i][j].a16.objNumb = in.readSint16BE(); + _actListArr[i][j].a16.objIndex = in.readSint16BE(); _actListArr[i][j].a16.seqIndex = in.readSint16BE(); break; case SET_STATE_BITS: // 17 _actListArr[i][j].a17.timer = in.readSint16BE(); - _actListArr[i][j].a17.objNumb = in.readSint16BE(); + _actListArr[i][j].a17.objIndex = in.readSint16BE(); _actListArr[i][j].a17.stateMask = in.readSint16BE(); break; case CLEAR_STATE_BITS: // 18 _actListArr[i][j].a18.timer = in.readSint16BE(); - _actListArr[i][j].a18.objNumb = in.readSint16BE(); + _actListArr[i][j].a18.objIndex = in.readSint16BE(); _actListArr[i][j].a18.stateMask = in.readSint16BE(); break; case TEST_STATE_BITS: // 19 _actListArr[i][j].a19.timer = in.readSint16BE(); - _actListArr[i][j].a19.objNumb = in.readSint16BE(); + _actListArr[i][j].a19.objIndex = in.readSint16BE(); _actListArr[i][j].a19.stateMask = in.readSint16BE(); _actListArr[i][j].a19.actPassIndex = in.readUint16BE(); _actListArr[i][j].a19.actFailIndex = in.readUint16BE(); @@ -397,7 +397,7 @@ void Scheduler::loadActListArr(Common::File &in) { break; case INIT_HH_COORD: // 22 _actListArr[i][j].a22.timer = in.readSint16BE(); - _actListArr[i][j].a22.objNumb = in.readSint16BE(); + _actListArr[i][j].a22.objIndex = in.readSint16BE(); break; case EXIT: // 23 _actListArr[i][j].a23.timer = in.readSint16BE(); @@ -408,7 +408,7 @@ void Scheduler::loadActListArr(Common::File &in) { break; case COND_BOX: // 25 _actListArr[i][j].a25.timer = in.readSint16BE(); - _actListArr[i][j].a25.objNumb = in.readSint16BE(); + _actListArr[i][j].a25.objIndex = in.readSint16BE(); _actListArr[i][j].a25.x1 = in.readSint16BE(); _actListArr[i][j].a25.y1 = in.readSint16BE(); _actListArr[i][j].a25.x2 = in.readSint16BE(); @@ -422,15 +422,15 @@ void Scheduler::loadActListArr(Common::File &in) { break; case ADD_SCORE: // 27 _actListArr[i][j].a27.timer = in.readSint16BE(); - _actListArr[i][j].a27.objNumb = in.readSint16BE(); + _actListArr[i][j].a27.objIndex = in.readSint16BE(); break; case SUB_SCORE: // 28 _actListArr[i][j].a28.timer = in.readSint16BE(); - _actListArr[i][j].a28.objNumb = in.readSint16BE(); + _actListArr[i][j].a28.objIndex = in.readSint16BE(); break; case COND_CARRY: // 29 _actListArr[i][j].a29.timer = in.readSint16BE(); - _actListArr[i][j].a29.objNumb = in.readSint16BE(); + _actListArr[i][j].a29.objIndex = in.readSint16BE(); _actListArr[i][j].a29.actPassIndex = in.readUint16BE(); _actListArr[i][j].a29.actFailIndex = in.readUint16BE(); break; @@ -450,12 +450,12 @@ void Scheduler::loadActListArr(Common::File &in) { break; case INIT_PRIORITY: // 32 _actListArr[i][j].a32.timer = in.readSint16BE(); - _actListArr[i][j].a32.objNumb = in.readSint16BE(); + _actListArr[i][j].a32.objIndex = in.readSint16BE(); _actListArr[i][j].a32.priority = in.readByte(); break; case INIT_SCREEN: // 33 _actListArr[i][j].a33.timer = in.readSint16BE(); - _actListArr[i][j].a33.objNumb = in.readSint16BE(); + _actListArr[i][j].a33.objIndex = in.readSint16BE(); _actListArr[i][j].a33.screenIndex = in.readSint16BE(); break; case AGSCHEDULE: // 34 @@ -480,8 +480,8 @@ void Scheduler::loadActListArr(Common::File &in) { break; case INIT_LIPS: // 38 _actListArr[i][j].a38.timer = in.readSint16BE(); - _actListArr[i][j].a38.lipsObjNumb = in.readSint16BE(); - _actListArr[i][j].a38.objNumb = in.readSint16BE(); + _actListArr[i][j].a38.lipsObjIndex = in.readSint16BE(); + _actListArr[i][j].a38.objIndex = in.readSint16BE(); _actListArr[i][j].a38.dxLips = in.readByte(); _actListArr[i][j].a38.dyLips = in.readByte(); break; @@ -501,7 +501,7 @@ void Scheduler::loadActListArr(Common::File &in) { break; case TEXT_TAKE: // 42 _actListArr[i][j].a42.timer = in.readSint16BE(); - _actListArr[i][j].a42.objNumb = in.readSint16BE(); + _actListArr[i][j].a42.objIndex = in.readSint16BE(); break; case YESNO: // 43 _actListArr[i][j].a43.timer = in.readSint16BE(); @@ -524,14 +524,14 @@ void Scheduler::loadActListArr(Common::File &in) { break; case INIT_VIEW: // 47 _actListArr[i][j].a47.timer = in.readSint16BE(); - _actListArr[i][j].a47.objNumb = in.readSint16BE(); + _actListArr[i][j].a47.objIndex = in.readSint16BE(); _actListArr[i][j].a47.viewx = in.readSint16BE(); _actListArr[i][j].a47.viewy = in.readSint16BE(); _actListArr[i][j].a47.direction = in.readSint16BE(); break; case INIT_OBJ_FRAME: // 48 _actListArr[i][j].a48.timer = in.readSint16BE(); - _actListArr[i][j].a48.objNumb = in.readSint16BE(); + _actListArr[i][j].a48.objIndex = in.readSint16BE(); _actListArr[i][j].a48.seqIndex = in.readSint16BE(); _actListArr[i][j].a48.frameIndex = in.readSint16BE(); break; diff --git a/engines/hugo/schedule_v1d.cpp b/engines/hugo/schedule_v1d.cpp index f49ce1b238..966085260b 100644 --- a/engines/hugo/schedule_v1d.cpp +++ b/engines/hugo/schedule_v1d.cpp @@ -106,12 +106,12 @@ event_t *Scheduler_v1d::doAction(event_t *curEvent) { insertActionList(action->a0.actIndex); break; case START_OBJ: // act1: Start an object cycling - _vm->_object->_objects[action->a1.objNumb].cycleNumb = action->a1.cycleNumb; - _vm->_object->_objects[action->a1.objNumb].cycling = action->a1.cycle; + _vm->_object->_objects[action->a1.objIndex].cycleNumb = action->a1.cycleNumb; + _vm->_object->_objects[action->a1.objIndex].cycling = action->a1.cycle; break; case INIT_OBJXY: // act2: Initialise an object - _vm->_object->_objects[action->a2.objNumb].x = action->a2.x; // Coordinates - _vm->_object->_objects[action->a2.objNumb].y = action->a2.y; + _vm->_object->_objects[action->a2.objIndex].x = action->a2.x; // Coordinates + _vm->_object->_objects[action->a2.objIndex].y = action->a2.y; break; case PROMPT: { // act3: Prompt user for key phrase response = Utils::Box(BOX_PROMPT, "%s", _vm->_file->fetchString(action->a3.promptIndex)); @@ -137,27 +137,27 @@ event_t *Scheduler_v1d::doAction(event_t *curEvent) { _vm->_screen->setBackgroundColor(action->a4.newBackgroundColor); break; case INIT_OBJVXY: // act5: Initialise an object velocity - _vm->_object->setVelocity(action->a5.objNumb, action->a5.vx, action->a5.vy); + _vm->_object->setVelocity(action->a5.objIndex, action->a5.vx, action->a5.vy); break; case INIT_CARRY: // act6: Initialise an object - _vm->_object->setCarry(action->a6.objNumb, action->a6.carriedFl); // carried status + _vm->_object->setCarry(action->a6.objIndex, action->a6.carriedFl); // carried status break; case INIT_HF_COORD: // act7: Initialise an object to hero's "feet" coords - _vm->_object->_objects[action->a7.objNumb].x = _vm->_hero->x - 1; - _vm->_object->_objects[action->a7.objNumb].y = _vm->_hero->y + _vm->_hero->currImagePtr->y2 - 1; - _vm->_object->_objects[action->a7.objNumb].screenIndex = *_vm->_screen_p; // Don't forget screen! + _vm->_object->_objects[action->a7.objIndex].x = _vm->_hero->x - 1; + _vm->_object->_objects[action->a7.objIndex].y = _vm->_hero->y + _vm->_hero->currImagePtr->y2 - 1; + _vm->_object->_objects[action->a7.objIndex].screenIndex = *_vm->_screen_p; // Don't forget screen! break; case NEW_SCREEN: // act8: Start new screen newScreen(action->a8.screenIndex); break; case INIT_OBJSTATE: // act9: Initialise an object state - _vm->_object->_objects[action->a9.objNumb].state = action->a9.newState; + _vm->_object->_objects[action->a9.objIndex].state = action->a9.newState; break; case INIT_PATH: // act10: Initialise an object path and velocity - _vm->_object->setPath(action->a10.objNumb, (path_t) action->a10.newPathType, action->a10.vxPath, action->a10.vyPath); + _vm->_object->setPath(action->a10.objIndex, (path_t) action->a10.newPathType, action->a10.vxPath, action->a10.vyPath); break; case COND_R: // act11: action lists conditional on object state - if (_vm->_object->_objects[action->a11.objNumb].state == action->a11.stateReq) + if (_vm->_object->_objects[action->a11.objIndex].state == action->a11.stateReq) insertActionList(action->a11.actPassIndex); else insertActionList(action->a11.actFailIndex); @@ -166,18 +166,18 @@ event_t *Scheduler_v1d::doAction(event_t *curEvent) { Utils::Box(BOX_ANY, "%s", _vm->_file->fetchString(action->a12.stringIndex)); // Fetch string from file break; case SWAP_IMAGES: // act13: Swap 2 object images - _vm->_object->swapImages(action->a13.obj1, action->a13.obj2); + _vm->_object->swapImages(action->a13.objIndex1, action->a13.objIndex2); break; case COND_SCR: // act14: Conditional on current screen - if (_vm->_object->_objects[action->a14.objNumb].screenIndex == action->a14.screenReq) + if (_vm->_object->_objects[action->a14.objIndex].screenIndex == action->a14.screenReq) insertActionList(action->a14.actPassIndex); else insertActionList(action->a14.actFailIndex); break; case AUTOPILOT: // act15: Home in on a (stationary) object // object p1 will home in on object p2 - obj1 = &_vm->_object->_objects[action->a15.obj1]; - obj2 = &_vm->_object->_objects[action->a15.obj2]; + obj1 = &_vm->_object->_objects[action->a15.objIndex1]; + obj2 = &_vm->_object->_objects[action->a15.objIndex2]; obj1->pathType = AUTO; dx = obj1->x + obj1->currImagePtr->x1 - obj2->x - obj2->currImagePtr->x1; dy = obj1->y + obj1->currImagePtr->y1 - obj2->y - obj2->currImagePtr->y1; @@ -198,16 +198,16 @@ event_t *Scheduler_v1d::doAction(event_t *curEvent) { case INIT_OBJ_SEQ: // act16: Set sequence number to use // Note: Don't set a sequence at time 0 of a new screen, it causes // problems clearing the boundary bits of the object! t>0 is safe - _vm->_object->_objects[action->a16.objNumb].currImagePtr = _vm->_object->_objects[action->a16.objNumb].seqList[action->a16.seqIndex].seqPtr; + _vm->_object->_objects[action->a16.objIndex].currImagePtr = _vm->_object->_objects[action->a16.objIndex].seqList[action->a16.seqIndex].seqPtr; break; case SET_STATE_BITS: // act17: OR mask with curr obj state - _vm->_object->_objects[action->a17.objNumb].state |= action->a17.stateMask; + _vm->_object->_objects[action->a17.objIndex].state |= action->a17.stateMask; break; case CLEAR_STATE_BITS: // act18: AND ~mask with curr obj state - _vm->_object->_objects[action->a18.objNumb].state &= ~action->a18.stateMask; + _vm->_object->_objects[action->a18.objIndex].state &= ~action->a18.stateMask; break; case TEST_STATE_BITS: // act19: If all bits set, do apass else afail - if ((_vm->_object->_objects[action->a19.objNumb].state & action->a19.stateMask) == action->a19.stateMask) + if ((_vm->_object->_objects[action->a19.objIndex].state & action->a19.stateMask) == action->a19.stateMask) insertActionList(action->a19.actPassIndex); else insertActionList(action->a19.actFailIndex); @@ -227,9 +227,9 @@ event_t *Scheduler_v1d::doAction(event_t *curEvent) { gameStatus.gameOverFl = true; break; case INIT_HH_COORD: // act22: Initialise an object to hero's actual coords - _vm->_object->_objects[action->a22.objNumb].x = _vm->_hero->x; - _vm->_object->_objects[action->a22.objNumb].y = _vm->_hero->y; - _vm->_object->_objects[action->a22.objNumb].screenIndex = *_vm->_screen_p;// Don't forget screen! + _vm->_object->_objects[action->a22.objIndex].x = _vm->_hero->x; + _vm->_object->_objects[action->a22.objIndex].y = _vm->_hero->y; + _vm->_object->_objects[action->a22.objIndex].screenIndex = *_vm->_screen_p;// Don't forget screen! break; case EXIT: // act23: Exit game back to DOS _vm->endGame(); @@ -238,7 +238,7 @@ event_t *Scheduler_v1d::doAction(event_t *curEvent) { processBonus(action->a24.pointIndex); break; case COND_BOX: // act25: Conditional on bounding box - obj1 = &_vm->_object->_objects[action->a25.objNumb]; + obj1 = &_vm->_object->_objects[action->a25.objIndex]; dx = obj1->x + obj1->currImagePtr->x1; dy = obj1->y + obj1->currImagePtr->y2; if ((dx >= action->a25.x1) && (dx <= action->a25.x2) && @@ -248,13 +248,13 @@ event_t *Scheduler_v1d::doAction(event_t *curEvent) { insertActionList(action->a25.actFailIndex); break; case ADD_SCORE: // act27: Add object's value to score - _vm->adjustScore(_vm->_object->_objects[action->a27.objNumb].objValue); + _vm->adjustScore(_vm->_object->_objects[action->a27.objIndex].objValue); break; case SUB_SCORE: // act28: Subtract object's value from score - _vm->adjustScore(-_vm->_object->_objects[action->a28.objNumb].objValue); + _vm->adjustScore(-_vm->_object->_objects[action->a28.objIndex].objValue); break; case COND_CARRY: // act29: Conditional on object being carried - if (_vm->_object->isCarried(action->a29.objNumb)) + if (_vm->_object->isCarried(action->a29.objIndex)) insertActionList(action->a29.actPassIndex); else insertActionList(action->a29.actFailIndex); diff --git a/engines/hugo/schedule_v2d.cpp b/engines/hugo/schedule_v2d.cpp index 8764826e52..191b33ed4a 100644 --- a/engines/hugo/schedule_v2d.cpp +++ b/engines/hugo/schedule_v2d.cpp @@ -114,12 +114,12 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { insertActionList(action->a0.actIndex); break; case START_OBJ: // act1: Start an object cycling - _vm->_object->_objects[action->a1.objNumb].cycleNumb = action->a1.cycleNumb; - _vm->_object->_objects[action->a1.objNumb].cycling = action->a1.cycle; + _vm->_object->_objects[action->a1.objIndex].cycleNumb = action->a1.cycleNumb; + _vm->_object->_objects[action->a1.objIndex].cycling = action->a1.cycle; break; case INIT_OBJXY: // act2: Initialise an object - _vm->_object->_objects[action->a2.objNumb].x = action->a2.x; // Coordinates - _vm->_object->_objects[action->a2.objNumb].y = action->a2.y; + _vm->_object->_objects[action->a2.objIndex].x = action->a2.x; // Coordinates + _vm->_object->_objects[action->a2.objIndex].y = action->a2.y; break; case PROMPT: { // act3: Prompt user for key phrase response = Utils::Box(BOX_PROMPT, "%s", _vm->_file->fetchString(action->a3.promptIndex)); @@ -151,27 +151,27 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { _vm->_screen->setBackgroundColor(action->a4.newBackgroundColor); break; case INIT_OBJVXY: // act5: Initialise an object velocity - _vm->_object->setVelocity(action->a5.objNumb, action->a5.vx, action->a5.vy); + _vm->_object->setVelocity(action->a5.objIndex, action->a5.vx, action->a5.vy); break; case INIT_CARRY: // act6: Initialise an object - _vm->_object->setCarry(action->a6.objNumb, action->a6.carriedFl); // carried status + _vm->_object->setCarry(action->a6.objIndex, action->a6.carriedFl); // carried status break; case INIT_HF_COORD: // act7: Initialise an object to hero's "feet" coords - _vm->_object->_objects[action->a7.objNumb].x = _vm->_hero->x - 1; - _vm->_object->_objects[action->a7.objNumb].y = _vm->_hero->y + _vm->_hero->currImagePtr->y2 - 1; - _vm->_object->_objects[action->a7.objNumb].screenIndex = *_vm->_screen_p; // Don't forget screen! + _vm->_object->_objects[action->a7.objIndex].x = _vm->_hero->x - 1; + _vm->_object->_objects[action->a7.objIndex].y = _vm->_hero->y + _vm->_hero->currImagePtr->y2 - 1; + _vm->_object->_objects[action->a7.objIndex].screenIndex = *_vm->_screen_p; // Don't forget screen! break; case NEW_SCREEN: // act8: Start new screen newScreen(action->a8.screenIndex); break; case INIT_OBJSTATE: // act9: Initialise an object state - _vm->_object->_objects[action->a9.objNumb].state = action->a9.newState; + _vm->_object->_objects[action->a9.objIndex].state = action->a9.newState; break; case INIT_PATH: // act10: Initialise an object path and velocity - _vm->_object->setPath(action->a10.objNumb, (path_t) action->a10.newPathType, action->a10.vxPath, action->a10.vyPath); + _vm->_object->setPath(action->a10.objIndex, (path_t) action->a10.newPathType, action->a10.vxPath, action->a10.vyPath); break; case COND_R: // act11: action lists conditional on object state - if (_vm->_object->_objects[action->a11.objNumb].state == action->a11.stateReq) + if (_vm->_object->_objects[action->a11.objIndex].state == action->a11.stateReq) insertActionList(action->a11.actPassIndex); else insertActionList(action->a11.actFailIndex); @@ -180,18 +180,18 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { Utils::Box(BOX_ANY, "%s", _vm->_file->fetchString(action->a12.stringIndex)); // Fetch string from file break; case SWAP_IMAGES: // act13: Swap 2 object images - _vm->_object->swapImages(action->a13.obj1, action->a13.obj2); + _vm->_object->swapImages(action->a13.objIndex1, action->a13.objIndex2); break; case COND_SCR: // act14: Conditional on current screen - if (_vm->_object->_objects[action->a14.objNumb].screenIndex == action->a14.screenReq) + if (_vm->_object->_objects[action->a14.objIndex].screenIndex == action->a14.screenReq) insertActionList(action->a14.actPassIndex); else insertActionList(action->a14.actFailIndex); break; case AUTOPILOT: // act15: Home in on a (stationary) object // object p1 will home in on object p2 - obj1 = &_vm->_object->_objects[action->a15.obj1]; - obj2 = &_vm->_object->_objects[action->a15.obj2]; + obj1 = &_vm->_object->_objects[action->a15.objIndex1]; + obj2 = &_vm->_object->_objects[action->a15.objIndex2]; obj1->pathType = AUTO; dx = obj1->x + obj1->currImagePtr->x1 - obj2->x - obj2->currImagePtr->x1; dy = obj1->y + obj1->currImagePtr->y1 - obj2->y - obj2->currImagePtr->y1; @@ -212,16 +212,16 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { case INIT_OBJ_SEQ: // act16: Set sequence number to use // Note: Don't set a sequence at time 0 of a new screen, it causes // problems clearing the boundary bits of the object! t>0 is safe - _vm->_object->_objects[action->a16.objNumb].currImagePtr = _vm->_object->_objects[action->a16.objNumb].seqList[action->a16.seqIndex].seqPtr; + _vm->_object->_objects[action->a16.objIndex].currImagePtr = _vm->_object->_objects[action->a16.objIndex].seqList[action->a16.seqIndex].seqPtr; break; case SET_STATE_BITS: // act17: OR mask with curr obj state - _vm->_object->_objects[action->a17.objNumb].state |= action->a17.stateMask; + _vm->_object->_objects[action->a17.objIndex].state |= action->a17.stateMask; break; case CLEAR_STATE_BITS: // act18: AND ~mask with curr obj state - _vm->_object->_objects[action->a18.objNumb].state &= ~action->a18.stateMask; + _vm->_object->_objects[action->a18.objIndex].state &= ~action->a18.stateMask; break; case TEST_STATE_BITS: // act19: If all bits set, do apass else afail - if ((_vm->_object->_objects[action->a19.objNumb].state & action->a19.stateMask) == action->a19.stateMask) + if ((_vm->_object->_objects[action->a19.objIndex].state & action->a19.stateMask) == action->a19.stateMask) insertActionList(action->a19.actPassIndex); else insertActionList(action->a19.actFailIndex); @@ -242,9 +242,9 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { gameStatus.gameOverFl = true; break; case INIT_HH_COORD: // act22: Initialise an object to hero's actual coords - _vm->_object->_objects[action->a22.objNumb].x = _vm->_hero->x; - _vm->_object->_objects[action->a22.objNumb].y = _vm->_hero->y; - _vm->_object->_objects[action->a22.objNumb].screenIndex = *_vm->_screen_p;// Don't forget screen! + _vm->_object->_objects[action->a22.objIndex].x = _vm->_hero->x; + _vm->_object->_objects[action->a22.objIndex].y = _vm->_hero->y; + _vm->_object->_objects[action->a22.objIndex].screenIndex = *_vm->_screen_p;// Don't forget screen! break; case EXIT: // act23: Exit game back to DOS _vm->endGame(); @@ -253,7 +253,7 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { processBonus(action->a24.pointIndex); break; case COND_BOX: // act25: Conditional on bounding box - obj1 = &_vm->_object->_objects[action->a25.objNumb]; + obj1 = &_vm->_object->_objects[action->a25.objIndex]; dx = obj1->x + obj1->currImagePtr->x1; dy = obj1->y + obj1->currImagePtr->y2; if ((dx >= action->a25.x1) && (dx <= action->a25.x2) && @@ -269,13 +269,13 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { _vm->_sound->playSound(action->a26.soundIndex, BOTH_CHANNELS, MED_PRI); break; case ADD_SCORE: // act27: Add object's value to score - _vm->adjustScore(_vm->_object->_objects[action->a27.objNumb].objValue); + _vm->adjustScore(_vm->_object->_objects[action->a27.objIndex].objValue); break; case SUB_SCORE: // act28: Subtract object's value from score - _vm->adjustScore(-_vm->_object->_objects[action->a28.objNumb].objValue); + _vm->adjustScore(-_vm->_object->_objects[action->a28.objIndex].objValue); break; case COND_CARRY: // act29: Conditional on object being carried - if (_vm->_object->isCarried(action->a29.objNumb)) + if (_vm->_object->isCarried(action->a29.objIndex)) insertActionList(action->a29.actPassIndex); else insertActionList(action->a29.actFailIndex); @@ -295,10 +295,10 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { _maze.enabledFl = false; break; case INIT_PRIORITY: - _vm->_object->_objects[action->a32.objNumb].priority = action->a32.priority; + _vm->_object->_objects[action->a32.objIndex].priority = action->a32.priority; break; case INIT_SCREEN: - _vm->_object->_objects[action->a33.objNumb].screenIndex = action->a33.screenIndex; + _vm->_object->_objects[action->a33.objIndex].screenIndex = action->a33.screenIndex; break; case AGSCHEDULE: // act34: Schedule a (global) action list insertActionList(action->a34.actIndex); @@ -316,10 +316,10 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { _vm->_screenStates[action->a37.screenIndex] = action->a37.newState; break; case INIT_LIPS: // act38: Position lips on object - _vm->_object->_objects[action->a38.lipsObjNumb].x = _vm->_object->_objects[action->a38.objNumb].x + action->a38.dxLips; - _vm->_object->_objects[action->a38.lipsObjNumb].y = _vm->_object->_objects[action->a38.objNumb].y + action->a38.dyLips; - _vm->_object->_objects[action->a38.lipsObjNumb].screenIndex = *_vm->_screen_p; // Don't forget screen! - _vm->_object->_objects[action->a38.lipsObjNumb].cycling = CYCLE_FORWARD; + _vm->_object->_objects[action->a38.lipsObjIndex].x = _vm->_object->_objects[action->a38.objIndex].x + action->a38.dxLips; + _vm->_object->_objects[action->a38.lipsObjIndex].y = _vm->_object->_objects[action->a38.objIndex].y + action->a38.dyLips; + _vm->_object->_objects[action->a38.lipsObjIndex].screenIndex = *_vm->_screen_p; // Don't forget screen! + _vm->_object->_objects[action->a38.lipsObjIndex].cycling = CYCLE_FORWARD; break; case INIT_STORY_MODE: // act39: Init story_mode flag // This is similar to the QUIET path mode, except that it is @@ -340,7 +340,7 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { insertActionList(action->a41.actFailIndex); break; case TEXT_TAKE: // act42: Text box with "take" message - Utils::Box(BOX_ANY, TAKE_TEXT, _vm->_arrayNouns[_vm->_object->_objects[action->a42.objNumb].nounIndex][TAKE_NAME]); + Utils::Box(BOX_ANY, TAKE_TEXT, _vm->_arrayNouns[_vm->_object->_objects[action->a42.objIndex].nounIndex][TAKE_NAME]); break; case YESNO: // act43: Prompt user for Yes or No if (Utils::Box(BOX_YESNO, "%s", _vm->_file->fetchString(action->a43.promptIndex)) != 0) @@ -364,16 +364,16 @@ event_t *Scheduler_v2d::doAction(event_t *curEvent) { gameStatus.jumpExitFl = action->a46.jumpExitFl; break; case INIT_VIEW: // act47: Init object.viewx, viewy, dir - _vm->_object->_objects[action->a47.objNumb].viewx = action->a47.viewx; - _vm->_object->_objects[action->a47.objNumb].viewy = action->a47.viewy; - _vm->_object->_objects[action->a47.objNumb].direction = action->a47.direction; + _vm->_object->_objects[action->a47.objIndex].viewx = action->a47.viewx; + _vm->_object->_objects[action->a47.objIndex].viewy = action->a47.viewy; + _vm->_object->_objects[action->a47.objIndex].direction = action->a47.direction; break; case INIT_OBJ_FRAME: // act48: Set seq,frame number to use // Note: Don't set a sequence at time 0 of a new screen, it causes // problems clearing the boundary bits of the object! t>0 is safe - _vm->_object->_objects[action->a48.objNumb].currImagePtr = _vm->_object->_objects[action->a48.objNumb].seqList[action->a48.seqIndex].seqPtr; + _vm->_object->_objects[action->a48.objIndex].currImagePtr = _vm->_object->_objects[action->a48.objIndex].seqList[action->a48.seqIndex].seqPtr; for (dx = 0; dx < action->a48.frameIndex; dx++) - _vm->_object->_objects[action->a48.objNumb].currImagePtr = _vm->_object->_objects[action->a48.objNumb].currImagePtr->nextSeqPtr; + _vm->_object->_objects[action->a48.objIndex].currImagePtr = _vm->_object->_objects[action->a48.objIndex].currImagePtr->nextSeqPtr; break; case OLD_SONG: // Replaces ACT26 for DOS games. |