My journey becoming a Unity game developer: 2.5D Infinite Runner-Ledge Grab System-Pt4

Player Grab Ledge and Stand Up to their Standing Idle animation.
Climbing animation Root Transform is Baked into Pose.
Climbing animation added to the Animator with a ClimbUp trigger created.
Hanging Idle to Climbing transition created.
Climbing to Standing Idle transition created.
Turned off the Player’s ability to run or jump as they hang on the ledge.
Player goes from Hanging Idle to Climbing Up animation, but loses their position.
OnLedge variable created to allow the Climb Up animation.
Player climbs up onto the ledge when the ‘E’ key is pressed.
Active ledge variable is set to equal the Current Ledge the player is on.
GetStandPos() method created to return the standing position game object.
ClimbUpComplete() method created for when the player finishes the climb up animation.
Climb Up Behavior script created from the Climb Up animation state.
ClimbUpComplete() method used in OnStateExit() method for when the player climbs to the top of the ledge.
Stand Position game object created and positioned for the player to stand on after climbing up.
Player climbs up to the Stand Position object, but their position changes when standing on their spot.
Exit Time and Transition Duration set to zero so the player stands in position immediately.
Player standing up in Idle animation and ready to go.
Duplicated Ledge Checker object and positioned it in a reverse angle along the platform ledge.
Being able to grab a ledge from either direction the player is facing.
Player’s hands 0.3f meters away from the ledge.
Changed the Player’s hands position to 0.05f meters away from the ledge.
Player’s hands 0.05f meters away from the ledge.
Ledge Checker object and children objects turned off.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store