Skip to content

fix: crouched and standing still the hero kneels like at a chest - camera at the kneel pose's eyes (1.08 m × scale) - #553

Open
BoroBongo wants to merge 4 commits into
developfrom
fix/crouch-low-when-still
Open

BoroBongo wants to merge 4 commits into
developfrom
fix/crouch-low-when-still

Conversation

@BoroBongo

@BoroBongo BoroBongo commented Nov 22, 2026 •

Copy link
Copy Markdown
Contributor

What

Crouched and standing still for 1 s, the VR hero kneels like at a chest in Gothic (S_CHESTSMALL_S0, G1 and G2 HUMANS.MDS). The camera goes down to the kneel pose's eyes. Moving with the thumbstick sneaks again at once (after 0.15 s of continuous movement; sneak pose, camera back up). Head movement doesn't count: the body capsule follows the head by its center, without moving. The 0.15 s keep a short push of the capsule from ending the kneel, e.g. when you lean your head into the chest. Bodies without the kneel animation keep sneaking.

pose eyes at body scale 1 camera at 1.66 m eye height (scale 0.96)
standing (S_RUN) 1.71 m 1.66 m
sneaking (S_SNEAK) 1.40 m ~1.35 m
kneeling (S_CHESTSMALL_S0) 1.08 m 1.04 m

The body keeps its size, and its feet/knee stay on the floor, because the camera sits at the eyes of the pose it plays. The switch between poses is the animator's crossfade (0.2 s); the camera moves at the rig's crouch speed (1.5 m/s, about 0.2 s for the 0.3 m).

  • VrHeroLocomotion: KneelAnimation/SneakAnimation, IsMoving; crouched and not moving plays the kneel pose when isKneeling.
  • VRHeroBody: UpdateKneeling (1 s still while crouched; while kneeling, 0.15 s of continuous movement end it; logs the transitions), MeasureEyeHeight per pose (sneak and kneel, once per built body), UpdateCrouchHeight picks the pose's eyes.

Why

Playtest (G2, PCVR build from develop): only the first crouch after building/loading the body went low (the rig's 0.7 m). Once S_SNEAK was measured, the camera rose to a half crouch (1.41 m × scale), and chest locks needed a real crouch (also in sitting mode). That height is right for sneaking, which is a shallow bend in Gothic. It came from the #476 review: camera at the body's pose, so the feet stay on the floor.

In the original, the hero kneels on one knee at a chest (screenshot in the comments).

Checked in the Editor (G2, save 2, XRI Device Simulator, crouch toggled): Sneak pose (S_SNEAK): eyes 1.41 m, after 1 s Crouched and still - the hero kneels., Kneel pose (S_CHESTSMALL_S0): eyes 1.08 m, camera 1.036 m at scale 0.958. The poses' eye heights were also computed from the .MAN files for G1 and G2 (S_SNEAK 1.40, S_CHESTSMALL_S0 1.08, S_CHESTBIG_S0 1.12, S_PRAY 1.16).

How to test manually

  • VR (G1 or G2), press crouch and stand still: the hero sneaks, and after ~1 s kneels. The camera goes down to about knee-on-the-floor height. Looking down shows the kneeling body, full size, on the floor.
  • Kneeling, move with the stick: at once back to sneaking, camera up to the sneak height.
  • Kneeling, turn/lean your head (also into the chest): the hero keeps kneeling.
  • Kneel in front of a locked chest: key/lock pick reach the lock without crouching for real.
  • Release crouch: back to standing.
  • Sitting mode: same.
  • Log: [VRHeroBody] Kneel pose (S_CHESTSMALL_S0): eyes 1.08 m ... once per body, Crouched and still - the hero kneels. / Crouch ended or moving ... on changes.

Save/load

No new state. A loaded game rebuilds the body; both poses are measured again on first use.

Known gaps / follow-ups

  • The first kneel of a body goes to the sneak height first and then down, as it measures the pose when it plays. Same for the first sneak (from the rig's 0.7 m).
  • No kneel-down transition animation (T_CHESTSMALL_STAND_2_S0), only the crossfade.

…neeling at a chest), moving takes it back to the sneak pose - the body shrinks so its feet stay on the floor

The crouch button took the camera to the eyes of the sneak pose (S_SNEAK, 1.41 m at scale 1): only the first crouch of a body reached the rig's 0.7 m, then the camera rose to a half crouch and chest locks needed a real crouch (also in sitting mode). Now crouched and still for 0.3 s the camera goes to the rig's crouch height, moving takes it back to the sneak pose's eyes. Lower than the sneak pose (also the player's own head held low) the body gets smaller instead of pushing its feet into the floor.
@BoroBongo

Copy link
Copy Markdown
Contributor Author
image

…othic - the camera goes down to the kneel pose's eyes without shrinking the body

Replaces the shrinking of the previous commit: crouched and still for 0.3 s the body plays S_CHESTSMALL_S0 (the hero's kneel at a chest, G1 and G2) and the camera goes to its eyes, 1.08 m at scale 1 (sneak pose: 1.40 m). Moving goes back to the sneak pose. Bodies without the kneel animation sneak.
@BoroBongo BoroBongo changed the title fix: crouching while still takes the camera down to 0.7 m, moving back to the sneak pose fix: crouched and standing still the hero kneels like at a chest - camera at the kneel pose's eyes (1.08 m × scale) Nov 22, 2026
…s after 0.15 s of real movement (the thumbstick), so leaning the head into a chest doesn't take the camera up at its lock
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant