--- deliantra/server/random_maps/random_map.h 2006/12/31 20:46:17 1.7 +++ deliantra/server/random_maps/random_map.h 2007/01/27 02:19:37 1.13 @@ -1,6 +1,7 @@ /* * CrossFire, A Multiplayer game for X-windows * + * Copyright (C) 2005, 2006, 2007 Marc Lehmann & Crossfire+ Development Team * Copyright (C) 2001 Mark Wedel & Crossfire Development Team * Copyright (C) 1992 Frank Tore Johansen * @@ -39,9 +40,9 @@ char exitstyle[512]; shstr this_map; char exit_on_final_map[512]; + char *custom; - int Xsize; - int Ysize; + int xsize, ysize; int expand2x; int layoutoptions1; int layoutoptions2; @@ -50,19 +51,25 @@ int difficulty; int difficulty_given; float difficulty_increase; + int dungeon_level; int dungeon_depth; + int decoroptions; int orientation; int origin_y; int origin_x; - int random_seed; + uint32_t random_seed; uint64_t total_map_hp; int map_layout_style; int treasureoptions; int symmetry_used; struct region *region; + + // "private", adjusted sizes + int Xsize; + int Ysize; }; enum { @@ -113,11 +120,10 @@ SYMMETRY_XY, }; -#define MIN_RANDOM_MAP_SIZE 10 - -/* a macro to get a strongly centered random distribution, - from 0 to x, centered at x/2 */ -#define BC_RANDOM(x) ((int) ((RANDOM() % (x)+RANDOM()%(x)+RANDOM()%(x))/3.)) +// 12 has been experimentally :( determined ot be a lot more stable +// than 11 or 10, leading to the assumption that something inherently +// needs a minimum size of at least 12 +#define MIN_RANDOM_MAP_SIZE 12 #endif