Getting Started with Remote Console

From GTA Network Wiki
Jump to: navigation, search

Getting Started with Remote Console

Introduction

The Remote Console is a command prompt where you can use commands without having to be in game.

How to use

1- Simply launch the RCON.exe executable inside bridge directory.

2- Change or leave by default the Server IP Address.

3- Input the Server Password.

4- You're all set!

RCON 2018-05-02 17-04-591.png

Available commands

NAPI

Description: Invokes an API method.

USAGE: NAPI.(Category).(Method)

Example: NAPI.Util.ConsoleOutput("test")


!revent

Description: Invokes a RemoteEvent.

USAGE: !revent [eventName] ([params])

Example: !revent MyEventName true, false


!sevent

Description: Invokes a ServerEvent.

USAGE: !sevent [eventName] ([params])

Example: !sevent PlayerWeaponSwitch WeaponHash.Unarmed, WeaponHash.Knife


/

Description: Invokes a Command.

USAGE: /(command) [params]

Example: /mycommand test lol


!!

Description: Executes any C#-based code at runtime.

USAGE: !!(Code)

Example: !!var myVar = "1"; bool test = true; NAPI.Util.ConsoleOutput(myVar + test);


!exit

Well, uhm.. it does exactly what it says.

Changing Login Password

By default, the RCON login password is set to changeme, it is very recommended to change it to your personal, as following:

1- Open settings.xml in your bridge directory.

2- Chip in the following: (Don't forget to change YourPasswordHere with your desired password)

<rcon_password>YourPasswordHere</rcon_password>

Make sure it looks like the following:

notepad++ 2018-05-02 17-39-44.png

3- Save the file and start your server.

Allow External Connections

By default, the RCON is set up to only accept connections from localhost for security reasons. In order to allow an external IP to connect to the server, you will have to exclude the IP address from being filtered by adding it to the rcon_whitelist.

1- Open settings.xml in your bridge directory.

2- Chip in the following: (Don't forget to change YourExternaIPAddressHere with your desired IP)

<rcon_whitelist>
  <allow>YourExternalIPAddressHere</allow>
</rcon_whitelist>

Make sure it looks like the following:

notepad++ 2018-05-02 17-26-04.png

3- Save the file and start your server.

4- You should be able to log into your server externally.

Disabling RCON

The RCON is turned on by default and only allows the localhost to log in with the exception of whitelisted hosts. If for some reason you would like to turn off the RCON:

1- Open settings.xml in your bridge directory.

2- Chip in the following:

<rcon_enabled>false</rcon_enabled>

Make sure it looks like the following:

notepad++ 2018-05-02 17-32-16.png

3- Save the file and start your server.