mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Merge branch 'slope-adjust-cleanup' into 'master'
Clean up debug messages left from slope adjustments branch See merge request KartKrew/Kart!2465
This commit is contained in:
commit
29013f17f7
3 changed files with 24 additions and 24 deletions
|
|
@ -12552,7 +12552,7 @@ boolean K_FastFallBounce(player_t *player)
|
||||||
}
|
}
|
||||||
|
|
||||||
player->mo->momz = bounce * P_MobjFlip(player->mo);
|
player->mo->momz = bounce * P_MobjFlip(player->mo);
|
||||||
CONS_Printf("%s FastFallBounce %d\n", player_names[player-players], player->mo->momz);
|
// CONS_Printf("%s FastFallBounce %d\n", player_names[player-players], player->mo->momz);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2783,11 +2783,11 @@ fixed_t P_GetThingStepUp(mobj_t *thing, fixed_t destX, fixed_t destY)
|
||||||
slopemom.z = 0;
|
slopemom.z = 0;
|
||||||
P_QuantizeMomentumToSlope(&slopemom, thing->standingslope);
|
P_QuantizeMomentumToSlope(&slopemom, thing->standingslope);
|
||||||
fixed_t momentumzdelta = FixedDiv(slopemom.z, FixedHypot(slopemom.x, slopemom.y)); // so this lets us know what the zdelta is for the vector the player is travelling along, in addition to the slope's zdelta in its xydirection
|
fixed_t momentumzdelta = FixedDiv(slopemom.z, FixedHypot(slopemom.x, slopemom.y)); // so this lets us know what the zdelta is for the vector the player is travelling along, in addition to the slope's zdelta in its xydirection
|
||||||
if (thing->player)
|
// if (thing->player)
|
||||||
CONS_Printf("%s P_GetThingStepUp %d +", player_names[thing->player-players], maxstep);
|
// CONS_Printf("%s P_GetThingStepUp %d +", player_names[thing->player-players], maxstep);
|
||||||
maxstep += abs(momentumzdelta);
|
maxstep += abs(momentumzdelta);
|
||||||
if (thing->player)
|
// if (thing->player)
|
||||||
CONS_Printf(" %d = %d\n", momentumzdelta, maxstep);
|
// CONS_Printf(" %d = %d\n", momentumzdelta, maxstep);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
38
src/p_mobj.c
38
src/p_mobj.c
|
|
@ -1916,13 +1916,13 @@ boolean P_XYMovement(mobj_t *mo)
|
||||||
mo->standingslope = oldslope;
|
mo->standingslope = oldslope;
|
||||||
P_SetPitchRollFromSlope(mo, mo->standingslope);
|
P_SetPitchRollFromSlope(mo, mo->standingslope);
|
||||||
P_SlopeLaunch(mo);
|
P_SlopeLaunch(mo);
|
||||||
if (mo->player)
|
// if (mo->player)
|
||||||
CONS_Printf("%s Slope change launch old angle %f - new angle %f = %f\n",
|
// CONS_Printf("%s Slope change launch old angle %f - new angle %f = %f\n",
|
||||||
player_names[mo->player-players],
|
// player_names[mo->player-players],
|
||||||
FIXED_TO_FLOAT(AngleFixed(oldangle)),
|
// FIXED_TO_FLOAT(AngleFixed(oldangle)),
|
||||||
FIXED_TO_FLOAT(AngleFixed(newangle)),
|
// FIXED_TO_FLOAT(AngleFixed(newangle)),
|
||||||
FIXED_TO_FLOAT(AngleFixed(oldangle-newangle))
|
// FIXED_TO_FLOAT(AngleFixed(oldangle-newangle))
|
||||||
);
|
// );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
@ -1934,8 +1934,8 @@ boolean P_XYMovement(mobj_t *mo)
|
||||||
|| ( (mo->eflags & MFE_VERTICALFLIP) && FixedDiv(slopemom.z, mo->scale) + P_GetMobjGravity(mo)*24 < 0 && predictedz - mo->z < slopemom.z*4/5 )
|
|| ( (mo->eflags & MFE_VERTICALFLIP) && FixedDiv(slopemom.z, mo->scale) + P_GetMobjGravity(mo)*24 < 0 && predictedz - mo->z < slopemom.z*4/5 )
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
if (mo->player)
|
// if (mo->player)
|
||||||
CONS_Printf("%s Ramp Launch %d %d %d+%d > 0 && %d-%d > %d True\n", player_names[mo->player-players], mo->scale, momentumzdelta, FixedDiv(slopemom.z, mo->scale), P_GetMobjGravity(mo)*24, predictedz, mo->z, slopemom.z*4/5);
|
// CONS_Printf("%s Ramp Launch %d %d %d+%d > 0 && %d-%d > %d True\n", player_names[mo->player-players], mo->scale, momentumzdelta, FixedDiv(slopemom.z, mo->scale), P_GetMobjGravity(mo)*24, predictedz, mo->z, slopemom.z*4/5);
|
||||||
P_SlopeLaunch(mo);
|
P_SlopeLaunch(mo);
|
||||||
}
|
}
|
||||||
// else
|
// else
|
||||||
|
|
@ -2282,8 +2282,8 @@ boolean P_ZMovement(mobj_t *mo)
|
||||||
mo->standingslope = NULL;
|
mo->standingslope = NULL;
|
||||||
else if (!onground)
|
else if (!onground)
|
||||||
{
|
{
|
||||||
if (mo->player)
|
// if (mo->player)
|
||||||
// CONS_Printf("ZMovement launch?\n");
|
// CONS_Printf("ZMovement launch?\n");
|
||||||
P_SlopeLaunch(mo);
|
P_SlopeLaunch(mo);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -2821,16 +2821,16 @@ void P_PlayerZMovement(mobj_t *mo)
|
||||||
|
|
||||||
if (mo->eflags & MFE_JUSTSTEPPEDDOWN && abs(mo->momz) > 1)
|
if (mo->eflags & MFE_JUSTSTEPPEDDOWN && abs(mo->momz) > 1)
|
||||||
{
|
{
|
||||||
CONS_Printf("%s Check Step up momz reset %d < %d + %d", player_names[mo->player-players], abs(mo->momz), P_GetThingStepUp(mo, mo->x, mo->y)/6, abs(P_GetMobjGravity(mo)*3));
|
// CONS_Printf("%s Check Step up momz reset %d < %d + %d", player_names[mo->player-players], abs(mo->momz), P_GetThingStepUp(mo, mo->x, mo->y)/6, abs(P_GetMobjGravity(mo)*3));
|
||||||
if (abs(mo->momz) < P_GetThingStepUp(mo, mo->x, mo->y)/6 + abs(P_GetMobjGravity(mo)*3))
|
if (abs(mo->momz) < P_GetThingStepUp(mo, mo->x, mo->y)/6 + abs(P_GetMobjGravity(mo)*3))
|
||||||
{
|
{
|
||||||
CONS_Printf(" True\n");
|
// CONS_Printf(" True\n");
|
||||||
mo->momz = 0;
|
mo->momz = 0;
|
||||||
}
|
}
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
CONS_Printf(" False\n");
|
// CONS_Printf(" False\n");
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
mo->z += mo->momz;
|
mo->z += mo->momz;
|
||||||
|
|
@ -2847,9 +2847,9 @@ void P_PlayerZMovement(mobj_t *mo)
|
||||||
mo->standingslope = NULL;
|
mo->standingslope = NULL;
|
||||||
else if (!onground)
|
else if (!onground)
|
||||||
{
|
{
|
||||||
CONS_Printf("%s PlayerZMovement launch %d ", player_names[mo->player-players], mo->momz);
|
// CONS_Printf("%s PlayerZMovement launch %d ", player_names[mo->player-players], mo->momz);
|
||||||
P_SlopeLaunch(mo);
|
P_SlopeLaunch(mo);
|
||||||
CONS_Printf("%d\n", mo->momz);
|
// CONS_Printf("%d\n", mo->momz);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue