30 #ifndef MAPSQUARE_WALKABLE_H_ 31 #define MAPSQUARE_WALKABLE_H_ 48 #define ALL_WALKABLE 15 54 #define WALKABLE_SOUTH 1 60 #define WALKABLE_NORTH 2 66 #define WALKABLE_EAST 4 72 #define WALKABLE_WEST 8 78 #define NONE_WALKABLE 0 261 surface * target = NULL)
const = 0;
288 if (area.size ())
return area[0].size ();
302 return &(area[x][y]);
397 mutable vector <vector<mapsquare_walkable> > area;
Class to write data from a Gzip compressed file.
void set_walkable_north(bool w)
Sets the reachability from north of a mapsquare.
u_int16 area_height() const
Returns the height of the area.
Class to read data from a Gzip compressed file.
#define u_int16
16 bits long unsigned integer
Class where drawables can actually be drawn to.
u_int16 area_length() const
Returns the length of the area.
#define u_int8
8 bits long unsigned integer
#define WALKABLE_WEST
Walkable from West.
bool is_walkable_east() const
Returns whether a mapsquare is walkable from east.
#define WALKABLE_SOUTH
Walkable from South.
u_int8 get_walkable() const
Gets the raw walkable parameter of a mapsquare.
bool is_walkable_north() const
Returns whether a mapsquare is walkable from north.
bool is_walkable_west() const
Returns whether a mapsquare is walkable from west.
bool is_walkable_south() const
Returns whether a mapsquare is walkable from south.
Declares the drawable class.
Contains information about the walkability of a mapsquare.
Implements "drawing zones" for drawing operations.
#define ALL_WALKABLE
Walkable from every side.
#define WALKABLE_NORTH
Walkable from North.
#define s_int16
16 bits long signed integer
void set_walkable(u_int8 w)
Sets the walkable parameter of a mapsquare.
mapsquare_walkable * get_square(u_int16 x, u_int16 y) const
Returns a pointer to a desired square.
u_int16 base_x() const
Returns the X offset of the base square of this object.
const u_int16 MAPSQUARE_SIZE
Size of a mapsquare (in pixels).
mapsquare_walkable()
Default constructor.
Area of mapsquare_walkables, for use with mapcharacter and mapobject classes.
void set_walkable_south(bool w)
Sets the reachability from south of a mapsquare.
void set_walkable_east(bool w)
Sets the reachability from east of a mapsquare.
void copy(const mapsquare_walkable_area &src)
Synonym of operator = to guarantee its access from Python.
Abstract class for drawable objects manipulation.
s_int8 put(ogzstream &file) const
Puts a mapsquare_walkable into an opened file.
Declares the igzstream, ogzstream and fileops classes.
u_int16 base_y() const
Returns the Y offset of the base square of this object.
#define WALKABLE_EAST
Walkable from East.
void set_walkable_west(bool w)
Sets the reachability from west of a mapsquare.
#define s_int8
8 bits long signed integer