--- deliantra/server/include/cfperl.h 2008/04/02 11:13:54 1.94 +++ deliantra/server/include/cfperl.h 2008/06/19 09:08:22 1.98 @@ -52,7 +52,9 @@ #undef srand48 #undef drand48 #undef srandom +#undef opendir #undef readdir +#undef closedir #undef getprotobyname #undef gethostbyname #undef ctime @@ -81,7 +83,7 @@ #define CHECK_ERROR \ if (SvTRUE (ERRSV)) \ - LOG (llevError, "runtime error in %s: %s\n", __func__, SvPVutf8_nolen (ERRSV)); + LOG (llevError, "runtime error in %s: %s", __func__, SvPVutf8_nolen (ERRSV)); #define CALL_BEGIN(args) dSP; ENTER; SAVETMPS; PUSHMARK (SP); EXTEND (SP, args) #define CALL_ARG_SV(sv) PUSHs (sv_2mortal (sv)) // separate because no refcount inc @@ -97,11 +99,28 @@ void cfperl_emergency_save (); void cfperl_cleanup (int make_core); void cfperl_make_book (object *book, int level); +void cfperl_expand_cfpod (player *pl, std::string &msg); void cfperl_send_msg (client *ns, int color, const char *type, const char *msg); int cfperl_can_merge (object *ob1, object *ob2); ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +#if IVSIZE >= 8 + typedef IV val64; + typedef IV uval64; +# define newSVval64 newSViv +# define SvVAL64 SvIV +# define newSVuval64 newSVuv +# define SvUVAL64 SvUV +#else + typedef double val64; + typedef double uval64; +# define newSVval64 newSVnv +# define SvVAL64 SvNV +# define newSVuval64 newSVnv +# define SvUVAL64 SvNV +#endif + extern tstamp runtime; // virtual server time, excluding time jumps and lag extern tstamp NOW; // real time of current server tick