run multiple bots from the same .exe

From OpenKore Wiki
Revision as of 11:37, 24 June 2010 by Cozzie (talk | contribs) (First Version; copied and edited from forum)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Introduction

If you run a lot of bots you may wish to run many bots from the same folder. It reduces the maintenance required and gives you more time to bot =)

This is done by specifying certain command line parameters (options) which are available. You may wish to create a shortcut to your bot first, then open the shortcut properties and add these parameters there. (easiest way)

What is a command line parameter?

The command line in this case refers to the directory of a shortcut's target box as shown below.

Command Line

Parameters mean extra information that you want to program to process when it loads. In this case, it would be telling openkore the user specified location of folders or files to load.

Folder options:

These are the available options which are listed when you run the bot with the --help parameter:

  • --control=path

path is the path for the control folder. Example for the location of control folder D:\Kore\swordsman\control below:

D:\Kore\start.exe --control=Kore\swordsman\control
  • --tables=path

path is the path for the tables folder. Example for folder D:\Kore\swordsman\control below:

D:\Kore\start.exe --control=Kore\swordsman\tables
  • --logs=path

path is the path for the logs folder. Example for bot folder D:\Kore\swordsman\logs below:

D:\Kore\start.exe --control=Kore\swordsman\logs
  • --plugins=path

path is the path for the plugins folder. Example for bot folder D:\Kore\swordsman\plugins below:

D:\Kore\start.exe --control=Kore\swordsman\plugins
  • --fields=path

path is the path for the fields folder. Example for bot folder D:\Kore\swordsman\fields below:

D:\Kore\start.exe --control=Kore\swordsman\fields

Specific file options:

There are also some specific files which you can specify using the command line:

  • --config=path\file

path/file specifies which config.txt to use. Example for bot file D:\Kore\control\config_1.txt below:

D:\Kore\start.exe --config=control\config_1.txt
  • --mon_control=path\file

path\file specifies which mon_control.txt to use. Example for bot folder D:\Kore\control\mon_control_2.txt below:

D:\Kore\start.exe --mon_control=control\mon_control_2.txt
  • --items_control=path\file

path\file specifies which items_control.txt to use. Example for bot folder D:\Kore\control\items_control_0.txt below:

D:\Kore\start.exe --items_control=control\items_control_0.txt
  • --pickupitems=path\file

path/file specifies which pickupitems.txt to use. Example for bot folder D:\Kore\control\pickupitems_all.txt below:

D:\Kore\start.exe --pickupitems=control\pickupitems_all.txt
  • --chat=path\file

path/file specifies which chat.txt to use. Example for bot folder D:\Kore\control\chat_7_25.txt below:

D:\Kore\start.exe --chat=control\chat_7_25.txt
  • --shop=path\file

path/file specifies which shop.txt to use. Example for bot folder D:\Kore\control\shop_merch1.txt below:

D:\Kore\start.exe --shop=control\shop_merch1.txt
  • --monsters=path\file

path/file specifies which monsters.txt to use. Example for bot folder D:\Kore\control\monsters_iz_dun.txt below:

D:\Kore\start.exe --monsters=control\monsters_iz_dun.txt
  • --items=path\file

path/file specifies which items.txt to use. Example for bot folder D:\Kore\control\items_in_sphinx below:

 D:\Kore\start.exe --items=control\items_in_sphinx.txt

Interface option:

This command line allows you to specify which interface to use at startup:

  • --interface=module

module is the name of the Perl module for the interface. Check your src\Interface folder for available interface modules. Example: if you want to use the console interface when you run wxstart.exe, put

  • --interface=Console

Note: If you are using the compiled Perl interpreter (e.g. start.exe) you must ensure that the application supports the interface you want to use. For example, wxstart.exe is for Wx, vxstart.exe for Vx, and so on. You can use the "Console" interface using any interpreter.

Usage:

So to use the options just put them into your shortcut. Example:

D:\Kore\start.exe --control=swordsman\control --logs=swordsman\logs

Just make shortcuts like these, each for a different bot settings folder, and you're done. All you really need is control and logs, so I use this with my own bots.

Original Post by hakore [1]. which is based on a post by Joseph

If you have any problems, please post in the forums.