Scripting

Update 1.1 introduced basic modding support, aka scripting, to Colt Canyon. This is achieved with the help of the developer console and is only available in the PC version of the game. There is no official platform for sharing mods but the discord is a good place to start looking for mods and support.

Scripts work by simply being a collection of command prompt commands. When a script is executed (e.g. using the console command "run") every line in the script, which should be a simple txt-file, will be executed through the console one after other, starting with the first line.

Installing scripts
There are two ways to install scripts.


 * 1) Add script files to the scripts folder. If you have a script file you will need to place it in the folder that opens when you execute  in the window that opens after pressing Windows + R (with the game closed). Make sure to not modify the name of the script file as it might break the script. If not specified otherwise the mod will now be installed and activated.
 * 2) A different way to install a script is to use the command prompt. If you have a script command ("scriptadd ...") copy it to your clipboard and simply paste it to the command prompt (opened by pressing F1). Confirm by pressing the Enter key. The script will automatically be installed and activated. This is the easiest way to share and add scripts.

Uninstalling scripts
To remove installed scripts you can either remove the script file from %localappdata%/ColtCanyon/scripts or call "scriptremove [scriptname]" in the command prompt.

Auto execution
Colt Canyon's command prompt supports automatic execution of scripts at certain points. For example whenever the game is launched or whenever a level was generated. This is the basic principle under which basic modding/scripting of Colt Canyon works.

To let scripts automatically be executed their file name has to adhere to specific naming conventions. The prefix of the script's filename tells the game when it is supposed to be executed. For example a script file called "gsMyScript" will be automatically executed as soon as the game is started. No need to open the command prompt at all.