Make sure the right canvas is set for titles and briefings, fixing bug where briefing is shown in the cockpit when using 'freespace' cheat

This commit is contained in:
kreatordxx 2010-07-15 09:45:25 +00:00
parent 9596e0fcf8
commit 8c23459d9e
2 changed files with 4 additions and 2 deletions

View file

@ -4,6 +4,7 @@ D1X-Rebirth Changelog
--------
main/wall.c, main/newdemo.c, main/newdemo.h, main/gauges.c: Cleaned the variables used for newdemo code; Instead of giving both old and new values to special recording functions, added new variables to demo code serving this purpose and also checking for redundant record calls which only would waste bytes; Removed duplicated-object-id-hack which did not work as expected and caused jittering on playback; In that process, found a bug where Num_open_doors might nor be set correctly - cleaned that up a little and got also rid of one aweful goto
main/titles.c: Scale tab stops in briefings to font-size correctly
main/titles.c: Make sure the right canvas is set for titles and briefings, fixing bug where briefing is shown in the cockpit when using 'farmerjoe' cheat
20100713
--------

View file

@ -116,6 +116,7 @@ int title_handler(window *wind, d_event *event, title_screen *ts)
break;
case EVENT_WINDOW_DRAW:
gr_set_current_canvas( NULL );
show_fullscr(&ts->title_bm);
break;
@ -158,8 +159,6 @@ int show_title_screen( char * filename, int allow_keys, int from_hog_only )
Error( "Error loading briefing screen <%s>, PCX load error: %s (%i)\n",filename, pcx_errormsg(pcx_error), pcx_error);
}
gr_set_current_canvas( NULL );
ts->timer = timer_get_fixed_seconds() + i2f(3);
gr_palette_load( gr_palette );
@ -1170,6 +1169,8 @@ int briefing_handler(window *wind, d_event *event, briefing *br)
break;
case EVENT_WINDOW_DRAW:
gr_set_current_canvas(NULL);
if (br->background.bm_data)
show_fullscr(&br->background);