summaryrefslogtreecommitdiffstats
path: root/zoom/level.h
diff options
context:
space:
mode:
authorneoraider <devnull@localhost>2005-04-18 17:27:00 +0200
committerneoraider <devnull@localhost>2005-04-18 17:27:00 +0200
commitf3df7ef89aa15aed2e4d68e2b414d31aef57f976 (patch)
tree53c5630e7a890dc6c1b0b0a2d631119a21da984a /zoom/level.h
downloadlibzoom-f3df7ef89aa15aed2e4d68e2b414d31aef57f976.tar
libzoom-f3df7ef89aa15aed2e4d68e2b414d31aef57f976.zip
Verzeichnisstruktur ge?ndert
Diffstat (limited to 'zoom/level.h')
-rw-r--r--zoom/level.h48
1 files changed, 48 insertions, 0 deletions
diff --git a/zoom/level.h b/zoom/level.h
new file mode 100644
index 0000000..50911b0
--- /dev/null
+++ b/zoom/level.h
@@ -0,0 +1,48 @@
+#ifndef GAME_LEVEL_H
+#define GAME_LEVEL_H
+
+#include <GL/gl.h>
+#include "types.h"
+
+#pragma pack(push, 2)
+typedef struct _LEVELHEADER {
+ char l, f;
+ int nRooms;
+ int nTextures;
+} LEVELHEADER;
+
+typedef struct _ROOMHEADER {
+ int nTriangles;
+ int nObjects;
+ int nGates;
+} ROOMHEADER;
+
+typedef struct _GATEINFO {
+ unsigned short state;
+ unsigned short timer;
+} GATEINFO;
+
+typedef struct _ROOM {
+ int nTriangles;
+ int nObjects;
+ int nGates;
+ TRIANGLE *triangles;
+ OBJECT *objects;
+ GATE *gates;
+ GATEINFO *gateinfo;
+} ROOM;
+
+typedef struct _LEVEL {
+ int nRooms;
+ ROOM *rooms;
+ int nTextures;
+ GLuint *textures;
+} LEVEL;
+#pragma pack(pop)
+
+
+int LoadLevel(char *, LEVEL *);
+void DrawRoom(LEVEL *, int);
+void FreeLevel(LEVEL *);
+
+#endif