diff --git a/src/menu/doommenu.cpp b/src/menu/doommenu.cpp index e28eebc10..1e5115827 100644 --- a/src/menu/doommenu.cpp +++ b/src/menu/doommenu.cpp @@ -510,6 +510,11 @@ CCMD(reset2saved) R_SetViewSize (screenblocks); } +CCMD(resetb2defaults) +{ + C_SetDefaultBindings (); +} + //============================================================================= // diff --git a/wadsrc/static/defbinds.txt b/wadsrc/static/engine/commonbinds.txt similarity index 83% rename from wadsrc/static/defbinds.txt rename to wadsrc/static/engine/commonbinds.txt index 420d22432..6de42786a 100644 --- a/wadsrc/static/defbinds.txt +++ b/wadsrc/static/engine/commonbinds.txt @@ -1,4 +1,4 @@ -/* Default keybindings for all games */ +// These bindings are valid for all configurations ` toggleconsole 1 "slot 1" @@ -18,20 +18,8 @@ mwheelright invnext enter invuse - sizedown = sizeup -ctrl +attack -alt +strafe shift +speed -space +use -rightarrow +right -leftarrow +left -uparrow +forward -downarrow +back -, +moveleft -. +moveright mouse1 +attack -mouse2 +strafe -mouse3 +forward -mouse4 +speed capslock "toggle cl_run" f1 menu_help f2 menu_save @@ -62,12 +50,6 @@ pgdn +lookup del +lookdown end centerview -// Generic joystick buttons -joy1 +attack -joy2 +strafe -joy3 +speed -joy4 +use - // Xbox 360 / PS2 controllers pad_a +use pad_y +jump diff --git a/wadsrc/static/engine/defbinds.txt b/wadsrc/static/engine/defbinds.txt new file mode 100644 index 000000000..6e3d8cff7 --- /dev/null +++ b/wadsrc/static/engine/defbinds.txt @@ -0,0 +1,10 @@ +/* Default WASD keybindings for all games */ + +w +forward +s +back +a +moveleft +d +moveright +space +jump +x crouch +e +use +mouse2 +altattack diff --git a/wadsrc/static/engine/leftbinds.txt b/wadsrc/static/engine/leftbinds.txt new file mode 100644 index 000000000..63cf50e81 --- /dev/null +++ b/wadsrc/static/engine/leftbinds.txt @@ -0,0 +1,18 @@ +/* Default keybindings for all games */ + +KP8 +forward +KP5 +back +KP4 +moveleft +KP6 +moveright +KP7 +jump +KP1 crouch +KP0 +use +UpArrow +forward +DownArrow +back +LeftArrow +moveleft +RightArrow +moveright +mouse2 +altattack + + + + diff --git a/wadsrc/static/engine/origbinds.txt b/wadsrc/static/engine/origbinds.txt new file mode 100644 index 000000000..02326c7c0 --- /dev/null +++ b/wadsrc/static/engine/origbinds.txt @@ -0,0 +1,20 @@ +/* Default classic keybindings for all games */ + +ctrl +attack +alt +strafe +rightarrow +right +leftarrow +left +uparrow +forward +downarrow +back +, +moveleft +. +moveright +space +use +mouse2 +strafe +mouse3 +forward +mouse4 +speed + +// Generic joystick buttons +joy1 +attack +joy2 +strafe +joy3 +speed +joy4 +use diff --git a/wadsrc/static/filter/game-heretic/defbinds.txt b/wadsrc/static/filter/game-heretic/engine/defbinds.txt similarity index 100% rename from wadsrc/static/filter/game-heretic/defbinds.txt rename to wadsrc/static/filter/game-heretic/engine/defbinds.txt diff --git a/wadsrc/static/filter/game-heretic/engine/leftbinds.txt b/wadsrc/static/filter/game-heretic/engine/leftbinds.txt new file mode 100644 index 000000000..ed820a378 --- /dev/null +++ b/wadsrc/static/filter/game-heretic/engine/leftbinds.txt @@ -0,0 +1,3 @@ +/* Default keybindings for Heretic */ + +backspace "use ArtiTomeOfPower" \ No newline at end of file diff --git a/wadsrc/static/filter/game-heretic/engine/origbinds.txt b/wadsrc/static/filter/game-heretic/engine/origbinds.txt new file mode 100644 index 000000000..ed820a378 --- /dev/null +++ b/wadsrc/static/filter/game-heretic/engine/origbinds.txt @@ -0,0 +1,3 @@ +/* Default keybindings for Heretic */ + +backspace "use ArtiTomeOfPower" \ No newline at end of file diff --git a/wadsrc/static/filter/game-hexen/engine/defbinds.txt b/wadsrc/static/filter/game-hexen/engine/defbinds.txt new file mode 100644 index 000000000..d951bc981 --- /dev/null +++ b/wadsrc/static/filter/game-hexen/engine/defbinds.txt @@ -0,0 +1,11 @@ +/* Default keybindings for Hexen */ + +backspace invuseall +\ "use ArtiHealth" +0 useflechette +9 "use ArtiBlastRadius" +8 "use ArtiTeleport" +7 "use ArtiTeleportOther" +6 "use ArtiPork" +5 "use ArtiInvulnerability2" +scroll +showscores \ No newline at end of file diff --git a/wadsrc/static/filter/game-hexen/engine/leftbinds.txt b/wadsrc/static/filter/game-hexen/engine/leftbinds.txt new file mode 100644 index 000000000..d951bc981 --- /dev/null +++ b/wadsrc/static/filter/game-hexen/engine/leftbinds.txt @@ -0,0 +1,11 @@ +/* Default keybindings for Hexen */ + +backspace invuseall +\ "use ArtiHealth" +0 useflechette +9 "use ArtiBlastRadius" +8 "use ArtiTeleport" +7 "use ArtiTeleportOther" +6 "use ArtiPork" +5 "use ArtiInvulnerability2" +scroll +showscores \ No newline at end of file diff --git a/wadsrc/static/filter/game-hexen/defbinds.txt b/wadsrc/static/filter/game-hexen/engine/origbinds.txt similarity index 100% rename from wadsrc/static/filter/game-hexen/defbinds.txt rename to wadsrc/static/filter/game-hexen/engine/origbinds.txt diff --git a/wadsrc/static/filter/game-strife/engine/defbinds.txt b/wadsrc/static/filter/game-strife/engine/defbinds.txt new file mode 100644 index 000000000..e5f8d029d --- /dev/null +++ b/wadsrc/static/filter/game-strife/engine/defbinds.txt @@ -0,0 +1,7 @@ +/* Default keybindings for Strife */ + +c "showpop 1" +backspace invdrop +z "showpop 3" +k "showpop 2" +q invquery diff --git a/wadsrc/static/filter/game-strife/engine/leftbinds.txt b/wadsrc/static/filter/game-strife/engine/leftbinds.txt new file mode 100644 index 000000000..763ff987f --- /dev/null +++ b/wadsrc/static/filter/game-strife/engine/leftbinds.txt @@ -0,0 +1,7 @@ +/* Default keybindings for Strife */ + +w "showpop 1" +backspace invdrop +z "showpop 3" +s "showpop 2" +q invquery diff --git a/wadsrc/static/filter/game-strife/defbinds.txt b/wadsrc/static/filter/game-strife/engine/origbinds.txt similarity index 100% rename from wadsrc/static/filter/game-strife/defbinds.txt rename to wadsrc/static/filter/game-strife/engine/origbinds.txt diff --git a/wadsrc/static/menudef.txt b/wadsrc/static/menudef.txt index 3933fec74..b20948960 100644 --- a/wadsrc/static/menudef.txt +++ b/wadsrc/static/menudef.txt @@ -504,6 +504,13 @@ ListMenu "PlayerMenu" // //------------------------------------------------------------------------------------------- +OptionValue "Layouts" +{ + 0, "$OPTVAL_MODERN" + 1, "$OPTVAL_CLASSICZ" + 2, "$OPTVAL_MODERNLEFT" +} + OptionMenu "CustomizeControls" protected { Title "$CNTRLMNU_TITLE" @@ -515,6 +522,9 @@ OptionMenu "CustomizeControls" protected Submenu "$CNTRLMNU_OTHER" , "OtherControlsMenu" Submenu "$CNTRLMNU_POPUPS" , "StrifeControlsMenu" Submenu "$MAPCNTRLMNU_CONTROLS" , "MapControlsMenu" + StaticText "" + Option "$CNTRLMNU_LAYOUT", "cl_defaultconfiguration", "Layouts" + SafeCommand "$OPTMNU_DEFAULTS", "resetb2defaults" } OptionMenu "ActionControlsMenu" protected