Skip to content

Commit

Permalink
Head Leaning Implementation
Browse files Browse the repository at this point in the history
Split SlideMove mainloop, first one moves body based upon control input,
second loop tries to move the body to the head, then clamps the head
distance from the body, and finally checks for head colliding with
environment outside of body paremeter.
  • Loading branch information
Codes4Fun committed Dec 7, 2016
1 parent ef84aa7 commit 65b7895
Show file tree
Hide file tree
Showing 3 changed files with 294 additions and 32 deletions.
2 changes: 1 addition & 1 deletion neo/d3xp/Player.cpp
Expand Up @@ -10995,7 +10995,7 @@ idVec3 idPlayer::GetEyePosition() const
{
org = GetPhysics()->GetOrigin();
}
return org + ( GetPhysics()->GetGravityNormal() * -eyeOffset.z );
return org + ( GetPhysics()->GetGravityNormal() * -eyeOffset.z ) + physicsObj.GetHeadOffset();
}

/*
Expand Down

0 comments on commit 65b7895

Please sign in to comment.