Deniii 0 Share Posted April 24, 2016 So I am learning the API of Dreambot and making a simple Cowhide looter/Cow killer that banks in Al-Kharid. The script works pretty good, but sometimes it just messes up and I have to restart the script. Basically the bot does not click on the cows to attack nor clicks on the cowhides to loot. Instead it "tries" to click it while hovering ABOVE the item thus not getting the interact option at all. This only happens sometimes, and when it does happen - a restart is needed. Is this a bug with Dreambot or something wrong with my code? if (groundItem != null) { log("Taking cowhides."); //get current inv count int inventoryCount = getInventory().fullSlotCount(); //take cowhide if (!groundItem.isOnScreen()) { getCamera().rotateToEntity(groundItem); } if (groundItem.interact("Take")) { //sleep until it is picked up or after 6 seconds. if(sleepUntil(() -> getInventory().fullSlotCount() > inventoryCount, 6000)) { hidesLooted++; } } } It keeps twitching the camera a little (like the item is not on screen, but really small camera movements) and hovers above the item instead of actually putting the cursor on the item and interacting. Link to comment Share on other sites More sharing options...
Dreamlicker 750 Share Posted April 24, 2016 Make sure your client is at default zoom and fixed video mode. Link to comment Share on other sites More sharing options...
justanotherki 0 Share Posted April 24, 2016 wow that sleep until is really clever will copy Link to comment Share on other sites More sharing options...
Deniii 0 Author Share Posted April 24, 2016 Make sure your client is at default zoom and fixed video mode. Thanks, I forget that when debugging and zooming etc. wow that sleep until is really clever will copy Yeah, it is so we can be 100% sure that we picked up something. Link to comment Share on other sites More sharing options...
Cardozz 46 Share Posted May 5, 2016 Dreambot's client automatically sets the fixed static video, so that's not a big deal. The zoom is different though Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.