Skip to content

Commit 9ee94de

Browse files
committed
temp fix soft lock. status bar/hud/automap cleanup. config file save directory /3ds/prboom3ds for cia and install directory for 3dsx.
1 parent 5786861 commit 9ee94de

File tree

12 files changed

+54
-19
lines changed

12 files changed

+54
-19
lines changed

Makefile

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,15 @@ export OUTPUT_FORMAT ?= 3dsx
3535
#---------------------------------------------------------------------------------
3636
ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard -mtp=soft
3737

38-
CFLAGS := -g -Wall -O2 -mword-relocations -save-temps \
38+
CFLAGS2 := -g -Wall -O2 -mword-relocations -save-temps \
3939
-fomit-frame-pointer -ffast-math \
4040
$(ARCH)
4141

42-
CFLAGS1 := -g -O0 -mword-relocations \
43-
-ffast-math \
44-
$(ARCH)
42+
CFLAGS := -g -Wall -mword-relocations \
43+
-ffunction-sections \
44+
-fdata-sections \
45+
$(ARCH) \
46+
-O2
4547

4648
CFLAGS += $(INCLUDE) -DARM11 -D_3DS -DHAVE_CONFIG_H
4749

arm11/source/3ds_sound.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ void S_ChangeMusic(int music_id, int looping) {
9191
sprintf(namebuf, "d_%s", music->name);
9292
music->lumpnum = W_GetNumForName(namebuf);
9393
}
94-
printf("mus: d_%s\n", music->name);
94+
//printf("mus: d_%s\n", music->name);
9595
music->data = W_CacheLumpNum(music->lumpnum);
9696
mus_play_music(music->data);
9797

arm11/source/keyboard.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ static char key_buttons[] = "1234567890";
2323

2424

2525
sregion_t key_button_array[] = {
26-
{ 32, 0, 0, 0, 0, 0, key_buttons, key_buttons },
27-
{ 270, 0, 6, 0, 0, 0x200, 0 },
26+
{ 32, 16, 0, 0, 0, 0, key_buttons, key_buttons },
27+
{ 270, 16, 6, 0, 0, 0x200, 0 },
2828
{ -30, 32 * 1, 7, 0, 0, KEYD_AUX1, KEYD_AUX1 },
2929
{ -30, 32 * 2, 7, 0, 0, KEYD_AUX2, KEYD_AUX2 },
3030
{ -30, 32 * 3, 7, 0, 0, KEYD_AUX3, KEYD_AUX3 },

arm9/source/ds_vid.c

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -452,11 +452,38 @@ void I_StartTic(void) {
452452
}
453453
}
454454

455+
#define automapactive ((automapmode & am_active) != 0)
456+
455457
//
456458
// I_StartFrame
457459
//
458460
void I_StartFrame(void)
459461
{
462+
extern int viewheight;
463+
extern int keyboard_visible_last;
464+
extern int hud_displayed;
465+
byte *subscreen = screens[5].data;
466+
static viewheight_last = 0;
467+
static hud_displayed_last = 0;
468+
469+
#define HU_HEIGHT 57
470+
#define HU_TOP (240 - HU_HEIGHT - 1)
471+
#define HU_ROWS (240 - HU_TOP)
472+
473+
//if the automap is not active then erase the top few lines
474+
if (!automapactive) {
475+
memset(subscreen, 0, screens[5].width * 16);
476+
}
477+
478+
//erase the bottom if the viewsize changes or the hud is active
479+
if (hud_displayed ||
480+
hud_displayed_last != hud_displayed ||
481+
viewheight_last > viewheight) {
482+
memset(subscreen + (screens[5].width * HU_TOP), 0, screens[5].width * HU_ROWS);
483+
}
484+
485+
viewheight_last = viewheight;
486+
hud_displayed_last = hud_displayed;
460487
}
461488

462489

prboom3ds.3ds

3.5 KB
Binary file not shown.

prboom3ds.3dsx

12 KB
Binary file not shown.

prboom3ds.cia

3.5 KB
Binary file not shown.

src/am_map.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1563,6 +1563,8 @@ inline static void AM_drawCrosshair(int color)
15631563
V_DrawLine(&line, color);
15641564
}
15651565

1566+
extern boolean automapontop;
1567+
15661568
//
15671569
// AM_Drawer()
15681570
//
@@ -1575,7 +1577,7 @@ void AM_Drawer (void)
15751577
// CPhipps - all automap modes put into one enum
15761578
if (!(automapmode & am_active)) return;
15771579

1578-
if (!(automapmode & am_overlay)) // cph - If not overlay mode, clear background for the automap
1580+
if ((!(automapmode & am_overlay)) || (!automapontop)) // cph - If not overlay mode, clear background for the automap
15791581
V_FillRect(FB, f_x, f_y, f_w, f_h, (byte)mapcolor_back); //jff 1/5/98 background default color
15801582
if (automapmode & am_grid)
15811583
AM_drawGrid(mapcolor_grid); //jff 1/7/98 grid default color

src/d_main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -301,10 +301,10 @@ void D_Display (void)
301301
if (viewheight == SCREENHEIGHT) {
302302
SCREENWIDTH = 320;
303303
}
304-
ST_Drawer(true,
304+
ST_Drawer(!hud_displayed,
305305
//((viewheight != SCREENHEIGHT)
306306
// || ((automapmode & am_active) && !(automapmode & am_overlay))),
307-
redrawborderstuff,
307+
redrawborderstuff && !hud_displayed,
308308
(menuactive == mnact_full));
309309

310310
HU_Drawer();

src/hu_stuff.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ int hud_graph_keys=1; //jff 3/7/98 display HUD keys as graphics
6767
//jff 2/16/98 change 167 to ST_Y-1
6868
// CPhipps - changed to ST_TY
6969
// proff - changed to 200-ST_HEIGHT for stretching
70-
#define HU_TITLEY ((200-ST_HEIGHT) - 1 - hu_font[0].height)
70+
#define HU_TITLEY ((200-ST_HEIGHT) - 17 - hu_font[0].height)
7171

7272
//jff 2/16/98 add coord text widget coordinates
7373
// proff - changed to SCREENWIDTH to 320 for stretching
@@ -789,8 +789,8 @@ void HU_Drawer(void)
789789
(
790790
hud_active>0 && // hud optioned on
791791
hud_displayed && // hud on from fullscreen key
792-
viewheight==SCREENHEIGHT && // fullscreen mode is active
793-
!(automapmode & am_active) // automap is not active
792+
viewheight==SCREENHEIGHT //&& // fullscreen mode is active
793+
//!(automapmode & am_active) // automap is not active
794794
)
795795
{
796796
doit = !(gametic&1); //jff 3/4/98 speed update up for slow systems

0 commit comments

Comments
 (0)