public class WidgetDestination extends MouseDestination
Constructor and Description |
---|
WidgetDestination(Bot bot,
RS2Widget widget)
Creates an instance of this mouse destination for a widget.
|
WidgetDestination(Bot bot,
RS2Widget widget,
boolean ignoreIsHidden)
Creates an instance of this mouse destination for a widget.
|
WidgetDestination(Bot bot,
RS2Widget widget,
int margin)
Creates an instance of this mouse destination for a widget.
|
WidgetDestination(Bot bot,
RS2Widget widget,
int marginX,
int marginY)
Creates an instance of this mouse destination for a widget
with margins.
|
Modifier and Type | Method and Description |
---|---|
boolean |
evaluate()
Evaluates whether an interaction for this mouse destination is allowed to
be performed.
|
java.awt.geom.Area |
getArea()
Gets the destination area specified by a
Area
object. |
java.awt.Rectangle |
getBoundingBox()
Gets the bounding box rectangle of this mouse destination.
|
boolean |
isVisible()
Determines whether this destination is visible.
|
boolean |
isVisible(java.awt.Rectangle boundingBox) |
getBot, getShape, isHover, setHover
public WidgetDestination(Bot bot, RS2Widget widget)
bot
- The bot instance.widget
- The widget that is the destination.public WidgetDestination(Bot bot, RS2Widget widget, boolean ignoreIsHidden)
bot
- The bot instance.widget
- The widget that is the destination.ignoreIsHidden
- Ignores the isHidden() value for the widget.public WidgetDestination(Bot bot, RS2Widget widget, int margin)
bot
- The bot instance.widget
- The widget that is the destination.margin
- The margin around the widgetpublic WidgetDestination(Bot bot, RS2Widget widget, int marginX, int marginY)
bot
- The bot instance.widget
- The widget that is the destination.marginX
- The margin around the widget in the x orientationmarginY
- The margin around the widget in the y orientationpublic java.awt.geom.Area getArea()
MouseDestination
Area
object.getArea
in class MouseDestination
Area
.public boolean evaluate()
MouseDestination
evaluate
in class MouseDestination
public java.awt.Rectangle getBoundingBox()
MouseDestination
getBoundingBox
in class MouseDestination
public boolean isVisible()
MouseDestination
isVisible
in class MouseDestination
public boolean isVisible(java.awt.Rectangle boundingBox)