Defines a class to load an animation.
More...
#include <spritedef.h>
Defines a class to load an animation.
Definition at line 86 of file spritedef.h.
◆ SpriteDef()
◆ ~SpriteDef()
SpriteDef::~SpriteDef |
( |
| ) |
|
|
overrideprivate |
◆ getAction()
Action * SpriteDef::getAction |
( |
const std::string & |
action | ) |
const |
◆ includeSprite()
void SpriteDef::includeSprite |
( |
XML::Node |
includeNode | ) |
|
|
private |
Include another sprite into this one.
Definition at line 288 of file spritedef.cpp.
◆ load()
SpriteDef * SpriteDef::load |
( |
const std::string & |
file, |
|
|
int |
variant |
|
) |
| |
|
static |
Loads a sprite definition file.
Definition at line 54 of file spritedef.cpp.
◆ loadAction()
void SpriteDef::loadAction |
( |
XML::Node |
node, |
|
|
int |
variant_offset |
|
) |
| |
|
private |
◆ loadAnimation()
void SpriteDef::loadAnimation |
( |
XML::Node |
animationNode, |
|
|
Action * |
action, |
|
|
ImageSet * |
imageSet, |
|
|
int |
variant_offset |
|
) |
| |
|
private |
◆ loadImageSet()
void SpriteDef::loadImageSet |
( |
XML::Node |
node, |
|
|
const std::string & |
palettes |
|
) |
| |
|
private |
◆ loadSprite()
void SpriteDef::loadSprite |
( |
XML::Node |
spriteNode, |
|
|
int |
variant, |
|
|
const std::string & |
palettes = std::string() |
|
) |
| |
|
private |
◆ makeSpriteDirection()
SpriteDirection SpriteDef::makeSpriteDirection |
( |
const std::string & |
direction | ) |
|
|
static |
Converts a string into a SpriteDirection enum.
Definition at line 331 of file spritedef.cpp.
◆ substituteAction()
void SpriteDef::substituteAction |
( |
std::string |
complete, |
|
|
std::string |
with |
|
) |
| |
|
private |
When there are no animations defined for the action "complete", its animations become a copy of those of the action "with".
Definition at line 87 of file spritedef.cpp.
◆ substituteActions()
void SpriteDef::substituteActions |
( |
| ) |
|
|
private |
Complete missing actions by copying existing ones.
Definition at line 99 of file spritedef.cpp.
◆ mActions
std::map<std::string, Action *> SpriteDef::mActions |
|
private |
◆ mImageSets
The documentation for this class was generated from the following files: