Jump to content

How to use the OSBot Script Queueing


Khaleesi

Recommended Posts

How to use the OSBot script queue in 2023:

Introduction:
Recently OSBot added the support to queue scripts, this means you can create a list of tasks and let the bot do all fo those tasks one by one. No more stopping and starting scripts to change tasks.
Note: Scripts don't have script queue support by default, the script developer has to make some minor changes to support it.
More info can be found in the script developer section.


How do we start using this:
In the client you will see a new Icon where you can start a script.
Click it and you will be able to start making a script queue! Simple as that
aWGysFW.png


Example account build:
The best way to explain this is probably by showing a small example, I will be using my own scripts to create this example as I know these already support script queuing.

Let's say we want to get the following stats on a fresh account:
- 40 Woodcutting
- 25 Thieving

To start this you will need the following script: Khal AIO Woodcutter, Khal AIO Thiever
After that we want to start creating tasks on how we want to achieve these levels listed above.
For each task we will have to create 1 or 2 files that holds all info so the script queue knows what to do.

Woodcutting:
1-15 chop+bank at trees at Varrock
15-30 chop+bank at Oaks at Varrock
30-40 powerchop willows at Lumbridge

Thieving:
1-5 Thieving man/Woman at Lumbridge
5-25 Thieving cake stalls at Ardougne


Example CLI file creation:
Task 1: 1-15 woodcutting at Varrock East Trees (Banking).
1. Set the right location and the right tree to chop (Varrock East + Tree).
2. Save as a CLI file and pick a name, I will use WC_1-15_Varrock
3. Enable the breakmanager
4. Set a stop by level condition to 15 woodcutting.
5. Save the breakfile as CLI file and pick a name for it, I will use WC_1-15_Varrock_Breaks

iz8V2js.png

Task 2: 15-30 woodcutting at Varrock East Oak trees (Banking).
1. Set the right location and the right tree to chop (Varrock-East + Oak tree).
2. Save as a CLI file and pick a name, I will use WC_15-30_Varrock
3. Enable the breakmanager
4. Set a stop by level condition to 30 woodcutting.
5. Save the breakfile as CLI file and pick a name for it, I will use 
WC_15-30_Varrock_Breaks
tQ2oQ5h.png


Task 3: 30-40 woodcutting at Lumbridge willows (powerchopping).

1. Choose your settings + make sure to have your player on the right location you want to chop in so the file knows what to save.
2. Save as a CLI file and pick a name, I will use WC_30-40_Willows
3. Enable the breakmanager
4. Set a stop by level condition to 40 woodcutting.
5. Save the breakfile as CLI file and pick a name for it, I will use WC_30-40_Willows_Breaks

4Pf8My2.png

Task 4: 1-25 thieving, for this example without breaks for this task
(Because of the built-in task system in the script we only have to make 1 CLI file for this instead of 3 like the woodcutter)

1. Choose your settings and make sure to set the stopcontion right.
2. Add task and repeat adding tasks as you like
3. Save the Task list as CLI file and pick a name for it, I will use TH_1-25

oPu4JiU.png

6F0nGht.png

3GPmNVB.png

Example How to make the queue:
So in total you should have created 7 CLI files at this point. (4 script CLI files + 3 Breakmanager CLI fles)
All files can also be found in your OSBot Khal folder: C:\Users\YOURNAME\OSBot\Data\khal

1. Select the Khal AIO Woodcutter script from the list
2. Use your CLI file names as argument and add a "." in between them, first part is the script CLI file, the second part is the breakmanager cli file (Optional).
    => WC_1-15_Varrock.WC_1-15_Varrock_Breaks
    => WC_15-30_Varrock.WC_15-30_Varrock_Breaks
    => WC_30-40_Willows.WC_30-40_Willows_Breaks
    => TH_1-25
3. Add the tasks to the queue

YDdx8DU.png

After adding all tasks start the queue and watch the magic happen :)

txXhmfP.png

How to use queues with CLI:
There are 2 options on how to start a queue from the command line:
1. scriptqueue {queuename} (queue fdile has to be in the OSBot/Data folder)
2. scriptqueue {filepath}

Example usage:

1.  -scriptqueue testqueue
2.  -scriptqueue C:\MyQueues\testqueue.txt (Or whatever the path is in your case)


Feel free to join Our discord for more info and updates! <3
ehkgjLb.png

Edited by Khaleesi
  • Like 6
  • Heart 3
Link to comment
Share on other sites

37 minutes ago, spoook said:

so, when doing this, will it automatically walk/run to the next location?

 

Well that really depends on the script you are trying to queue, I know that for most of my scripts it happends automatically.
There are however some special cases in scripts that needs some special inventory/gear setup, I will deal with those very soon!

but I can't tell about other scripts and how compatible they are at this point. Can always ask a scripter to add if it's not working :)
They have to add queue support aswell to start with

Edited by Khaleesi
  • Heart 1
Link to comment
Share on other sites

4 hours ago, Khaleesi said:

Well that really depends on the script you are trying to queue, I know that for most of my scripts it happends automatically.
There are however some special cases in scripts that needs some special inventory/gear setup, I will deal with those very soon!

but I can't tell about other scripts and how compatible they are at this point. Can always ask a scripter to add if it's not working :)
They have to add queue support aswell to start with

wanna write up a guide regarding the Java implementation side? asked pat about it after he announced the feature. Haven't seen anything yet. 

Link to comment
Share on other sites

14 hours ago, thatboredguy said:

👀

Exactly What @Gunmansaid.
The original way to stop a script is stop();

The only thing you have to do now is use complete() instead;
If there is a next script in queue it will launch the next task, if it's the last one in queue, the queue will stop() instead :D

Edited by Khaleesi
Link to comment
Share on other sites

11 hours ago, Loldude123 said:

Is it possible to use script queue when launching Osbot from CLI? Or does it have to be manually configured through the GUI?

 

Not yet available, will probably beadded in the future.
I assume you will be able to launch some queue file like this in the future: -queue QUEUE_FILENAME

But atm it's just the first version available, will see how it evolves :)

Edited by Khaleesi
  • Sad 1
Link to comment
Share on other sites

  • 2 weeks later...
2 hours ago, kayke666 said:

Hey guys,

when i set this up the bot goes till the first task ends but then just stops completly instead of starting the next script. if i remove the done task(script) and then start the que manually it works. 

Not every SDN script supports queue support I believe, which scripts are you trying to queue?
There is a minor bug in the current version that prevent the queue sometimes, should be fixed in the next client version 😉

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...