Jump to content

Bind System


Recommended Posts

Script name: Bind SystemImage

Script author: Cake

 

 

 


 

Introduction

The binding system will allow you to create and manage a limited amount of hotkeys that can trigger a command when you press the key. Unfortunately, due to scripting limitations, the server is only able to detect keys that are attached to a game action. That means that the server is unable to detect any key that isn't hooked to your game's controls. While the server will prompt you with a list of available keys to choose from, it is important to notice that they are merely the default keys and may not represent what the keys might be for you.

 

Following is the list of states that are available, and what the default keys to that state is:


State                                On-Foot Default Key                    In-Vehicle Default Key
KEY_YES                                    Key Y                                            Key Y
KEY_CTRL_BACK                       Key H    
KEY_NO                                    Key N                                            Key N
KEY_SPRINT                              Spacebar                                      Key W
KEY_SECONDARY_ATTACK       Enter                                             Enter
KEY_JUMP                                Left Shift                                       Key S
KEY_WALK                                Left ALT    
KEY_LOOK_RIGHT                                                                          Key E
KEY_LOOK_LEFT                                                                             Key Q
KEY_CROUCH                          Key C                                              Key H / Capslock
KEY_FIRE                                  LMB / Left CTRL                             Left ALT
KEY_LOOK_BEHIND                 MMB / Numpad 1                          Key 2
KEY_HANDBRAKE                    RMB                                               Spacebar
KEY_ACTION                            TAB                                                ALT GR / LCTRL / NUMPAD 0

 


Commands

  • /binds

This will prompt you with a dialog to manage all of your binds. If you do not have any created binds, you will be prompted to create one. The creation process contains 3 steps: what key, when (in vehicle, on foot, or both), and what command to execute.

 

You cannot have two or more binds overlapping each other, as in executing on the same bind. This is restricted to avoid abuse.

 

In the manage your bind profiles dialog, you're able to toggle specific binds on or off, without removing them or disabling your binds all together.

  • /togbinds

This will toggle all of your binds off and will restrict you from the /binds menu until you toggle the binds back on. By default, your binds are disabled and must be enabled with /togbinds.

 

When you trigger a bind, by pressing its hotkey, the command you entered in /binds will execute. The system will inform you if the command failed to execute, if the command does not exist, or failed to execute in rare circumstances.

 


Media

 

MGjGCMe.png XqNu6VZ.png

Edited by asapdev
Link to comment
Share on other sites

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.