Class Prop
java.lang.Object
de.gurkenlabs.litiengine.entities.Entity
de.gurkenlabs.litiengine.entities.CollisionEntity
de.gurkenlabs.litiengine.entities.CombatEntity
de.gurkenlabs.litiengine.entities.Prop
- All Implemented Interfaces:
EntityRenderedListener,EntityRenderListener,ICollisionEntity,ICombatEntity,IEntity,Tweenable,java.util.EventListener
public class Prop
extends CombatEntityField Summary
Constructor Summary
Constructors Constructor Description Prop(double x, double y, java.lang.String spritesheetName)Instantiates a newPropentity.Prop(double x, double y, java.lang.String spritesheetName, Material material)Instantiates a newPropentity.Prop(java.awt.geom.Point2D location, java.lang.String spritesheetName)Instantiates a newPropentity.Prop(java.awt.geom.Point2D location, java.lang.String spritesheetName, Material material)Instantiates a newPropentity.Prop(java.lang.String spritesheetName)Instantiates a newPropentity.Method Summary
Modifier and Type Method Description protected IEntityAnimationController<?>createAnimationController()booleanflipHorizontally()booleanflipVertically()MaterialgetMaterial()RotationgetSpriteRotation()java.lang.StringgetSpritesheetName()PropStategetState()Gets the state.booleanisAddShadow()booleanisDead()Checks if is dead.booleanisScaling()voidsetAddShadow(boolean addShadow)voidsetFlipHorizontally(boolean flipHorizontally)voidsetFlipVertically(boolean flipVertically)voidsetMaterial(Material material)voidsetScaling(boolean scaling)voidsetSpriteRotation(Rotation spriteRotation)voidsetSpritesheetName(java.lang.String spriteName)java.lang.StringtoString()Methods inherited from class de.gurkenlabs.litiengine.entities.CombatEntity
addCombatEntityListener, die, getAppliedEffects, getHitBox, getHitPoints, getTarget, getTeam, getTweenValues, hit, hit, isFriendly, isIndestructible, isNeutral, onDeath, onHit, onResurrect, removeCombatEntityListener, removeListener, removeListener, removeListener, resurrect, setIndestructible, setTarget, setTeam, setTweenValues, wasHitMethods inherited from class de.gurkenlabs.litiengine.entities.CollisionEntity
canCollideWith, fireCollisionEvent, getCollisionBox, getCollisionBox, getCollisionBox, getCollisionBoxAlign, getCollisionBoxCenter, getCollisionBoxHeight, getCollisionBoxValign, getCollisionBoxWidth, getCollisionType, hasCollision, onCollision, refreshCollisionBox, removeCollisionListener, setCollision, setCollisionBoxAlign, setCollisionBoxHeight, setCollisionBoxValign, setCollisionBoxWidth, setCollisionType, setHeight, setLocation, setSize, setWidthMethods inherited from class de.gurkenlabs.litiengine.entities.Entity
actions, addController, addEntityRenderListener, addListener, addTag, addTransformListener, animations, attachControllers, behavior, canRender, detachControllers, getAngle, getBoundingBox, getCenter, getController, getControllers, getEnvironment, getHeight, getLocation, getMapId, getName, getProperties, getRenderType, getTags, getWidth, getX, getY, hasTag, isLoaded, isVisible, loaded, onMessage, onMessage, onRendered, perform, register, removed, removeListener, removeListener, removeListener, removeListener, removeListener, removeTag, rendered, rendering, renderWithLayer, sendMessage, setAngle, setController, setLocation, setMapId, setName, setRenderType, setRenderWithLayer, setVisible, setX, setYMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface de.gurkenlabs.litiengine.entities.ICollisionEntity
canCollideWith, fireCollisionEvent, getCollisionBox, getCollisionBox, getCollisionBoxAlign, getCollisionBoxCenter, getCollisionBoxHeight, getCollisionBoxValign, getCollisionBoxWidth, getCollisionType, hasCollision, onCollision, removeCollisionListener, setCollision, setCollisionBoxAlign, setCollisionBoxHeight, setCollisionBoxValign, setCollisionBoxWidth, setCollisionTypeMethods inherited from interface de.gurkenlabs.litiengine.entities.IEntity
actions, addController, addEntityRenderListener, addListener, addTag, addTransformListener, animations, attachControllers, behavior, detachControllers, getAngle, getBoundingBox, getCenter, getController, getEnvironment, getHeight, getLocation, getMapId, getName, getProperties, getRenderType, getTags, getWidth, getX, getY, hasTag, isLoaded, isVisible, loaded, onMessage, onMessage, onRendered, perform, register, removed, removeListener, removeListener, removeListener, removeListener, removeListener, removeTag, renderWithLayer, sendMessage, setAngle, setController, setHeight, setLocation, setLocation, setMapId, setName, setRenderType, setRenderWithLayer, setSize, setVisible, setWidth, setX, setY
Constructor Details
Prop
public Prop(java.lang.String spritesheetName)Instantiates a newPropentity.- Parameters:
spritesheetName- The spritesheet name of this prop.
Prop
public Prop(double x, double y, java.lang.String spritesheetName)Instantiates a newPropentity.- Parameters:
x- The x-coordinate of this prop.y- The y-coordinate of this prop.spritesheetName- The spritesheet name of this prop.
Prop
Instantiates a newPropentity.- Parameters:
x- The x-coordinate of this prop.y- The y-coordinate of this prop.spritesheetName- The spritesheet name of this prop.material- The material of this prop.
Prop
public Prop(java.awt.geom.Point2D location, java.lang.String spritesheetName)Instantiates a newPropentity.- Parameters:
location- The location of this prop.spritesheetName- The spritesheet name of this prop.
Prop
Instantiates a newPropentity.- Parameters:
location- The location of this prop.spritesheetName- The spritesheet name of this prop.material- The material of this prop.
Method Details
getMaterial
getSpritesheetName
public java.lang.String getSpritesheetName()getState
Gets the state.- Returns:
- the state
isAddShadow
public boolean isAddShadow()isScaling
public boolean isScaling()flipHorizontally
public boolean flipHorizontally()flipVertically
public boolean flipVertically()getSpriteRotation
setMaterial
setSpritesheetName
public void setSpritesheetName(java.lang.String spriteName)setAddShadow
public void setAddShadow(boolean addShadow)setScaling
public void setScaling(boolean scaling)isDead
public boolean isDead()Description copied from class:CombatEntityChecks if is dead.- Specified by:
isDeadin interfaceICombatEntity- Overrides:
isDeadin classCombatEntity- Returns:
- true, if is dead
setSpriteRotation
setFlipHorizontally
public void setFlipHorizontally(boolean flipHorizontally)setFlipVertically
public void setFlipVertically(boolean flipVertically)toString
public java.lang.String toString()createAnimationController
