]> 4ch.mooo.com Git - 16.git/blob - src/lib/16_ca.h
somewhat ported!
[16.git] / src / lib / 16_ca.h
1 /* Catacomb Apocalypse Source Code\r
2  * Copyright (C) 1993-2014 Flat Rock Software\r
3  *\r
4  * This program is free software; you can redistribute it and/or modify\r
5  * it under the terms of the GNU General Public License as published by\r
6  * the Free Software Foundation; either version 2 of the License, or\r
7  * (at your option) any later version.\r
8  *\r
9  * This program is distributed in the hope that it will be useful,\r
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of\r
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\r
12  * GNU General Public License for more details.\r
13  *\r
14  * You should have received a copy of the GNU General Public License along\r
15  * with this program; if not, write to the Free Software Foundation, Inc.,\r
16  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.\r
17  */\r
18 \r
19 // ID_CA.H\r
20 #ifndef __16_CA__\r
21 #define __16_CA__
22
23 #include <stdio.h>
24 #include <stdlib.h>
25
26 #ifndef __16_MM__
27 #include "src/lib/16_head.h"
28 #include "src/lib/16_mm.h"\r
29 #endif\r
30 \r
31 //===========================================================================\r
32 \r
33 //#define NOMAPS\r
34 //#define NOGRAPHICS\r
35 //#define NOAUDIO\r
36 \r
37 //#define MAPHEADERLINKED\r
38 //#define GRHEADERLINKED\r
39 //#define AUDIOHEADERLINKED\r
40 \r
41 //#define NUMMAPS               39\r
42 //#define MAPPLANES             3\r
43 \r
44 //===========================================================================\r
45 \r
46 /*typedef       struct\r
47 {\r
48         long            planestart[3];\r
49         unsigned        planelength[3];\r
50         unsigned        width,height;\r
51         char            name[16];\r
52 } maptype;*/\r
53 \r
54 //===========================================================================\r
55 \r
56 /*extern        byte            _seg    *tinf;\r
57 extern  int                     mapon;\r
58 \r
59 extern  unsigned        _seg    *mapsegs[3];\r
60 extern  maptype         _seg    *mapheaderseg[NUMMAPS];\r
61 extern  byte            _seg    *audiosegs[NUMSNDCHUNKS];\r
62 extern  void            _seg    *grsegs[NUMCHUNKS];\r
63 \r
64 extern  byte            far     grneeded[NUMCHUNKS];\r
65 extern  byte            ca_levelbit,ca_levelnum;\r
66 \r
67 extern  char            *titleptr[8];\r
68 \r
69 extern  int                     profilehandle,debughandle;*/\r
70 \r
71 //\r
72 // hooks for custom cache dialogs\r
73 //\r
74 extern  void    (*drawcachebox)         (char *title, unsigned numcache);\r
75 extern  void    (*updatecachebox)       (void);\r
76 extern  void    (*finishcachebox)       (void);\r
77 \r
78 //===========================================================================\r
79 \r
80 // just for the score box reshifting\r
81 \r
82 //void CAL_ShiftSprite (unsigned segment,unsigned source,unsigned dest,unsigned width, unsigned height, unsigned pixshift, boolean domask);\r
83 \r
84 //===========================================================================\r
85 \r
86 void CA_OpenDebug (void);\r
87 void CA_CloseDebug (void);\r
88 boolean CA_FarRead (int handle, byte far *dest, dword length);\r
89 boolean CA_FarWrite (int handle, byte far *source, dword length);\r
90 boolean CA_ReadFile (char *filename, memptr *ptr);\r
91 boolean CA_LoadFile (char *filename, memptr *ptr);\r
92 \r
93 //long CA_RLEWCompress (unsigned huge *source, long length, unsigned huge *dest,unsigned rlewtag);\r
94 \r
95 //void CA_RLEWexpand (unsigned huge *source, unsigned huge *dest,long length,unsigned rlewtag);\r
96 \r
97 void CA_Startup (void);\r
98 void CA_Shutdown (void);\r
99 \r
100 //void CA_CacheAudioChunk (int chunk);\r
101 //void CA_LoadAllSounds (void);\r
102 \r
103 /*void CA_UpLevel (void);\r
104 void CA_DownLevel (void);\r
105 \r
106 void CA_SetAllPurge (void);\r
107 \r
108 void CA_ClearMarks (void);\r
109 void CA_ClearAllMarks (void);\r
110 \r
111 #define CA_MarkGrChunk(chunk)   grneeded[chunk]|=ca_levelbit\r
112 \r
113 void CA_CacheGrChunk (int chunk);\r
114 void CA_CacheMap (int mapnum);\r
115 \r
116 void CA_CacheMarks (char *title);*/\r
117 #endif\r