summaryrefslogtreecommitdiff
path: root/inc
diff options
context:
space:
mode:
Diffstat (limited to 'inc')
-rw-r--r--inc/demo.h10
-rw-r--r--inc/pack.h3
2 files changed, 12 insertions, 1 deletions
diff --git a/inc/demo.h b/inc/demo.h
index 0b398b0..25c0070 100644
--- a/inc/demo.h
+++ b/inc/demo.h
@@ -3,6 +3,14 @@
#include <stdio.h>
+typedef enum
+{
+ DEMOTICK = 0,
+ DEMOSNAP = 1,
+ DEMOMESSAGE = 2,
+ DEMODELTA = 3
+} demotype;
+
/* demoheader struct */
typedef struct
{
@@ -72,7 +80,7 @@ typedef union {
/* demochunk struct */
typedef struct
{
- unsigned char type;
+ demotype type;
chunkdata data;
} demochunk;
diff --git a/inc/pack.h b/inc/pack.h
index d04d6ca..581bcf9 100644
--- a/inc/pack.h
+++ b/inc/pack.h
@@ -3,6 +3,9 @@
#include <stdio.h>
+/* reads a big endian int into an int */
+int reverseint(const unsigned char in[4]);
+
/* reads a teeworlds packed int from given buffer */
/* the given pointer is incremented */
int readint(unsigned char **cp);