Add support for examine price to clue scroll reward
This commit is contained in:
@@ -266,6 +266,7 @@ public class WidgetID
|
||||
static class Cluescroll
|
||||
{
|
||||
static final int CLUE_TEXT = 2;
|
||||
static final int CLUE_SCROLL_ITEM_CONTAINER = 3;
|
||||
}
|
||||
|
||||
static class Minimap
|
||||
|
||||
@@ -56,6 +56,7 @@ public enum WidgetInfo
|
||||
WORLD_MAP_OPTION(WidgetID.WORLD_MAP_MENU_GROUP_ID, WidgetID.WorldMap.OPTION),
|
||||
|
||||
CLUE_SCROLL_TEXT(WidgetID.CLUE_SCROLL_GROUP_ID, WidgetID.Cluescroll.CLUE_TEXT),
|
||||
CLUE_SCROLL_REWARD_ITEM_CONTAINER(WidgetID.CLUE_SCROLL_REWARD_GROUP_ID, WidgetID.Cluescroll.CLUE_SCROLL_ITEM_CONTAINER),
|
||||
|
||||
EQUIPMENT(WidgetID.EQUIPMENT_GROUP_ID, 0),
|
||||
EQUIPMENT_INVENTORY_ITEMS_CONTAINER(WidgetID.EQUIPMENT_INVENTORY_GROUP_ID, WidgetID.Equipment.INVENTORY_ITEM_CONTAINER),
|
||||
|
||||
@@ -258,6 +258,16 @@ public class ExaminePlugin extends Plugin
|
||||
itemId = widgetItem.getItemId();
|
||||
}
|
||||
}
|
||||
else if (WidgetInfo.CLUE_SCROLL_REWARD_ITEM_CONTAINER.getGroupId() == widgetGroup)
|
||||
{
|
||||
Widget[] children = widget.getDynamicChildren();
|
||||
if (pendingExamine.getActionParam() < children.length)
|
||||
{
|
||||
Widget widgetItem = children[pendingExamine.getActionParam()];
|
||||
quantity = widgetItem.getItemQuantity();
|
||||
itemId = widgetItem.getItemId();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (itemId == -1)
|
||||
|
||||
Reference in New Issue
Block a user