From 4648dcb1f73e37506cf317131521c2c326bf0767 Mon Sep 17 00:00:00 2001 From: lantus360 Date: Thu, 26 Jul 2018 15:17:00 -0500 Subject: [PATCH] no longer need a 'tmp' folder. reduced input lag --- Makefile.doom | 4 ++-- release/chocolate-doom.cfg | 2 +- src/i_timer.c | 2 ++ src/m_controls.c | 6 +++--- src/m_misc.c | 2 +- 5 files changed, 9 insertions(+), 7 deletions(-) diff --git a/Makefile.doom b/Makefile.doom index 6075e7a..f698247 100644 --- a/Makefile.doom +++ b/Makefile.doom @@ -11,7 +11,7 @@ export BUILD_EXEFS_SRC := build/exefs APP_TITLE := Chocolate-Doom APP_DESCRIPTION := Chocolate-Doom APP_AUTHOR := MVG -APP_VERSION := 1.0.0 +APP_VERSION := 1.0.2 ICON := Doom.jpg CC = aarch64-none-elf-gcc @@ -21,7 +21,7 @@ LINKOBJ = obj/deh_str.o obj/d_event.o obj/d_iwad.o obj/i_endoom.o obj/i_joysti #OPL Music LINKOBJ += obj/opl.o obj/opl_sdl.o obj/i_oplmusic.o obj/opl_queue.o obj/opl3.o obj/midifile.o -LIBS = -specs=$(DEVKITPRO)/libnx/switch.specs -g -march=armv8-a -mtune=cortex-a57 -mtp=soft -fPIE -L$(DEVKITPRO)/libnx/lib -L$(DEVKITPRO)/portlibs/switch/lib -lSDL2_mixer -lvorbisfile -lvorbis -logg -lmodplug -lmpg123 -lSDL2 -lm -lstdc++ -lnx +LIBS = -specs=$(DEVKITPRO)/libnx/switch.specs -g -march=armv8-a -mtune=cortex-a57 -mtp=soft -fPIE -L$(DEVKITPRO)/libnx/lib -L$(DEVKITPRO)/portlibs/switch/lib -lSDL2_mixer -lvorbisfile -lvorbis -logg -lmodplug -lmpg123 -lSDL2 -lm -lstdc++ -lnx INCS = -Isrc -Icodeblocks -Iopl -Itextscreen -I$(DEVKITPRO)/portlibs/switch/include/SDL2 -I"src/main" -I$(DEVKITPRO)/libnx/include -I$(DEVKITPRO)/portlibs/switch/include CXXINCS = -I$(DEVKITPRO)/portlibs/switch/include/SDL2 -I"src/main" -I$(DEVKITPRO)/libnx/include -I$(DEVKITPRO)/portlibs/switch/include BUILD = build diff --git a/release/chocolate-doom.cfg b/release/chocolate-doom.cfg index 464c055..2c1c823 100644 --- a/release/chocolate-doom.cfg +++ b/release/chocolate-doom.cfg @@ -38,7 +38,7 @@ mouseb_use -1 mouseb_backward -1 mouseb_prevweapon -1 mouseb_nextweapon -1 -dclick_use 1 +dclick_use 0 joystick_guid "" joystick_index -1 joystick_x_axis 2 diff --git a/src/i_timer.c b/src/i_timer.c index 9c03a61..4aa6cc3 100644 --- a/src/i_timer.c +++ b/src/i_timer.c @@ -67,7 +67,9 @@ void I_Sleep(int ms) void I_WaitVBL(int count) { +#ifndef SWITCH I_Sleep((count * 1000) / 70); +#endif } diff --git a/src/m_controls.c b/src/m_controls.c index 562116a..3e5a725 100644 --- a/src/m_controls.c +++ b/src/m_controls.c @@ -179,8 +179,8 @@ int key_menu_screenshot = 0; // int joybfire = 9; -int joybstrafe = 1; -int joybuse = 3; +int joybstrafe = -1; +int joybuse = 1; int joybspeed = 2; int joybstrafeleft = -1; @@ -197,7 +197,7 @@ int joybautomap = -1; // Control whether if a mouse button is double clicked, it acts like // "use" has been pressed -int dclick_use = 1; +int dclick_use = 0; // // Bind all of the common controls used by Doom and all other games. diff --git a/src/m_misc.c b/src/m_misc.c index 3662629..64bcbe2 100644 --- a/src/m_misc.c +++ b/src/m_misc.c @@ -251,7 +251,7 @@ char *M_TempFile(const char *s) #else // In Unix, just use /tmp. - tempdir = "tmp"; + tempdir = ""; #endif return M_StringJoin(tempdir, DIR_SEPARATOR_S, s, NULL);