--- deliantra/server/common/map.C 2006/12/11 02:41:25 1.36 +++ deliantra/server/common/map.C 2006/12/12 20:53:02 1.39 @@ -26,9 +26,7 @@ #include #include -#ifndef WIN32 /* ---win32 exclude header */ -# include -#endif /* win32 */ +#include #include "path.h" @@ -159,19 +157,14 @@ { char buf[MAX_BUF]; -#ifndef WIN32 char *endbuf; struct stat statbuf; int mode = 0; -#endif if (prepend_dir) strcpy (buf, create_pathname (name)); else strcpy (buf, name); -#ifdef WIN32 /* ***win32: check this sucker in windows style. */ - return (_access (buf, 0)); -#else /* old method (strchr(buf, '\0')) seemd very odd to me - * this method should be equivalant and is clearer. @@ -194,7 +187,6 @@ mode |= 2; return (mode); -#endif } /* @@ -602,7 +594,7 @@ } } - free_object (op); + op->destroy (0); link_multipart_objects (m); } @@ -873,7 +865,7 @@ if (!value) { - if (end = strchr (key, '\n')) + if ((end = strchr (key, '\n'))) *end = 0; } else @@ -1318,8 +1310,8 @@ clean_object (op); if (QUERY_FLAG (op, FLAG_IS_LINKED)) remove_button_link (op); - remove_ob (op); - free_object (op); + op->remove (); + op->destroy (0); } } } @@ -1432,17 +1424,10 @@ } if (m->shopgreed) fprintf (freezer, "shopgreed %f\n", m->shopgreed); -#ifndef WIN32 if (m->shopmin) fprintf (freezer, "shopmin %llu\n", m->shopmin); if (m->shopmax) fprintf (freezer, "shopmax %llu\n", m->shopmax); -#else - if (m->shopmin) - fprintf (freezer, "shopmin %I64u\n", m->shopmin); - if (m->shopmax) - fprintf (freezer, "shopmax %I64u\n", m->shopmax); -#endif if (m->shoprace) fprintf (freezer, "shoprace %s\n", m->shoprace); if (m->darkness) @@ -1534,8 +1519,8 @@ clean_object (tmp); if (QUERY_FLAG (tmp, FLAG_IS_LINKED)) remove_button_link (tmp); - remove_ob (tmp); - free_object (tmp); + tmp->remove (); + tmp->destroy (0); } } @@ -1570,8 +1555,8 @@ */ if (m->in_memory == MAP_IN_MEMORY) clean_object (op); - remove_ob (op); - free_object (op); + op->remove (); + op->destroy (0); } } }