diff --git a/src/main/java/inf112/skeleton/app/DrawableObject.java b/src/main/java/inf112/skeleton/app/DrawableObject.java index 3ad6669..72de09c 100644 --- a/src/main/java/inf112/skeleton/app/DrawableObject.java +++ b/src/main/java/inf112/skeleton/app/DrawableObject.java @@ -1,7 +1,9 @@ package inf112.skeleton.app; +/** + * This class represents an object that can be drawn using libgdx + */ public class DrawableObject implements IDrawableObject { - private int xPos; private int yPos; private int width = 64; @@ -11,6 +13,17 @@ public class DrawableObject implements IDrawableObject { private boolean flipX = false; private boolean flipY = false; + /** + * Initializes a drawable object + * @param xPos The pixel to start drawing on for the x axis + * @param yPos The pixel to start drawing on for the y axis + * @param texture The texture to use for drawing the element + * @param rotation The amount of degrees to rotate the element counterclockwise + * @param width The width of the element + * @param height The height of the element + * @param flipX Whether to flip/mirror the element over the x axis + * @param flipY Whether to flip/mirror the element over the y axis + */ public DrawableObject(int xPos, int yPos, GameTexture texture, int rotation, int width, int height, boolean flipX, boolean flipY) { this.xPos = xPos; this.yPos = yPos; @@ -22,6 +35,12 @@ public class DrawableObject implements IDrawableObject { this.flipY = flipY; } + /** + * Initializes a new drawable object + * @param xPos The pixel to start drawing on for the x axis + * @param yPos The pixel to start drawing on for the y axis + * @param texture The texture to use for drawing the element + */ public DrawableObject(int xPos, int yPos, GameTexture texture) { this.xPos = xPos; this.yPos = yPos;