templex 5 Share Posted November 14, 2017 completely uninstalled java and reinstalled the freshest JDK 64 bit, installed eclipse 64 (my windows 10 is 64 bit), still getting the same problem. https://gyazo.com/acba4a9d8123f2c9dcb9a12f9a9c2a14 also getting a new problem?? https://gyazo.com/3da86da04e125ae1e196ae94504fdb53 very frustrating as you can imagine ok i think i solved most of the issue by installing eclipse oxygen rather the download what was linked this is the only problem i have now https://gyazo.com/01abfd351a2ea967956d1d24c3a423b7 Link to comment Share on other sites More sharing options...
LogicSoup 92 Share Posted November 19, 2017 Should make it check if the method returns true. otherwise you might sleep for 15s on rare occasions Link to comment Share on other sites More sharing options...
ProBotterIamN 11 Share Posted November 19, 2017 completely uninstalled java and reinstalled the freshest JDK 64 bit, installed eclipse 64 (my windows 10 is 64 bit), still getting the same problem. https://gyazo.com/acba4a9d8123f2c9dcb9a12f9a9c2a14 also getting a new problem?? https://gyazo.com/3da86da04e125ae1e196ae94504fdb53 very frustrating as you can imagine ok i think i solved most of the issue by installing eclipse oxygen rather the download what was linked this is the only problem i have now https://gyazo.com/01abfd351a2ea967956d1d24c3a423b7 ic what you did do wrong package "your package here"; without the quotes a package is where your class is located https://gyazo.com/b368e88d05e1e7f8cfd4f454f5bcf8b2 in my case it would be package noobcwalker; it has to be on the top of your script https://gyazo.com/0081e3f917ffaf52ac9e8518713eed89 take a look at this: package noobcwalker; import org.dreambot.api.methods.Calculations; import org.dreambot.api.methods.map.Area; import org.dreambot.api.methods.map.Tile; import org.dreambot.api.script.AbstractScript; import org.dreambot.api.script.ScriptManifest; import org.dreambot.api.script.Category; import org.dreambot.api.utilities.Timer; import java.awt.*; import java.text.DecimalFormat; import java.util.concurrent.TimeUnit; @ScriptManifest(author = "ProBotterIamN", name = "Example Script", version = 0.0, description = "Just To Show how packaging wors!", category = Category.MISC) public class main extends AbstractScript { public void onStart() { } private enum State { }; private State getState() { } public void onExit() { } @Override public int onLoop() { } } Link to comment Share on other sites More sharing options...
G_G 0 Share Posted August 30, 2019 Hi, I'm totally new to coding and I'm getting an error on the import section: - The import org cannot be resolved - Must declare a named package because this compilation unit is associated to the named module 'simpleTeaThief' Do you know what I could have done wrong? import org.dreambot.api.script.AbstractScript; // All these imports are from the dreambot API import org.dreambot.api.script.ScriptManifest; // API can be found here: https://dreambot.org/javadocs/ import org.dreambot.api.script.Category; import org.dreambot.api.wrappers.interactive.GameObject; Link to comment Share on other sites More sharing options...
Nex 2542 Author Share Posted August 30, 2019 16 minutes ago, G_G said: Hi, I'm totally new to coding and I'm getting an error on the import section: - The import org cannot be resolved - Must declare a named package because this compilation unit is associated to the named module 'simpleTeaThief' Do you know what I could have done wrong? import org.dreambot.api.script.AbstractScript; // All these imports are from the dreambot API import org.dreambot.api.script.ScriptManifest; // API can be found here: https://dreambot.org/javadocs/ import org.dreambot.api.script.Category; import org.dreambot.api.wrappers.interactive.GameObject; You need to import the dreambot "client.jar", path: "C:\Users\PC_NAME\DreamBot\BotData\client.jar" Add it here: Link to comment Share on other sites More sharing options...
SyarTheTitan 0 Share Posted November 26, 2019 I noticed you put sleepUntil(() -> !getLocalPlayer().isAnimating() , 15000); could me instead put sleepUntil(tree = null, 5000); This way the bot will keep cutting until the tree is gone or after 15 seconds? I ask because I attempted to do just that and it made me cast tree=null as a condition such as below. sleepUntil((Condition) (tree = null), 5000); Do you think this is fine or do you think problems could arise. Thank you though for the guide. Link to comment Share on other sites More sharing options...
Nex 2542 Author Share Posted November 26, 2019 12 hours ago, SyarTheTitan said: I noticed you put sleepUntil(() -> !getLocalPlayer().isAnimating() , 15000); could me instead put sleepUntil(tree = null, 5000); This way the bot will keep cutting until the tree is gone or after 15 seconds? I ask because I attempted to do just that and it made me cast tree=null as a condition such as below. sleepUntil((Condition) (tree = null), 5000); Do you think this is fine or do you think problems could arise. Thank you though for the guide. " sleepUntil(() -> !getLocalPlayer().isAnimating() , 15000); " means it will keep cutting till the player is no longer animating, or if 15 seconds passes it will also stop. But yea you can add the tree in this condition aswell: " sleepWhile(() -> tree != null, 15000); " Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.