121 bool forceDisplay =
true);
139 int width,
int height,
int type,
int size);
bool draw(Graphics *graphics, int offsetX, int offsetY) const override
Draws the Actor to the given graphics context.
void setAlpha(float alpha) override
Sets the alpha value used to draw the actor.
static void loadTargetCursor(const std::string &filename, int width, int height, int type, int size)
Helper function for loading target cursors.
static ResourceRef< ImageSet > targetCursorImages[NUM_TCT][NUM_TC]
Images of the target cursor.
void controlParticle(Particle *particle)
Take control of a particle.
void setTargetType(TargetCursorType type)
Sets the target animation for this actor.
static void initTargetCursor()
Load the target cursors into memory.
virtual TargetCursorSize getTargetCursorSize() const
Returns the required size of a target cursor for this being.
static void cleanupTargetCursors()
Remove the target cursors from memory.
void setMap(Map *map) override
bool drawSpriteAt(Graphics *graphics, int x, int y) const
static SimpleAnimation * targetCursor[NUM_TCT][NUM_TC]
Animated target cursors.
float getAlpha() const override
Returns the current alpha value used to draw the actor.
void setupSpriteDisplay(const SpriteDisplay &display, bool forceDisplay=true)
void untarget()
Untargets the actor.
SimpleAnimation * mUsedTargetCursor
Target cursor being used.
virtual Type getType() const
Returns the type of the ActorSprite.
int getDrawOrder() const override
Returns the pixel Y coordinate that the actor should be drawn at.
virtual Map::BlockType getBlockType() const
Gets the way the object blocks pathfinding for other objects.
std::vector< ParticleHandle > mChildParticleEffects
int getHeight() const
Gets the height in pixels of the first sprite in the list.
void setAlpha(float alpha)
int getWidth() const
Gets the width in pixels of the first sprite in the list.
A central point of control for graphics.
A particle spawned by a ParticleEmitter.
Automatically counting Resource reference.
This class is a leightweight alternative to the Sprite class.