Class MoonActor

java.lang.Object
com.badlogic.gdx.scenes.scene2d.Actor
com.csse3200.game.components.loading.MoonActor

public class MoonActor extends com.badlogic.gdx.scenes.scene2d.Actor
An actor representing the moon, which fills up as the loading progresses.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
     
    void
    draw(com.badlogic.gdx.graphics.g2d.Batch batch, float parentAlpha)
     
    float
     
    float
     
    void
    setOpacity(float opacity)
    Set the opacity for the moon.
    void
    setProgress(float progress)
    Set the moon's progress (from 0 to 1) to adjust how much of the moon is visible.

    Methods inherited from class com.badlogic.gdx.scenes.scene2d.Actor

    act, addAction, addCaptureListener, addListener, ancestorsVisible, ascendantsVisible, clear, clearActions, clearListeners, clipBegin, clipBegin, clipEnd, debug, drawDebug, drawDebugBounds, fire, firstAscendant, getActions, getCaptureListeners, getColor, getDebug, getHeight, getListeners, getName, getOriginX, getOriginY, getParent, getRight, getRotation, getScaleX, getScaleY, getStage, getTop, getTouchable, getUserObject, getWidth, getX, getX, getY, getY, getZIndex, hasActions, hasKeyboardFocus, hasParent, hasScrollFocus, hit, isAscendantOf, isDescendantOf, isTouchable, isTouchFocusListener, isTouchFocusTarget, isVisible, localToActorCoordinates, localToAscendantCoordinates, localToParentCoordinates, localToScreenCoordinates, localToStageCoordinates, moveBy, notify, parentToLocalCoordinates, positionChanged, remove, removeAction, removeCaptureListener, removeListener, rotateBy, rotationChanged, scaleBy, scaleBy, scaleChanged, screenToLocalCoordinates, setBounds, setColor, setColor, setDebug, setHeight, setName, setOrigin, setOrigin, setOriginX, setOriginY, setParent, setPosition, setPosition, setRotation, setScale, setScale, setScaleX, setScaleY, setSize, setStage, setTouchable, setUserObject, setVisible, setWidth, setX, setX, setY, setY, setZIndex, sizeBy, sizeBy, sizeChanged, stageToLocalCoordinates, toBack, toFront, toString

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • MoonActor

      public MoonActor()
  • Method Details

    • draw

      public void draw(com.badlogic.gdx.graphics.g2d.Batch batch, float parentAlpha)
      Overrides:
      draw in class com.badlogic.gdx.scenes.scene2d.Actor
    • setProgress

      public void setProgress(float progress)
      Set the moon's progress (from 0 to 1) to adjust how much of the moon is visible.
    • setOpacity

      public void setOpacity(float opacity)
      Set the opacity for the moon. Values should be between 0 (completely transparent) and 1 (fully opaque).
    • getOpacity

      public float getOpacity()
    • getProgress

      public float getProgress()
    • dispose

      public void dispose()