Conscious Realm Posted May 24, 2020 Share Posted May 24, 2020 Hello, I'm new to coding, like today new... I've only just learnt how to install and set up Eclipse! But now well on my way to (Attempting) to code a Woodcutting script. I have ran into my first problem it seems... When trying to write a line of code for: if ( Client.getInventory().isFull(){ } My code doesn't seem to want to pick up the client at all? I feel like I have set up Eclipse well and added the OSB client correct following a guide here, so what could be my issue? Appreciate the help, It's all love Quote Link to comment Share on other sites More sharing options...
Lol_marcus Posted May 24, 2020 Share Posted May 24, 2020 (edited) You don't need to use "Client." You can use "Inventory.isFull()" or "getInventory().isFull()". You can do something like this: private void drop() throws InterruptedException { if (getInventory().isFull()) { getInventory().dropAllExcept("Rune axe"); sleep(random(50, 105)); new ConditionalSleep(5000, 600) { @Override public boolean condition() { return (getInventory().isEmptyExcept("Rune axe")); } }.sleep(); } else { stop(false); } } Furthermore, when using Eclipse you can press "cntrl+space" and it'll give you all possible options for what you're trying. So if you type "getInven" and pres cntrl+space, it'll show "getInventory()", and after you type ".", it'll show everything like "getInventory.isFull" "getInventory.isEmpty", etc. Edited May 24, 2020 by Lol_marcus 1 Quote Link to comment Share on other sites More sharing options...
Conscious Realm Posted May 24, 2020 Author Share Posted May 24, 2020 I see, thank you very much for that! So it's kinda optional? This video guide I'm watching to create the script and learn 10:40 says to use client so I can carry on and just adjust the step as you say Quote Link to comment Share on other sites More sharing options...
Conscious Realm Posted May 24, 2020 Author Share Posted May 24, 2020 So, now my code looks like this Quote Link to comment Share on other sites More sharing options...
D9BLADEE Posted May 24, 2020 Share Posted May 24, 2020 6 minutes ago, Conscious Realm said: I see, thank you very much for that! So it's kinda optional? This video guide I'm watching to create the script and learn 10:40 says to use client so I can carry on and just adjust the step as you say This guide is 7 years old, API's been updated since then Quote Link to comment Share on other sites More sharing options...
Conscious Realm Posted May 24, 2020 Author Share Posted May 24, 2020 1 minute ago, D9BLADEE said: This guide is 7 years old, API's been updated since then Damn... I learn by following things like step by step coding the script like this and there doesn't appear to be recent coding videos like this one? Quote Link to comment Share on other sites More sharing options...
Lol_marcus Posted May 24, 2020 Share Posted May 24, 2020 I highly recommend these 2 videos, as well as the tutorials in the tutorial section by Apaec and Explv. 1 Quote Link to comment Share on other sites More sharing options...
Ace99 Posted May 24, 2020 Share Posted May 24, 2020 1 hour ago, Lol_marcus said: I highly recommend these 2 videos, as well as the tutorials in the tutorial section by Apaec and Explv. +1 to Explv as it is what I started on 1 Quote Link to comment Share on other sites More sharing options...