Dab in a Lab Posted May 4, 2018 Share Posted May 4, 2018 Been having trouble trying to get my script to run the past few hours. It was working fine yesterday and earlier today. Does anyone know a potential cause for this? Is it the code? This is my first script and it was quickly getting messy, so I started over. Is the two failed things in the logger important? What causes them not to load? I wasn't getting that error earlier. https://gyazo.com/f625440b253168a7ddf937d95075ae6b In case it is the code that's causing it, here's the source code, its not finished yet. Any feedback would be appreciated since this is my first script. https://github.com/Dab-in-a-Lab/Wilderness-Looter/blob/master/Wilderness Looter Source Code Quote Link to comment Share on other sites More sharing options...
ThatGamerBlue Posted May 4, 2018 Share Posted May 4, 2018 restart osbot client, sometimes this happens to me Quote Link to comment Share on other sites More sharing options...
Dab in a Lab Posted May 4, 2018 Author Share Posted May 4, 2018 9 minutes ago, ThatGamerBlue said: restart osbot client, sometimes this happens to me I've tried that a couple times. This is the only script thats doing it to me too Quote Link to comment Share on other sites More sharing options...
zwaffel Posted May 4, 2018 Share Posted May 4, 2018 (edited) put RS2Object ditch = getObjects().closest("Wilderness Ditch"); and GroundItem items = getGroundItems().closest(getDirectoryData() + getName() + File.separator + "osrs items.txt"); in your onloop. You shouldn't define RS2objects and Grounditems outside of your onloop this is causing your problem. Also i believe interactionevents need to be in your onloop since once there executed they expire (get the status finished) so they have to be created every loop (i could be wrong here) . Edited May 4, 2018 by zwaffel 1 Quote Link to comment Share on other sites More sharing options...
Alek Posted May 4, 2018 Share Posted May 4, 2018 Run OSBot in debug mode, it will print out the full error. 1 Quote Link to comment Share on other sites More sharing options...
Tommm39 Posted May 4, 2018 Share Posted May 4, 2018 I think it's because you're initialising your variables at the same time as your declaring them. Also I think there is a problem here: if (!getInventory().isFull()) ;{ getWalking().webWalk(Wilderness); if (getWalking().webWalk(Wilderness)) Unless I'm missing what you're trying to do you should haven't a semi-colon after the first line, it should probably look more like this if (!getInventory().isFull()) { if (!myPlayer().getPosition().equals(Wilderness)) { if (getWalking().webWalk(Wilderness) { //conditional sleep until myPlayer().getPosition().equals(Wilderness) } } else { //loot } } 1 Quote Link to comment Share on other sites More sharing options...
Dab in a Lab Posted May 4, 2018 Author Share Posted May 4, 2018 11 hours ago, Alek said: Run OSBot in debug mode, it will print out the full error. This shows up when I run it in debug mode https://gyazo.com/034aec96c08343e707873f4c13a961ac the list of stuff goes on for a bit Quote Link to comment Share on other sites More sharing options...