MidnightBlue Posted June 4, 2014 Share Posted June 4, 2014 So when the inventory tab is open, I want to draw a rectangle around a certain slot.here's my code if(Tab.INVENTORY.isOpen(null)) { Rectangle slot = client.getInventory().getDestinationForSlot(1); g.drawRect(slot.x, slot.y, slot.width, slot.height); } isOpen requires a paramater of the type RS2InterfaceChild, I've got no clue as to what to put for the parameter. Can somebody help me? Link to comment Share on other sites More sharing options...
Nezz Posted June 4, 2014 Share Posted June 4, 2014 if(currentTab().equals(Tab.INVENTORY)) I think that's what you're looking for. Link to comment Share on other sites More sharing options...
Eliot Posted June 4, 2014 Share Posted June 4, 2014 (edited) You should really be learning OSBot 2 API, not OSBot 1. For OSBot 2, isOpen takes script.bot, isOpen(this.bot) Edited June 4, 2014 by Eliot Link to comment Share on other sites More sharing options...