Package com.dicycat.kroy.misc
Class StatBar
- java.lang.Object
-
- com.dicycat.kroy.GameObject
-
- com.dicycat.kroy.misc.StatBar
-
public class StatBar extends GameObject
Sprites used to display statistics for the player- Author:
- IsaacAlbiston
-
-
Constructor Summary
Constructors Constructor Description StatBar(com.badlogic.gdx.math.Vector2 spawnPos, java.lang.String texture, int height)
initialises the bar
-
Method Summary
Modifier and Type Method Description void
setBarDisplay(float x)
Changes the width of the bar to xvoid
update()
Called every frame.-
Methods inherited from class com.dicycat.kroy.GameObject
changePosition, die, getCentre, getHeight, getOriginX, getOriginY, getPosition, getRotation, getSprite, getTexture, getTextureHeight, getTextureWidth, getWidth, getX, getXScale, getY, getYScale, isDisplayable, isRemove, render, setPosition, setRemove, setRotation
-
-
-
-
Method Detail
-
setBarDisplay
public void setBarDisplay(float x)
Changes the width of the bar to x- Parameters:
x
-
-
update
public void update()
Description copied from class:GameObject
Called every frame. Update the game object.- Specified by:
update
in classGameObject
-
-