Add null-cancelling script

This commit is contained in:
Lyrositor
2014-02-23 11:06:56 +01:00
parent f2680134c2
commit 1f910b6371
3 changed files with 28 additions and 0 deletions

View File

@@ -42,6 +42,11 @@ alias MUSIC_PLAYER "music_on"
// the Team videos.
alias MUSIC_PLAYER_CLASSES "music_classes_off"
// NULL_CANCELLING
// Values: null_on | null_off
// If set to null_on, null-cancelling movement is active.
alias NULL_CANCELLING null_on
// SHOW_NETGRAPH
// Values: netgraph_on | netgraph_off
// Shows the netgraph when the user press Tab.

View File

@@ -103,6 +103,26 @@ alias netgraph_off "bind TAB +showscores"
SHOW_NETGRAPH
// Null-Cancelling
// By default, pressing opposite movement keys stops the movement. This script
// changes the behavior so that the last pressed key takes effect.
alias +nc_forward "-back; +forward; alias check_forward +forward"
alias +nc_back "-forward; +back; alias check_back +back"
alias +nc_left "-moveright; +moveleft; alias check_left +moveleft"
alias +nc_right "-moveleft; +moveright; alias check_right +moveright"
alias -nc_forward "-forward; check_back; alias check_forward empty"
alias -nc_back "-back; check_forward; alias check_back empty"
alias -nc_left "-moveleft; check_right; alias check_left empty"
alias -nc_right "-moveright; check_left; alias check_right empty"
alias check_forward empty
alias check_back empty
alias check_left empty
alias check_right empty
alias null_on "bind W +nc_forward; bind S +nc_back; bind A +nc_left; bind D +nc_right"
alias null_off "bind W +forward; bind S +back; bind A +moveleft; bind D +moveright"
NULL_CANCELLING
// Pyro Airblast Call
// Sends a team message asking for a Pyro to airblast you.
bind BACKSPACE pyro_airblast_text