Khaleesi Posted January 21, 2023 Share Posted January 21, 2023 (edited) 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 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 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 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 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 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 After adding all tasks start the queue and watch the magic happen 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! Edited June 19, 2023 by Khaleesi 6 3 Quote Link to comment Share on other sites More sharing options...
spoook Posted January 21, 2023 Share Posted January 21, 2023 so, when doing this, will it automatically walk/run to the next location? Quote Link to comment Share on other sites More sharing options...
Khaleesi Posted January 21, 2023 Author Share Posted January 21, 2023 (edited) 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 January 21, 2023 by Khaleesi 1 Quote Link to comment Share on other sites More sharing options...
thatboredguy Posted January 21, 2023 Share Posted January 21, 2023 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. Quote Link to comment Share on other sites More sharing options...
Gunman Posted January 21, 2023 Share Posted January 21, 2023 59 minutes ago, thatboredguy said: wanna write up a guide regarding the Java implementation side? asked pat about it after he announced the feature. Haven't seen anything yet. Add CLI to your script, then call complete() in your script when ready to move on to the next script in the queue. 1 Quote Link to comment Share on other sites More sharing options...
thatboredguy Posted January 21, 2023 Share Posted January 21, 2023 8 minutes ago, Gunman said: Add CLI to your script, then call complete() in your script when ready to move on to the next script in the queue. Quote Link to comment Share on other sites More sharing options...
Khaleesi Posted January 22, 2023 Author Share Posted January 22, 2023 (edited) 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 Edited January 22, 2023 by Khaleesi Quote Link to comment Share on other sites More sharing options...
Wet Posted January 22, 2023 Share Posted January 22, 2023 Is it possible to use script queue when launching Osbot from CLI? Or does it have to be manually configured through the GUI? Quote Link to comment Share on other sites More sharing options...
Gunman Posted January 22, 2023 Share Posted January 22, 2023 40 minutes 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? @Patrick Quote Link to comment Share on other sites More sharing options...
Khaleesi Posted January 23, 2023 Author Share Posted January 23, 2023 (edited) 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 January 23, 2023 by Khaleesi 1 Quote Link to comment Share on other sites More sharing options...
kayke666 Posted February 6, 2023 Share Posted February 6, 2023 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. Quote Link to comment Share on other sites More sharing options...
Khaleesi Posted February 6, 2023 Author Share Posted February 6, 2023 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 Quote Link to comment Share on other sites More sharing options...
kayke666 Posted February 6, 2023 Share Posted February 6, 2023 Hey @Khaleesi, i was trying this with czar perfect fighter and stealth quester. Quote Link to comment Share on other sites More sharing options...
Khaleesi Posted February 6, 2023 Author Share Posted February 6, 2023 39 minutes ago, kayke666 said: Hey @Khaleesi, i was trying this with czar perfect fighter and stealth quester. Ask the scripters themselves, probably not support it yet. Quote Link to comment Share on other sites More sharing options...
Khaleesi Posted March 18, 2023 Author Share Posted March 18, 2023 Updated slightly Quote Link to comment Share on other sites More sharing options...