game folder "just" compiles (not link)

This commit is contained in:
Ondřej Novák 2025-01-25 13:08:41 +01:00
parent 13d3908273
commit 1b0f7fe0c2
135 changed files with 2161 additions and 2336 deletions

31
libs/expand.c Normal file
View file

@ -0,0 +1,31 @@
#include <stdio.h>
#include <stdlib.h>
#include <mem.h>
#include "memman.h"
void help()
{
puts("Usage: Extract skeldal.ddl source.ext target.ext");
exit(1);
}
main(int argc,char **argv)
{
void *z;long s;
FILE *f;
if (argc!=4) help();
OPEN_LOG("");
init_manager(argv[1],NULL);
z=afile(argv[2],read_group(0),&s);
if (z==NULL)
{
puts("File not found");
return 1;
}
f=fopen(argv[3],"w");
fwrite(z,1,s,f);
fclose(f);
puts("File successfuly expanded");
return 0;
}