X-Git-Url: https://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Fconfig.c;h=c51e9eeb65d3b435004c299acc12bbf26d014fc4;hb=e0591938c7c76de8d25d574f67255d61499bc4cf;hp=4989e29f153e251f6d6e757b84f5ac67a6c46c33;hpb=a2115940e7643dcb1b87286f3d19fe95f7b79bd3;p=flatwaifu.git diff --git a/src/config.c b/src/config.c index 4989e29..c51e9ee 100644 --- a/src/config.c +++ b/src/config.c @@ -24,22 +24,18 @@ #include #include #include -//#include -//#include -#include "config.h" -#include "vga.h" -#include "error.h" +#include "map.h" #include "sound.h" -#include "keyb.h" -#include "files.h" -#include "memory.h" +#include "music.h" #include "view.h" +#include "monster.h" #include "player.h" - -#include - -extern byte _warp,fastdraw,nomon; -extern int mem_chk_sz; +#include "menu.h" +#include "files.h" +#include "render.h" +#include "error.h" +#include "input.h" +#include "my.h" enum{NONE,BYTE,WORD,DWORD,STRING,SW_ON,SW_OFF,FILES,KEY}; @@ -49,13 +45,12 @@ typedef struct{ byte t,o; }cfg_t; - byte cheat=0; - byte shot_vga=0; - - char cd_path[128]=""; +char cfg_file[128]="default.cfg"; + +static char buf[256]; static cfg_t cfg[]={ {"file",NULL,NULL,FILES,0}, @@ -63,11 +58,11 @@ static cfg_t cfg[]={ {"vga","screenshot",&shot_vga,SW_ON,0}, {"sndvol","sound_volume",&snd_vol,WORD,0}, {"musvol","music_volume",&mus_vol,WORD,0}, - {"fullscr","fullscreen",&fullscreen,SW_ON,0}, - {"window",NULL,&fullscreen,SW_OFF,0}, +// {"fullscr","fullscreen",&fullscreen,SW_ON,0}, +// {"window",NULL,&fullscreen,SW_OFF,0}, {NULL,"sky",&w_horiz,SW_ON,0}, {"mon",NULL,&nomon,SW_OFF,0}, - {"gamma","gamma",&gammaa,DWORD,0}, +// {"gamma","gamma",&gammaa,DWORD,0}, {"warp",NULL,&_warp,BYTE,0}, {"width","screen_width",&SCRW,DWORD,0}, {"height","screen_height",&SCRH,DWORD,0}, @@ -93,14 +88,9 @@ static cfg_t cfg[]={ {NULL,"pl2_prev", &pl2.kwl,KEY,0}, {NULL,"pl2_use", &pl2.kp,KEY,0}, {"config",NULL,cfg_file,STRING,0}, - {NULL,NULL,NONE,0} + {NULL,NULL,NULL,NONE,0} }; - -char cfg_file[128]="DEFAULT.CFG"; - -static char buf[256]; - void CFG_args(int argc, char *argv[]) { int j; dword n; @@ -164,19 +154,6 @@ next: } } -int get_key(char *name) -{ - int i; - for(i=1; i