X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Fphysics.qh;h=3ddb24486632fb1c5f6dd401440d8c99301a4099;hb=ae82f85be7a1ccc080e5ea620976a03c43eeb962;hp=7a9bd3c5456e7f698ed7e86fba21323891dfb8ed;hpb=96d50426c7929a9f6b080f575cba5732aa3010d6;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/physics.qh b/qcsrc/common/physics.qh index 7a9bd3c54..3ddb24486 100644 --- a/qcsrc/common/physics.qh +++ b/qcsrc/common/physics.qh @@ -1,5 +1,7 @@ // Client/server mappings +.entity conveyor; + #ifdef CSQC float player_multijump; @@ -10,6 +12,7 @@ #define PHYS_WORLD_ANGLES(s) input_angles #define PHYS_INPUT_TIMELENGTH input_timelength + #define PHYS_INPUT_FRAMETIME serverdeltatime #define PHYS_INPUT_MOVEVALUES(s) input_movevalues @@ -45,6 +48,8 @@ #define SET_ONGROUND(s) s.pmove_flags |= PMF_ONGROUND #define UNSET_ONGROUND(s) s.pmove_flags &= ~PMF_ONGROUND + #define WAS_ONGROUND(s) !!(s.lastflags & PMF_ONGROUND) + #define ITEMS(s) getstati(STAT_ITEMS, 0, 24) #define PHYS_AMMO_FUEL(s) getstati(STAT_FUEL) @@ -72,6 +77,7 @@ #define PHYS_AIRSTRAFEACCELERATE getstatf(STAT_MOVEVARS_AIRSTRAFEACCELERATE) #define PHYS_ENTGRAVITY(s) getstatf(STAT_MOVEVARS_ENTGRAVITY) #define PHYS_FRICTION getstatf(STAT_MOVEVARS_FRICTION) + #define PHYS_FRICTION_ONLAND getstatf(STAT_MOVEVARS_FRICTION_ONLAND) #define PHYS_GRAVITY getstatf(STAT_MOVEVARS_GRAVITY) #define PHYS_HIGHSPEED getstatf(STAT_MOVEVARS_HIGHSPEED) #define PHYS_JUMPVELOCITY getstatf(STAT_MOVEVARS_JUMPVELOCITY) @@ -101,6 +107,7 @@ #define PHYS_WORLD_ANGLES(s) s.angles #define PHYS_INPUT_TIMELENGTH frametime + #define PHYS_INPUT_FRAMETIME sys_frametime #define PHYS_INPUT_MOVEVALUES(s) s.movement // TODO: cache @@ -136,6 +143,8 @@ #define SET_ONGROUND(s) s.flags |= FL_ONGROUND #define UNSET_ONGROUND(s) s.flags &= ~FL_ONGROUND + #define WAS_ONGROUND(s) !!((s).lastflags & FL_ONGROUND) + #define ITEMS(s) s.items #define PHYS_AMMO_FUEL(s) s.ammo_fuel @@ -163,6 +172,7 @@ #define PHYS_AIRSTRAFEACCELERATE autocvar_sv_airstrafeaccelerate #define PHYS_ENTGRAVITY(s) s.gravity #define PHYS_FRICTION autocvar_sv_friction + #define PHYS_FRICTION_ONLAND autocvar_sv_friction_on_land #define PHYS_GRAVITY autocvar_sv_gravity #define PHYS_HIGHSPEED autocvar_g_movement_highspeed #define PHYS_JUMPVELOCITY autocvar_sv_jumpvelocity