Everything posted by Mocro
- OSBot client username.
-
OSBot client username.
i used OSBot client username to keep the progress of each botter is that aloud?
-
getmessage from chatbox
my whole bot crashes when getting messages is there a way to get the last message only so not the whole array im using this. else if(api.chatbox.contains(MessageType.ALL, "Welcome to runescape.")) and then i get nulled when someone types a message or when i typ somthing
-
Check if user is in clan.
Does someone have this to check if your bot is in a clan and if not it will join a clan.
-
FTP Karajama Lobster Fisher and Banker
C:\Users\<username>\OSBot\Scripts Then with Eclipse export it if you dont know i uploaded the jar file for you so you can put it in the folder. http://s000.tinyupload.com/index.php?file_id=87681524579547191526
-
stuck on getInventory.....
how do i call it from the main class it wont let me do it... getting NUlled or error i did Inventory inventory = new Inventory(); or Inventory inventory = new Inventory(null);
-
OsBot wont load?
cannot connect to osbot! What i get in osbot I think server is down
-
stuck on getInventory.....
Thank you il try that its so weird you cant like call methode from that class objects are working for me now but i want to make classes im using public voids now in main class....
-
get itemid by item name.
Oke Thanks anyway its a start
-
get itemid by item name.
do i need to have that item in my inventory?
-
get itemid by item name.
this gives me the amount in my inventory : this.getInventory().getAmount("Cowhide"); i want the ID if i do "CowHide"
- get itemid by item name.
-
stuck on getInventory.....
man im really stuck here im trying my best to understand it just wont work just getting nulled... and im trying to code in objectoriented and in classes ... if i put everything in main class it works fine.... but then its not objectoriented...
-
stuck on getInventory.....
i have no clue how this works.... Inv invent = new Inv(); Inv.this.exchangeContext(bot); invent.compareItems(); banked = invent.getWillowsCut(); private MethodProvider api; public void onStart() { api = new Inv(); api.exchangeContext(getBot()); } did it in my class still null class called Inv en main class called main
-
stuck on getInventory.....
where do i put it inside my class or main?
-
stuck on getInventory.....
awsome thanks works now public class Inventory extends MethodProvider{
-
stuck on getInventory.....
is it possible to use it with myPlayer method?
-
stuck on getInventory.....
import org.osbot.rs07.api.model.Item; import org.osbot.rs07.script.MethodProvider; public class Inventory { // WARNING: Untested code /** Holds the amount of willows we have cut */ private int willowsCut = 0; /** Holds the last inventory that was compared */ private Item[] lastInv; /** * Simple getter * @return the number of willows cut */ public int getWillowsCut() { return willowsCut; } /** * Compares your last inventory with the current inventory. */ public void compareItems() { if (lastInv == null) { lastInv = getInventory().getItems(); return; // It will be the same, no need to check } String item = "Willow logs"; Item[] currInv = getInventory().getItems(); for (int i = 0; i < 28; i++) { // Check for the same thing if ((currInv[i] == null && lastInv == null) || currInv[i].getName().equals(lastInv[i].getName())) continue; // Its the same, continue if (currInv[i] != null) { // We have an item when we didn't if (currInv[i].getName().equals(item)) willowsCut++; // It was a willow log, ++ } else { // We don't have an item when we did if (lastInv[i].getName().equals(item)) willowsCut--; // It was a willow log, -- } } lastInv = currInv; // Update the inv } /** * Run this when the lastInv needs refreshing, aka after banking */ public void resetItems() { lastInv = getInventory().getItems(); } } cant find the getInventory() try to import nothing works.. suggestion of eclipse nothing...
-
When you level Wc Stuck.
ow lmao soz why not though about the try and catch and thanks for the filter
-
When you level Wc Stuck.
i know what a try catch is i always use it i just forgot for that one :P can you send me a example with a filter please? never did that before
-
When you level Wc Stuck.
cords dont want all tree's just 2 i always use try and catch i just forgot on that one lol anyway its fixed now i put it at the first line of the loop before cutting the tree
-
When you level Wc Stuck.
After i click the level up away it works fine this code happens then -> if(level >= 31 && this.myPosition().getY() > 3402) try{ inventory.dropAll("Oak logs"); this.localWalker.walkPath(PathWillows); }catch(Exception e){ } and if the level up dialogues is there this happend and there is no willow tree in sight so thats why the error. -> if (level >= 31){ if ((!this.inventory.isFull()) && (!myPlayer().isAnimating())) { Entity tree = this.objects.closest(11755); for (int i = 0; i < Willow.length; i++) { if(tree.isVisible() && tree.getY() == Willow[i]) try{ tree.interact("Chop Down"); status = "Cutting Willow."; sleep(random(75, 150)); }catch(Exception e){ } } } } i got it need to call it before cutting in loop :p
-
When you level Wc Stuck.
i was Woodcutting and i did when you hit lvl 31 you need to go to willows but its stuck on the dialog screen when you level up on lvl 31 and the bot just gives me nulls because it cant move when i click it away the bot goes on and works fine. i tryed with this: this.dialogues.completeDialogue(); but no effect.
-
cutted willow
Thanks awsome Youtube Java coding allot of people have tuts I need the exp to get it automaticly is that possible getChoppedLogs(40),
-
need good scripter write a private script (can pay $$$$or gp)
im no pro but i can code.