aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/cine/anim.cpp2
-rw-r--r--engines/cine/cine.cpp2
-rw-r--r--engines/cine/main_loop.cpp4
-rw-r--r--engines/cine/msg.cpp12
-rw-r--r--engines/cine/object.cpp27
-rw-r--r--engines/cine/pal.cpp39
-rw-r--r--engines/cine/pal.h2
-rw-r--r--engines/cine/part.cpp13
-rw-r--r--engines/cine/part.h9
-rw-r--r--engines/cine/prc.cpp77
-rw-r--r--engines/cine/script.cpp14
-rw-r--r--engines/cine/sfx_player.cpp10
-rw-r--r--engines/cine/sfx_player.h6
-rw-r--r--engines/cine/sound_driver.cpp4
-rw-r--r--engines/cine/sound_driver.h4
-rw-r--r--engines/cine/various.cpp40
-rw-r--r--engines/cine/various.h12
17 files changed, 112 insertions, 165 deletions
diff --git a/engines/cine/anim.cpp b/engines/cine/anim.cpp
index e163af388a..eff98d47b3 100644
--- a/engines/cine/anim.cpp
+++ b/engines/cine/anim.cpp
@@ -856,7 +856,7 @@ void loadResourcesFromSave() {
strcpy(part, currentPartName);
for (currentAnim = 0; currentAnim < NUM_MAX_ANIMDATA; currentAnim++) {
- animDataStruct *currentPtr = &animDataTable[currentAnim];
+ AnimData *currentPtr = &animDataTable[currentAnim];
if (currentPtr->ptr1 && currentPtr->fileIdx != -1) {
int8 isMask = 0;
int8 isSpl = 0;
diff --git a/engines/cine/cine.cpp b/engines/cine/cine.cpp
index cf3c3f014d..d1254aeac6 100644
--- a/engines/cine/cine.cpp
+++ b/engines/cine/cine.cpp
@@ -201,7 +201,7 @@ static void initialize() {
textDataPtr = (uint8 *)malloc(8000);
- partBuffer = (partBufferStruct *)malloc(255 * sizeof(animDataStruct));
+ partBuffer = (PartBuffer *)malloc(255 * sizeof(PartBuffer));
loadTextData("texte.dat", textDataPtr);
snd_loadBasesonEntries("BASESON.SND");
diff --git a/engines/cine/main_loop.cpp b/engines/cine/main_loop.cpp
index 60820da585..9e382d265c 100644
--- a/engines/cine/main_loop.cpp
+++ b/engines/cine/main_loop.cpp
@@ -94,7 +94,7 @@ void mainLoop(int bootScriptIdx) {
closeEngine3();
resetMessageHead();
- resetUnkList();
+ resetSeqList();
resetglobalScriptsHead();
resetObjectScriptHead();
mainLoopSub1();
@@ -154,7 +154,7 @@ void mainLoop(int bootScriptIdx) {
}
}
- processUnkList();
+ processSeqList();
executeList1();
executeList0();
diff --git a/engines/cine/msg.cpp b/engines/cine/msg.cpp
index d0aa437afe..5f3fba134b 100644
--- a/engines/cine/msg.cpp
+++ b/engines/cine/msg.cpp
@@ -31,7 +31,7 @@
namespace Cine {
-uint16 msgVar0;
+uint16 messageCount;
void loadMsg(char *pMsgName) {
uint16 i;
@@ -39,7 +39,7 @@ void loadMsg(char *pMsgName) {
checkDataDisk(-1);
- msgVar0 = 0;
+ messageCount = 0;
for (i = 0; i < NUM_MAX_MESSAGE; i++) {
messageTable[i].len = 0;
@@ -57,15 +57,15 @@ void loadMsg(char *pMsgName) {
processPendingUpdates(1);
- msgVar0 = READ_BE_UINT16(ptr); ptr += 2;
+ messageCount = READ_BE_UINT16(ptr); ptr += 2;
- ASSERT(msgVar0 <= NUM_MAX_MESSAGE);
+ ASSERT(messageCount <= NUM_MAX_MESSAGE);
- for (i = 0; i < msgVar0; i++) {
+ for (i = 0; i < messageCount; i++) {
messageTable[i].len = READ_BE_UINT16(ptr); ptr += 2;
}
- for (i = 0; i < msgVar0; i++) {
+ for (i = 0; i < messageCount; i++) {
if (messageTable[i].len) {
messageTable[i].ptr = (uint8 *) malloc(messageTable[i].len);
diff --git a/engines/cine/object.cpp b/engines/cine/object.cpp
index b85e487d82..f09b6baca9 100644
--- a/engines/cine/object.cpp
+++ b/engines/cine/object.cpp
@@ -70,31 +70,24 @@ void loadObject(char *pObjectName) {
processPendingUpdates(1);
- numEntry = *(uint16 *) ptr;
- ptr += 2;
- flipU16(&numEntry);
+ numEntry = READ_BE_UINT16(ptr); ptr += 2;
- entrySize = *(uint16 *) ptr;
- ptr += 2;
- flipU16(&entrySize);
+ entrySize = READ_BE_UINT16(ptr); ptr += 2;
ASSERT(numEntry <= NUM_MAX_OBJECT);
- ASSERT(entrySize == sizeof(objectStruct)); // carefull, it's directly read to memory
+
for (i = 0; i < numEntry; i++) {
if (objectTable[i].costume != -2) // flag is keep ?
{
- memcpy(&objectTable[i], ptr, entrySize);
-
- flipU16((uint16 *) & objectTable[i].x);
- flipU16((uint16 *) & objectTable[i].y);
- flipU16(&objectTable[i].mask);
- flipU16((uint16 *) & objectTable[i].frame);
- flipU16((uint16 *) & objectTable[i].costume);
- flipU16(&objectTable[i].part);
+ objectTable[i].x = READ_BE_UINT16(ptr); ptr += 2;
+ objectTable[i].y = READ_BE_UINT16(ptr); ptr += 2;
+ objectTable[i].mask = READ_BE_UINT16(ptr); ptr += 2;
+ objectTable[i].frame = READ_BE_UINT16(ptr); ptr += 2;
+ objectTable[i].costume = READ_BE_UINT16(ptr); ptr += 2;
+ memcpy(objectTable[i].name, ptr, 20); ptr += 20;
+ objectTable[i].part = READ_BE_UINT16(ptr); ptr += 2;
}
-
- ptr += entrySize;
}
if (!strcmp(pObjectName, "INTRO.OBJ")) {
diff --git a/engines/cine/pal.cpp b/engines/cine/pal.cpp
index a228541242..26258e01f6 100644
--- a/engines/cine/pal.cpp
+++ b/engines/cine/pal.cpp
@@ -32,12 +32,11 @@ uint16 tempPalette[256];
uint8 colorMode256 = 0;
uint8 palette256[256 * 3];
-uint16 palVar;
-uint16 palVar0;
+uint16 palEntriesCount;
Common::File palFileHandle;
-palEntryStruct *palPtr;
+PalEntry *palPtr;
uint8 paletteBuffer1[16];
uint8 paletteBuffer2[16];
@@ -56,21 +55,22 @@ void loadPal(const char *fileName) {
palPtr = NULL;
}
- palVar = 0;
- palVar0 = 42;
+ palEntriesCount = 0;
palFileHandle.open(buffer);
ASSERT(palFileHandle.isOpen());
- palFileHandle.read(&palVar, 2); // endian: not fliped !
- palFileHandle.read(&palVar0, 2);
-
- palPtr = (palEntryStruct *) malloc(palVar * palVar0);
-
+ palEntriesCount = palFileHandle.readUint16LE();
+ palFileHandle.readUint16LE(); // entry size
+
+ palPtr = (PalEntry *)malloc(palEntriesCount * sizeof(PalEntry));
ASSERT_PTR(palPtr);
-
- palFileHandle.read(palPtr, palVar * palVar0);
+ for (int i = 0; i < palEntriesCount; ++i) {
+ palFileHandle.read(palPtr[i].name, 10);
+ palFileHandle.read(palPtr[i].pal1, 16);
+ palFileHandle.read(palPtr[i].pal2, 16);
+ }
}
int16 findPaletteFromName(const char *fileName) {
@@ -82,13 +82,13 @@ int16 findPaletteFromName(const char *fileName) {
while (position < strlen(fileName)) {
if (buffer[position] > 'a' && buffer[position] < 'z') {
- buffer[position] += 0xE0;
+ buffer[position] += 'A' - 'a';
}
position++;
}
- for (i = 0; i < palVar; i++) {
+ for (i = 0; i < palEntriesCount; i++) {
if (!strcmp(buffer, palPtr[i].name)) {
return i;
}
@@ -112,14 +112,9 @@ void loadRelatedPalette(const char *fileName) {
paletteBuffer1[i] = paletteBuffer2[i] = (i << 4) + i;
}
} else {
- palEntryStruct *palEntryPtr = &palPtr[paletteIndex];
-
- ASSERT_PTR(paletteBuffer2);
-
- for (i = 0; i < 16; i++) { // convert palette
- paletteBuffer1[i] = palEntryPtr->pal1[i];
- paletteBuffer2[i] = palEntryPtr->pal2[i];
- }
+ assert(paletteIndex < palEntriesCount);
+ memcpy(paletteBuffer1, palPtr[paletteIndex].pal1, 16);
+ memcpy(paletteBuffer2, palPtr[paletteIndex].pal2, 16);
}
}
diff --git a/engines/cine/pal.h b/engines/cine/pal.h
index 73a54afbfb..baa7505550 100644
--- a/engines/cine/pal.h
+++ b/engines/cine/pal.h
@@ -27,7 +27,7 @@
namespace Cine {
-struct palEntryStruct {
+struct PalEntry {
char name[10];
uint8 pal1[16];
uint8 pal2[16];
diff --git a/engines/cine/part.cpp b/engines/cine/part.cpp
index 74069531a2..a5757825db 100644
--- a/engines/cine/part.cpp
+++ b/engines/cine/part.cpp
@@ -30,10 +30,9 @@
namespace Cine {
uint16 numElementInPart;
-uint16 partVar1;
-animDataStruct animDataTable[NUM_MAX_PARTDATA];
-partBufferStruct *partBuffer;
+AnimData animDataTable[NUM_MAX_PARTDATA];
+PartBuffer *partBuffer;
void loadPart(const char *partName) {
uint16 i;
@@ -43,11 +42,9 @@ void loadPart(const char *partName) {
partBuffer[i].offset = 0;
partBuffer[i].packedSize = 0;
partBuffer[i].unpackedSize = 0;
- partBuffer[i].var1A = 0;
}
numElementInPart = 0;
- partVar1 = 30;
partFileHandle.close();
@@ -60,9 +57,7 @@ void loadPart(const char *partName) {
processPendingUpdates(-1);
numElementInPart = partFileHandle.readUint16BE();
- partVar1 = partFileHandle.readUint16BE();
-
- assert(partVar1 == 30);
+ partFileHandle.readUint16BE(); // entry size
strcpy(currentPartName, partName);
@@ -71,7 +66,7 @@ void loadPart(const char *partName) {
partBuffer[i].offset = partFileHandle.readUint32BE();
partBuffer[i].packedSize = partFileHandle.readUint32BE();
partBuffer[i].unpackedSize = partFileHandle.readUint32BE();
- partBuffer[i].var1A = partFileHandle.readUint32BE();
+ partFileHandle.readUint32BE(); // unused
}
if (gameType == Cine::GID_FW)
diff --git a/engines/cine/part.h b/engines/cine/part.h
index 77d7370d77..4af6c6066c 100644
--- a/engines/cine/part.h
+++ b/engines/cine/part.h
@@ -27,15 +27,14 @@
namespace Cine {
-struct partBufferStruct {
+struct PartBuffer {
char partName[14];
uint32 offset;
uint32 packedSize;
uint32 unpackedSize;
- uint32 var1A; /* unused */
};
-struct animDataStruct {
+struct AnimData {
uint16 width;
uint16 var1;
uint16 bpp;
@@ -51,8 +50,8 @@ struct animDataStruct {
#define NUM_MAX_PARTDATA 255
#define NUM_MAX_ANIMDATA 255
-extern animDataStruct animDataTable[NUM_MAX_ANIMDATA];
-extern partBufferStruct *partBuffer;
+extern AnimData animDataTable[NUM_MAX_ANIMDATA];
+extern PartBuffer *partBuffer;
void loadPart(const char *partName);
void freePartRange(uint8 startIdx, uint8 numIdx);
diff --git a/engines/cine/prc.cpp b/engines/cine/prc.cpp
index 4034eeca4f..876937f0d7 100644
--- a/engines/cine/prc.cpp
+++ b/engines/cine/prc.cpp
@@ -59,16 +59,15 @@ void freePrcLinkedList(void) {
void loadPrc(const char *pPrcName) {
uint8 i;
- uint16 numEntry;
+ uint16 numScripts;
+ const uint8 *scriptPtr;
ASSERT_PTR(pPrcName);
for (i = 0; i < NUM_MAX_SCRIPT; i++) {
if (scriptTable[i].ptr) {
ASSERT_PTR(scriptTable[i].ptr);
-
free(scriptTable[i].ptr);
-
scriptTable[i].ptr = NULL;
scriptTable[i].size = 0;
}
@@ -76,64 +75,30 @@ void loadPrc(const char *pPrcName) {
checkDataDisk(-1);
if ((gameType == Cine::GID_FW) && (!strcmp(pPrcName, "AUTO00.PRC"))) {
- const unsigned char *readPtr = AUT000;
-
- processPendingUpdates(1);
-
- numEntry = READ_BE_UINT16(readPtr); readPtr += 2;
-
- ASSERT(numEntry <= NUM_MAX_SCRIPT);
-
- for (i = 0; i < numEntry; i++) {
- scriptTable[i].size = READ_BE_UINT16(readPtr); readPtr += 2;
- }
-
- for (i = 0; i < numEntry; i++) {
- uint16 size;
-
- size = scriptTable[i].size;
-
- if (size) {
- scriptTable[i].ptr = (byte *)malloc(size);
-
- ASSERT_PTR(scriptTable[i].ptr);
-
- memcpy(scriptTable[i].ptr, readPtr, size);
- readPtr += size;
-
- computeScriptStack(scriptTable[i].ptr, scriptTable[i].stack, size);
- }
- }
+ // bypass protection
+ scriptPtr = AUT000;
} else {
- uint8 *ptr = readBundleFile(findFileInBundle(pPrcName));
-
- ASSERT_PTR(ptr);
-
- processPendingUpdates(1);
-
- numEntry = READ_BE_UINT16(ptr); ptr += 2;
-
- ASSERT(numEntry <= NUM_MAX_SCRIPT);
-
- for (i = 0; i < numEntry; i++) {
- scriptTable[i].size = READ_BE_UINT16(ptr); ptr += 2;
- }
-
- for (i = 0; i < numEntry; i++) {
- uint16 size;
-
- size = scriptTable[i].size;
+ scriptPtr = readBundleFile(findFileInBundle(pPrcName));
+ ASSERT_PTR(scriptPtr);
+ }
- if (size) {
- scriptTable[i].ptr = (byte *) malloc(size);
+ processPendingUpdates(1);
- ASSERT_PTR(scriptTable[i].ptr);
+ numScripts = READ_BE_UINT16(scriptPtr); scriptPtr += 2;
+ ASSERT(numScripts <= NUM_MAX_SCRIPT);
- memcpy(scriptTable[i].ptr, ptr, size);
- ptr += size;
+ for (i = 0; i < numScripts; i++) {
+ scriptTable[i].size = READ_BE_UINT16(scriptPtr); scriptPtr += 2;
+ }
- computeScriptStack(scriptTable[i].ptr, scriptTable[i].stack, size);
- }
+ for (i = 0; i < numScripts; i++) {
+ uint16 size = scriptTable[i].size;
+ if (size) {
+ scriptTable[i].ptr = (byte *) malloc(size);
+ ASSERT_PTR(scriptTable[i].ptr);
+ memcpy(scriptTable[i].ptr, scriptPtr, size);
+ scriptPtr += size;
+ computeScriptStack(scriptTable[i].ptr, scriptTable[i].stack, size);
}
}
}
diff --git a/engines/cine/script.cpp b/engines/cine/script.cpp
index c4f1575462..b3d42a5d53 100644
--- a/engines/cine/script.cpp
+++ b/engines/cine/script.cpp
@@ -75,8 +75,8 @@ void addGfxElementA0(int16 param1, int16 param2) {
}
void removeSeq(uint16 param1, uint16 param2, uint16 param3) {
- unkListElementStruct *currentHead = &unkList;
- unkListElementStruct *tempHead = currentHead;
+ SeqListElement *currentHead = &seqList;
+ SeqListElement *tempHead = currentHead;
while (currentHead && (currentHead->var6 != param1 || currentHead->var4 != param2 || currentHead->varE != param3)) {
tempHead = currentHead;
@@ -89,8 +89,8 @@ void removeSeq(uint16 param1, uint16 param2, uint16 param3) {
}
uint16 isSeqRunning(uint16 param1, uint16 param2, uint16 param3) {
- unkListElementStruct *currentHead = &unkList;
- unkListElementStruct *tempHead = currentHead;
+ SeqListElement *currentHead = &seqList;
+ SeqListElement *tempHead = currentHead;
while (currentHead && (currentHead->var6 != param1 || currentHead->var4 != param2 || currentHead->varE != param3)) {
tempHead = currentHead;
@@ -1920,9 +1920,9 @@ void executeScript(prcLinkedListStruct *scriptElement, uint16 params) {
param7 = READ_BE_UINT16(currentScriptPtr + currentPosition);
currentPosition += 2;
- DEBUG_SCRIPT(currentLine, "addUnkListElement(%d,%d,%d,%d,%d)", param1, param2, param3, param4, param5, param6, param7);
+ DEBUG_SCRIPT(currentLine, "addSeqListElement(%d,%d,%d,%d,%d)", param1, param2, param3, param4, param5, param6, param7);
- addUnkListElement(param1, 0, param2, param3, param4, param5, param6, 0, param7);
+ addSeqListElement(param1, 0, param2, param3, param4, param5, param6, 0, param7);
break;
}
@@ -2122,7 +2122,7 @@ void executeScript(prcLinkedListStruct *scriptElement, uint16 params) {
}
if (currentAdditionalBgIdx2 == temp) {
- currentAdditionalBgIdx = 0;
+ currentAdditionalBgIdx2 = 0;
}
strcpy(currentBgName[temp], "");
diff --git a/engines/cine/sfx_player.cpp b/engines/cine/sfx_player.cpp
index 299260eaad..cc4eee495a 100644
--- a/engines/cine/sfx_player.cpp
+++ b/engines/cine/sfx_player.cpp
@@ -37,7 +37,7 @@ namespace Cine {
uint16 snd_eventsDelay;
int snd_songIsPlaying = 0;
uint8 snd_nullInstrument[] = { 0, 0 };
-sfxStateStruct snd_sfxState;
+SfxState snd_sfxState;
static uint8 snd_mute = 0;
static char snd_songFileName[30];
@@ -45,7 +45,7 @@ static char snd_songFileName[30];
/* LVDT specific */
static Common::File *snd_baseSndFile = NULL;
static uint16 snd_numBasesonEntries = 0;
-static BasesonEntryStruct *snd_basesonEntries = NULL;
+static BasesonEntry *snd_basesonEntries = NULL;
int snd_loadBasesonEntries(const char *fileName) {
int i;
@@ -57,10 +57,10 @@ int snd_loadBasesonEntries(const char *fileName) {
snd_numBasesonEntries = snd_baseSndFile->readUint16BE();
snd_baseSndFile->readUint16BE(); /* entry_size */
- snd_basesonEntries = (BasesonEntryStruct *)malloc(snd_numBasesonEntries * sizeof(BasesonEntryStruct));
+ snd_basesonEntries = (BasesonEntry *)malloc(snd_numBasesonEntries * sizeof(BasesonEntry));
if (snd_basesonEntries) {
for (i = 0; i < snd_numBasesonEntries; ++i) {
- BasesonEntryStruct *be = &snd_basesonEntries[i];
+ BasesonEntry *be = &snd_basesonEntries[i];
snd_baseSndFile->read(be->name, 14);
be->offset = snd_baseSndFile->readUint32BE();
be->size = snd_baseSndFile->readUint32BE();
@@ -109,7 +109,7 @@ static uint8 *snd_loadBasesonEntry(const char *entryName) {
} else {
entryNum = snd_findBasesonEntry(entryName);
if (entryNum != -1 && entryNum < snd_numBasesonEntries) {
- const BasesonEntryStruct *be = &snd_basesonEntries[entryNum];
+ const BasesonEntry *be = &snd_basesonEntries[entryNum];
entryData = (uint8 *)malloc(be->unpackedSize);
if (entryData) {
if (be->unpackedSize > be->size) {
diff --git a/engines/cine/sfx_player.h b/engines/cine/sfx_player.h
index fb66b95c5a..b082f5391a 100644
--- a/engines/cine/sfx_player.h
+++ b/engines/cine/sfx_player.h
@@ -27,14 +27,14 @@
namespace Cine {
-struct BasesonEntryStruct {
+struct BasesonEntry {
char name[14];
uint32 offset;
uint32 size;
uint32 unpackedSize;
};
-struct sfxStateStruct {
+struct SfxState {
uint8 *songData;
int currentInstrumentChannel[4];
uint8 *instruments[15];
@@ -46,7 +46,7 @@ struct sfxStateStruct {
extern uint16 snd_eventsDelay;
extern int snd_songIsPlaying;
extern uint8 snd_nullInstrument[];
-extern sfxStateStruct snd_sfxState;
+extern SfxState snd_sfxState;
extern int snd_loadBasesonEntries(const char *fileName);
extern void snd_clearBasesonEntries();
diff --git a/engines/cine/sound_driver.cpp b/engines/cine/sound_driver.cpp
index ffd189aca5..ecf3f83061 100644
--- a/engines/cine/sound_driver.cpp
+++ b/engines/cine/sound_driver.cpp
@@ -37,7 +37,7 @@ uint8 snd_useAdlib = 0;
uint16 snd_fadeOutCounter = 0;
uint16 snd_songTicksCounter = 0;
uint8 *snd_adlibInstrumentsTable[4];
-sndDriverStruct snd_driver;
+SoundDriver snd_driver;
static uint8 snd_adlibVibrato = 0;
static int16 snd_adlibChannelVolume[4];
@@ -318,7 +318,7 @@ static void snd_adlibDriverPlaySound(uint8 * data, int channelNum, int volume) {
}
}
-static sndDriverStruct snd_adlibDriver = {
+static SoundDriver snd_adlibDriver = {
&snd_adlibDriverSetupChannel,
&snd_adlibDriverSetChannelFrequency,
&snd_adlibDriverStopChannel,
diff --git a/engines/cine/sound_driver.h b/engines/cine/sound_driver.h
index 929801634a..1dbc59ff85 100644
--- a/engines/cine/sound_driver.h
+++ b/engines/cine/sound_driver.h
@@ -46,7 +46,7 @@ namespace Cine {
#define ADLIB_REG_FEEDBACK_STRENGTH_CONNECTION_TYPE 0xC0
#define ADLIB_REG_WAVE_SELECT 0xE0
-struct sndDriverStruct {
+struct SoundDriver {
void (*setupChannel) (int channelNum, const uint8 * data, int instrumentNum);
void (*setChannelFrequency) (int channelNum, int frequency);
void (*stopChannel) (int channelNum);
@@ -55,7 +55,7 @@ struct sndDriverStruct {
extern uint16 snd_fadeOutCounter, snd_songTicksCounter;
extern uint8 *snd_adlibInstrumentsTable[4];
-extern sndDriverStruct snd_driver;
+extern SoundDriver snd_driver;
extern void snd_adlibDriverInit();
extern void snd_adlibDriverExit();
diff --git a/engines/cine/various.cpp b/engines/cine/various.cpp
index 0d9b042fad..cc324baedf 100644
--- a/engines/cine/various.cpp
+++ b/engines/cine/various.cpp
@@ -825,7 +825,7 @@ void makeSave(char *saveFileName) {
flipU16((uint16 *)&animDataTable[i].fileIdx);
flipU16((uint16 *)&animDataTable[i].frameIdx);
- fHandle.write(&animDataTable[i], sizeof(animDataStruct));
+ fHandle.write(&animDataTable[i], sizeof(AnimData));
flipU16(&animDataTable[i].width);
flipU16(&animDataTable[i].var1);
@@ -2433,7 +2433,7 @@ void drawOverlays(void) {
if (gameType == Cine::GID_OS) {
uint16 partVar1;
uint16 partVar2;
- animDataStruct *pPart;
+ AnimData *pPart;
pPart = &animDataTable[objPtr->frame];
partVar1 = pPart->var1;
@@ -2445,7 +2445,7 @@ void drawOverlays(void) {
} else {
uint16 partVar1;
uint16 partVar2;
- animDataStruct *pPart;
+ AnimData *pPart;
int16 part = objPtr->part;
ASSERT(part >= 0 && part <= NUM_MAX_PARTDATA);
@@ -2511,7 +2511,7 @@ void drawOverlays(void) {
if (objPtr->frame >= 0) {
uint16 partVar1;
uint16 partVar2;
- animDataStruct *pPart;
+ AnimData *pPart;
int16 part = objPtr->part;
ASSERT(part >= 0 && part <= NUM_MAX_PARTDATA);
@@ -2679,12 +2679,12 @@ void addMessage(uint8 param1, int16 param2, int16 param3, int16 param4, int16 pa
currentHead->previous = newElement;
}
-unkListElementStruct unkList;
+SeqListElement seqList;
-void addUnkListElement(int16 param0, int16 param1, int16 param2, int16 param3, int16 param4, int16 param5, int16 param6, int16 param7, int16 param8) {
- unkListElementStruct *currentHead = &unkList;
- unkListElementStruct *tempHead = currentHead;
- unkListElementStruct *newElement;
+void addSeqListElement(int16 param0, int16 param1, int16 param2, int16 param3, int16 param4, int16 param5, int16 param6, int16 param7, int16 param8) {
+ SeqListElement *currentHead = &seqList;
+ SeqListElement *tempHead = currentHead;
+ SeqListElement *newElement;
currentHead = tempHead->next;
@@ -2693,7 +2693,7 @@ void addUnkListElement(int16 param0, int16 param1, int16 param2, int16 param3, i
currentHead = tempHead->next;
}
- newElement = (unkListElementStruct *)malloc(sizeof(unkListElementStruct));
+ newElement = (SeqListElement *)malloc(sizeof(SeqListElement));
newElement->next = tempHead->next;
tempHead->next = newElement;
@@ -2714,11 +2714,11 @@ void addUnkListElement(int16 param0, int16 param1, int16 param2, int16 param3, i
newElement->var1E = 0;
}
-void resetUnkList() {
- unkList.next = NULL;
+void resetSeqList() {
+ seqList.next = NULL;
}
-void computeMove1(unkListElementStruct *element, int16 x, int16 y, int16 param1,
+void computeMove1(SeqListElement *element, int16 x, int16 y, int16 param1,
int16 param2, int16 x2, int16 y2) {
element->var16 = 0;
element->var14 = 0;
@@ -2744,7 +2744,7 @@ void computeMove1(unkListElementStruct *element, int16 x, int16 y, int16 param1,
}
}
-uint16 computeMove2(unkListElementStruct *element) {
+uint16 computeMove2(SeqListElement *element) {
int16 returnVar = 0;
if (element->var16 == 1) {
@@ -2834,7 +2834,7 @@ void resetGfxEntityEntry(uint16 objIdx) {
#endif
}
-uint16 addAni(uint16 param1, uint16 param2, uint8 *ptr, unkListElementStruct *element, uint16 param3, int16 *param4) {
+uint16 addAni(uint16 param1, uint16 param2, uint8 *ptr, SeqListElement *element, uint16 param3, int16 *param4) {
uint8 *currentPtr = ptr;
uint8 *ptrData;
uint8 *ptr2;
@@ -2877,7 +2877,7 @@ uint16 addAni(uint16 param1, uint16 param2, uint8 *ptr, unkListElementStruct *el
return 1;
}
-void processUnkListElement(unkListElementStruct *element) {
+void processSeqListElement(SeqListElement *element) {
int16 x;
int16 y;
uint8 *ptr1;
@@ -2967,15 +2967,15 @@ void processUnkListElement(unkListElementStruct *element) {
}
}
-void processUnkList(void) {
- unkListElementStruct *currentHead = &unkList;
- unkListElementStruct *tempHead = currentHead;
+void processSeqList(void) {
+ SeqListElement *currentHead = &seqList;
+ SeqListElement *tempHead = currentHead;
currentHead = tempHead->next;
while (currentHead) {
if (currentHead->var4 != -1) {
- processUnkListElement(currentHead);
+ processSeqListElement(currentHead);
}
tempHead = currentHead;
diff --git a/engines/cine/various.h b/engines/cine/various.h
index 85e3150733..e78829a273 100644
--- a/engines/cine/various.h
+++ b/engines/cine/various.h
@@ -50,8 +50,8 @@ struct unk1Struct {
extern unk1Struct messageTable[NUM_MAX_MESSAGE];
-struct unkListElementStruct {
- struct unkListElementStruct *next;
+struct SeqListElement {
+ struct SeqListElement *next;
int16 var4;
int16 var6;
int16 var8;
@@ -68,7 +68,7 @@ struct unkListElementStruct {
int16 var1E;
};
-extern unkListElementStruct unkList;
+extern SeqListElement seqList;
extern uint32 var6;
extern uint32 var8;
@@ -182,9 +182,9 @@ struct mouseStatusStruct {
extern int16 additionalBgVScroll;
-void addUnkListElement(int16 param0, int16 param1, int16 param2, int16 param3, int16 param4, int16 param5, int16 param6, int16 param7, int16 param8);
-void resetUnkList();
-void processUnkList(void);
+void addSeqListElement(int16 param0, int16 param1, int16 param2, int16 param3, int16 param4, int16 param5, int16 param6, int16 param7, int16 param8);
+void resetSeqList();
+void processSeqList(void);
} // End of namespace Cine