Class EntitySpawnAction


  • public class EntitySpawnAction
    extends EntityAction
    An entity action for when the entity is added to a play field
    Author:
    Tim Neumann
    • Constructor Detail

      • EntitySpawnAction

        public EntitySpawnAction​(long tickNumber,
                                 Entity entity,
                                 Playfield playfield,
                                 Position position)
        Create an entity spawn action.
        Parameters:
        tickNumber - the tick the action happened at
        entity - the entity that caused the action
        playfield - the playfield the entity was added to
        position - the position the entity was added at
    • Method Detail

      • getPlayfield

        public Playfield getPlayfield()
        Returns:
        the playfield the entity was added to
      • getPosition

        public Position getPosition()
        Returns:
        the position the entity was added at
      • getDescription

        public String getDescription()
        Specified by:
        getDescription in class Action
        Returns:
        the description of this action