- Joined
- Aug 23, 2015
- Messages
- 1,961
- Thread Author
- #1
Gamemode: Osrs
Repeatability: 100%
Description: No "Use" option in inventory actions list
Code:
Output:
Mithril full helm
[Wear, Drop]
Coins
[Drop]
Potato with cheese
[Eat, Drop]
From my very brief testing, it seemed that the code "spriteItem.interact("Use", Inventory.getSelectedItem() + " -> " + GameObject);" will just hover the item in the inventory, but using the code spriteItem.interact("Use") does eventually manage to use the item.
Repeatability: 100%
Description: No "Use" option in inventory actions list
Code:
Code:
SpriteItem ok = Inventory.newQuery().names("Coins").results().first();
SpriteItem ok0 = Inventory.newQuery().names("Potato with cheese").results().first();
SpriteItem mithItem = Inventory.newQuery().names("Mithril full helm").results().first();
if(mithItem != null){
System.out.println(mithItem.getDefinition().getName());
System.out.println(mithItem.getDefinition().getInventoryActions());
}
if(ok != null){
System.out.println(ok.getDefinition().getName());
System.out.println(ok.getDefinition().getInventoryActions());
}
if(ok0 != null){
System.out.println(ok0.getDefinition().getName());
System.out.println(ok0.getDefinition().getInventoryActions());
}
Output:
Mithril full helm
[Wear, Drop]
Coins
[Drop]
Potato with cheese
[Eat, Drop]
From my very brief testing, it seemed that the code "spriteItem.interact("Use", Inventory.getSelectedItem() + " -> " + GameObject);" will just hover the item in the inventory, but using the code spriteItem.interact("Use") does eventually manage to use the item.
Last edited: