summaryrefslogtreecommitdiff
path: root/src/commands.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/commands.c')
-rw-r--r--src/commands.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/commands.c b/src/commands.c
index 752b451..337b0d3 100644
--- a/src/commands.c
+++ b/src/commands.c
@@ -171,6 +171,14 @@ int changemap(FILE *map, char *mapname, demo *demo)
return 1;
}
+int exportmap(FILE *out, demo *demo)
+{
+ if (fwrite(demo->map.data, 1, demo->header.mapsize, out) < (unsigned int) demo->header.mapsize)
+ return -1;
+
+ return 1;
+}
+
void runcommand(cmdinput *cmd, demo *demo)
{
switch (cmd->cmdtype)