Ladder Entity - CE3.4 (deprecated)

Obsolete Documentation

This documentation is from CRYENGINE 3.4.x or earlier. See current documentation here: Ladder

Overview

The ladder entity is a usable object type which allows the character to climb up or down it. While using the ladder, the player can control whether he wants to move upwards or downwards by pressing up/down on the keyboard or controller. The ladder object can have different lengths.

The ladder entity can be found in Rollup Bar -> Entity -> Ladders

Ladder Properties

Property

Description

Model

The ladder model object file (Examples are in objects/structures/ladders/).

SmartObjectClass

Should be "Ladder".

UseDistance

How far away can the player be to be able to trigger the ladder climb.

Ladder Asset Requirements

The ladder object needs to fulfill certain requirements in order to work with the ladder system. Please see the Ladders tutorial for information on creating ladders for CryENGINE.

Animation Setup

While on the ladder, the code updates and advances the character's animation manually, in order to fit it to the desired movement (when the user presses on the keyboard or the controller). This requires a special setup in the animation graph.

The AnimationGraph shipping with CryENGINE 3 SDK has this set up, please see there for reference. Or see the Animation Graph Tutorial 4 - Ladder Climbing on how to create the basic setup.

Debugging Ladders

pl_ladder_animOffset

The console variable pl_ladder_animOffset allows you to specify and offset on the calculation of the animation time based on the position of the player. This let's you adjust the character on the object so that his hands are actually on the ladder.

Note that it only makes sense to use values from -1...1

It is also important that you put your changes into the CVars default value once you are satisfied with the results.

pl_debug_ladders

The console variable pl_debug_ladders 1 will give you some additional information if you are currently climbing on a ladder.

If you enable the debug output while in First Person view, the view will switch to a third person one to enable you to see the debug items on screen.

The character's head in this view is missing, this is intentional, so the camera doesn't clip in first person while the character is on the ladder.

This hiding of the head is done in the player.lua script (search for "ladder" if you need to change this).