public class CircleBouncerAnimationElement extends AnimationElement
| Constructor and Description |
|---|
CircleBouncerAnimationElement(IItem item,
IStage stage)
Creates an animation element for the supplied item which can then create
the flick motion by repositioning the managed item using JME's animation
system.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCollidable(IItem item,
java.lang.Float radius) |
void |
clearCollidable()
Clear collidables
|
void |
elementStart(float tpf)
Called on the first
|
int |
getTapCount()
Gets the tap count.
|
boolean |
isFinished()
When this method returns true, the animation element will be reset.
|
void |
removeCollidable(IItem item) |
void |
reset()
Called when the animation element is finished.
|
void |
resetTapCount()
Reset tap count.
|
void |
setRadius(float radius)
Sets the radius.
|
void |
updateAnimationState(float tpf)
Called each frame in the game loop.
|
enable, toString, updateStatepublic CircleBouncerAnimationElement(IItem item, IStage stage)
item - The item to be influenced by this animation.stage - The stage the item currently resides in.public void addCollidable(IItem item, java.lang.Float radius)
collidables - the collidables to setpublic void clearCollidable()
public void elementStart(float tpf)
AnimationElementelementStart in class AnimationElementpublic int getTapCount()
public boolean isFinished()
AnimationElementisFinished in class AnimationElementpublic void removeCollidable(IItem item)
collidables - the collidable item to removepublic void reset()
AnimationElementisFinished()reset in class AnimationElementpublic void resetTapCount()
public void setRadius(float radius)
radius - the new radiuspublic void updateAnimationState(float tpf)
AnimationElementupdateAnimationState in class AnimationElement