#include <Drawable.h>
Inheritance diagram for Drawable:
Public Methods | |
virtual | ~Drawable () |
virtual void | draw (const Point &anchor)=0 |
Draw this object on the screen, given the anchor point on the screen, which is defined as the center of the object's contact with the ground. | |
virtual const Rect & | getPosition () const=0 |
Get the current position on the map. | |
virtual float | getHeight () const |
Returns the height of the object. | |
virtual bool | needsTransform () const |
A method that returns true if the Drawable will be drawing pre-transformed (XYZRHW) and pre-lit vertices, and its anchor needs transforming due to viewport changes. | |
Protected Methods | |
Drawable () |
A Drawable object must have a position.
|
|
|
|
|
Draw this object on the screen, given the anchor point on the screen, which is defined as the center of the object's contact with the ground.
Implemented in Bomb, Character, Effect, Entity, Explosion, HomingBomb, Particle, Powerup, and ThrownBomb. |
|
Returns the height of the object. If the returned number is negative (the default implementation), the object's height is taken to be the tile's height when it is drawn. If the number is 0.0f or greater, the height given is taken to be the absolute height, and the tile's height will not be taken into consideration. The default implementation of getHeight returns a negative number. Reimplemented in Bomb, Character, Explosion, Particle, and Powerup. |
|
Get the current position on the map.
|
|
A method that returns true if the Drawable will be drawing pre-transformed (XYZRHW) and pre-lit vertices, and its anchor needs transforming due to viewport changes.
Reimplemented in Particle. |