public class SpriteParticle extends Sprite implements Particle
Particle.Listener
Modifier and Type | Field and Description |
---|---|
protected ParticleEmitter |
mEmitter |
protected boolean |
mFinished |
protected Particle.Listener |
mListener |
protected java.util.Random |
mRandom |
protected PointF |
mVelocity |
mAtlasFrame, mOffsetX, mOffsetY
mFocus, mTouchable, mTouchListener, mTouchPointerID
ATT_ASYNC, ATT_SOURCE, mColorBuffer, mTexture, mTextureCoordBuffer, mTextureCoordBufferScaled, mVertexBuffer, TAG
ATT_ALPHA, ATT_ANIMATOR, ATT_BLEND_MODE, ATT_COLOR, ATT_DEBUG, ATT_ORIGIN_AT_CENTER, ATT_ROTATION, ATT_VISIBLE, mAlive, mAlpha, mAlphaTestEnabled, mAutoUpdateBounds, mBlendFunc, mBounds, mBypassCameraClipping, mColor, mDebugFlags, mFrameDuration, mHasTransformValues, mId, mInvalidateFlags, mManipulators, mMask, mMatrix, mNumManipulators, mOrigin, mParent, mPerspectiveEnabled, mPivot, mPosition, mRotation, mRotationVectorX, mRotationVectorY, mRotationVectorZ, mScale, mScene, mSceneSize, mSize, mSkew, mTransformMatrix, mTransformMatrixValues, mUIConstraint, mVisible, mZ
FLIP_X, FLIP_Y
ALL, ALPHA, BLEND, BOUNDS, CACHE, CHILDREN, COLOR, DEPTH, FRAME, ORIGIN, PARENT, PARENT_BOUNDS, PERSPECTIVE, PIVOT, POSITION, ROTATION, SCALE, SIZE, SKEW, TEXTURE, TEXTURE_COORDS, TRANSFORM_MATRIX, VERTICES, VISIBILITY, VISUAL
Constructor and Description |
---|
SpriteParticle() |
Modifier and Type | Method and Description |
---|---|
void |
finish() |
ParticleEmitter |
getEmitter() |
Particle.Listener |
getParticleListener() |
PointF |
getVelocity() |
boolean |
isFinished() |
void |
reset(java.lang.Object... params) |
void |
setEmitter(ParticleEmitter emitter) |
void |
setParticleListener(Particle.Listener listener) |
void |
setSize(float w,
float h) |
void |
setVelocity(PointF velocity) |
boolean |
update(int deltaTime) |
getAtlasFrame, isSizeToFrame, isSizeToTexture, onTextureLoaded, setAtlasFrame, setSizeToFrame, setSizeToTexture, setTexture
drawWireframe, getTouchListener, hitTest, isTouchable, onTouchEvent, setRect, setTouchable, setTouchListener, setXMLAttributes
dispose, drawChildren, drawStart, flipTextureCoordBuffer, getColorBuffer, getTexture, getTextureCoordBuffer, getVertexBuffer, onAdded, setColorBuffer, setTextureCoordBuffer, setTextureCoordBuffer, setVertexBuffer, validateTextureCoordBuffer
addManipulator, draw, drawBounds, drawEnd, getAlpha, getBlendFunc, getBounds, getColor, getDebugFlags, getFps, getGlobalPosition, getHeight, getId, getInheritedBlendFunc, getInheritedColor, getManipulator, getMask, getMatrix, getNumManipulators, getObjectTree, getOrigin, getParent, getParentMatrix, getPivot, getPosition, getRotation, getScale, getScene, getSceneSize, getSize, getSkew, getUIConstraint, getWidth, getX, getY, getZ, globalToLocal, invalidate, invalidate, isAlive, isAlphaTestEnabled, isAutoUpdateBounds, isBypassCameraClipping, isOriginAtCenter, isPerspectiveEnabled, isVisible, localToGlobal, move, moveTo, onAddedToScene, onCreateChildren, onPreConcatParentMatrix, onRemoved, onRemovedFromScene, queueEvent, removeAllManipulators, removeFromParent, removeManipulator, rotate, setAlive, setAlpha, setAlphaTestEnabled, setAutoUpdateBounds, setBlendFunc, setBypassCameraClipping, setColor, setDebugFlags, setFps, setId, setMask, setOrigin, setOrigin, setOriginAtCenter, setPerspectiveEnabled, setPivot, setPivot, setPivotAtCenter, setPosition, setPosition, setRotation, setRotationVector, setScale, setScale, setSize, setSkew, setUIConstraint, setVisible, setX, setY, setZ, shouldDraw, toString, updateBounds, updateChildren, validate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
draw, isPerspectiveEnabled, onAdded, onCreateChildren, setPerspectiveEnabled, setXMLAttributes
addManipulator, dispose, getAlpha, getBlendFunc, getBounds, getColor, getFps, getId, getInheritedBlendFunc, getInheritedColor, getManipulator, getNumManipulators, getObjectTree, getOrigin, getParent, getPivot, getScene, getSkew, getZ, globalToLocal, invalidate, invalidate, isAlive, isAutoUpdateBounds, isVisible, localToGlobal, onAddedToScene, onRemoved, onRemovedFromScene, queueEvent, removeAllManipulators, removeFromParent, removeManipulator, setAlive, setAlpha, setAutoUpdateBounds, setBlendFunc, setColor, setFps, setId, setOrigin, setOrigin, setOriginAtCenter, setPivot, setPivot, setPivotAtCenter, setSkew, setVisible, setZ, shouldDraw, updateBounds
getHeight, getPosition, getRotation, getScale, getSize, getWidth, getX, getY, move, moveTo, rotate, setPosition, setPosition, setRotation, setScale, setScale, setSize, setX, setY
protected ParticleEmitter mEmitter
protected Particle.Listener mListener
protected PointF mVelocity
protected final java.util.Random mRandom
protected boolean mFinished
public boolean update(int deltaTime)
update
in interface Displayable
update
in class Shape
public void setSize(float w, float h)
setSize
in interface Manipulatable
setSize
in class Rectangular
public void setEmitter(ParticleEmitter emitter)
setEmitter
in interface Particle
public ParticleEmitter getEmitter()
getEmitter
in interface Particle
public void setParticleListener(Particle.Listener listener)
setParticleListener
in interface Particle
public Particle.Listener getParticleListener()
getParticleListener
in interface Particle
public PointF getVelocity()
public void setVelocity(PointF velocity)
velocity
- the velocity to setpublic boolean isFinished()
isFinished
in interface Particle