From ab58736efb04ea76497e02af45651d22d15d6e66 Mon Sep 17 00:00:00 2001 From: tankefugl Date: Tue, 16 May 2006 21:29:27 +0000 Subject: [PATCH] o Fixed bug that would cause charge to pushback only towards west. o Minor charge tweaks. git-svn-id: https://unknownworlds.svn.cloudforge.com/ns1@488 67975925-1194-0748-b3d5-c16f83f1a3a1 --- releases/3.2.0/source/mod/AvHPlayer.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/releases/3.2.0/source/mod/AvHPlayer.cpp b/releases/3.2.0/source/mod/AvHPlayer.cpp index 737710a4..d2af9fe5 100644 --- a/releases/3.2.0/source/mod/AvHPlayer.cpp +++ b/releases/3.2.0/source/mod/AvHPlayer.cpp @@ -6833,15 +6833,17 @@ void AvHPlayer::InternalMovementThink() float dot = DotProduct(heading, direction); if (dot > 0.0f) { - direction[0] = 50; VectorScale(direction, factor * dot, direction); VectorAdd(theEntity->pev->velocity, direction, theEntity->pev->velocity); + theEntity->pev->velocity[2] = max(181, theEntity->pev->velocity[2]); if (Length(theEntity->pev->velocity) > theEntity->pev->maxspeed * maxpushbackspeedfactor) { VectorNormalize(theEntity->pev->velocity); VectorScale(theEntity->pev->velocity, theEntity->pev->maxspeed * maxpushbackspeedfactor, theEntity->pev->velocity); } } + + // ALERT(at_console, UTIL_VarArgs("direction %f %f %f heading %f %f %f endvel %f %f %f\n", direction[0], direction[1], direction[2], heading[0], heading[1], heading[2], theEntity->pev->velocity[0], theEntity->pev->velocity[1], theEntity->pev->velocity[2])); } } }