Right-click hold while camera follows avatar: orbit the avatar and turn it to face the camera #862

Closed
opened 2026-10-19 08:17:23 +00:00 by sky_line · 1 comment
Owner

Hold-right-click orbit around the avatar when the camera is following it.

Scenario

  • Third-person shooter camera (SlipstreamTPSCamera) is off.
  • The camera is in its normal follow state, focused on the avatar (e.g. after pressing Escape / reset view).
  • The user holds right-click (the hold trigger from #861).

Behaviour

  • The camera enters orbit mode centred on the avatar, not on the point under the cursor.
  • While right-click is held:
    • The mouse is captured: cursor hidden, and mouse movement orbits the camera around the avatar (yaw + pitch).
    • The avatar turns to face the camera's heading, as with the TPS camera's "Avatar faces camera direction" (SlipstreamTPSFaceCamera). Walking with WASD then moves the avatar in the direction the camera looks.
  • On release:
    • The cursor comes back where the press started.
    • The camera stays at its new angle behind the avatar and keeps following.
  • When the camera is not following the avatar (it has been moved or focused on something else), holding right-click keeps the #861 behaviour: orbit around the clicked point.
  • A quick right-click (under the hold threshold) still opens the context menu.
  • Mouselook, avatar customize and TPS camera on: unchanged.

Implementation notes

  • Branch in LLToolPie::handleRightMouseDown / the #861 hold path on gAgentCamera.getFocusOnAvatar() (and camera mode FOLLOW/third person).
  • Reuse the avatar-turning logic from sltpscamera.cpp (face-camera yaw) instead of duplicating it. Only drive it while the hold is active.
  • Mouse capture/hide and cursor restore on release follow the existing endRightOrbit() path.

Acceptance

  • From a reset/following camera, holding right-click and moving the mouse orbits around the avatar, and the avatar turns to match the camera heading.
  • WASD while held moves relative to the camera heading.
  • Releasing restores the cursor and leaves the camera behind the avatar at the new angle.
  • With the camera focused elsewhere, the hold orbits the clicked point (#861).
  • A quick click still opens the context menu.

Depends on #861 (hold-to-orbit trigger).

Hold-right-click orbit around **the avatar** when the camera is following it. ## Scenario - Third-person shooter camera (`SlipstreamTPSCamera`) is **off**. - The camera is in its normal follow state, focused on the avatar (e.g. after pressing Escape / reset view). - The user holds right-click (the hold trigger from #861). ## Behaviour - The camera enters orbit mode **centred on the avatar**, not on the point under the cursor. - While right-click is held: - The mouse is **captured**: cursor hidden, and mouse movement orbits the camera around the avatar (yaw + pitch). - The **avatar turns to face the camera's heading**, as with the TPS camera's "Avatar faces camera direction" (`SlipstreamTPSFaceCamera`). Walking with WASD then moves the avatar in the direction the camera looks. - On release: - The cursor comes back where the press started. - The camera stays at its new angle behind the avatar and keeps following. - When the camera is **not** following the avatar (it has been moved or focused on something else), holding right-click keeps the #861 behaviour: orbit around the clicked point. - A quick right-click (under the hold threshold) still opens the context menu. - Mouselook, avatar customize and TPS camera on: unchanged. ## Implementation notes - Branch in `LLToolPie::handleRightMouseDown` / the #861 hold path on `gAgentCamera.getFocusOnAvatar()` (and camera mode FOLLOW/third person). - Reuse the avatar-turning logic from sltpscamera.cpp (face-camera yaw) instead of duplicating it. Only drive it while the hold is active. - Mouse capture/hide and cursor restore on release follow the existing `endRightOrbit()` path. ## Acceptance - From a reset/following camera, holding right-click and moving the mouse orbits around the avatar, and the avatar turns to match the camera heading. - WASD while held moves relative to the camera heading. - Releasing restores the cursor and leaves the camera behind the avatar at the new angle. - With the camera focused elsewhere, the hold orbits the clicked point (#861). - A quick click still opens the context menu. Depends on #861 (hold-to-orbit trigger).
sky_line added this to the Slipstream project 2026-10-19 08:17:23 +00:00
Author
Owner

Fixed in 1.4.1 (754995a643). Reopen if you still see it.

Fixed in 1.4.1 (754995a643). Reopen if you still see it.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
sky_line/Slipstream#862
No description provided.