Package org.dreambot.api.wrappers.items
Class Item
- java.lang.Object
-
- org.dreambot.api.wrappers.items.Item
-
- All Implemented Interfaces:
Identifiable
public class Item extends java.lang.Object implements Identifiable
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
java.lang.String[]
getActions()
int
getAmount()
org.dreambot.internal.cache.wrappers.def.ItemDef
getComposite()
AbstractMouseDestination
getDestination()
int
getDiscardableID()
int
getDiscardableValue()
int
getHighAlchValue()
int
getID()
Gets ID number of the given object.int
getLivePrice()
This will get the average selling price on the GE, if availableint
getLowAlchValue()
java.lang.String
getName()
Gets the name of the given object.int
getNotedItemID()
int
getPlaceholderID()
int
getPlaceholderValue()
int
getShiftClickIndex()
int
getSlot()
For Inventory items only!int
getTeam()
int
getUnnotedItemID()
int
getValue()
boolean
hasAction(java.lang.String... actions)
int
hashCode()
boolean
interact()
Interacts with the itemboolean
interact(java.lang.String action)
Interacts with the item using the specified actionboolean
isMembers()
boolean
isMembersOnly()
boolean
isNotable()
boolean
isNoted()
boolean
isPlaceholder()
boolean
isStackable()
boolean
isTradable()
boolean
isValid()
void
setDestination(RectangleDestination destination)
boolean
useOn(int id)
Uses this item on another item
Note: this item MUST be an inventory item for this method to workboolean
useOn(java.lang.String name)
Uses this item on another item
Note: this item MUST be an inventory item for this method to workboolean
useOn(Filter<Item> filter)
Uses this item on another item
Note: this item MUST be an inventory item for this method to workboolean
useOn(Entity entity)
Uses this item on an entity
Note: this item MUST be an inventory item for this method to workboolean
useOn(Item item)
Uses this item on another item
Note: this item MUST be an inventory item for this method to work
-
-
-
Method Detail
-
getDestination
public AbstractMouseDestination getDestination()
-
setDestination
public void setDestination(RectangleDestination destination)
-
getID
public int getID()
Description copied from interface:Identifiable
Gets ID number of the given object.- Specified by:
getID
in interfaceIdentifiable
- Returns:
- the ID number as integer.
-
getAmount
public int getAmount()
-
getLivePrice
public int getLivePrice()
This will get the average selling price on the GE, if available- Returns:
- The current average price sold on the GE if found, otherwise 0
-
getSlot
public int getSlot()
For Inventory items only!- Returns:
- Slot for inventory item.
-
isMembersOnly
public boolean isMembersOnly()
-
isStackable
public boolean isStackable()
-
getUnnotedItemID
public int getUnnotedItemID()
-
getNotedItemID
public int getNotedItemID()
-
isNoted
public boolean isNoted()
-
isNotable
public boolean isNotable()
-
isPlaceholder
public boolean isPlaceholder()
-
getPlaceholderValue
public int getPlaceholderValue()
-
getPlaceholderID
public int getPlaceholderID()
-
getDiscardableValue
public int getDiscardableValue()
-
getDiscardableID
public int getDiscardableID()
-
getComposite
public org.dreambot.internal.cache.wrappers.def.ItemDef getComposite()
-
getName
public java.lang.String getName()
Description copied from interface:Identifiable
Gets the name of the given object.- Specified by:
getName
in interfaceIdentifiable
- Returns:
- the name as a string.
-
isValid
public boolean isValid()
-
useOn
public boolean useOn(Entity entity)
Uses this item on an entity
Note: this item MUST be an inventory item for this method to work- Parameters:
entity
- The entity you want to use this item on- Returns:
- True if successful
-
useOn
public boolean useOn(Item item)
Uses this item on another item
Note: this item MUST be an inventory item for this method to work- Parameters:
item
- The Item you want to use this item on- Returns:
- True if successful
-
useOn
public boolean useOn(java.lang.String name)
Uses this item on another item
Note: this item MUST be an inventory item for this method to work- Parameters:
name
- The Item name you want to use this item on- Returns:
- True if successful
-
useOn
public boolean useOn(int id)
Uses this item on another item
Note: this item MUST be an inventory item for this method to work- Parameters:
id
- The Item id you want to use this item on- Returns:
- True if successful
-
useOn
public boolean useOn(Filter<Item> filter)
Uses this item on another item
Note: this item MUST be an inventory item for this method to work- Parameters:
filter
- The Item filter you want to use this item on- Returns:
- True if successful
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
interact
public boolean interact()
Interacts with the item- Returns:
- True if successful
-
interact
public boolean interact(java.lang.String action)
Interacts with the item using the specified action- Parameters:
action
- The action to interact with- Returns:
- True if successful
-
hasAction
public boolean hasAction(java.lang.String... actions)
-
isMembers
public boolean isMembers()
-
getTeam
public int getTeam()
-
getValue
public int getValue()
-
getShiftClickIndex
public int getShiftClickIndex()
-
isTradable
public boolean isTradable()
-
getActions
public java.lang.String[] getActions()
-
getLowAlchValue
public int getLowAlchValue()
-
getHighAlchValue
public int getHighAlchValue()
-
-