use of java.awt.Polygon in project runelite by runelite.
the class TileIndicatorsOverlay method render.
@Override
public Dimension render(Graphics2D graphics) {
LocalPoint dest = client.getLocalDestinationLocation();
if (dest == null) {
return null;
}
Polygon poly = Perspective.getCanvasTilePoly(client, dest);
if (poly == null) {
return null;
}
OverlayUtil.renderPolygon(graphics, poly, config.highlightDestinationColor());
return null;
}
use of java.awt.Polygon in project runelite by runelite.
the class OverlayUtil method renderTileOverlay.
public static void renderTileOverlay(Client client, Graphics2D graphics, LocalPoint localLocation, BufferedImage image, Color color) {
Polygon poly = Perspective.getCanvasTilePoly(client, localLocation);
if (poly != null) {
renderPolygon(graphics, poly, color);
}
renderImageLocation(client, graphics, localLocation, image, 0);
}
use of java.awt.Polygon in project runelite by runelite.
the class OverlayUtil method renderActorOverlayImage.
public static void renderActorOverlayImage(Graphics2D graphics, Actor actor, BufferedImage image, Color color, int zOffset) {
Polygon poly = actor.getCanvasTilePoly();
if (poly != null) {
renderPolygon(graphics, poly, color);
}
Point imageLocation = actor.getCanvasImageLocation(graphics, image, zOffset);
if (imageLocation != null) {
renderImageLocation(graphics, imageLocation, image);
}
}
use of java.awt.Polygon in project runelite by runelite.
the class OverlayUtil method renderActorOverlay.
public static void renderActorOverlay(Graphics2D graphics, Actor actor, String text, Color color) {
Polygon poly = actor.getCanvasTilePoly();
if (poly != null) {
renderPolygon(graphics, poly, color);
}
Point textLocation = actor.getCanvasTextLocation(graphics, text, actor.getLogicalHeight() + 40);
if (textLocation != null) {
renderTextLocation(graphics, textLocation, text, color);
}
}
use of java.awt.Polygon in project runelite by runelite.
the class OverlayUtil method renderTileOverlay.
public static void renderTileOverlay(Graphics2D graphics, TileObject tileObject, String text, Color color) {
Polygon poly = tileObject.getCanvasTilePoly();
if (poly != null) {
renderPolygon(graphics, poly, color);
}
Point minimapLocation = tileObject.getMinimapLocation();
if (minimapLocation != null) {
renderMinimapLocation(graphics, minimapLocation, color);
}
Point textLocation = tileObject.getCanvasTextLocation(graphics, text, 0);
if (textLocation != null) {
renderTextLocation(graphics, textLocation, text, color);
}
}
Aggregations