itzDot Posted July 11, 2015 Posted July 11, 2015 hey idk what causes this issue but once a while my script fails to drop the log and instead clicks use, and then it just stops droping the logs and moves onto different task, the method im using to drop the logs is inventory.dropAll(treeType);
Bobrocket Posted July 11, 2015 Posted July 11, 2015 It's an API problem. I believe it's fixed in the upcoming stable versions. The bounding boxes for the Drop and Use options intersect (just by 1px), so it will sometimes accidentally use it instead of dropping it.
Bobrocket Posted July 11, 2015 Posted July 11, 2015 alright thanks for the heads up You could fix this simply: if (getInventory().isItemSelected()) getMouse().click(false); //continue loop If an item is selected, it will left click. This will remove an item from being selected 1
Psvxe Posted July 11, 2015 Posted July 11, 2015 You could fix this simply: if (getInventory().isItemSelected()) getMouse().click(false);//continue loopIf an item is selected, it will left click. This will remove an item from being selected Or getInventory().deselectItem()
Bobrocket Posted July 11, 2015 Posted July 11, 2015 Or getInventory().deselectItem() That works too, but IMO it's better to rely as little as possible on these smaller "on top" methods, if you will. 1
Psvxe Posted July 11, 2015 Posted July 11, 2015 That works too, but IMO it's better to rely as little as possible on these smaller "on top" methods, if you will. That all depends how likely things will break. However, due to the question I think those "On top" methods will suit him better. Since that way he will learn things about the API. Nothing personal too, I get your point.
Joseph Posted July 11, 2015 Posted July 11, 2015 Or getInventory().deselectItem() it will deselect by clicking on the inventory tab. Rather then on the item itself
Psvxe Posted July 11, 2015 Posted July 11, 2015 it will deselect by clicking on the inventory tab. Rather then on the item itself Didn't check that part. could be indeed.