View Full Version : [Request] Tutorial on how to include scripts into cavebot
Funkgary
02-28-2012, 10:30 AM
Title pretty much says it all, if anyone is able/willing to provide a tutorial on how to include scripts into the cavebot function it would be much appreciated. I'm not asking for a tutorial on how to write scripts, just how to put them into my cavebots.
Elvang
02-28-2012, 11:18 AM
Step One: Create a Label
Step Two: Add this line at the top of the script:
registerEventListener(WALKER_SELECTLABEL, "onWalkerSelectLabel")
Step Three: Add something similar to this:
function onWalkerSelectLabel(labelName)
if (labelName == "check") then
dofile("syntax.lua")
if ( count(7378, "weapon") < 7 ) then
gotoLabel("refill")
else
gotoLabel("hunt")
end
Syntax
02-28-2012, 02:17 PM
Elvang, when declaring dofile it has to be above everything. It's like import.
Elvang
02-29-2012, 04:32 AM
Copied from another thread, I know :P
Xparn
01-17-2013, 08:34 PM
Indeed, kinda crappy it doesn't exist already.... Someone might add like Do your waypoint, and then do this to get it to go to go x and say x when there.
Or something easy, so poeple can learn... really it's amazing it's not here already.
haard
11-06-2013, 01:34 PM
I can't really see why DarkStaR did not just put it as simple as LoW did.
Just have a "action" function instead of this importing and such
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.