pmove: reformat structures to make it compatible with engine again

This commit is contained in:
mittorn 2021-02-14 21:02:17 +00:00
parent cdc96f628d
commit 1a3c9787c8
3 changed files with 9 additions and 12 deletions

View File

@ -25,7 +25,7 @@ typedef struct
} pmplane_t;
typedef struct pmtrace_s pmtrace_t;
#pragma pack(1)
struct pmtrace_s
{
qboolean allsolid; // if true, plane is not valid
@ -35,13 +35,10 @@ struct pmtrace_s
vec3_t endpos; // final position
pmplane_t plane; // surface normal at impact
int ent; // entity at impact
vec3_t deltavelocity; // Change in player's velocity caused by impact.
// Only run on server.
union
{
int hitgroup; // 0 == generic, non zero is specific body part
struct mstudiomat_s *surf; // only if ent->v.solid == SOLID_CUSTOM!
};
// Change in player's velocity caused by impact.
int stub1;
struct mstudiomat_s *surf; // only if ent->v.solid == SOLID_CUSTOM!
int hitgroup; // 0 == generic, non zero is specific body part
};
#pragma pack()
#endif

View File

@ -134,7 +134,7 @@ typedef struct playermove_s
int watertype;
int oldwaterlevel;
char sztexturename[252]; // cutoff four bytes for a new variable (see below)
char sztexturename[248]; // cutoff four bytes for a new variable (see below)
struct matdef_s *pMaterial; // pointer to a material
char chtexturetype;

View File

@ -350,7 +350,7 @@ qboolean PM_AddToTouched(pmtrace_t tr, const Vector &impactvelocity)
if (i != pmove->numtouch) // Already in list.
return false;
VectorCopy( impactvelocity, tr.deltavelocity );
// VectorCopy( impactvelocity, tr.deltavelocity );
if (pmove->numtouch >= MAX_PHYSENTS)
pmove->Con_DPrintf("Too many entities were touched!\n");
@ -3077,7 +3077,7 @@ and client. This will ensure that prediction behaves appropriately.
void PM_Move ( struct playermove_s *ppmove, int server )
{
assert( pm_shared_initialized );
// return;
pmove = ppmove;
// ppmove->Con_Printf("clientmaxspeed: %f\n", ppmove->clientmaxspeed);