19 #ifndef OPENXCOM_UNITSPRITE_H
20 #define OPENXCOM_UNITSPRITE_H
22 #include "../Engine/Surface.h"
40 SurfaceSet *_unitSurface, *_itemSurfaceA, *_itemSurfaceB;
41 int _part, _animationFrame, _drawingRoutine;
66 UnitSprite(
int width,
int height,
int x,
int y);
~UnitSprite()
Cleans up the UnitSprite.
Definition: UnitSprite.cpp:55
void setBattleUnit(BattleUnit *unit, int part=0)
Sets the battleunit to be rendered.
Definition: UnitSprite.cpp:79
UnitSprite(int width, int height, int x, int y)
Creates a new UnitSprite at the specified position and size.
Definition: UnitSprite.cpp:48
Container of a set of surfaces.
Definition: SurfaceSet.h:38
Represents a single item in the battlescape.
Definition: BattleItem.h:39
Element that is blit (rendered) onto the screen.
Definition: Surface.h:39
void draw()
Draws the unit.
Definition: UnitSprite.cpp:141
A class that renders a specific unit, given its render rules combining the right frames from the surf...
Definition: UnitSprite.h:35
void setAnimationFrame(int frame)
Sets the animation frame.
Definition: UnitSprite.cpp:133
void setSurfaces(SurfaceSet *unitSurface, SurfaceSet *itemSurfaceA, SurfaceSet *itemSurfaceB)
Sets surfacesets for rendering.
Definition: UnitSprite.cpp:66
Represents a moving unit in the battlescape, player controlled or AI controlled it holds info about i...
Definition: BattleUnit.h:58
void setBattleItem(BattleItem *item)
Sets the battleitem to be rendered.
Definition: UnitSprite.cpp:90