Sebastian Posted December 1, 2015 Share Posted December 1, 2015 (edited) Hi everyone. What am i doing wrong here. I used the same method for opening settings tab. But Inventory doesn't seem to work. It also logs that it's opening the inventory. [INFO][Bot #1][12/01 09:06:11 PM]: Started script : SBTutorialIsland [INFO][Bot #1][12/01 09:06:12 PM]: Opening inventory if (!getWidgets().containingText("Click on the flashing backpack").isEmpty()) { getTabs().open(Tab.INVENTORY); log("Opening inventory"); sleep(random(600,700)); } Edited December 1, 2015 by OSRS Sebastian 1 Quote Link to comment Share on other sites More sharing options...
Chris Posted December 1, 2015 Share Posted December 1, 2015 (edited) getWidgets().getWidgetContainingText("Click on the flashing backpack icon to the right hand side") != null though this is how I use it for tutorial island @Override public void run() throws InterruptedException { RS2Widget w = getWidgets().get(548, 54); WidgetDestination m = new WidgetDestination(getBot(),w); ClickMouseEvent g = new ClickMouseEvent(m); if(w != null && w.isVisible()) { execute(g); //w.interact("Inventory"); sleep(500 + random (100, 600)); } } or do fix it your way if (!getTabs().getOpen().equals(Tab.INVENTORY)) getTabs().open(Tab.INVENTORY); Edited December 1, 2015 by Trinity 1 Quote Link to comment Share on other sites More sharing options...
Joseph Posted December 1, 2015 Share Posted December 1, 2015 Hi everyone. What am i doing wrong here. I used the same method for opening settings tab. But Inventory doesn't seem to work. It also logs that it's opening the inventory. [INFO][Bot #1][12/01 09:06:11 PM]: Started script : SBTutorialIsland [INFO][Bot #1][12/01 09:06:12 PM]: Opening inventory if (!getWidgets().containingText("Click on the flashing backpack").isEmpty()) { getTabs().open(Tab.INVENTORY); log("Opening inventory"); sleep(random(600,700)); } Because the method used to open the inventory doesn't match the same widget. The blinking inventory does not equal the neutral inventory 1 Quote Link to comment Share on other sites More sharing options...
Sebastian Posted December 1, 2015 Author Share Posted December 1, 2015 This worked! if(getWidgets().getWidgetContainingText("Click on the flashing backpack icon to the right hand side") != null) { I just created a new account to check it. Worked like a charm! Thanks! Quote Link to comment Share on other sites More sharing options...
Explv Posted December 1, 2015 Share Posted December 1, 2015 Hi everyone. What am i doing wrong here. I used the same method for opening settings tab. But Inventory doesn't seem to work. It also logs that it's opening the inventory. [INFO][Bot #1][12/01 09:06:11 PM]: Started script : SBTutorialIsland [INFO][Bot #1][12/01 09:06:12 PM]: Opening inventory if (!getWidgets().containingText("Click on the flashing backpack").isEmpty()) { getTabs().open(Tab.INVENTORY); log("Opening inventory"); sleep(random(600,700)); } I recommend you use configs for Tutorial Island. It greatly simplifies everything. For example, when config 281 == 30 you need to open the Inventory tab ( on the Survival stage of Tut Island ) if(script.getConfigs().get(281) == 30){ script.getTabs().open(Tab.INVENTORY); new ConditionalSleep(1500) { @Override public boolean condition() throws InterruptedException { return script.getTabs().getOpen() == Tab.INVENTORY; } }.sleep(); } 1 Quote Link to comment Share on other sites More sharing options...
tinnetju Posted July 18, 2017 Share Posted July 18, 2017 (edited) On 1-12-2015 at 9:30 PM, Explv said: I recommend you use configs for Tutorial Island. It greatly simplifies everything. For example, when config 281 == 30 you need to open the Inventory tab ( on the Survival stage of Tut Island ) if(script.getConfigs().get(281) == 30){ script.getTabs().open(Tab.INVENTORY); new ConditionalSleep(1500) { @Override public boolean condition() throws InterruptedException { return script.getTabs().getOpen() == Tab.INVENTORY; } }.sleep(); } Sorry for reviving an old thread but thank you for bringing this to my attention, you have posted this on several threads and everytime you get either ignored or they use their own shitty method to determine states of something. This (script.getConfigs().get(281)) is truly the best and most trustworthy way. Thanks again Edited July 18, 2017 by tinnetju Quote Link to comment Share on other sites More sharing options...
slazter Posted July 18, 2017 Share Posted July 18, 2017 2 hours ago, tinnetju said: Sorry for reviving an old thread but thank you for bringing this to my attention, you have posted this on several threads and everytime you get either ignored or they use their own shitty method to determine states of something. This (script.getConfigs().get(281)) is truly the best and most trustworthy way. Thanks again You do realize that the most of us that use other methods that you consider worse, do it because we're unaware that this is superior or exist at all right? Quote Link to comment Share on other sites More sharing options...
tinnetju Posted July 18, 2017 Share Posted July 18, 2017 2 hours ago, slazter said: You do realize that the most of us that use other methods that you consider worse, do it because we're unaware that this is superior or exist at all right? That's why I thank him, for repeating it despite not getting thanked for it and still spreading this information Quote Link to comment Share on other sites More sharing options...