Skip to content

feat: free movement gizmo improvements - #1163

Merged
nicoecheza merged 7 commits into
mainfrom
feat/snap-free-gizmos
Jul 22, 2025
Merged

feat: free movement gizmo improvements#1163
nicoecheza merged 7 commits into
mainfrom
feat/snap-free-gizmos

Conversation

@nicoecheza

@nicoecheza nicoecheza commented Jul 18, 2025

Copy link
Copy Markdown
Member

closes decentraland/creator-hub#323

Changes

🎯 Enhanced Free Gizmo Implementation

  • Visual Indicators: Added cross-shaped gizmo indicator with red and blue sticks for better visibility
  • Improved Centroid Calculation: Enhanced centroid calculation with proper GizmoManager integration
  • Better Drag Behavior: Refactored drag handling with improved snapping and position updates
  • Enhanced State Management: Better state reset and cleanup mechanisms

Testing Instructions

Manual Testing

  1. Free Gizmo Functionality:

    • Select an entity in the scene
    • Switch to Free Gizmo mode
    • Verify the cross-shaped indicator appears at the entity's centroid
    • Drag the entity and verify smooth movement with proper snapping
    • Test with multiple selected entities to verify centroid calculation
  2. Gizmo Switching:

    • Test switching between all gizmo types (Free, Position, Rotation, Scale)
    • Verify proper cleanup and setup of each gizmo type
    • Check that gizmo indicators appear/disappear correctly
  3. Multi-Entity Selection:

    • Select multiple entities
    • Verify centroid calculation works correctly for multiple entities
    • Test dragging multiple entities together
  4. Snapping Behavior:

    • Enable snap settings in the gizmo panel
    • Test free gizmo movement with different snap distances
    • Verify Y position remains unchanged during free movement

Visual Verification

  • Free gizmo should display a cross-shaped indicator with:
    • Red horizontal sticks (X-axis)
    • Blue vertical sticks (Z-axis)
    • Proper depth and visibility settings
  • Indicator should update position when entities are moved
  • No visual artifacts or rendering issues

@nicoecheza
nicoecheza force-pushed the feat/snap-free-gizmos branch 2 times, most recently from 2609687 to fc07d30 Compare July 18, 2025 16:34
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 18, 2025

Copy link
Copy Markdown

Deploying js-sdk-toolchain with  Cloudflare Pages  Cloudflare Pages

Latest commit: f533966
Status: ✅  Deploy successful!
Preview URL: https://d0553ced.js-sdk-toolchain.pages.dev
Branch Preview URL: https://feat-snap-free-gizmos.js-sdk-toolchain.pages.dev

View logs

@github-actions

github-actions Bot commented Jul 18, 2025

Copy link
Copy Markdown
Contributor

Test this pull request

  • The @dcl/sdk package can be tested in scenes by running

    npm install "https://sdk-team-cdn.decentraland.org/@dcl/js-sdk-toolchain/branch/feat/snap-free-gizmos/dcl-sdk-7.8.22-16449543896.commit-4079534.tgz"
  • To test with npx init

    export SDK_COMMANDS="https://sdk-team-cdn.decentraland.org/@dcl/js-sdk-toolchain/branch/feat/snap-free-gizmos/dcl-sdk-commands-7.8.22-16449543896.commit-4079534.tgz"
    npx $SDK_COMMANDS init
  • The @dcl/inspector package can be tested by visiting this url

    • Or by installing it via NPM
    npm install "https://sdk-team-cdn.decentraland.org/@dcl/js-sdk-toolchain/branch/feat/snap-free-gizmos/@dcl/inspector/dcl-inspector-7.8.22-16449543896.commit-4079534.tgz"
  • The /changerealm command to test test in-world

    /changerealm https://sdk-team-cdn.decentraland.org/ipfs/feat/snap-free-gizmos-e2e
    
  • You can preview this build entering:
    https://playground.decentraland.org/?sdk-branch=feat/snap-free-gizmos

@nicoecheza
nicoecheza force-pushed the feat/snap-free-gizmos branch 2 times, most recently from 8c22265 to 5a888cf Compare July 21, 2025 15:19
@nicoecheza
nicoecheza enabled auto-merge (squash) July 21, 2025 16:20
@nicoecheza
nicoecheza force-pushed the feat/snap-free-gizmos branch 2 times, most recently from 42cba95 to ea6f82a Compare July 21, 2025 16:30
@nicoecheza
nicoecheza disabled auto-merge July 21, 2025 18:24
@Ludmilafantaniella
Ludmilafantaniella self-requested a review July 21, 2025 20:32
@nicoecheza
nicoecheza force-pushed the feat/snap-free-gizmos branch from ad8e117 to f533966 Compare July 22, 2025 16:03
@nicoecheza
nicoecheza enabled auto-merge (squash) July 22, 2025 16:04

@cyaiox cyaiox left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀 🚀

@nicoecheza
nicoecheza merged commit a3e1759 into main Jul 22, 2025
9 checks passed
@nicoecheza
nicoecheza deleted the feat/snap-free-gizmos branch July 22, 2025 17:40
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.

[BUG] Inspector: Free Movement Tool behaves inconsistently

2 participants