X-Git-Url: https://git.xonotic.org/?a=blobdiff_plain;f=qtypes.h;h=69600ec163868685e3a4e4e924747a436ba35f21;hb=5297b46dcb238b0e738e2bad7ea5b34413d361a8;hp=f6ce845d633a82910e0d9aa8384d2e0f4ddbc855;hpb=0ad63a18c8d59dc27c0729175d6d0fea3cdd4d18;p=xonotic%2Fdarkplaces.git diff --git a/qtypes.h b/qtypes.h index f6ce845d..69600ec1 100644 --- a/qtypes.h +++ b/qtypes.h @@ -4,8 +4,9 @@ #include #include +#include -typedef bool qboolean; +typedef bool qbool; #ifndef NULL #define NULL ((void *)0) @@ -20,26 +21,27 @@ typedef bool qboolean; // fall over #define ROLL 2 -#if defined(__GNUC__) || (defined(_MSC_VER) && _MSC_VER >= 1400) +#if defined(__GNUC__) || (__clang__) || (__TINYC__) || (_MSC_VER >= 1400) #define RESTRICT __restrict #else #define RESTRICT #endif -typedef long long dpint64; -typedef unsigned long long dpuint64; - // LadyHavoc: upgrade the prvm to double precision for better time values // LadyHavoc: to be enabled when bugs are worked out... -#define PRVM_64 +//#define PRVM_64 #ifdef PRVM_64 typedef double prvm_vec_t; -typedef long long prvm_int_t; -typedef unsigned long long prvm_uint_t; +typedef int64_t prvm_int_t; +typedef uint64_t prvm_uint_t; +#define PRVM_PRIi PRIi64 +#define PRVM_PRIu PRIu64 #else typedef float prvm_vec_t; -typedef int prvm_int_t; -typedef unsigned int prvm_uint_t; +typedef int32_t prvm_int_t; +typedef uint32_t prvm_uint_t; +#define PRVM_PRIi PRIi32 +#define PRVM_PRIu PRIu32 #endif typedef prvm_vec_t prvm_vec3_t[3];