Package net.regsirius06.engine.utils
Interface Drawable2D
- All Known Implementing Classes:
AbstractLabyrinthPanel,AbstractPanel,LabyrinthGraphics2D,LabyrinthPanel,MiniMap
public interface Drawable2D
This interface represents an object that can be drawn on a 2D graphics context.
Any class implementing this interface should provide the logic for how it is drawn.
The draw(Graphics2D) method is responsible for rendering the object on the screen using a provided
Graphics2D context, allowing for custom rendering logic for various 2D shapes or entities.
-
Method Summary
Modifier and TypeMethodDescriptionvoiddraw(Graphics2D g2d) Draws the object on the specifiedGraphics2Dcontext.
-
Method Details
-
draw
Draws the object on the specifiedGraphics2Dcontext. This method should contain the logic for rendering the object on the screen.- Parameters:
g2d- TheGraphics2Dobject that is used to render the object. It provides various drawing methods for rendering shapes, images, etc.
-