Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions EXILED/Exiled.API/Features/Roles/FpcRole.cs
Original file line number Diff line number Diff line change
Expand Up @@ -313,5 +313,15 @@ public void ResetStamina(bool multipliers = false)
StaminaUsageMultiplier = 1f;
StaminaRegenMultiplier = 1f;
}

/// <summary>
/// Makes the player jump using the default or a specified strength.
/// </summary>
/// <param name="jumpStrength">Optional. The strength of the jump. If not provided, the default jump speed for Role is used.</param>
public void Jump(float? jumpStrength = null)
{
float strength = jumpStrength ?? FirstPersonController.FpcModule.JumpSpeed;
FirstPersonController.FpcModule.Motor.JumpController.ForceJump(strength);
}
}
}
Loading