- Joined
- Apr 21, 2016
- Messages
- 2
- Thread Author
- #1
Used Partyshankeds's advise and edited code. But script still dont buy things. I noticed that he tries target NPC behind shop interface and open it again. So maybe there is problem with opening the shop?
Solved in Slack Ty to Partyshanked. Can be closed now
Code:
InterfaceComponentQueryResults shoplangas = Interfaces.newQuery().texts("Auburys's Rune Shop.").results();
if (!shoplangas.isEmpty()) {
InterfaceComponentQueryResults validFlourInterfaces = Interfaces.newQuery().names("Fire rune").results();
if (!validFlourInterfaces.isEmpty()) {
InterfaceComponent flourInterface = validFlourInterfaces.first();
if (flourInterface != null) {
if (flourInterface.interact("Buy 10")) {
Execution.delay(1200, 1600);
if (Menu.isOpen()) {
Menu.close();
}
}
}
}
}
Solved in Slack Ty to Partyshanked. Can be closed now
Last edited: