Use same config for all chars
#14
This code is outdated and will not work as standard.
This will allow you to use multiple storage files for the same bot config
Open your OtClient folder and open \modules\game_bot\bot.lua
Find the text -- storage and replace with the code below.
You can then copy the contents of your previous storage.json into the new file and reopen the config.
Open your OtClient folder and open \modules\game_bot\bot.lua
Find the text -- storage and replace with the code below.
You can then copy the contents of your previous storage.json into the new file and reopen the config.
local configName = settings[index].config
+ local playerName = g_game.getLocalPlayer():getName():lower()
-- storage
botStorage = {}
- botStorageFile = "/bot/" .. configName .. "/storage.json"
+ botStorageFile = "/bot/" .. configName .. "/".. playerName .."_storage.json"
- remove | + add
01 Jan 2020