ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/include/map.h
(Generate patch)

Comparing deliantra/server/include/map.h (file contents):
Revision 1.20 by root, Sat Sep 16 22:06:17 2006 UTC vs.
Revision 1.25 by pippijn, Mon Dec 11 18:41:32 2006 UTC

20 20
21 The authors can be reached via e-mail at crossfire-devel@real-time.com 21 The authors can be reached via e-mail at crossfire-devel@real-time.com
22*/ 22*/
23 23
24/* 24/*
25 * The mapstruct is allocated each time a new map is opened. 25 * The maptile is allocated each time a new map is opened.
26 * It contains pointers (very indirectly) to all objects on the map. 26 * It contains pointers (very indirectly) to all objects on the map.
27 */ 27 */
28 28
29#ifndef MAP_H 29#ifndef MAP_H
30#define MAP_H 30#define MAP_H
274 * almost certainly break various features. You may think 274 * almost certainly break various features. You may think
275 * it is safe to look at width and height values directly 275 * it is safe to look at width and height values directly
276 * (or even through the macros), but doing so will completely 276 * (or even through the macros), but doing so will completely
277 * break map tiling. 277 * break map tiling.
278 */ 278 */
279ACC_CLASS (mapstruct) 279ACC_CLASS (maptile)
280struct mapstruct:zero_initialised, attachable < mapstruct > 280struct maptile : zero_initialised, attachable<maptile>
281{ 281{
282 struct mapstruct *ACC (RW, next); /* Next map, linked list */ 282 maptile *ACC (RW, next); /* Next map, linked list */
283 char *ACC (RO, tmpname); /* Name of temporary file */ 283 char *ACC (RO, tmpname); /* Name of temporary file */
284 char *ACC (RO, name); /* Name of map as given by its creator */ 284 char *ACC (RO, name); /* Name of map as given by its creator */
285 struct region *ACC (RW, region); /* What jurisdiction in the game world this map is ruled by 285 struct region *ACC (RW, region); /* What jurisdiction in the game world this map is ruled by
286 * points to the struct containing all the properties of 286 * points to the struct containing all the properties of
287 * the region */ 287 * the region */
295 bool ACC (RW, unique); /* if set, this is a per player unique map */ 295 bool ACC (RW, unique); /* if set, this is a per player unique map */
296 bool ACC (RW, templatemap); /* if set, this is a template map */ 296 bool ACC (RW, templatemap); /* if set, this is a template map */
297 bool ACC (RW, nosmooth); /* if set the content of this map has smoothlevel=0 forced */ 297 bool ACC (RW, nosmooth); /* if set the content of this map has smoothlevel=0 forced */
298 sint32 ACC (RW, timeout); /* swapout is set to this */ 298 sint32 ACC (RW, timeout); /* swapout is set to this */
299 sint32 ACC (RW, swap_time); /* When it reaches 0, the map will be swapped out */ 299 sint32 ACC (RW, swap_time); /* When it reaches 0, the map will be swapped out */
300 sint16 ACC (RW, players); /* How many plares are on this level right now */ 300 sint16 ACC (RW, players); /* How many players are on this level right now */
301 uint32 ACC (RW, in_memory); /* If not true, the map has been freed and must 301 uint32 ACC (RW, in_memory); /* If not true, the map has been freed and must
302 * be loaded before used. The map,omap and map_ob 302 * be loaded before used. The map,omap and map_ob
303 * arrays will be allocated when the map is loaded */ 303 * arrays will be allocated when the map is loaded */
304 uint16 ACC (RW, difficulty); /* What level the player should be to play here */ 304 uint16 ACC (RW, difficulty); /* What level the player should be to play here */
305 305
318 sint8 ACC (RW, sky); /* sky conditions */ 318 sint8 ACC (RW, sky); /* sky conditions */
319 int ACC (RW, wpartx), ACC (RW, wparty); /*Highly fasten conversion between worldmap and weathermap */ 319 int ACC (RW, wpartx), ACC (RW, wparty); /*Highly fasten conversion between worldmap and weathermap */
320 struct shopitems *shopitems; /* a semi-colon seperated list of item-types the map's shop will trade in */ 320 struct shopitems *shopitems; /* a semi-colon seperated list of item-types the map's shop will trade in */
321 char *ACC (RO, shoprace); /* the preffered race of the local shopkeeper */ 321 char *ACC (RO, shoprace); /* the preffered race of the local shopkeeper */
322 double ACC (RW, shopgreed); /* how much our shopkeeper overcharges */ 322 double ACC (RW, shopgreed); /* how much our shopkeeper overcharges */
323 uint64 ACC (RW, shopmin); /* minimum price a shop will trade for */ 323 sint64 ACC (RW, shopmin); /* minimum price a shop will trade for */
324 uint64 ACC (RW, shopmax); /* maximum price a shop will offer */ 324 sint64 ACC (RW, shopmax); /* maximum price a shop will offer */
325 char *ACC (RO, msg); /* Message map creator may have left */ 325 char *ACC (RO, msg); /* Message map creator may have left */
326 char *ACC (RO, maplore); /* Map lore information */ 326 char *ACC (RO, maplore); /* Map lore information */
327 char *tile_path[4]; /* path to adjoining maps */ 327 char *tile_path[4]; /* path to adjoining maps */
328 struct mapstruct *tile_map[4]; /* Next map, linked list */ 328 maptile *tile_map[4]; /* Next map, linked list */
329 char ACC (RW, path)[HUGE_BUF]; /* Filename of the map */ 329 char ACC (RW, path)[HUGE_BUF]; /* Filename of the map */
330
331 maptile ();
332 void allocate ();
330}; 333};
331 334
332/* This is used by get_rangevector to determine where the other 335/* This is used by get_rangevector to determine where the other
333 * creature is. get_rangevector takes into account map tiling, 336 * creature is. get_rangevector takes into account map tiling,
334 * so you just can not look the the map coordinates and get the 337 * so you just can not look the the map coordinates and get the
346 int direction; 349 int direction;
347 object *part; 350 object *part;
348}; 351};
349 352
350#endif 353#endif
354

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines