diff --git a/CHANGELOG.txt b/CHANGELOG.txt index ed5de9a94..09d56f1b7 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -4,6 +4,7 @@ D2X-Rebirth Changelog -------- main/gamecntl.c: If a key combo is called which uses key of default wepaon binding, flush inputs main/mission.c, main/mission.h: Added support for another registered D1 HOG with different patching order... damn you PARALLAX! +d2x.ini, arch/sdl/digi_mixer.c, include/args.h, main/gamefont.c, main/inferno.c, misc/args.c: Added -nomusic ability for SDL_mixer API; Added -gl_fontfixwidth to scale fonts with fixed aspect on widescreen resolutions, scaled to height 20080518 -------- diff --git a/arch/sdl/digi_mixer.c b/arch/sdl/digi_mixer.c index 53dd4ffe0..438717e59 100644 --- a/arch/sdl/digi_mixer.c +++ b/arch/sdl/digi_mixer.c @@ -213,6 +213,9 @@ int digi_mixer_get_max_channels() { return digi_max_channels; } // MIDI stuff follows. void digi_mixer_play_midi_song(char * filename, char * melodic_bank, char * drum_bank, int loop ) { + if (GameArg.SndNoMusic) + return; + mix_set_music_volume(midi_volume); jukebox_load(); // update jukebox state diff --git a/d2x.ini b/d2x.ini index dfff5a585..f293649ed 100644 --- a/d2x.ini +++ b/d2x.ini @@ -36,6 +36,7 @@ ;-lowresmovies Play low resolution movies if available (for slow machines) ;-subtitles Turn on movie subtitles ;-gl_fixedfont Do not scale fonts to current resolution +;-gl_fontfixwidth Scale fonts with fixed width for widescreen resolutions Multiplayer: diff --git a/include/args.h b/include/args.h index 0b85c5e00..1181fec5c 100644 --- a/include/args.h +++ b/include/args.h @@ -70,6 +70,7 @@ typedef struct Arg int GfxMovieSubtitles; #ifdef OGL int OglFixedFont; + int OglFixedFontWidth; #endif int MplGameProfile; int MplNoRankings; diff --git a/main/gamefont.c b/main/gamefont.c index 1c6c80ad6..4a7ac7b1b 100644 --- a/main/gamefont.c +++ b/main/gamefont.c @@ -112,8 +112,15 @@ void gamefont_choose_game_font(int scrx,int scry){ #ifdef OGL if (!GameArg.OglFixedFont) { - FNTScaleX=scrx/font_conf[gf].font[m].x; - FNTScaleY=scry/font_conf[gf].font[m].y; + if (GameArg.OglFixedFontWidth) + { + FNTScaleX = FNTScaleY = scry/font_conf[gf].font[m].y; + } + else + { + FNTScaleX = scrx/font_conf[gf].font[m].x; + FNTScaleY = scry/font_conf[gf].font[m].y; + } } #endif gamefont_loadfont(gf,m); diff --git a/main/inferno.c b/main/inferno.c index 27fbb336b..e78a2acf5 100644 --- a/main/inferno.c +++ b/main/inferno.c @@ -180,6 +180,7 @@ void print_commandline_help() printf( " -subtitles %s\n", "Turn on movie subtitles"); #ifdef OGL printf( " -gl_fixedfont %s\n", "Do not scale fonts to current resolution"); + printf( " -gl_fontfixwidth %s\n", "Scale fonts with fixed width for widescreen resolutions"); #endif // OGL #ifdef NETWORK diff --git a/misc/args.c b/misc/args.c index e35e20bef..281acb27e 100644 --- a/misc/args.c +++ b/misc/args.c @@ -179,6 +179,7 @@ void ReadCmdArgs(void) // OpenGL Options GameArg.OglFixedFont = FindArg("-gl_fixedfont"); + GameArg.OglFixedFontWidth = FindArg("-gl_fontfixwidth"); #endif // Multiplayer Options