Interface Renderable
- All Known Subinterfaces:
Actor,Clickable,GameEntity,GraphicsObject,GroundItem,Interactable,ItemWidget,LocatableEntity,NPC,Player,Projectile,SceneObject,WidgetChild
- All Known Implementing Classes:
Tile
public interface Renderable
An entity that is rendered in the game.
-
Method Summary
Modifier and TypeMethodDescriptionbooleanDetermines if this entity contains the given point.default voiddraw(PaintContext paintCtx) Renders this entity.default voiddraw(PaintContext paintCtx, Color color) Renders this entity.default voiddraw(PaintContext paintCtx, Color color, int strokeWidth) Renders this entity.Gets the central point within the entity calculated using only visible model points.Get a random point within the entity.Gets the central point within the entity calculated using visible and non-visible model points.booleanGets if this entity is visible on screen.
-
Method Details
-
isVisible
boolean isVisible()Gets if this entity is visible on screen.- Returns:
- true if visible, false otherwise
-
contains
Determines if this entity contains the given point.- Parameters:
point- the point- Returns:
- true if this entity contains the point, false otherwise
-
getRandomPoint
Point getRandomPoint()Get a random point within the entity.- Returns:
Point
-
getCentralPoint
Point getCentralPoint()Gets the central point within the entity calculated using only visible model points.- Returns:
Point- See Also:
-
getRealCentralPoint
Point getRealCentralPoint()Gets the central point within the entity calculated using visible and non-visible model points.- Returns:
Point- See Also:
-