Crossfire Client, Branch
R11627
|
#include "client-types.h"
Go to the source code of this file.
Data Structures | |
struct | Map |
struct | MapCell |
The heads[] in the mapcell is used for single part objects or the head piece for multipart. More... | |
struct | MapCellLayer |
Defines | |
#define | MAP1_LAYERS 3 |
#define | MAX_VIEW 64 |
Maximum size of view area a server could support. | |
#define | MAXLAYERS 10 |
The protocol supports 10 layers, so set MAXLAYERS accordingly. | |
Functions | |
sint16 | mapdata_bigface (int x, int y, int layer, int *ww, int *hh) |
Returns the face to display at a given location. | |
sint16 | mapdata_face (int x, int y, int layer) |
Returns the face to display at a given location. | |
void | mapdata_init (void) |
Initializes the module. | |
int | mapdata_is_inside (int x, int y) |
Checks whether the given coordinates are within the current display size (as set by mapdata_set_size). | |
void | mapdata_newmap (void) |
Clears the map view. | |
void | mapdata_reset (void) |
Resets all stored information. | |
void | mapdata_scroll (int dx, int dy) |
Scrolls the map view. | |
void | mapdata_set_size (int viewx, int viewy) |
Sets the current display size. | |
Variables | |
struct Map | the_map |
#define MAP1_LAYERS 3 |
#define MAX_VIEW 64 |
Maximum size of view area a server could support.
Definition at line 37 of file mapdata.h.
Referenced by expand_clear_bigface(), expand_clear_bigface_from_layer(), expand_set_bigface(), Map2Cmd(), mapdata_bigface_head(), mapdata_clear_old(), mapdata_clear_space(), mapdata_init(), mapdata_set_anim_layer(), mapdata_set_check_space(), mapdata_set_darkness(), mapdata_set_face_layer(), mapdata_set_smooth(), and recenter_virtual_map_view().
#define MAXLAYERS 10 |
The protocol supports 10 layers, so set MAXLAYERS accordingly.
Definition at line 32 of file mapdata.h.
Referenced by display_mapcell(), expand_clear_bigface(), expand_clear_bigface_from_layer(), expand_clear_face(), expand_clear_face_from_layer(), expand_need_update_from_layer(), expand_set_bigface(), expand_set_face(), Map2Cmd(), mapdata_animation(), mapdata_bigface(), mapdata_bigface_head(), mapdata_clear_old(), mapdata_clear_space(), mapdata_face(), mapdata_init(), mapdata_set_anim_layer(), and mapdata_set_check_space().
sint16 mapdata_bigface | ( | int | x, |
int | y, | ||
int | layer, | ||
int * | ww, | ||
int * | hh | ||
) |
Returns the face to display at a given location.
This function returns the "tail" information, i.e. big faces expanded by the client.
*ww and *hh return the offset of the current tile relative to the head; 0 <= *ww < (width of face), 0 <= *hh < (height of face).
When drawing the map view, this function must be used instead than a direct access to the_map.cells[]. This is because the_map.cells[] eventually still contains obsolete (fog of war) big face information; this function detects and clears such faces.
sint16 mapdata_face | ( | int | x, |
int | y, | ||
int | layer | ||
) |
void mapdata_init | ( | void | ) |
int mapdata_is_inside | ( | int | x, |
int | y | ||
) |
void mapdata_newmap | ( | void | ) |
void mapdata_reset | ( | void | ) |
void mapdata_scroll | ( | int | dx, |
int | dy | ||
) |
void mapdata_set_size | ( | int | viewx, |
int | viewy | ||
) |