Changes

From Vendetta Online Wiki
Jump to: navigation, search

Binds

5,526 bytes added, 11:52, 29 March 2007
==How binds work== In Vendetta Online, the player can customize their own '''binds and aliases''' to improve their experience. Binds allow you to automate, or program steps, that can be accomplished on the command line within the game. These can range from a simple bind to toggle the auto-aim mode, to a complicated system of aliases and binds that can be used as an online encyclopedia.  Binds operate sequentially. What this means is that if you create a bind that charges a charge cannon for 10 seconds, and then fires, that is what it will do. You cannot interrupt the bind. It will wait the full 10 seconds before finishing. If you have done something to discharge the gun before then, the command to release the trigger "+Shoot1 0" will still go off at the appropriate time. Many binds can be operating at the same time, and overlap their effects.
==How to "Install" Binds==
#Copy and paste.
#Clean up the WGAF file by removing any '/' characters at the beginning of the aliases and/or binds you copied.
 
 
==Loading a Bind (/load filename.cfg)==
When you use the /load filename.cfg command, the binds you have stored in the filename.cfg file will be loaded into the wgaf.cfg file. The filename.cfg file must be loaded from the same directory that wgaf.cfg lives, or you can type the full path to the bind in quotes.
/load filename.cfg
/load "C:\Program Files\Vendetta Online\binds\filename.cfg"
 
The loaded file can be any text file, edited by the editor of your choice, even notepad (yuck) if you are so inclined. If you load a file that contains binds with the same name or alias, then the new ones will overwrite the existing binds. There is no way I know of to erase a bind from the command line in the wgaf.cfg file. If you need to do this you can either edit the wgaf.cfg file directly, or delete the wgaf.cfg file with Vendetta off. It will create a new default wgaf.cfg file, and then you can re-load all your preferred binds and configurations. This may become necessary because when Vendetta re-saves this file after every change, the order of the loaded binds is not preserved, and is stored in a manner that makes it hard to find all the related binds, or follow logical programming paths.
 
Using this way to load binds also allows you to test and troubleshoot the binds without having to reload the game every time.
 
==The config.ini File==
 
 
A discussion on binds would not be complete without a discussion of the config.ini file. This file contains many items, but what I will focus on in relation to binds are the peripherals, specifically the joystick peripherals and how the buttons for them work.
 
Within the config.ini file you will see a label for any joystick that has been connected to your computer when you have played the game. These are added automatically every time you plug in a new device, and old ones can and will clutter up the file if you do this frequently.
 
If you want to change a button to a bind, they behave differently than the keyboard binds. You cannot add joystick configurations to a filename.cfg file and load it, you must change the config.ini file directly. You must also do this while the game is not running as the config.ini file is often updated and overwritten by the game during the course of play.
 
==+/-==
By placing a + or a - on the front of an alias, you designate that this is what happens when the key is pressed or released. It is very useful for altering the effects of joystick buttons, as it is the only way that you can designate a counter event when a button is released. This, as well as all other binds, have the side effect of fireing th
 
In the below example I have switched out the standard "+Shoot1" from the config.ini file for my own custom +guns alias.
 
==Example==
[config.ini]
JOYBUTTON0=+guns
JOYBUTTON1=+Shoot3
 
[fire.cfg]
alias +guns "+Shoot1 1"
alias -guns "+Shoot1 0"
 
==Basic Binds==
 
A basic bind is written on a single line within the file and looks like this.
bind "q" +RotateCW
In this case I have bound my q key to the Rotate Counter Clockwise command. You can bind any key press, except for joystick buttons, to any command or alias.
 
==The Alias==
 
An alias is a designation of one or more commands defined in the wgaf.cfg file. What this means is that you can create any alias you like, and assign it specific commands.
alias mt "+turbo 0"
 
This assigns the "mt" to the action of "+turbo 0". I personally recommend that you use aliases that have more meaning than the above. I have not found a limit on alias length, and it will make it easier to follow your own binds when you want to change them later.
alias masterturbo "+turbo 0"
 
To call an alias you can either bind it directly to a key, or call it directly from within another bind or alias.
 
bind “q” masterturbo
alias foo masterturbo
You can assign multiple commands to an alias, by separating them with a ";".
alias +t "+turbo; alias -t masterturbo"
 
As this example demonstrates, you can also within the alias assign new aliases as part of the assigned alias. This nesting can get quite complex, but also gives you a great deal of control.
==Using Quotes==
Quotes need to be dealt with in a similar manner to other programming languages, with the exception that there is not an escape character. In order to nest a quote within a bind definition, you need to switch from the outside double quotes (“) to an apostrophe or single quote (‘).
 
In the below example, the alias example creates a new alias foo, that contains two commands included within the single quotes. It also calls a third alias, foo3.
 
alias example "alias foo '+Shoot1; wait 0.015 foo2'; foo3"
 
==Sets==
Sets allow you to change on the fly various aspects of the game dynamics. For example you can change your music volume to maximum by using
set snd_musicvolume '1.000000'
 
==The List==
==How to Make Command line Binds==The commands '''/alias''' and '''/bind''' are the only tools used to make your own command-line scripts and shortcutswhen Vendetta is loaded, and you have opened a chat prompt.
==Syntax==
3
edits