Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/29/23 in all areas

  1. import org.osbot.rs07.api.map.Area; import org.osbot.rs07.api.map.constants.Banks; import org.osbot.rs07.api.model.Entity; import org.osbot.rs07.api.model.Player; import org.osbot.rs07.api.model.RS2Object; import org.osbot.rs07.api.ui.Skill; import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; import org.osbot.rs07.utility.ConditionalSleep; @ScriptManifest(author = "Duhrealtim", name = "1-15 WoodCutter", info = "My First Script", version = 0.1, logo = "") public final class Woodcut extends Script { //Areas private final Area treeArea = new Area(3197, 3205, 3180, 3229); private final Area lumbridgeBankArea = new Area(3208, 3218, 3209, 3219); @Override public int onLoop() throws InterruptedException { //Keeps looping if (getInventory().getEmptySlotCount() != 0) { RS2Object tree = getObjects().closest(obj -> obj != null && obj.getName().equals("Tree") && getMap().canReach(obj)); //tree to chop if (!myPlayer().isAnimating()) { if (tree != null) { if (tree.interact("Chop down")) { new ConditionalSleep(5000, 2000) { @Override public boolean condition() throws InterruptedException { return false; } }.sleep(); } } } else if (tree == null) { // if it dont see tree it moves getCamera().toEntity(tree); log("Searching for a tree"); if (getWalking().webWalk(treeArea)) { log("Walking to trees"); new ConditionalSleep(5100, 6100) { @Override public boolean condition() throws InterruptedException { return false; } }; } } } else { log("Inventory Full."); //Walks to bank if (getWalking().webWalk(Banks.LUMBRIDGE_UPPER)) { //What bank it banks at. log("Walking to bank..."); new ConditionalSleep(5000, 1000) { @Override public boolean condition() throws InterruptedException { return true; } }; Entity depoBox = objects.closest("Bank deposit box"); //Opens deposit box and deposits logs. if (depoBox != null) { new ConditionalSleep(2000, 5000) { @Override public boolean condition() throws InterruptedException { return true; } }; if (depoBox.interact("Deposit")) { while (!depositBox.isOpen()) { new ConditionalSleep(2000, 5000) { @Override public boolean condition() throws InterruptedException { return true; } }; } depositBox.depositAllExcept("Bronze axe"); getWalking().webWalk(treeArea); } } } } return 1000; } } My very first script. Still trying to learn how to make it progressive.
    3 points
  2. Take a look at ConditionalSleep's Api docs again, your usage is incorrect. https://osbot.org/api/org/osbot/rs07/utility/ConditionalSleep.html. You really need to be overriding condition() and using that to determine when to stop sleeping. Right now you are just sleeping and hoping 5000ms is enough if you CS is returning false. Also every ConditionalSleep where you are just returning true imminently does nothing. For example if (tree.interact("Chop down")) { new ConditionalSleep(5000, 2000) { @Override public boolean condition() throws InterruptedException { return false; } }.sleep(); } I think your intention is to attempt to chop down a tree, then sleep until the tree is chopped down. In which case it should be something like... if (tree.interact("Chop down")) { new ConditionalSleep(5000, 2000) { @Override public boolean condition() throws InterruptedException { // As long condition() resolves to false, Conditional sleep will continue sleeping (if it hasn't been 5seconds yet). // When you are woodcutting, myPlayer().isAnimating() returns true. // I want to my script to wait until the woodcutting animation is complete (meaning the tree is chopped down) // so by !myPlayer().isAnimating() (note the ! in the beginning) // The script will wait until your character stops chopping (aka stops animating) before checking for the next tree. return !myPlayer().isAnimating(); } }.sleep(); }
    2 points
  3. ────────────── PREMIUM SUITE ────────────── ─────────────── FREE / VIP+ ─────────────── ──────────────────────────────────────────────────────────── ⌠ Sand crabs - $4,99 | Rooftop Agility - $5,99 | AIO Smither - $4,99 | AIO Cooker - $3,99 | Unicow Killer - £3,99 | Chest Thiever - £2,99 | Rock crabs - $4,99 | Rune Sudoku - $9,99 ⌡ ⌠ AIO Herblore - FREE & OPEN-SOURCE | Auto Alcher - FREE | Den Cooker - FREE | Gilded Altar - FREE | AIO Miner - VIP+ ⌡ ──────────────────────────────────── What is a trial? A trial is a chance for you to give any of my scripts a test run. After following the instructions below, you will receive unrestricted access to the respective script for 24 hours starting when the trial is assigned. Your trial request will be processed when I log in. The trial lasts for 24 hours to cater for time zones, such that no matter when I start the trial, you should still get a chance to use the script. Rules: Only 1 trial per user per script. How to get a trial: 'Like' this thread AND the corresponding script thread using the button at the bottom right of the original post. Reply to this thread with the name of the script you would like a trial for. Your request will be processed as soon as I log in. If i'm taking a while, i'm probably asleep! Check back in the morning Once I process your request, you will have the script in your collection (just like any other SDN script) for 24 hours. Private scripts: Unfortunately I do not currently offer private scripts. ________________________________________ Thanks in advance and enjoy your trial! -Apaec.
    1 point
  4. About: Learn more about the mini-game here: https://oldschool.runescape.wiki/w/Sorceress's_Garden VIP only script Features Supported Rewards - Pick Herbs or Pick Sq'irk Fruit Juice Reward Mode - Start the script at the bank with a pestle and mortar to enable this mode automatically when your inventory is full. You must have beer glass in the bank to use this mode. Currently, the script will always withdraw 15 beer glass and 5 energy potions. Bank Reward Mode - If you do not enable juice reward, the script will bank the fruit or herbs picked and return back to the mini-game. If you are picking herbs then the script will always grab 3 energy potions on return. Supported Potions - Normal energy potions, Super energy potions, and Stamina potions. Supported Gardens - Winter, Spring, Autumn Invoke Interaction Mode - Interaction method that does not use the mouse. Useful for position accuracy and successful attempts. This is off by default and only enabled by you. The script will use the mouse to click the mini-map if you do not use invoke interaction. CLI Compatibility: 1) (Required) Garden Parameters: enableWinter, enableSpring, and enableAutumn 2) (Required) Reward Parameters: enableHerbMode, enableFruitMode 3) (Required) Energy Potion Parameters: enableNormalEnergy, enableSuperEnergy, enableStamina 4) (Optional) Interaction Parameter: enableInvoke (off by default) (do not include if you want to use the mouse) Example -script 1220:enableWinter_enableHerbMode_enableSuperEnergy_enableInvoke Media Pick only mode Juice mode
    1 point
  5. Amazing script been using Czar's scripts and they are by far my favorite if you are at all hesitant don't be really well made script and if there is ever an issue or question Czar is quick to respond with a solution / addition couldn't ask for anything more!
    1 point
  6. gotta love these scripts.
    1 point
  7. Hey Czar, it did not show up for me.
    1 point
  8. 1 point
  9. you can.... just type f2p or p2p into the world option
    1 point
  10. Thats very kind of you! Although, I'm not sure how to receive/use it ?
    1 point
  11. Still works thanks mate
    1 point
  12. If you didn't know.. XP on tutorial island maxes out at level 3 you can't go past that.
    1 point
×
×
  • Create New...