• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Auto Hotkey Guide.

Status
Not open for further replies.

Baker

Donator
Joined
Mar 31, 2010
Messages
1,390
Likes
0
#1
Chapter One: Introduction
Chapter Two: What is a keybinder?
Chapter Three: Downloading & Installing
Chapter Four: Setting your binds
Chapter Five: The End


Chapter One: Introduction

Hello and welcome to a guide for "AutoHotkey Keybinder". All of the information will be written in white, except for the Chapter names. This guide will teach you how to use and set up one of the most popular and easiest keybinders, "AutoHotkey", called AHK for short. Remember, you can use it on other games too! So, let's start, shall we?

Chapter Two: What is a Keybinder?

First thing which came to your mind while reading the guide's name (if you are new to keybinders), is "What the hell is a keybinder?". A keybinder is a program which allows you to instantly write, order the computer to execute a command, launch a program, and so on by pressing a button or certain button combinations.

Confused? This is a lot easier than it looks like. A typical bind: /q. It orders computer to end process "GTASA: SAMP". Rather than going on ESC, clicking "End Game", then "Yes", you can exit a lot quicker. Unfortunately, there isn't a Key on your Keyboard which allow computer to instantly type and submit command /q, but this is why we here: learning to set it up. Since we are talking about SAMP, the whole thing will be on typing commands.



Chapter Three: Downloading & Installing

The whole time I was playing on SAMP I used a keybinder called "AutoHotkey", AHK for short. This is by far, I guess, the most used keybinder in SAMP. It's fast, easy and free. This guide will be on only about AHK, but in the near future I might add some more of keybinders and their setting here.

Step ONE: Download AutoHotkey. http://www.autohotkey.com/download/

This program is tottaly virus-free. If you don't trust this, you can Google "Autohotkey" and download from another site.

Press on "AutoHotkey Installer" which is in this line:
AutoHotkey Installer (1.95 MB): It is not necessary to uninstall your old version first. If you prefer not to run the installer, download this zip file instead.


Begin downloading. (1.95 MB, a matter of seconds.)


Step TWO: Install the AHK.


Run>Next>I agree>Next>Install (Choose the location on where to install it first)


Wait until it will be installed. When it finish, press "Finish", after unchecking "View Readme". Now, go to the folder in which you've installed the AHK, then make a shortcut and place it on the dekstop for quicker access in the future. Press twice on the shortcut.


Now, look at the programs's icons at the bottom right of your screen. If there is an "H" in a green square, then right mouse click it and select "Edit this Script". If not, then press "<" and then do it.


Congratulations, you've successfully installed AHK.



Chapter Four: Setting your Binds

Sounds hard? Hell no. Okay, you might be confused. You've just opened an empty notepad. The Notepad ain't special, I guess you already noticed that. Alright, let's start with binding.


Write what you want to bind. If you want to bind unholstering your deagle, then the sentence should look like that:


/me takes out his deagle from his waistline.


Okay, we started well. Now, we need the computer to auto-enter the command. We will add {enter} in the end. Keep that in mind, that needs to be {, not [.


/me takes out his deagle from his waistline.{enter}


Good. Since it's typing, we need to activate the chat too. It will get you bored for pressing the button to activate the chat everytime you want to press the bind. It is SAMP. And I know, that the key to activate the chatbox is T. Now, your sentence should be like written below.


t/me takes out his deagle from his waistline.{enter}


No space between the first letter of the sentence and "t". Remember that. Now, you might want to write in the button's name you want to bind on the sentence. Let's pick up, for example, F1.


F1 t/me takes out his deagle from his waistline.{enter}


We ain't done yet. After the button's name which on you wanted to bind the sentence on, there should be written ":: SendInput". You can also write on ":: Send", but it is slower. Sometimes, the slower it is, the better it is, because instant command submit (especially in medical situations) makes you look like a ROBOT.



F1:: SendInput t/me takes out his deagle from his waistline.{enter}


The bind's done. You might ask me, how to combine few commands-sentences on one key? Simple. Let's say, you want to show the the clip of the deagle is full. Watch this.


F1:: SendInput t/me takes out his deagle from his waistline.{enter}t/do Deagle's clip is full{enter}


It's easy to combine. Just writing the next command-sentence without space between {enter} and "t". Likewise, my MP5 bind:


NumPad9:: SendInput t/do Is wearing a black bag on my back{enter}t/me takes off the bag from his back, unzips it.{enter}t/me puts the MP5 inside, then zips the backpack and attaches it to his back.{enter}


I almost forgot about symbols, and combining keys.
! stands for ALT
^ stands for CTRL (Control)
+ stands for SHIFT


If you want to combine the hotkeys (pressing 2 or more keys at the same time to activate), then the line should be like:


^T:: SendInput tBlablblablabal{enter}



Sometimes, it's more roleplay to write the command (waaay slower) than just pressing the button. Why? Because it makes you look like a robot. No fun of the roleplay if all you need to do is to press a button.


Wait, we ain't done yet. Exit the notepad, it will ask you do you want to save the changes, click "Yes". Then, right click the AHK icon which is at the bottom left corner, and select "Reload this Script". If you've done any mistakes, it will throw off an error message. Fix the mistakes. You must reload the script everytime when editing AHK notepad for changes to take effect. Do not exit the AHK.


WARNING: Some commands, like copy (CTRL+C) won't work if CTRL+C is binded with AHK which is running at the time. You must close AHK, or better, suspend the hotkeys. How to do it? Right click the H, then select "Suspend Hotkeys". The H changes into S. To activate the hotkeys, press "Suspend Hotkeys" again.



Now, if you've done everything correctly as I wrote here, and reloaded the script, go In-Game, and test your binds. Here you go, congratulations, you've just learned how to bind a key with AHK.


(P.S: I've found out, with "Preview post", that some of the text because of ::(S}endInput, got replaced with smilies. The original command should be ::(S)endInput, (Remove ( ) )without the space between :: and S. If you find out that binded keys don't work, then remove the space. It works well for me with the space too.)



Chapter Five: The End

Thank you for taking your time reading this. Your help and suggestions to improve this guide is always welcomed and appreciated. If you've spotted any mistakes in my guide, please inform me. I am not a pro at AHK, I don't even know the tricks, but I will try to find them and post them up here.

- Credits to the guy who made this guide.
 

Kabo

Donator
Joined
Aug 1, 2010
Messages
933
Likes
0
IG Name
Xavi/ Miklo/ BillyJo
IG Faction
HTLO/ ED/ CHC
#3
Thank You Very Much but it's wrong section why didnt you post it in Guides and Tutorils topic? But it's awsome guide anway
 

Dr. Paine

Retired Admin
Joined
Jul 6, 2010
Messages
3,726
Likes
0
IG Name
Jedediah_Rhodes
IG Faction
Corn Hauling C**ts !
#5
Moved. Sexy guide, Lou-Lou ! 8)
 
Status
Not open for further replies.