Everything posted by dreameo
-
How to call the sleep method in classes outside of main?
You can make your own sleep method by utilizing a Timer class.
- Project's random.dat Remover Tool
-
Any way to get notified when a bot/client logs out?
Could try something like this: !Client.isLoggedIn() { notify }
-
TT Birds [Free Hunter Script][All Birds supported!]
Just ignore them OP. People easily ridicule others but hide their code and obfuscate it so that no one can look at their mess. No one starts out amazing so, just keep at it, make sure to follow standards and learn more.
- iSHOO «ANTI-BAN» «UP TO 1K SHOO'S P/H» «ONLY $10» «FARMERS PARADISE»
-
A Simple Login Handler
Had this small problem myself and found a fix. The event is blocking. The LoginResponseCodeListener is delayed because of this by a minute or so. set the loginEvent to async and it'll solve that problem.
-
inventory #contains
- inventory #contains
Just keep track # of runes and divide them all by rune needed per spell, before casting, make sure each rune divided by runeUsage >= 1. decrement runes by each spell.- Referencing log from a static context help
yea bbg, I meant Logger logger; private Logger() {} Private Mp mp; public initLog(Mp mp) { if(logger == null) logger = new Logger() logger.mp = mp; } . . . Singleton op (somfin like dat)- Referencing log from a static context help
Logger logger = new Logger(); logger.m = m; edit: im thinkin more singleton but urs is fine ;)- Detecting level up
Look at total skill level, whenever it changes, you've leveled up.- Easiest way to store data
lol okay- Easiest way to store data
Yes, JSON takes minutes to pick up. Plus, you would need to download a library to make good use of it in Java I believe. Not sure why you would want to parse through a string and do string operations to get value from x item. Serialize hash map would be a one time thing to save the file. Read it each time and instantly get the value from key.- Easiest way to store data
Use a hashmap. Heres how to serialize: https://beginnersbook.com/2013/12/how-to-serialize-hashmap-in-java/- Why is this unreachable code?
ofcourse you read the api but cant read about control flow -.-- Why is this unreachable code?
Read the API and if it doesn't help you out, just have a separate file were you can test behavior of certain methods.- Interact() Selects Action too Fast
lol not like that, i meant code to right click an item to open menuIndex, delay, then interact with menuIndex- Interact() Selects Action too Fast
Hmmm.. not sure if you can change mouse speed via api. However, you can make your own interact method of right clicking item and then interacting with the action- webwalking crashing instantly
- Cooking bot, double click
try sleep untill my player is animating. (for the fire interact part) What you have, sleep untill inv does not contain raw,// always returns true edit: the way you have it set up, it returns true always, that's why its spamming I think that'll work, if not, rip- Copy log to txt
Hmm.. not sure if true but I've heard a couple of times that I/O is blocked by the client.- Checking if bank contains a list of items?
This would just get any glory, he's looking to prioritize getting glories with the lowest charge (1),(2)...(n)- Checking if bank contains a list of items?
// assuming bank is open because needGlory is true String[] glorys = [...] if(getBank().isOpen) { for(String glory : glorys) { if(getBank().contains(glory) { if(getBank().withdraw(glory, 1) { cond sleep // inv contains glory break; // exit loop since we have item // needGlory should be false now } { } // script should exit here since bank contains no glory stop(true); } Not tested, insert the condition sleep, (maybe few syntax errors idk, just wrote it here)- Checking if bank contains a list of items?
zz Just use a for loop, if need glory and bank open iterate through the glory strings (1,...6) if has glory, withdraw (cond sleep) if inv contains a glory, break the for loop need glory bool should be flase now- Crafting interface cant figure out...
The string values for interact changed behind the scenes. You gotta find out the new string value of the interact from tooltip. - inventory #contains