CS-Nation

Covering the future of Counter-Strike
cycling aliases tutorial
Introduction
Tired of having too many keys bound to 1, 2, and 3? or other variations? well in this tutorial we will go over how to make a cycling alias, which will allow you to cycle the net graph through all of its settings with only one button.

Step one, making a cycle
lets take what we have from step two of the toggle alias, and make it cycle through all the net graph settings, we'll go backwards, 3-0. This is what we have thrus far:
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"
So we need to take what we have and add the other 2 settings, and change a few words to something else, change ngon to ng1 and ngoff to ng4, also edit the echo a little bit, and add these lines between them:
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 1; bind n ng4"
So now we have this:
alias ng1 "developer 1; echo Net Graph on, setting 1; developer 0; net_graph 3; 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 1; bind n ng4"
alias ng4 "developer 1; echo Net Graph off;developer 0; net_graph 0; bind n ng1"
bind n "ng1"
There, thats done. now we can cycle through all of the net graph settings.

Step two, user friendlizing
To make it so it can be added to the control's menu, we need to take out all those alias binds
(example: alias ng1 "developer 1; echo Net Graph on, setting 1;developer 0; net_graph 3; BIND N NG2")
to do this we need to change that to an alias, its not as tough as it sounds. Replace it with "alias ng ng2", and be sure to change the others as well. So now we have this:
alias ng1 "developer 1; echo Net Graph on, setting 1; developer 0; net_graph 3; 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 1; alias ng ng4"
alias ng4 "developer 1; echo Net Graph off;developer 0; net_graph 0; alias ng ng1"
But this also means we have to add another alias, put this below it: alias ng ng1, so we now have:
alias ng1 "developer 1; echo Net Graph on, setting 1; developer 0; net_graph 3; 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 1; alias ng ng4"
alias ng4 "developer 1; echo Net Graph off; developer 0; net_graph 0; alias ng ng1"
alias ng "ng1"
And now all we have to do is bind ng:
alias ng1 "developer 1; echo Net Graph on, setting 1; developer 0; net_graph 3; 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 1; 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"
There we go! now to change this toggle all we have to do is change the bind, simple! so we can add this to kb_act.lst (open with notepad):
"ng" "Toggle the net graph"

-Corpo