[Scummvm-cvs-logs] CVS: scummvm/queen cutaway.cpp,1.105,1.106 defs.h,1.40,1.41 display.cpp,1.47,1.48 graphics.cpp,1.73,1.74 graphics.h,1.56,1.57 journal.cpp,1.20,1.21 logic.cpp,1.163,1.164 logic.h,1.106,1.107 walk.h,1.21,1.22 xref.txt,1.58,1.59
Gregory Montoir
cyx at users.sourceforge.net
Thu Jan 8 08:42:03 CET 2004
Update of /cvsroot/scummvm/scummvm/queen
In directory sc8-pr-cvs1:/tmp/cvs-serv6045/queen
Modified Files:
cutaway.cpp defs.h display.cpp graphics.cpp graphics.h
journal.cpp logic.cpp logic.h walk.h xref.txt
Log Message:
cleanup, xref update
Index: cutaway.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/cutaway.cpp,v
retrieving revision 1.105
retrieving revision 1.106
diff -u -d -r1.105 -r1.106
--- cutaway.cpp 8 Jan 2004 14:10:32 -0000 1.105
+++ cutaway.cpp 8 Jan 2004 16:41:03 -0000 1.106
@@ -954,7 +954,7 @@
if (_roomFade) {
_vm->update();
int end = 223;
- if (IS_CD_INTRO_ROOM(_vm->logic()->currentRoom())) {
+ if (_vm->logic()->isIntroRoom(_vm->logic()->currentRoom())) {
end = 255;
}
BobSlot *j = _vm->graphics()->bob(0);
Index: defs.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/defs.h,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -d -r1.40 -r1.41
--- defs.h 8 Jan 2004 10:25:17 -0000 1.40
+++ defs.h 8 Jan 2004 16:41:03 -0000 1.41
@@ -70,10 +70,9 @@
enum {
ITEM_NONE = 0,
- ITEM_BAT = 1,
+ ITEM_BAT,
ITEM_JOURNAL,
- ITEM_JOURNAL_DEMO = 7,
- ITEM_KNIFE = 3,
+ ITEM_KNIFE,
ITEM_COCONUT_HALVES,
ITEM_BEEF_JERKY,
ITEM_PROPELLER,
@@ -247,9 +246,6 @@
AZURA_HEAD = 106,
FRANK_HEAD = 107
};
-
-#define IS_ALT_INTRO_ROOM(x) ((x) >= 90 && (x) <= 94)
-#define IS_CD_INTRO_ROOM(x) ((x) >= 115 && (x) <= 125)
//! GameState vars
Index: display.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/display.cpp,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -d -r1.47 -r1.48
--- display.cpp 8 Jan 2004 10:25:17 -0000 1.47
+++ display.cpp 8 Jan 2004 16:41:03 -0000 1.48
@@ -23,6 +23,7 @@
#include "queen/display.h"
#include "queen/input.h"
+#include "queen/logic.h"
#include "queen/queen.h"
#include "queen/resource.h"
@@ -79,7 +80,7 @@
_dynalum.valid = false;
_dynalum.prevColMask = 0xFF;
- if (!(IS_ALT_INTRO_ROOM(roomNum) || IS_CD_INTRO_ROOM(roomNum))) {
+ if (!(_vm->logic()->isAltIntroRoom(roomNum) || _vm->logic()->isIntroRoom(roomNum))) {
char filename[20];
sprintf(filename, "%s.msk", roomName);
@@ -184,7 +185,7 @@
void Display::palFadeIn(int start, int end, uint16 roomNum, bool dynalum, int16 dynaX, int16 dynaY) {
debug(9, "Display::palFadeIn(%d, %d)", start, end);
memcpy(_pal.screen, _pal.room, 256 * 3);
- if (!(IS_ALT_INTRO_ROOM(roomNum) || IS_CD_INTRO_ROOM(roomNum))) {
+ if (!(_vm->logic()->isAltIntroRoom(roomNum) || _vm->logic()->isIntroRoom(roomNum))) {
if (dynalum) {
dynalumUpdate(dynaX, dynaY);
}
@@ -204,7 +205,7 @@
}
}
_pal.dirtyMin = 0;
- _pal.dirtyMax = IS_CD_INTRO_ROOM(roomNum) ? 255 : 223;
+ _pal.dirtyMax = _vm->logic()->isIntroRoom(roomNum) ? 255 : 223;
_pal.scrollable = true;
}
@@ -213,7 +214,7 @@
debug(9, "Display::palFadeOut(%d, %d)", start, end);
_pal.scrollable = false;
int n = end - start + 1;
- if (IS_ALT_INTRO_ROOM(roomNum) || IS_CD_INTRO_ROOM(roomNum)) {
+ if (_vm->logic()->isAltIntroRoom(roomNum) || _vm->logic()->isIntroRoom(roomNum)) {
memset(_pal.screen + start * 3, 0, n * 3);
palSet(_pal.screen, start, end, true);
} else {
@@ -659,7 +660,7 @@
_bdWidth = READ_LE_UINT16(pcxBuf + 12);
_bdHeight = READ_LE_UINT16(pcxBuf + 14);
readPCX(_backdropBuf, BACKDROP_W, pcxBuf + 128, _bdWidth, _bdHeight);
- memcpy(_pal.room, pcxBuf + size - 768, IS_CD_INTRO_ROOM(room) ? 256 * 3 : 144 * 3);
+ memcpy(_pal.room, pcxBuf + size - 768, _vm->logic()->isIntroRoom(room) ? 256 * 3 : 144 * 3);
delete[] pcxBuf;
palCustomColors(room);
Index: graphics.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/graphics.cpp,v
retrieving revision 1.73
retrieving revision 1.74
diff -u -d -r1.73 -r1.74
--- graphics.cpp 8 Jan 2004 14:10:32 -0000 1.73
+++ graphics.cpp 8 Jan 2004 16:41:03 -0000 1.74
@@ -974,7 +974,7 @@
}
-const BamDataBlock BamScene::_carData[] = {
+const BamScene::BamDataBlock BamScene::_carData[] = {
{ { 310, 105, 1 }, { 314, 106, 17 }, { 366, 101, 1 }, 0 },
{ { 303, 105, 1 }, { 307, 106, 17 }, { 214, 0, 10 }, 0 },
{ { 297, 104, 1 }, { 301, 105, 17 }, { 214, 0, 10 }, 0 },
@@ -1052,7 +1052,7 @@
{ { 310, 110, 1 }, { 314, 111, 17 }, { 214, 0, 10 }, 99 }
};
-const BamDataBlock BamScene::_fight1Data[] = {
+const BamScene::BamDataBlock BamScene::_fight1Data[] = {
{ { 75, 96, 1 }, { 187, 96, -23 }, { 58, 37, 46 }, 0 },
{ { 75, 96, 2 }, { 187, 96, -23 }, { 58, 37, 46 }, 0 },
{ { 75, 96, 3 }, { 187, 96, -23 }, { 58, 37, 46 }, 0 },
@@ -1101,7 +1101,7 @@
{ { 75, 96, 1 }, { 187, 96, -23 }, { 0, 0, 0 }, 99 }
};
-const BamDataBlock BamScene::_fight2Data[] = {
+const BamScene::BamDataBlock BamScene::_fight2Data[] = {
{ { 75, 96, 1 }, { 187, 96, -23 }, { 150, 45, 35 }, 0 },
{ { 78, 96, 2 }, { 187, 96, -23 }, { 150, 45, 35 }, 0 },
{ { 81, 96, 3 }, { 189, 96, -18 }, { 150, 45, 35 }, 0 },
@@ -1159,7 +1159,7 @@
{ { 75, 96, 5 }, { 187, 96, -23 }, { 224, 53, 53 }, 99 }
};
-const BamDataBlock BamScene::_fight3Data[] = {
+const BamScene::BamDataBlock BamScene::_fight3Data[] = {
{ { 75, 96, 1 }, { 187, 96, -23 }, { 150, 45, 35 }, 0 },
{ { 77, 96, 2 }, { 187, 96, -22 }, { 150, 45, 35 }, 0 },
{ { 80, 96, 3 }, { 185, 96, -17 }, { 150, 45, 35 }, 0 },
Index: graphics.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/graphics.h,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -d -r1.56 -r1.57
--- graphics.h 8 Jan 2004 14:10:32 -0000 1.56
+++ graphics.h 8 Jan 2004 16:41:03 -0000 1.57
@@ -23,8 +23,8 @@
#define QUEENGRAPHICS_H
#include "common/str.h"
-#include "queen/defs.h"
#include "common/util.h"
+#include "queen/defs.h"
#include "queen/structs.h"
namespace Queen {
@@ -173,18 +173,6 @@
};
-struct BamDataObj {
- int16 x, y;
- int16 frame;
-};
-
-struct BamDataBlock {
- BamDataObj obj1; // truck / Frank
- BamDataObj obj2; // Rico / robot
- BamDataObj fx;
- int16 sfx;
-};
-
class BamScene {
public:
@@ -209,6 +197,18 @@
uint16 _flag, _index;
private:
+
+ struct BamDataObj {
+ int16 x, y;
+ int16 frame;
+ };
+
+ struct BamDataBlock {
+ BamDataObj obj1; // truck / Frank
+ BamDataObj obj2; // Rico / robot
+ BamDataObj fx;
+ int16 sfx;
+ };
BobSlot *_obj1;
BobSlot *_obj2;
Index: journal.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/journal.cpp,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -d -r1.20 -r1.21
--- journal.cpp 8 Jan 2004 14:10:32 -0000 1.20
+++ journal.cpp 8 Jan 2004 16:41:03 -0000 1.21
@@ -334,7 +334,6 @@
void Journal::handleMouseWheel(int inc) {
-
if (_mode == M_NORMAL) {
int curSave = _currentSavePage * SAVE_PER_PAGE + _currentSaveSlot + inc;
if (curSave >= 0 && curSave < SAVE_PER_PAGE * 10) {
@@ -349,7 +348,6 @@
void Journal::handleMouseDown(int x, int y) {
-
int16 zone = _vm->grid()->findZoneForPos(GS_ROOM, x, y);
if (_mode == M_INFO_BOX) {
handleInfoBoxMode(_mode);
@@ -363,7 +361,6 @@
void Journal::handleKeyDown(uint16 ascii, int keycode) {
-
if (_mode == M_YES_NO) {
if (keycode == 27) { // escape
handleYesNoMode(ZN_NO);
@@ -377,7 +374,6 @@
void Journal::clearPanelTexts() {
-
int i;
for (i = 0; i < _panelTextCount; ++i) {
_vm->graphics()->textClear(_panelTextY[i], _panelTextY[i]);
@@ -386,7 +382,6 @@
void Journal::drawPanelText(int y, const char *text) {
-
char s[80];
strcpy(s, text);
char *p = strchr(s, ' ');
@@ -403,7 +398,6 @@
void Journal::drawCheckBox(bool active, int bobNum, int16 x, int16 y, int frameNum) {
-
if (active) {
showBob(bobNum, x, y, frameNum);
} else {
Index: logic.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/logic.cpp,v
retrieving revision 1.163
retrieving revision 1.164
diff -u -d -r1.163 -r1.164
--- logic.cpp 8 Jan 2004 14:10:32 -0000 1.163
+++ logic.cpp 8 Jan 2004 16:41:03 -0000 1.164
@@ -821,16 +821,17 @@
sprintf(filename, "%s.BBK", room);
_vm->bankMan()->load(filename, 15);
- _vm->grid()->setupNewRoom(_currentRoom, _roomData[_currentRoom]);
_numFrames = 37 + FRAMES_JOE_XTRA;
roomSetupFurniture();
roomSetupObjects();
- _vm->display()->forceFullRefresh();
-
if (_currentRoom >= 90) {
_vm->graphics()->putCameraOnBob(0);
}
+
+ _vm->grid()->setupNewRoom(_currentRoom, _roomData[_currentRoom]);
+ _vm->display()->forceFullRefresh();
+
}
@@ -850,11 +851,8 @@
if (mode != RDM_NOFADE_JOE) {
_vm->update();
BobSlot *joe = _vm->graphics()->bob(0);
- if (IS_CD_INTRO_ROOM(_currentRoom)) {
- _vm->display()->palFadeIn(0, 255, _currentRoom, joe->active, joe->x, joe->y);
- } else {
- _vm->display()->palFadeIn(0, 223, _currentRoom, joe->active, joe->x, joe->y);
- }
+ int end = isIntroRoom(_currentRoom) ? 255 : 223;
+ _vm->display()->palFadeIn(0, end, _currentRoom, joe->active, joe->x, joe->y);
}
if (pod != NULL) {
_vm->walk()->moveJoe(0, pod->x, pod->y, inCutaway);
@@ -1469,7 +1467,7 @@
}
-void Logic::handleSpecialArea(int facing, uint16 areaNum, uint16 walkDataNum) {
+void Logic::handleSpecialArea(Direction facing, uint16 areaNum, uint16 walkDataNum) {
// queen.c l.2838-2911
debug(9, "handleSpecialArea(%d, %d, %d)\n", facing, areaNum, walkDataNum);
Index: logic.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/logic.h,v
retrieving revision 1.106
retrieving revision 1.107
diff -u -d -r1.106 -r1.107
--- logic.h 8 Jan 2004 14:10:32 -0000 1.106
+++ logic.h 8 Jan 2004 16:41:03 -0000 1.107
@@ -77,6 +77,14 @@
error("Invalid room number: %i", room);
}
+ bool isAltIntroRoom(uint16 room) const {
+ return room >= 90 && room <= 94;
+ }
+
+ bool isIntroRoom(uint16 room) const {
+ return room >= 115 && room <= 125;
+ }
+
ObjectData *objectData(int index) const;
uint16 roomData(int room) const { return _roomData[room]; }
GraphicData *graphicData(int index) const { return &_graphicData[index]; }
@@ -183,7 +191,7 @@
//! Copy data from dummy object to object
void objectCopy(int dummyObjectIndex, int objectIndex);
- void handleSpecialArea(int facing, uint16 areaNum, uint16 walkDataNum);
+ void handleSpecialArea(Direction facing, uint16 areaNum, uint16 walkDataNum);
void handlePinnacleRoom();
@@ -207,6 +215,20 @@
void executeSpecialMove(uint16 sm);
+ void startCredits(const char *filename);
+ void stopCredits();
+
+ enum {
+ JOE_RESPONSE_MAX = 40,
+ DEFAULT_TALK_SPEED = 7 * 3,
+ GAME_STATE_COUNT = 211,
+ TALK_SELECTED_COUNT = 86
+ };
+
+protected:
+
+ void initialise();
+
void asmMakeJoeUseDress();
void asmMakeJoeUseNormalClothes();
void asmMakeJoeUseUnderwear();
@@ -247,20 +269,6 @@
void asmEndDemo();
void asmInterviewIntro();
void asmEndInterview();
-
- void startCredits(const char *filename);
- void stopCredits();
-
- enum {
- JOE_RESPONSE_MAX = 40,
- DEFAULT_TALK_SPEED = 7 * 3,
- GAME_STATE_COUNT = 211,
- TALK_SELECTED_COUNT = 86
- };
-
-protected:
-
- void initialise();
virtual bool preChangeRoom() = 0;
virtual bool handleSpecialMove(uint16 sm) = 0;
Index: walk.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/walk.h,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- walk.h 8 Jan 2004 14:10:32 -0000 1.21
+++ walk.h 8 Jan 2004 16:41:03 -0000 1.22
@@ -31,12 +31,12 @@
struct MovePersonAnim {
int16 firstFrame;
int16 lastFrame;
- uint16 facing;
+ Direction facing;
- void set(int16 ff, int16 lf, uint16 face) {
+ void set(int16 ff, int16 lf, Direction dir) {
firstFrame = ff;
lastFrame = lf;
- facing = face;
+ facing = dir;
}
};
Index: xref.txt
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/xref.txt,v
retrieving revision 1.58
retrieving revision 1.59
diff -u -d -r1.58 -r1.59
--- xref.txt 8 Jan 2004 14:10:32 -0000 1.58
+++ xref.txt 8 Jan 2004 16:41:03 -0000 1.59
@@ -47,7 +47,7 @@
COM_I_MAX Command::_numCmdInventory
COM_LIST Command::_cmdList
COM_LIST_MAX Command::_numCmdList
-COMMANDstr Command::_command
+COMMANDstr Command::_cmdText
DEFCOMM Command::_state.defaultVerb
MKEY Command::_mouseKey
OLDVERB,VERB Command::_state.*verb
@@ -59,18 +59,18 @@
CREDIT SCRIPTING SYSTEM
=======================
-Cinit()
-Ctext()
-Cupdate()
+Cinit() Credits::Credits()
+Ctext() *not needed* (included in Credits::update)
+Cupdate() Credits::update
-
-Ccol
-Ccount
+Ccol Credits::_color
+Ccount Credits::_count
Cfp
-Cflag
-Cfontsize
-Cjustify
-Cpausecount
-Czone
+Cflag Credits::_running
+Cfontsize Credits::_fontSize
+Cjustify Credits::_justify
+Cpausecount Credits::_pause
+Czone Credits::_zone
CUTAWAY
@@ -96,22 +96,22 @@
DEBUG
=====
cd_sample_check()
-debuginfo() Debug::printInfo
-select_new_room() Debug::jumpToRoom
+debuginfo() Debugger::Cmd_Info
+select_new_room() Debugger::Cmd_Room
-
AREAVAR (boolean, if true display objects/areas boxes)
GAME SETTINGS
=============
-game_load() Logic::gameLoad()
-game_save() Logic::gameSave()
+game_load() Logic::gameLoad
+game_save() Logic::gameSave
-
config_request
MUSICTOGGLE Sound::_musicToggle / ConfMan.("music_mute")
SFXTOGGLE Sound::_sfxToggle / ConfMan.("sfx_mute")
-TALKSPD Logic::_talkSpeed / ConfMan.("talkspeed")
-TEXTTOGGLE Logic::_subtitles / ConfMan.("subtitles")
+TALKSPD QueenEngine::_talkSpeed / ConfMan.("talkspeed")
+TEXTTOGGLE QueenEngine::_subtitles / ConfMan.("subtitles")
VersionStr GameVersion::versionString
VOICETOGGLE Sound::_speechToggle / ConfMan.("speech_mute")
VOLUME ? / ConfMan.("master_volume")
@@ -126,7 +126,7 @@
clearbob() Graphics::bobClear
drawbobs() Graphics::bobDrawAll
invbob() Graphics::bobDrawInventoryItem
-loadbackdrop() *included in Display::setupNewRoom*
+loadbackdrop() *not needed* (included in Display::setupNewRoom)
loadpanel() Display::setupPanel
MAKE_SPEAK_BOB() Graphics::bobSetText
makeanim() BobSlot::animNormal
@@ -247,11 +247,9 @@
NAMETOT Logic::_numNames
OBJ_DESC_DATA Logic::_objectDescription
OBJ_DESC_MAX Logic::_numObjDesc
-OBJECT_BOX Grid::_objectBox
OBJECT_DATA Logic::_objectData
OBJECT_DESCRstr Logic::_objDescription
OBJECT_NAMEstr Logic::_objName
-OBJMAX Grid::_objMax
OBJTOT Logic::_numObjects
OLDROOM,ROOM,NEW_ROOM Logic::_*oom
ROOMTOT Logic::_numRooms
@@ -353,7 +351,7 @@
TALK
====
FIND_SACTION() Talk::findSpeechParameters
-MOVE_SPEAK() *included in Talk::getSpeakCommand*
+MOVE_SPEAK() *not needed* (included in Talk::getSpeakCommand)
SPEAK() Talk::speak
SPEAK_SUB() Talk::speakSegment
talk() Talk::talk
@@ -418,18 +416,20 @@
SETUP_PANEL_ZONES() Grid::setupPanel
SETUP_ZONES() Grid::setupNewRoom
SetZone() Grid::setZone
-zone() Grid:findZoneForPos / Logic::findAreaForPos
+zone() Grid::findZoneForPos / Logic::findAreaForPos
-
AREA Grid::_area
AREAMAX Grid::_areaMax
+OBJECT_BOX Grid::_objectBox
+OBJMAX Grid::_objMax
zones Grid::_zones
(UNSORTED)
==========
-in() defs.h InRange() macro
+in() Cutaway::inRange
find_cd_cut() findCdCut
-find_cd_desc() *not needed* (see Logic::joeSpeak())
+find_cd_desc() *not needed* (included in Logic::joeSpeak)
-
Kstr
bank9
More information about the Scummvm-git-logs
mailing list