aboutsummaryrefslogtreecommitdiff
path: root/sword2/logic.h
diff options
context:
space:
mode:
authorTorbjörn Andersson2003-11-01 16:55:20 +0000
committerTorbjörn Andersson2003-11-01 16:55:20 +0000
commit94edf540ef57e801efda2145026d97b6606d66b3 (patch)
tree9fbe2f0f9f8169c25d96c952212191b5cf0a63d1 /sword2/logic.h
parent078091e7f4f67293a414979daf2062f5edfc393c (diff)
downloadscummvm-rg350-94edf540ef57e801efda2145026d97b6606d66b3.tar.gz
scummvm-rg350-94edf540ef57e801efda2145026d97b6606d66b3.tar.bz2
scummvm-rg350-94edf540ef57e801efda2145026d97b6606d66b3.zip
More moving of stuff into classes
svn-id: r11025
Diffstat (limited to 'sword2/logic.h')
-rw-r--r--sword2/logic.h34
1 files changed, 31 insertions, 3 deletions
diff --git a/sword2/logic.h b/sword2/logic.h
index 6edadf76d1..5d9e24f81c 100644
--- a/sword2/logic.h
+++ b/sword2/logic.h
@@ -22,8 +22,8 @@
#ifndef _LOGIC
#define _LOGIC
-// #include "sword2/defs.h"
#include "sword2/header.h"
+#include "sword2/driver/driver96.h"
namespace Sword2 {
@@ -32,6 +32,8 @@ namespace Sword2 {
// This must allow for the largest number of objects in a screen
#define OBJECT_KILL_LIST_SIZE 50
+#define MAX_SEQUENCE_TEXT_LINES 15
+
class Logic {
private:
// Point to the global variable data
@@ -69,8 +71,34 @@ private:
void setupOpcodes(void);
void processKillList(void);
+ // Stores resource id of the wav to use as lead-out from smacker
+ uint32 _smackerLeadOut;
+
+ int32 animate(int32 *params, bool reverse);
+ int32 megaTableAnimate(int32 *params, bool reverse);
+
+ // keeps count of number of text lines to disaply during the sequence
+ uint32 _sequenceTextLines;
+
+ // FOR TEXT LINES IN SEQUENCE PLAYER
+
+ struct _sequenceTextInfo {
+ uint32 textNumber;
+ uint16 startFrame;
+ uint16 endFrame;
+ mem *text_mem;
+ uint32 speechBufferSize;
+ uint16 *speech_mem;
+ };
+
+ _sequenceTextInfo _sequenceTextList[MAX_SEQUENCE_TEXT_LINES];
+
+ void createSequenceSpeech(_movieTextObject *sequenceText[]);
+ void clearSequenceSpeech(_movieTextObject *sequenceText[]);
+
public:
- Logic() : _globals(NULL), _kills(0), _debugFlag(false) {
+ Logic() : _globals(NULL), _kills(0), _debugFlag(false),
+ _smackerLeadOut(0), _sequenceTextLines(0) {
setupOpcodes();
}
@@ -197,7 +225,7 @@ public:
int32 fnRefreshInventory(int32 *params);
int32 fnChangeShadows(int32 *params);
- //do one cycle of the current session
+ // do one cycle of the current session
int processSession(void);
// cause the logic loop to terminate and drop out