CS-Nation

Covering the future of Counter-Strike
alias types
Introduction
This is a general run-down on alias types. I'll explain what types of aliases you can use, with examples, and their advantages/disadvantages. It will cover all that I can think of, From +/- to simple bind aliases.

+/- aliases
A +/- alias is a alias then will run a command when you press the button, and run another (could be the same, or non-related) when you let go.

Example:
alias +sayreload "+reload;say_team Cover me while I reload!"
alias -sayreload "-reload"
What this will do is say your reloading to your team mates, and ask them to cover you.

+Advantages
+Ability to make Meta Binds (more on this later).
+Lets you replace default movement/attack's with more complex commands (hold walk to say "proceed with stealth").
-Disadvantages
-None to note.

Meta binds
A Meta Bind is a +/- alias, but it rebinds keys. So if I press alt I can have it so 1-0 picks preset weapons and items, sort of like favorites, And letting go rebinds it to slot1-slot0

Example:
alias preset1 "buy; menuselect 4; menuselect 6; buy; menuselect 6; buyequip; menuselect 2"
//this buys a AWP, full ammo, and a kelvar + helmet

alias preset2 "buy; menuselect 3; menuselect 1; buy; menuselect 6; buyequip; menuselect 1; buyequip; menuselect 7"
//this buys a MP5, full ammo, kelvar, and night vision goggles

alias preset3 "buy; menuselect 2; menuselect 1; buy; menuselect 1; menuselect 5; buy; menuselect 6; buy; menuselect 7; buyequip; menuselect 2"
//my personal favorite, it buys a M3, akimbo beretta's, full ammo, and a kelvar + helmet

alias preset4 "buy; menuselect 1; menuselect 3; buy; menuselect 7"
//this buys a DE with full ammo

alias preset5 "developer 1; echo Preset not set!; developer 0"
//this will report to the game screen (top left) that this preset is not set

alias preset6 "developer 1; echo Preset not set!; developer 0"
alias preset7 "developer 1; echo Preset not set!; developer 0"
alias preset8 "developer 1; echo Preset not set!; developer 0"
alias preset9 "developer 1; echo Preset not set!; developer 0"
alias preset10 "developer 1; echo Preset not set!; developer 0"
//be creative

alias +toggle "bind 1 preset1; bind 2 preset2; bind 3 preset3; bind 4 preset4; bind 5 preset5; bind 6 preset6; bind 7 preset7; bind 8 preset8; bind 9 preset9; bind 0 preset10"

alias -toggle "bind 1 slot1; bind 2 slot2; bind 3 slot3; bind 4 slot4; bind 5 slot5; bind 6 slot6; bind 7 slot7; bind 8 slot8; bind 9 slot9; bind 0 slot0"

bind alt "+toggle"
What this will do is make it so holding alt changes 1-0 to different preset "classes" saving the time for buying/doing other things. For all those server's with no freeze time.

+Advantages
+Free up some keys.
+Easy to find the keys.
-Disadvantages
-Time consuming, it takes a very long time to make one, as simple as it works, it could take a half hour to do something like this.

Toggles
A toggle is much like turning the night vision goggles or flashlight on and off, simple. we'll use the net graph for this one.

Example:
alias ngon "developer 1; echo Net Graph on; developer 0; net_graph 3; bind n ngoff"
alias ngoff "developer 1; echo Net Graph off; developer 0; net_graph 0; bind n ngon"
bind n "ngon"
What this will do is make n turn on the net graph, setting 3 (no actual 'graph' in it, but it reports the frame's and packet loss via text).

+Advantages
+Can be used for cycling (more on this later).
-Disadvantages
-Cannot be added to the control's menu.
-Not very user friendly.

Toggles (complex)
This kind of toggle is much like the one above, but it only needs one bind (none in the aliases). Again, we'll use the net graph.

Example:
alias ngon "developer 1; echo Net Graph on; developer 0; net_graph 3; alias ng ngoff"
alias ngoff "developer 1; echo Net Graph off; developer 0; net_graph 0; alias ng ngon"
alias ng "ngon"
bind n "ng"
This will do the same thing as above, but with more advantages (I prefer this one for a more professional look, and ease to edit).

+Advantages
+Can be used for advanced cycling (more later).
+Can be added to the control's menu.
+User friendly.
-Disadvantages
-Takes more space, that extra alias may not seem like much.. but they all add up to cause a z_malloc =).

Cycle aliases
A cycle alias is almost the same as a toggle, but it has more then two options, what better example then the net graph.

Example:
alias ng1 "developer 1; echo Net Graph on, setting 1; developer 0; net_graph 1; bind n ng2"
alias ng2 "developer 1; echo Net Graph on, setting 2; developer 0; net_graph 2; bind n ng3"
alias ng3 "developer 1; echo Net Graph on, setting 3; developer 0; net_graph 3; bind n ng4"
alias ng4 "developer 1; echo Net Graph off; developer 0; net_graph 0; bind n ng1"
bind n "ng1"
This will do the same thing as the toggle, but it has more then one setting, you could have it cycle through different presets and echo which you have selected.

+Advantages
+Multipul commands on one key, altho there may not be alot of things that need it, you could do it.
-Disadvantages
-Cannot be added to the control's menu.
-Not very user friendly.

Cycle aliases (complex)
This kind of cycler is the same as a regular one, but different advantages (much like the complex toggle).

Example:
alias ng1 "developer 1; echo Net Graph on, setting 1; developer 0; net_graph 1; alias ng ng2"
alias ng2 "developer 1; echo Net Graph on, setting 2; developer 0; net_graph 2; alias ng ng3"
alias ng3 "developer 1; echo Net Graph on, setting 3; developer 0; net_graph 3; alias ng ng4"
alias ng4 "developer 1; echo Net Graph off; developer 0; net_graph 0; alias ng ng1"
alias ng "ng1"
bind n "ng"
Same thing as above, but easier to use.

+Advantages
+Can be added to the control's menu.
+User friendly.
-Disadvantages
-Takes more space.

-Corpo