Added DOS style scrolling via a commandline parameter

This commit is contained in:
twojstaryzdomu 2022-02-25 20:12:37 +01:00 committed by Gregory Montoir
parent e7aa6e5ce4
commit 29936e8a44
2 changed files with 6 additions and 0 deletions

View File

@ -60,6 +60,7 @@ Usage: blues [OPTIONS]...
--filter=NAME Graphics scaling filter (default 'nearest')
--screensize=WxH Graphics screen size (default 320x200)
--cga Enable CGA colors
--dosscroll Enable DOS style screen scrolling
```
## Downloads

5
main.c
View File

@ -23,6 +23,7 @@ static const char *USAGE =
" --filter=NAME Graphics scaling filter (default 'nearest')\n"
" --screensize=WxH Graphics screen size (default 320x200)\n"
" --cga Enable CGA colors\n"
" --dosscroll Enable DOS style screen scrolling\n"
;
static struct game_t *detect_game(const char *data_path) {
@ -80,6 +81,7 @@ int main(int argc, char *argv[]) {
{ "filter", required_argument, 0, 8 },
{ "screensize", required_argument, 0, 9 },
{ "cga", no_argument, 0, 10 },
{ "dosscroll", no_argument, 0, 11 },
{ 0, 0, 0, 0 },
};
int index;
@ -122,6 +124,9 @@ int main(int argc, char *argv[]) {
case 10:
g_options.cga_colors = true;
break;
case 11:
g_options.dos_scrolling = true;
break;
default:
fprintf(stdout, USAGE, argv[0]);
return -1;