Jump to content

Hayase

Members
  • Posts

    159
  • Joined

  • Last visited

  • Feedback

    100%

Everything posted by Hayase

  1. Like another poster said there is not enough default memory to run two tabs in the client. You have to tell the client to use more. In the same directory as your osbot jar make a bat file @echo off title WTF 2 TABZ java -jar "osbot 2.4.107.jar" -mem 2048 pause If it says that java cannot be found or is not a command, you'll have to change it to the full path to java "C:\Program Files\Java\jre1.8.0_111\bin\java.exe" -jar ...
  2. Sexy af. Can you make a signature for storing WC information?
  3. You got banned because you didn't buy VIP
  4. Coming back to this issue I have a better idea if you want to try it. Instead of taking count of the bones directly what about counting the empty spaces you have in your inventory and once you hit 0 you bury bones/bank and then restart? //Somewhere up at the top of your script or wherever you are keeping track of your bone count: int totalBones = 0; case LOOTING_BONES: if (!myPlayer().isAnimating()) { GroundItem bone = groundItems.closest("bones"); if (bone != null) { int currentFreeSpace = inventory.getEmptySlotCount(); bone.interact("Take"); /* * If you use conditional sleeps it will work more efficiently than static sleeping sleep(random(900)); */ new ConditionalSleep(900) { @[member='Override'] public boolean condition() throws InterruptedException { /* * If our empty slot count is less than before--we must have picked up that bone */ if (inventory.getEmptySlotCount() < currentFreeSpace) { //Increase the bone count totalBones++; return true; } return false; } }.sleep(); } } break;
  5. Or just use conditional sleeps: int currentBonerCount = inventory.getItem("Bones").getAmount(); pickUpBone(); new ConditionalSleep(2_000) { @[member='Override'] public boolean condition() throws InterruptedException { return inventory.getItem("Bones").getAmount() > currentBonerCount; } }.sleep();
  6. http://osbot.org/forum/topic/88389-mining-rocks-with-ore-no-ids/
  7. case STEAL: RS2Object stall = getObjects().closest("Tea Stall"); if(stall != null) { if(stall.hasAction("Steal-from") && stall.interact("Steal-from")) { return random(1900, 2500); } } break; Use conditional sleeps so you don't have to worry about sleeping for too little or too long. It's a good idea to get used to using conditional sleeps now for later down the road if you decide to make other scripts that involve interacting with NPCs/objects. case STEAL: RS2Object stall = getObjects().closest("Tea Stall"); if(stall != null) { if(stall.hasAction("Steal-from") && stall.interact("Steal-from")) { new ConditionalSleep(3_000) { @[member='Override'] public boolean condition() throws InterruptedException { return myPlayer().isAnimating(); } }.sleep(); } } break;
  8. Can I have a trial please?
  9. Actually yeah. In linux case actually matters. Try making it lowercase and see if that fixes it?
  10. go to the directory with gui.txt and change permissions on it. Do chmod 777 gui.txt
  11. If you use entity hover debug in the client what do you see about the object and it's id? Perhaps instead of calling it by the string name you can call it by the id instead?
  12. I changed my mind. public boolean validate() throws InterruptedException{ //// Checking if inventory is full, and if so, is our player in the bank or not return sA.inventory.isFull() && !data.EBank.contains(sA.players.myPosition()) && (banker !=null && !banker.isOnScreen()); } Does this work like your Bank node?
  13. Am tired public boolean validate() throws InterruptedException{ //// Checking if inventory is full, and if so, is our player in the bank or not return sA.inventory.isFull() && !data.EBank.contains(sA.players.myPosition()) && (banker !=null && !banker.isOnScreen()); }
  14. That means the object is still null. You need to keep looking for the object by either walking around or something to try and find those objects.
  15. You say you lag out as soon as you get a full inventory. Maybe you are getting a nullpointer? NPC banker = sA.npcs.closest(395); Try and test if (banker != null) before trying to use banker in your validate() && !banker.isOnScreen();
  16. Very elegant documentation it was a pleasure to read
  17. Do I need to do anything special with onMessage? I created a function checkForTrade() using the original code and I'm not sure if it's working or not. @[member='Override'] public void onMessage(Message c) { String m = c.getMessage().toLowerCase(); checkForTrade(); if (trade.getLastRequestingPlayer() !=null && m.contains(trade.getLastRequestingPlayer().getName().toLowerCase())) { log("We found a trade in our onMessage!"); } } Seems to be working now, thanks Saiyan.
  18. Player worker = trade.getLastRequestingPlayer(); log("Waiting for a trade"); if (worker != null) { //this is broken if (worker.isVisible()) { log("I see your trade! Allow me..."); if (worker.interact("Trade with")) { new ConditionalSleep(5000) { @[member='Override'] public boolean condition() throws InterruptedException { return trade.isCurrentlyTrading(); } }.sleep(); } if (trade.isCurrentlyTrading()) //do stuff } else { log("I CAN'T SEE YOU!"); camera.toEntity(worker); } } else { log("Where's the trader?"); } Currently the script doesn't detect a trade. It always returns null for all incoming trades. What is the proper usage to getLastRequestingPlayer()?
  19. Webwalk to the area before the conflicting area, then in the conflicting area use a manual path to walk. If you need to walk further just resume webwalking after you get past the problem area. I use this idea for draynor's attacking tree when I walk from draynor -> grand exchange Example: Area problem_area = new Area(...); Area destination = new Area(...); WebWalkEvent webEvent = new WebWalkEvent(destination); webEvent.setEnergyThreshold(18); webEvent.useSimplePath(); webEvent.setBreakCondition(new Condition() { @[member='Override'] public boolean evaluate() { if (problem_area.contains(myPlayer())) { //build path here https://explv.github.io //use a foreach to loop through positions for the walkPath walking.walkPath(...); return true; } else return false; } }); execute(webEvent);
×
×
  • Create New...