Dogcube Posted June 1, 2021 Share Posted June 1, 2021 (edited) Bad script deleted Edited September 14, 2021 by Dogcube Nothing was in onloop Quote Link to comment Share on other sites More sharing options...
Dogcube Posted June 1, 2021 Author Share Posted June 1, 2021 HELP I POSTED THREE AND DONT WANT TO SPAM HOW DO I DELETE Quote Link to comment Share on other sites More sharing options...
skillerkidos1 Posted June 1, 2021 Share Posted June 1, 2021 Erm it’s not going to do anything all I see is like a few methods but nothing in your onLoop did you test it? Quote Link to comment Share on other sites More sharing options...
Dogcube Posted June 1, 2021 Author Share Posted June 1, 2021 1 hour ago, skillerkidos1 said: Erm it’s not going to do anything all I see is like a few methods but nothing in your onLoop did you test it? No because I dont have any proxies I thought it would work ty for telling me I am a very big noob Quote Link to comment Share on other sites More sharing options...
Dogcube Posted June 1, 2021 Author Share Posted June 1, 2021 1 hour ago, skillerkidos1 said: Erm it’s not going to do anything all I see is like a few methods but nothing in your onLoop did you test it? 1 hour ago, skillerkidos1 said: Erm it’s not going to do anything all I see is like a few methods but nothing in your onLoop did you test it? do I just need to init it inside the onlooop? Quote Link to comment Share on other sites More sharing options...
skillerkidos1 Posted June 1, 2021 Share Posted June 1, 2021 3 minutes ago, Dogcube said: do I just need to init it inside the onlooop? yea so you need to put your methods to use in onLoop() otherwise nothing will happen if(needToHeal(){ heal() }else if(canAttack(){ attack() } Quote Link to comment Share on other sites More sharing options...
Dogcube Posted June 1, 2021 Author Share Posted June 1, 2021 2 minutes ago, skillerkidos1 said: yea so you need to put your methods to use in onLoop() otherwise nothing will happen if(needToHeal(){ heal() }else if(canAttack(){ attack() } ok thanks I am big retard Quote Link to comment Share on other sites More sharing options...
skillerkidos1 Posted June 1, 2021 Share Posted June 1, 2021 7 minutes ago, Dogcube said: ok thanks I am big retard lmao if you need any help add me on discord SkillerKido#2423 Quote Link to comment Share on other sites More sharing options...
Gunman Posted June 2, 2021 Share Posted June 2, 2021 @Dogcube Hid your reposts. Methods like this private boolean needToHeal(){ int healPercent = 45; if(healPercent > getHpPercent()){ return true; }else{ return false; } } Can be simplified to this private boolean needToHeal() { int healPercent = 45; return healPercent > getHpPercent(); } And make sure you use braces ( these -> {} ) on your if statements. Scripting tutorial linked below. https://osbot.org/forum/topic/115124-explvs-scripting-101/ Quote Link to comment Share on other sites More sharing options...
Dogcube Posted June 2, 2021 Author Share Posted June 2, 2021 10 hours ago, Gunman said: @Dogcube Hid your reposts. Methods like this private boolean needToHeal(){ int healPercent = 45; if(healPercent > getHpPercent()){ return true; }else{ return false; } } Can be simplified to this private boolean needToHeal() { int healPercent = 45; return healPercent > getHpPercent(); } And make sure you use braces ( these -> {} ) on your if statements. Scripting tutorial linked below. https://osbot.org/forum/topic/115124-explvs-scripting-101/ Thanks for the tip I will make sure to keep it in mind for future scripts Quote Link to comment Share on other sites More sharing options...