Jumpvalley 0.5.0
An app and library that can be used to test and run 3D platformer levels. Currently being made with Godot.
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Properties | Events | List of all members
Jumpvalley.Players.Movement.Climber Class Reference

Allows a character to climb objects. Specifically, these objects are PhysicsBody3Ds A PhysicsBody3D can be climbed if it has a boolean metadata entry named "is_climbable" that's set to true. More...

Inheritance diagram for Jumpvalley.Players.Movement.Climber:

Public Member Functions

 Climber (CollisionShape3D hitbox)
 Creates a new instance of Climber
 
new void Dispose ()
 Disposes of this Climber object and the RayCast3D instance being used to power it.
 
override void _PhysicsProcess (double delta)
 

Static Public Member Functions

static bool IsClimbable (GodotObject obj)
 Returns whether or not the given GodotObject can be climbed.
 

Public Attributes

float HitboxWidth = 0.25f
 The width of the climbing hitbox. This length is parallel to the x-axis that's relative to the position and rotation of the character's hitbox.
 
float HitboxDepth = 0.2f
 The depth of the climbing hitbox. This length is parallel to the z-axis that's relative to the position and rotation of the character's hitbox.
 

Static Public Attributes

static readonly string IS_CLIMBABLE_METADATA_NAME = "is_climbable"
 Name of the metadata entry that specifies whether or not a PhysicsBody3D is climbable.
 

Protected Member Functions

void RaiseOnCanClimbChanged (bool canClimb)
 

Properties

Area3D Area [get]
 The Area3D that allows the character to climb when a climbable PhysicsBody3D is intersecting with it.
 
bool CanClimb [get]
 Whether or not the character is able to climb because the raycast has hit a climbable PhysicsBody3D
 
Vector3 RaycastCollisionPoint = Vector3.Zero [get]
 The most recent collison point where the Climber's raycast hit a climbable PhysicsBody3D. When a Climber object is first instantiated, this is set to Vector3.Zero.
Whatever Vector3 this variable is set to should be accurate as long as CanClimb is true.
 
PhysicsBody3D CurrentlyClimbedObject = null [get]
 The PhysicsBody3D that's currently being climbed. This is set to null if we aren't climbing anything currently.
 
CollisionShape3D Hitbox [get, set]
 The character's hitbox that this Climber is associated with.
 

Events

EventHandler< bool > OnCanClimbChanged
 Event that's raised when the value of CanClimb changes. The 2nd argument for this event is a boolean that's set to the new value of CanClimb.
 

Detailed Description

Allows a character to climb objects. Specifically, these objects are PhysicsBody3Ds A PhysicsBody3D can be climbed if it has a boolean metadata entry named "is_climbable" that's set to true.

Member Function Documentation

◆ IsClimbable()

static bool Jumpvalley.Players.Movement.Climber.IsClimbable ( GodotObject obj)
inlinestatic

Returns whether or not the given GodotObject can be climbed.

Parameters
objThe node to check
Returns

The documentation for this class was generated from the following file: