Adonthell
0.4
|
Area of mapsquare_walkables, for use with mapcharacter and mapobject classes. More...
#include <mapsquare_walkable.h>
Public Member Functions | |
mapsquare_walkable_area () | |
Default constructor. More... | |
~mapsquare_walkable_area () | |
Destructor. More... | |
void | clear () |
Totally clears the area. More... | |
virtual void | draw (s_int16 x, s_int16 y, const drawing_area *da_opt=NULL, surface *target=NULL) const =0 |
Draw the object on the screen. More... | |
s_int8 | get (igzstream &file) |
Loads an area from an opened file. More... | |
s_int8 | put (ogzstream &file) const |
Saves an area into an opened file. More... | |
mapsquare_walkable_area & | operator= (const mapsquare_walkable_area &mo) |
Area copy (similar to copy ()). More... | |
void | copy (const mapsquare_walkable_area &src) |
Synonym of operator = to guarantee its access from Python. More... | |
Area settings. | |
u_int16 | area_length () const |
Returns the length of the area. More... | |
u_int16 | area_height () const |
Returns the height of the area. More... | |
mapsquare_walkable * | get_square (u_int16 x, u_int16 y) const |
Returns a pointer to a desired square. More... | |
void | resize_area (u_int16 nl, u_int16 nh) |
Resize the area. More... | |
Base square settings. | |
u_int16 | base_x () const |
Returns the X offset of the base square of this object. More... | |
u_int16 | base_y () const |
Returns the Y offset of the base square of this object. More... | |
void | set_base (u_int16 nx, u_int16 ny) |
Sets the base square of this object. More... | |
![]() | |
drawable () | |
Default constructor. More... | |
virtual | ~drawable () |
Destructor. More... | |
u_int16 | length () const |
Returns the length of the drawable. More... | |
u_int16 | height () const |
Returns the height of the drawable. More... | |
virtual bool | update () |
Virtual update function, provided for objects which doesn't need one. More... | |
virtual bool | input_update () |
Virtual input update function, provided for objects which doesn't need one. More... | |
Additional Inherited Members | |
![]() | |
void | set_length (u_int16 l) |
Sets the length of the drawable. More... | |
void | set_height (u_int16 h) |
Sets the height of the drawable. More... | |
Area of mapsquare_walkables, for use with mapcharacter and mapobject classes.
Definition at line 235 of file mapsquare_walkable.h.
mapsquare_walkable_area::mapsquare_walkable_area | ( | ) |
Default constructor.
Definition at line 43 of file mapsquare_walkable.cc.
mapsquare_walkable_area::~mapsquare_walkable_area | ( | ) |
Destructor.
Definition at line 49 of file mapsquare_walkable.cc.
void mapsquare_walkable_area::clear | ( | ) |
Totally clears the area.
Definition at line 53 of file mapsquare_walkable.cc.
|
pure virtual |
Draw the object on the screen.
x | X position where to draw. |
y | Y position where to draw. |
da_opt | optional drawing_area to use during the drawing operation. |
target | pointer to the surface where to draw the drawable. If NULL, draw on the screen. |
Implements drawable.
Implemented in mapcharacter, and mapobject.
|
inline |
Returns the length of the area.
Definition at line 271 of file mapsquare_walkable.h.
|
inline |
Returns the height of the area.
Definition at line 282 of file mapsquare_walkable.h.
|
inline |
Returns a pointer to a desired square.
x | X position of the square to get. |
y | Y position of the square to get. |
Definition at line 296 of file mapsquare_walkable.h.
Resize the area.
nl | new length (in number of squares) of the area. |
nh | new height (in number of squares) of the area. |
Definition at line 107 of file mapsquare_walkable.cc.
|
inline |
Returns the X offset of the base square of this object.
Definition at line 324 of file mapsquare_walkable.h.
|
inline |
Returns the Y offset of the base square of this object.
Definition at line 335 of file mapsquare_walkable.h.
Sets the base square of this object.
nx | X offset of the new base square. |
ny | Y offset of the new base square. |
Definition at line 119 of file mapsquare_walkable.cc.
Loads an area from an opened file.
file | the opened file from which to load. |
Definition at line 61 of file mapsquare_walkable.cc.
Saves an area into an opened file.
file | the opened file where to write. |
Definition at line 86 of file mapsquare_walkable.cc.
mapsquare_walkable_area & mapsquare_walkable_area::operator= | ( | const mapsquare_walkable_area & | mo) |
Area copy (similar to copy ()).
Definition at line 125 of file mapsquare_walkable.cc.
|
inline |
Synonym of operator = to guarantee its access from Python.
Definition at line 381 of file mapsquare_walkable.h.