Class Monster

    • Field Detail

      • directions

        public static com.badlogic.gdx.utils.ObjectMap<com.badlogic.gdx.math.Vector2,​java.lang.String> directions
    • Constructor Detail

      • Monster

        public Monster()
        Creates a monster entity, containing Transform, Renderable, RigidBody, and Pirate components.
    • Method Detail

      • setDirection

        public void setDirection​(com.badlogic.gdx.math.Vector2 dir)
        will rotate the monster to face the direction (just changes the sprite doesn't actually rotate)
        Parameters:
        dir - the dir to face (used to get the correct sprite )
      • setDirection

        public void setDirection​(java.lang.String direction)
        will rotate the monster to face the direction (just changes the sprite doesn't actually rotate)
        Parameters:
        direction - the dir to face (used to get the correct sprite )
      • getPosition

        public com.badlogic.gdx.math.Vector2 getPosition()
      • update

        public void update()
        Description copied from class: Entity
        Similar to the Component's update event
        Overrides:
        update in class Entity
      • getHealth

        public int getHealth()
      • setHealth

        public void setHealth​(int number)
      • isAlive

        public boolean isAlive()
      • MonsterDeath

        public void MonsterDeath()