[Scummvm-cvs-logs] CVS: scummvm/saga actor.cpp,1.191,1.192 interface.cpp,1.139,1.140 interface.h,1.74,1.75 rscfile.cpp,1.45,1.46 saga.h,1.127,1.128 saveload.cpp,1.26,1.27 scene.h,1.78,1.79 script.h,1.110,1.111 sfuncs.cpp,1.169,1.170
Eugene Sandulenko
sev at users.sourceforge.net
Tue Oct 4 16:39:15 CEST 2005
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/saga gfx.cpp,1.60,1.61 interface.cpp,1.138,1.139 interface.h,1.73,1.74 sfuncs.cpp,1.168,1.169
- Next message: [Scummvm-cvs-logs] CVS: scummvm/saga interface.cpp,1.140,1.141
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/scummvm/scummvm/saga
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32361
Modified Files:
actor.cpp interface.cpp interface.h rscfile.cpp saga.h
saveload.cpp scene.h script.h sfuncs.cpp
Log Message:
IHNM changes:
o Latest bit of Game Object structure
o Implemented spiritual barometer
o Fixed Ethics points data type
o Implemented sf74 and sf104
Index: actor.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/actor.cpp,v
retrieving revision 1.191
retrieving revision 1.192
diff -u -d -r1.191 -r1.192
--- actor.cpp 2 Oct 2005 03:09:29 -0000 1.191
+++ actor.cpp 4 Oct 2005 23:38:19 -0000 1.192
@@ -575,10 +575,7 @@
error("Actor::loadObjList frameListResourceId != 0");
}
object->_scriptEntrypointNumber = objectS.readUint32LE();
- objectS.readByte();
- objectS.readByte();
- objectS.readByte();
- objectS.readByte();
+ objectS.readUint32LE(); // xSprite *dSpr;
objectS.readUint16LE(); //LEFT
objectS.readUint16LE(); //RIGHT
objectS.readUint16LE(); //TOP
@@ -1080,11 +1077,6 @@
continue;
}
- if (_vm->getGameType() == GType_IHNM) {
- if (actor->_spriteList.spriteCount == 0)
- continue;
- }
-
switch (actor->_currentAction) {
case kActionWait:
if (!setup && (actor->_flags & kFollower)) {
Index: interface.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/interface.cpp,v
retrieving revision 1.139
retrieving revision 1.140
diff -u -d -r1.139 -r1.140
--- interface.cpp 4 Oct 2005 18:19:14 -0000 1.139
+++ interface.cpp 4 Oct 2005 23:38:19 -0000 1.140
@@ -202,6 +202,8 @@
_textInput = false;
_statusTextInput = false;
_statusTextInputState = kStatusTextInputFirstRun;
+
+ _disableAbortSpeeches = false;
}
Interface::~Interface(void) {
@@ -338,7 +340,8 @@
if (_vm->_scene->isInIntro()) {
_vm->_scene->skipScene();
} else {
- _vm->_actor->abortAllSpeeches();
+ if (!_disableAbortSpeeches)
+ _vm->_actor->abortAllSpeeches();
}
return true;
}
@@ -591,10 +594,13 @@
}
if (_vm->getGameType() == GType_IHNM) {
- _vm->_gfx->setPaletteColor(254,
- _portraitBgColor.red,
- _portraitBgColor.green,
- _portraitBgColor.blue);
+ if (_vm->_spiritualBarometer > 255)
+ _vm->_gfx->setPaletteColor(kIHNMColorPortrait, 0xff, 0xff, 0xff);
+ else
+ _vm->_gfx->setPaletteColor(kIHNMColorPortrait,
+ _portraitBgColor.red,
+ _portraitBgColor.green,
+ _portraitBgColor.blue);
}
if (_panelMode == kPanelMain || _panelMode == kPanelConverse ||
Index: interface.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/interface.h,v
retrieving revision 1.74
retrieving revision 1.75
diff -u -d -r1.74 -r1.75
--- interface.h 4 Oct 2005 18:19:14 -0000 1.74
+++ interface.h 4 Oct 2005 23:38:19 -0000 1.75
@@ -176,7 +176,8 @@
kITEColorLightBlue94 = 0x94,
kITEColorLightBlue96 = 0x96,
- kIHNMColorBlack = 0xfa
+ kIHNMColorBlack = 0xfa,
+ kIHNMColorPortrait = 0xfe
};
enum StatusTextInputState {
@@ -227,6 +228,7 @@
_portraitBgColor.green = green;
_portraitBgColor.blue = blue;
}
+
void draw();
void drawOption();
void drawQuit();
@@ -239,6 +241,8 @@
bool processAscii(uint16 ascii, bool synthetic = false);
void processKeyUp(uint16 ascii);
+ void disableAbortSpeeches(bool d) { _disableAbortSpeeches = d; }
+
bool _textInput;
bool _statusTextInput;
@@ -409,6 +413,8 @@
InterfacePanel _savePanel;
PanelButton * _saveEdit;
+ bool _disableAbortSpeeches;
+
int _saveReminderState;
bool _active;
int _fadeMode;
Index: rscfile.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/rscfile.cpp,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -d -r1.45 -r1.46
--- rscfile.cpp 1 Oct 2005 05:30:49 -0000 1.45
+++ rscfile.cpp 4 Oct 2005 23:38:19 -0000 1.46
@@ -29,6 +29,7 @@
#include "saga/interface.h"
#include "saga/music.h"
#include "saga/rscfile.h"
+#include "saga/scene.h"
#include "saga/sndres.h"
#include "saga/stream.h"
@@ -596,6 +597,9 @@
_vm->_script->loadVoiceLUT(_vm->_script->_globalVoiceLUT, resourcePointer, resourceLength);
free(resourcePointer);
}
+
+ _vm->_spiritualBarometer = 0;
+ _vm->_scene->setChapterNumber(chapter);
}
} // End of namespace Saga
Index: saga.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/saga.h,v
retrieving revision 1.127
retrieving revision 1.128
diff -u -d -r1.127 -r1.128
--- saga.h 30 Sep 2005 18:48:25 -0000 1.127
+++ saga.h 4 Oct 2005 23:38:19 -0000 1.128
@@ -575,7 +575,8 @@
int16 _framesEsc;
uint32 _globalFlags;
- byte _ethicsPoints[5]; // TODO: Verify that this is large enough
+ int16 _ethicsPoints[8];
+ int _spiritualBarometer;
int _soundVolume;
int _musicVolume;
Index: saveload.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/saveload.cpp,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -d -r1.26 -r1.27
--- saveload.cpp 26 Sep 2005 07:22:32 -0000 1.26
+++ saveload.cpp 4 Oct 2005 23:38:19 -0000 1.27
@@ -181,7 +181,7 @@
if (getGameType() != GType_ITE) {
out->writeUint32LE(_globalFlags);
for (int i = 0; i < ARRAYSIZE(_ethicsPoints); i++)
- out->writeByte(_ethicsPoints[i]);
+ out->writeSint16LE(_ethicsPoints[i]);
}
_interface->saveState(out);
@@ -226,7 +226,7 @@
if (getGameType() != GType_ITE) {
_globalFlags = in->readUint32LE();
for (int i = 0; i < ARRAYSIZE(_ethicsPoints); i++)
- _ethicsPoints[i] = in->readByte();
+ _ethicsPoints[i] = in->readSint16LE();
}
_interface->loadState(in);
Index: scene.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/scene.h,v
retrieving revision 1.78
retrieving revision 1.79
diff -u -d -r1.78 -r1.79
--- scene.h 28 Sep 2005 15:49:20 -0000 1.78
+++ scene.h 4 Oct 2005 23:38:19 -0000 1.79
@@ -261,6 +261,8 @@
return _sceneLUT[sceneNumber];
}
int currentSceneNumber() const { return _sceneNumber; }
+ int currentChapterNumber() const { return _chapterNumber; }
+ void setChapterNumber(int ch) { _chapterNumber = ch; }
int getOutsetSceneNumber() const { return _outsetSceneNumber; }
int currentSceneResourceId() const { return _sceneResourceId; }
void cutawaySkip() {
@@ -288,6 +290,7 @@
SceneQueueList _sceneQueue;
bool _sceneLoaded;
int _sceneNumber;
+ int _chapterNumber;
int _outsetSceneNumber;
int _sceneResourceId;
bool _inGame;
Index: script.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/script.h,v
retrieving revision 1.110
retrieving revision 1.111
diff -u -d -r1.110 -r1.111
--- script.h 4 Oct 2005 17:44:41 -0000 1.110
+++ script.h 4 Oct 2005 23:38:19 -0000 1.111
@@ -561,7 +561,7 @@
void sfPsychicProfile(SCRIPTFUNC_PARAMS);
void sfPsychicProfileOff(SCRIPTFUNC_PARAMS);
void sfSetSpeechBox(SCRIPTFUNC_PARAMS);
- void sf74(SCRIPTFUNC_PARAMS);
+ void sfSetChapterPoints(SCRIPTFUNC_PARAMS);
void sfSetPortraitBgColor(SCRIPTFUNC_PARAMS);
void sfScriptStartVideo(SCRIPTFUNC_PARAMS);
void sfScriptReturnFromVideo(SCRIPTFUNC_PARAMS);
@@ -575,7 +575,7 @@
void sfTestGlobalFlag(SCRIPTFUNC_PARAMS);
void sfSetPoints(SCRIPTFUNC_PARAMS);
void sf103(SCRIPTFUNC_PARAMS);
- void sf104(SCRIPTFUNC_PARAMS);
+ void sfDisableAbortSpeeches(SCRIPTFUNC_PARAMS);
void SF_stub(const char *name, ScriptThread *thread, int nArgs);
};
Index: sfuncs.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/sfuncs.cpp,v
retrieving revision 1.169
retrieving revision 1.170
diff -u -d -r1.169 -r1.170
--- sfuncs.cpp 4 Oct 2005 18:19:14 -0000 1.169
+++ sfuncs.cpp 4 Oct 2005 23:38:19 -0000 1.170
@@ -209,7 +209,7 @@
OPCODE(sfRand),
OPCODE(sfFadeMusic),
OPCODE(sfNull),
- OPCODE(sf74),
+ OPCODE(sfSetChapterPoints),
OPCODE(sfSetPortraitBgColor),
OPCODE(sfScriptStartCutAway),
OPCODE(sfReturnFromCutAway),
@@ -239,7 +239,7 @@
OPCODE(sfDebugShowData),
OPCODE(sfWaitFramesEsc),
OPCODE(sf103),
- OPCODE(sf104)
+ OPCODE(sfDisableAbortSpeeches)
};
if (_vm->getGameType() == GType_IHNM)
_scriptFunctionsList = IHNMscriptFunctionsList;
@@ -1840,8 +1840,13 @@
wakeUpThreads(kWaitTypeDialogBegin);
}
-void Script::sf74(SCRIPTFUNC_PARAMS) {
- SF_stub("sf74", thread, nArgs);
+void Script::sfSetChapterPoints(SCRIPTFUNC_PARAMS) {
+ int16 ethics = thread->pop();
+ int16 barometer = thread->pop();
+ int chapter = _vm->_scene->currentChapterNumber();
+
+ _vm->_ethicsPoints[chapter] = ethics;
+ _vm->_spiritualBarometer = barometer;
}
void Script::sfSetPortraitBgColor(SCRIPTFUNC_PARAMS) {
@@ -2002,8 +2007,10 @@
SF_stub("sf103", thread, nArgs);
}
-void Script::sf104(SCRIPTFUNC_PARAMS) {
- SF_stub("sf104", thread, nArgs);
+void Script::sfDisableAbortSpeeches(SCRIPTFUNC_PARAMS) {
+ int value = thread->pop();
+
+ _vm->_interface->disableAbortSpeeches(value != 0);
}
void Script::sfNull(SCRIPTFUNC_PARAMS) {
- Previous message: [Scummvm-cvs-logs] CVS: scummvm/saga gfx.cpp,1.60,1.61 interface.cpp,1.138,1.139 interface.h,1.73,1.74 sfuncs.cpp,1.168,1.169
- Next message: [Scummvm-cvs-logs] CVS: scummvm/saga interface.cpp,1.140,1.141
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Scummvm-git-logs
mailing list