duvetvem Posted June 30, 2023 Share Posted June 30, 2023 Hello, im trying out my simple wcbot here, but sadly im stuck even getting it to run I have 0 errors i my code, and there is 0 errors when compiling, after compiling i have my script in a .jar file and i copy it and paste it in the scripts folder of osbot folder. Below is the screenshot of what i thought i needed for the script to work. Could anyone please help me so i atleast can get it to run properly? I copied the logs of osbot below aswell. Thanks! [ERROR][06/30 06:23:18 PM]: Failed to load local script : org/osbot/Fg.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : org/osbot/GH.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : org/osbot/Mf.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : org/osbot/SF.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : org/osbot/th.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : org/osbot/zf.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/thoughtworks/xstream/converters/reflection/CGLIBEnhancedConverter$ReverseEngineeredCallbackFilter.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AbstractCatchingFuture$AsyncCatchingFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AbstractCatchingFuture$CatchingFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AbstractCatchingFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AbstractFuture$TrustedFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AbstractFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AbstractTransformFuture$AsyncTransformFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AbstractTransformFuture$TransformFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AbstractTransformFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AggregateFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/AggregateFutureState.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/CollectionFuture$ListFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/CollectionFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/CombinedFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/FluentFuture$TrustedFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/FluentFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/ForwardingFluentFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/Futures$InCompletionOrderFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/Futures$NonCancellationPropagatingFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/GwtFluentFutureCatchingSpecialization.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/ImmediateFuture$ImmediateCancelledFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/ImmediateFuture$ImmediateFailedFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/MoreExecutors$ScheduledListeningDecorator$NeverSuccessfulListenableFutureTask.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/SettableFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/TimeoutFuture.class [ERROR][06/30 06:23:18 PM]: Failed to load local script : com/google/common/util/concurrent/TrustedListenableFutureTask.class [INFO][06/30 06:23:19 PM]: Script list refreshed and loaded 0 scripts. Quote Link to comment Share on other sites More sharing options...
Gunman Posted June 30, 2023 Share Posted June 30, 2023 Make sure you're exporting the libraries Quote Link to comment Share on other sites More sharing options...
duvetvem Posted June 30, 2023 Author Share Posted June 30, 2023 22 minutes ago, Gunman said: Make sure you're exporting the libraries Yes, but could you maybe show me how? im abit confused where it comes to this part. Many thanks Quote Link to comment Share on other sites More sharing options...
ExtraBotz Posted June 30, 2023 Share Posted June 30, 2023 In your artifacts you can also setup your script to export directly to your scripts folder so you don't have to manually move it over each time. In this instance it looks like your script failed to load into the script list. Have you used the script template? I would recommend posting your code as well. Quote Link to comment Share on other sites More sharing options...
duvetvem Posted June 30, 2023 Author Share Posted June 30, 2023 12 minutes ago, ExtraBotz said: In your artifacts you can also setup your script to export directly to your scripts folder so you don't have to manually move it over each time. In this instance it looks like your script failed to load into the script list. Have you used the script template? I would recommend posting your code as well. Hello, Thank you for replying! So i think i fixed the output you talked about? Also the code below, tho it does not seem the code itself is producing the error, since i cant even find it in the osbot client, hence the error messages in the first post. Any ideas? import org.osbot.rs07.api.model.RS2Object; import org.osbot.rs07.script.Script; import org.osbot.rs07.utility.ConditionalSleep; import java.util.concurrent.ThreadLocalRandom; public class Wcbot extends Script { private static final String TREE_NAME = "Tree"; private static final int RANDOM_MIN = 500; private static final int RANDOM_MAX = 800; @Override public int onLoop() { if (!myPlayer().isAnimating()) { chopTree(); } return ThreadLocalRandom.current().nextInt(RANDOM_MIN, RANDOM_MAX); } private void chopTree() { RS2Object tree = getObjects().closest(TREE_NAME); if (tree != null) { if (!tree.isVisible()) { getCamera().toEntity(tree); } else if (tree.interact("Chop down")) { new ConditionalSleep(3000, 500) { @Override public boolean condition() { return myPlayer().isAnimating(); } }.sleep(); } } } @Override public void onStart() { log("Starting Woodcutting Bot"); } @Override public void onExit() { log("Stopping Woodcutting Bot"); } public static void main(String[] args) { Wcbot bot = new Wcbot(); bot.start(); } private void start() { } } Quote Link to comment Share on other sites More sharing options...
abc3 Posted July 1, 2023 Share Posted July 1, 2023 You need java 8 not 11 Quote Link to comment Share on other sites More sharing options...
duvetvem Posted July 1, 2023 Author Share Posted July 1, 2023 1 hour ago, abc3 said: You need java 8 not 11 Hello, thanks for helping out! Any specific 8 version? Or is this correct? Quote Link to comment Share on other sites More sharing options...
duvetvem Posted July 1, 2023 Author Share Posted July 1, 2023 Have i missed something? I dont have any errors now, but the script doesnt appear when i refresh in osbot, even tho my jar file is there after compiled? If anyone can help me, that would be great! Thanks Quote Link to comment Share on other sites More sharing options...