List of all members.
Detailed Description
Base class for derivitives.
- Note:
- Entities assume that the world they're in exist from 0, 0 to WorldWidth, WorldHeight.
Constructor & Destructor Documentation
| Entity::Entity |
( |
const std::string & |
name = "Undefined" |
) |
|
Entity Constructor.
- Parameters:
-
| renderer | A pointer to a Renderer object. Must not be NULL. |
| name | Name for this Entity. |
| Entity::Entity |
( |
const Entity & |
copy |
) |
|
| Entity::~Entity |
( |
|
) |
[virtual] |
Member Function Documentation
| bool Entity::canCollide |
( |
|
) |
[inline] |
| void Entity::canCollide |
( |
bool |
collide |
) |
[inline] |
| void Entity::draw |
( |
int |
rasterX, |
|
|
int |
rasterY | |
|
) |
| | |
| void Entity::drawBorder |
( |
bool |
border |
) |
[inline] |
| Image* Entity::getCurrentFrame |
( |
|
) |
[inline] |
| const int Entity::getHeight |
( |
|
) |
const [inline] |
| const string & Entity::getName |
( |
|
) |
|
Returns the name of this Entity.
| const int Entity::getPositionX |
( |
|
) |
const [inline] |
| const int Entity::getPositionY |
( |
|
) |
const [inline] |
| Recti Entity::getRect |
( |
int |
x, |
|
|
int |
y | |
|
) |
| | const [inline] |
| const int Entity::getWidth |
( |
|
) |
const [inline] |
| virtual void Entity::logic |
( |
|
) |
[inline, private, virtual] |
Logic that this entity should perform.
| void Entity::movePosition |
( |
int |
x, |
|
|
int |
y | |
|
) |
| | |
Moves Entity along its X and Y axis the number of world units specified.
| void Entity::movePositionX |
( |
int |
x |
) |
|
Moves Entity along its X axis the number of world units specified.
| void Entity::movePositionY |
( |
int |
y |
) |
|
Moves Entity along its Y axis the number of world units specified.
| void Entity::setAlpha |
( |
int |
alpha |
) |
[inline] |
| void Entity::setName |
( |
const std::string & |
name |
) |
|
| void Entity::setPosition |
( |
int |
x, |
|
|
int |
y | |
|
) |
| | |
Sets the absolute X and Y position of this Entity.
| void Entity::setPositionRaw |
( |
int |
x, |
|
|
int |
y | |
|
) |
| | |
Sets the absolute X and Y position of the Entity without any boundry checks.
| void Entity::setPositionX |
( |
int |
x |
) |
|
Sets the absolute X position of this Entity.
| void Entity::setPositionY |
( |
int |
y |
) |
|
Sets the absolute Y position of this Entity.
| void Entity::setSprite |
( |
Sprite & |
sprite |
) |
[protected] |
Sets a sprite.
- Parameters:
-
| sprite | A reference to a Sprite. |
- Note:
- This function creates a new copy of a Sprite using the provided reference.
| void Entity::setWorldCollisionMap |
( |
CollisionMap * |
map |
) |
[inline] |
| void Entity::setWorldDimensions |
( |
int |
width, |
|
|
int |
height | |
|
) |
| | |
Sets the world dimensions for the Entity.
Updates the Entity.
- Note:
- This function calls the logic functions of the Entity.
Member Data Documentation
Indicates whether or not the Entity can cause collisions with other Entity objects.
Indicates that the Entity should draw a frame around itself.
Indicates whether or not this Entity is visible or not regardless of the current visibility value. Defaults to true.
Sprite used to represent this object. Sprite is allowed to be NULL to indicate an invisible Entity.
A value between 0 - 255 representing the opacity of this Entity. 0 is completely transparent and 255 is completely opaque.
A pointer to an array of bool values indicating the world units this Entity is allowed to occupy. If this is empty, the Entity will asume that all areas can be occupied.
- Note:
- This pointer is defined outside of the Entity. See CollisionMap for more information.
World Height. Entity will assume that any value is valid if either of these are 0.
World Width. Entity will assume that any value is valid if either of these are 0.
The documentation for this class was generated from the following files:
- C:/Development/LoM/client/src/Core/Entities/Entity.h
- C:/Development/LoM/client/src/Core/Entities/Entity.cpp