X-Git-Url: http://git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=blobdiff_plain;f=progs.h;h=466521a7530cdc1cc3cd1f7e9b6a53e073c7c65b;hp=20d1754b27b34e418e4e567b31e821f26ddbb6ff;hb=91342dd0a88d002a188418a4b0dd21957e0737b6;hpb=48669036b4be979d997c27227942ed9c430277d5 diff --git a/progs.h b/progs.h index 20d1754b..466521a7 100644 --- a/progs.h +++ b/progs.h @@ -21,10 +21,23 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef PROGS_H #define PROGS_H #include "pr_comp.h" // defs shared with qcc +#include "qtypes.h" + #define ENTITYGRIDAREAS 16 #define MAX_ENTITYCLUSTERS 16 +#ifdef PRVM_64 +#define PRVM_FLOAT_IS_TRUE_FOR_INT(x) DOUBLE_IS_TRUE_FOR_INT(x) +#define PRVM_FLOAT_LOSSLESS_FORMAT DOUBLE_LOSSLESS_FORMAT +#define PRVM_VECTOR_LOSSLESS_FORMAT DOUBLE_VECTOR_LOSSLESS_FORMAT +#else +#define PRVM_FLOAT_IS_TRUE_FOR_INT(x) FLOAT_IS_TRUE_FOR_INT(x) +#define PRVM_FLOAT_LOSSLESS_FORMAT FLOAT_LOSSLESS_FORMAT +#define PRVM_VECTOR_LOSSLESS_FORMAT FLOAT_VECTOR_LOSSLESS_FORMAT +#endif + +#ifdef USEODE #define GEOMTYPE_NONE -1 #define GEOMTYPE_SOLID 0 #define GEOMTYPE_BOX 1 @@ -64,21 +77,18 @@ typedef struct edict_odefunc_s vec3_t v2; struct edict_odefunc_s *next; }edict_odefunc_t; +#endif typedef struct edict_engineprivate_s { - // true if this edict is unused - qboolean free; - // sv.time when the object was freed (to prevent early reuse which could - // mess up client interpolation or obscure severe QuakeC bugs) - float freetime; // mark for the leak detector int mark; // place in the code where it was allocated (for the leak detector) const char *allocation_origin; + // initially false to prevent projectiles from moving on their first frame // (even if they were spawned by an synchronous client think) - qboolean move; + qbool move; // cached cluster links for quick stationary object visibility checking vec3_t cullmins, cullmaxs; @@ -101,7 +111,7 @@ typedef struct edict_engineprivate_s int suspendedinairflag; // cached position to avoid redundant SV_CheckWaterTransition calls on monsters - qboolean waterposition_forceupdate; // force an update on this entity (set by SV_PushMove code for moving water entities) + qbool waterposition_forceupdate; // force an update on this entity (set by SV_PushMove code for moving water entities) vec3_t waterposition_origin; // updates whenever this changes // used by PushMove to keep track of where objects were before they were @@ -113,8 +123,9 @@ typedef struct edict_engineprivate_s frameblend_t frameblend[MAX_FRAMEBLENDS]; skeleton_t skeleton; +#ifdef USEODE // physics parameters - qboolean ode_physics; + qbool ode_physics; void *ode_body; void *ode_geom; void *ode_joint; @@ -132,7 +143,7 @@ typedef struct edict_engineprivate_s vec3_t ode_velocity; vec3_t ode_angles; vec3_t ode_avelocity; - qboolean ode_gravity; + qbool ode_gravity; int ode_modelindex; vec_t ode_movelimit; // smallest component of (maxs[]-mins[]) matrix4x4_t ode_offsetmatrix; @@ -145,6 +156,7 @@ typedef struct edict_engineprivate_s vec3_t ode_joint_velocity; // second joint axis vec3_t ode_joint_movedir; // parameters void *ode_massbuf; +#endif } edict_engineprivate_t;