--- cf.schmorp.de/server/random_maps/decor.C 2006/09/10 16:06:37 1.2 +++ cf.schmorp.de/server/random_maps/decor.C 2006/12/20 09:14:22 1.6 @@ -1,9 +1,3 @@ - -/* - * static char *rcsid_decor_ = - * "$Id: decor.C,v 1.2 2006/09/10 16:06:37 root Exp $"; - */ - /* CrossFire, A Multiplayer game for X-windows @@ -24,7 +18,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - The authors can be reached via e-mail at crossfire-devel@real-time.com + The authors can be reached via e-mail at */ @@ -37,12 +31,12 @@ /* return a simple count of objects in the map at x,y. */ int -obj_count_in_map (mapstruct *map, int x, int y) +obj_count_in_map (maptile *map, int x, int y) { int count = 0; object *tmp; - for (tmp = get_map_ob (map, x, y); tmp != NULL; tmp = tmp->above) + for (tmp = GET_MAP_OB (map, x, y); tmp != NULL; tmp = tmp->above) count++; return count; } @@ -50,9 +44,9 @@ /* put the decor into the map. Right now, it's very primitive. */ void -put_decor (mapstruct *map, char **maze, char *decorstyle, int decor_option, RMParms * RP) +put_decor (maptile *map, char **maze, char *decorstyle, int decor_option, RMParms * RP) { - mapstruct *decor_map; + maptile *decor_map; char style_name[256]; sprintf (style_name, "/styles/decorstyles"); @@ -85,7 +79,7 @@ new_decor_object = pick_random_object (decor_map); this_object = arch_to_object (new_decor_object->arch); - copy_object (new_decor_object, this_object); + new_decor_object->copy_to (this_object); this_object->x = x; this_object->y = y; /* it screws things up if decor can stop people */ @@ -111,7 +105,7 @@ new_decor_object = pick_random_object (decor_map); this_object = arch_to_object (new_decor_object->arch); - copy_object (new_decor_object, this_object); + new_decor_object->copy_to (this_object); this_object->x = i; this_object->y = j; /* it screws things up if decor can stop people */