aboutsummaryrefslogtreecommitdiff
path: root/engines/cruise/cruise_main.h
blob: 0ca40229dc9d87742f930cc6c06f0d37218a0f88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/* ScummVM - Scumm Interpreter
 * Copyright (C) 2006 The ScummVM project
 *
 * cinE Engine is (C) 2004-2005 by CinE Team
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.

 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.

 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 *
 * $URL$
 * $Id$
 *
 */

#ifndef _CRUISE_H_
#define _CRUISE_H_

#include <string.h>
#include <stdlib.h>
#include <assert.h>

#include "common/stdafx.h"
#include "common/scummsys.h"

#include "cruise/overlay.h"
#include "cruise/object.h"
#include "cruise/ctp.h"
#include "cruise/actor.h"
#include "cruise/vars.h"
#include "cruise/font.h"
#include "cruise/volume.h"
#include "cruise/fontCharacterTable.h"
#include "cruise/stack.h"
#include "cruise/script.h"
#include "cruise/various.h"
#include "cruise/stringSupport.h"
#include "cruise/function.h"
#include "cruise/loadSave.h"
#include "cruise/linker.h"
#include "cruise/mouse.h"
#include "cruise/gfxModule.h"
#include "cruise/dataLoader.h"
#include "cruise/perso.h"
#include "cruise/menu.h"

#include "cruise/background.h"
#include "cruise/backgroundIncrust.h"

#include "cruise/mainDraw.h"

namespace Cruise {

/*#define DUMP_SCRIPT
#define DUMP_OBJECT*/

#define ASSERT_PTR assert
#define ASSERT assert


int32 decomp(uint8 * in, uint8 * out, int32 size);

ovlData3Struct* getOvlData3Entry(int32 scriptNumber, int32 param);
ovlData3Struct* scriptFunc1Sub2(int32 scriptNumber, int32 param);
int16 loadShort(void* ptr);
void resetFileEntry(int32 entryNumber);
void saveShort(void* ptr, int16 var);
void* mallocAndZero(int32 size);
uint8* mainProc14(uint16 overlay, uint16 idx);
void printInfoBlackBox(char* string);
void waitForPlayerInput(void);
int loadCtp(uint8* ctpName);
void loadPakedFileToMem(int fileIdx, uint8* buffer);
int loadScriptSub1(int scriptIdx, int param);
void resetFileEntryRange(int param1, int param2);
int getProcParam(int overlayIdx, int param2, uint8* name);
void changeScriptParamInList(int param1, int param2, scriptInstanceStruct* pScriptInstance,int newValue, int param3);
uint8* getDataFromData3(ovlData3Struct* ptr, int param);
int32 prepareWordRender(int32 param, int32 var1,int16* out2, uint8* ptr3,uint8* string);
void removeExtention(const char* name, char* buffer);
void resetRaster(uint8* rasterPtr, int32 rasterSize);
void changeCursor(uint16 cursorType);
void resetPtr(objectStruct* ptr);
void resetPtr2(scriptInstanceStruct* ptr);
void getFileExtention(const char* name,char* buffer);
void *allocAndZero(int size);
void freeStuff2(void);
char* getObjectName(int index, uint8* string);
void mainLoop(void);
} // End of namespace Cruise

#endif