]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - server.h
DP_QC_ENTITYSTRING: menu builtins like reading/writing whole entities -> svqc, csqc too
[xonotic/darkplaces.git] / server.h
index d6cac81be0d366159602a35c0f51b17aa6f8ea1a..53ada65534e1d9bf097b9db8c7b1de163b05ee7f 100644 (file)
--- a/server.h
+++ b/server.h
@@ -68,6 +68,8 @@ typedef struct server_connectfloodaddress_s
 }
 server_connectfloodaddress_t;
 
+#define MAX_CLIENTNETWORKEYES 256
+
 typedef struct server_s
 {
        /// false if only a net client
@@ -142,7 +144,8 @@ typedef struct server_s
        int writeentitiestoclient_cliententitynumber;
        int writeentitiestoclient_clientnumber;
        sizebuf_t *writeentitiestoclient_msg;
-       vec3_t writeentitiestoclient_testeye;
+       vec3_t writeentitiestoclient_eyes[MAX_CLIENTNETWORKEYES];
+       int writeentitiestoclient_numeyes;
        int writeentitiestoclient_pvsbytes;
        unsigned char writeentitiestoclient_pvs[MAX_MAP_LEAFS/8];
        entity_state_t writeentitiestoclient_sendstates[MAX_EDICTS];
@@ -310,6 +313,7 @@ typedef struct client_s
 #define MOVETYPE_BOUNCEMISSILE 11              ///< bounce w/o gravity
 #define MOVETYPE_FOLLOW                        12              ///< track movement of aiment
 #define MOVETYPE_FAKEPUSH              13              ///< tenebrae's push that doesn't push
+#define MOVETYPE_PHYSICS               32              ///< indicates this object is physics controlled
 
 // edict->solid values
 #define        SOLID_NOT                               0               ///< no interaction with other objects
@@ -319,6 +323,10 @@ typedef struct client_s
 #define        SOLID_BSP                               4               ///< bsp clip, touch on edge, block
 // LordHavoc: corpse code
 #define        SOLID_CORPSE                    5               ///< same as SOLID_BBOX, except it behaves as SOLID_NOT against SOLID_SLIDEBOX objects (players/monsters)
+// LordHavoc: physics
+#define        SOLID_PHYSICS_BOX               32              ///< physics object (mins, maxs, mass, origin, axis_forward, axis_left, axis_up, velocity, spinvelocity)
+#define        SOLID_PHYSICS_SPHERE    33              ///< physics object (mins, maxs, mass, origin, axis_forward, axis_left, axis_up, velocity, spinvelocity)
+#define        SOLID_PHYSICS_CAPSULE   34              ///< physics object (mins, maxs, mass, origin, axis_forward, axis_left, axis_up, velocity, spinvelocity)
 
 // edict->deadflag values
 #define        DEAD_NO                                 0
@@ -409,6 +417,7 @@ extern cvar_t sv_fixedframeratesingleplayer;
 extern cvar_t sv_freezenonclients;
 extern cvar_t sv_friction;
 extern cvar_t sv_gameplayfix_blowupfallenzombies;
+extern cvar_t sv_gameplayfix_consistentplayerprethink;
 extern cvar_t sv_gameplayfix_delayprojectiles;
 extern cvar_t sv_gameplayfix_droptofloorstartsolid;
 extern cvar_t sv_gameplayfix_droptofloorstartsolid_nudgetocorrect;
@@ -499,7 +508,7 @@ void SV_BroadcastPrintf(const char *fmt, ...) DP_FUNC_PRINTF(1);
 
 void SV_Physics (void);
 void SV_Physics_ClientMove (void);
-void SV_Physics_ClientEntity (prvm_edict_t *ent);
+//void SV_Physics_ClientEntity (prvm_edict_t *ent);
 
 qboolean SV_PlayerCheckGround (prvm_edict_t *ent);
 qboolean SV_CheckBottom (prvm_edict_t *ent);
@@ -511,6 +520,7 @@ qboolean SV_movestep (prvm_edict_t *ent, vec3_t move, qboolean relink, qboolean
  */
 void SV_LinkEdict(prvm_edict_t *ent);
 void SV_LinkEdict_TouchAreaGrid(prvm_edict_t *ent);
+void SV_LinkEdict_TouchAreaGrid_Call(prvm_edict_t *touch, prvm_edict_t *ent); // if we detected a touch from another source
 
 /*! move an entity that is stuck by small amounts in various directions to try to nudge it back into the collision hull
  * returns true if it found a better place
@@ -524,6 +534,8 @@ trace_t SV_TraceBox(const vec3_t start, const vec3_t mins, const vec3_t maxs, co
 trace_t SV_TraceLine(const vec3_t start, const vec3_t end, int type, prvm_edict_t *passedict, int hitsupercontentsmask);
 trace_t SV_TracePoint(const vec3_t start, int type, prvm_edict_t *passedict, int hitsupercontentsmask);
 
+qboolean SV_CanSeeBox(int numsamples, vec_t enlarge, vec3_t eye, vec3_t entboxmins, vec3_t entboxmaxs);
+
 int SV_PointSuperContents(const vec3_t point);
 
 void SV_FlushBroadcastMessages(void);
@@ -544,5 +556,7 @@ void SV_VM_End(void);
 
 const char *Host_TimingReport(void); ///< for output in Host_Status_f
 
+int SV_GetPitchSign(prvm_edict_t *ent);
+
 #endif