3 #define IS_ONGROUND(s) boolean((s).flags & FL_ONGROUND)
4 #define SET_ONGROUND(s) ((s).flags |= FL_ONGROUND)
5 #define UNSET_ONGROUND(s) ((s).flags &= ~FL_ONGROUND)
6 #define IS_ONSLICK(s) boolean((s).flags & FL_ONSLICK)
7 #define SET_ONSLICK(s) ((s).flags |= FL_ONSLICK)
8 #define UNSET_ONSLICK(s) ((s).flags &= ~FL_ONSLICK)
10 #define GAMEPLAYFIX_DOWNTRACEONGROUND(s) STAT(GAMEPLAYFIX_DOWNTRACEONGROUND, s)
11 #define GAMEPLAYFIX_EASIERWATERJUMP(s) STAT(GAMEPLAYFIX_EASIERWATERJUMP, s)
12 #define GAMEPLAYFIX_STEPDOWN(s) STAT(GAMEPLAYFIX_STEPDOWN, s)
13 #define GAMEPLAYFIX_STEPMULTIPLETIMES(s) STAT(GAMEPLAYFIX_STEPMULTIPLETIMES, s)
14 #define GAMEPLAYFIX_UNSTICKPLAYERS(s) STAT(GAMEPLAYFIX_UNSTICKPLAYERS, s)
15 #define GAMEPLAYFIX_WATERTRANSITION(s) STAT(GAMEPLAYFIX_WATERTRANSITION, s)
22 void set_movetype(entity this, int mt);
26 //.vector move_origin;
27 //.vector move_angles;
28 //.vector move_velocity;
29 //.vector move_avelocity;
31 //.int move_watertype;
32 //.int move_waterlevel;
33 .void(float, float)contentstransition;
34 //.float move_bounce_factor;
35 //.float move_bounce_stopspeed;
36 .float move_nomonsters; // -1 for MOVE_NORMAL, otherwise a MOVE_ constant
41 .entity groundentity; // FIXME add move_groundnetworkentity?
42 .float move_suspendedinair;
43 .float move_didgravity;
45 void _Movetype_WallFriction(entity this, vector stepnormal);
46 int _Movetype_FlyMove(entity this, float dt, bool applygravity, vector stepnormal, float stepheight);
47 void _Movetype_CheckVelocity(entity this);
48 void _Movetype_CheckWaterTransition(entity ent);
49 float _Movetype_CheckWater(entity ent);
50 void _Movetype_LinkEdict_TouchAreaGrid(entity this);
51 void _Movetype_LinkEdict(entity this, float touch_triggers);
52 vector _Movetype_ClipVelocity(vector vel, vector norm, float f);
53 void _Movetype_PushEntityTrace(entity this, vector push);
54 float _Movetype_PushEntity(entity this, vector push, float failonstartsolid);
56 void Movetype_Physics_NoMatchTicrate(entity this, float movedt, bool isclient);
57 void Movetype_Physics_MatchTicrate(entity this, float tr, bool sloppy);
58 void Movetype_Physics_MatchServer(entity this, bool sloppy);
59 void Movetype_Physics_NoMatchServer(entity this);
60 void _Movetype_LinkEdict(entity this, float touch_triggers);
61 void _Movetype_LinkEdict_TouchAreaGrid(entity this);
63 float _Movetype_UnstickEntity(entity this);
65 const int MAX_CLIP_PLANES = 5;
68 const int MOVETYPE_NONE = 0;
69 const int MOVETYPE_ANGLENOCLIP = 1;
70 const int MOVETYPE_ANGLECLIP = 2;
71 const int MOVETYPE_WALK = 3;
72 const int MOVETYPE_STEP = 4;
73 const int MOVETYPE_FLY = 5;
74 const int MOVETYPE_TOSS = 6;
75 const int MOVETYPE_PUSH = 7;
76 const int MOVETYPE_NOCLIP = 8;
77 const int MOVETYPE_FLYMISSILE = 9;
78 const int MOVETYPE_BOUNCE = 10;
79 const int MOVETYPE_BOUNCEMISSILE = 11; // Like bounce but doesn't lose speed on bouncing
80 const int MOVETYPE_FOLLOW = 12;
81 const int MOVETYPE_PHYSICS = 32;
82 const int MOVETYPE_FLY_WORLDONLY = 33;
84 const int FL_ITEM = 256;
85 const int FL_ONGROUND = 512;
87 const int MOVETYPE_ANGLENOCLIP = 1;
88 const int MOVETYPE_ANGLECLIP = 2;
91 const int FL_ONSLICK = BIT(20);
93 const int MOVETYPE_FAKEPUSH = 13;
95 const int MOVEFLAG_VALID = BIT(23);
96 const int MOVEFLAG_Q2AIRACCELERATE = BIT(0);
97 const int MOVEFLAG_NOGRAVITYONGROUND = BIT(1);
98 const int MOVEFLAG_GRAVITYUNAFFECTEDBYTICRATE = BIT(2);
101 #define moveflags STAT(MOVEFLAGS)