Skip to content

feat: sdk trigger area#5244

Merged
pravusjif merged 48 commits into
devfrom
feat/sdk-trigger-area
Sep 29, 2025
Merged

feat: sdk trigger area#5244
pravusjif merged 48 commits into
devfrom
feat/sdk-trigger-area

Conversation

@pravusjif

@pravusjif pravusjif commented Sep 2, 2025

Copy link
Copy Markdown
Member

Related PRs:

WHY

We need support for the new TriggerArea and TriggerAreaResult components from the protocol, to be able to expose through the SDK interface the ability to use Unity's Trigger Colliders to detect OnEnter/OnStay/OnExit of scene Entities (and players) based on the SDK ColliderLayer layermask.

WHAT

  • Refactored the existent CharacterTriggerArea plugin and logic (previously used only for CameraModeArea and AvatarModifierArea components handling) into the new SDKEntityTriggerArea to:
    • Implemented support for setting the collider used as Sphere or Box (previously only Box)
    • Implemented support for setting the SDK Layermask wanted
    • Allow detecting sdk entities also, instead of just player avatars (kept the AllAvatars physics layer as an optimization to use that one on SDKEntityTriggerArea that only care for player avatars
    • The Prefab now holds both BoxCollider and SphereCollider disabled and enables the one it needs
  • Implemented new TriggerAreaHandlerSystem for the new SDK component

TEST TINSTRUCTIONS

  1. Download the build from this PR and use it to enter pravus.dcl.eth world
  2. Approach the leftmost clickable cube and test that by clicking it you move the small cube in and out of the transparent TriggerArea -> confirm that the transparent TriggerArea color DOESN'T CHANGE
  3. Then approach the rightmost clickable cube and confirm that when you click it, the monster is moved in and out of the transparent TriggerArea -> confirm that the TriggerArea color changes every time the monster enters/exits the area (sometimes it looks like it doesn't change because the randomized color ir very similar to the previous one, keep clicking to test more than once to confirm)
  4. Then move the player in and out of the transparent TriggerArea and confirm that the area color also changes when entering and exiting
  5. Approach the clickable SPHERE and click it to spawn a semi-transparent sphere at the top of it, that will fall with physics and disappear when it touches the clickable sphere -> confirm that the falling sphere disappears
Screen.Recording.2025-09-24.at.1.53.59.PM.mp4

@pravusjif pravusjif added force-build Used to trigger a build on draft PR and removed force-build Used to trigger a build on draft PR labels Sep 18, 2025
@pravusjif
pravusjif removed the request for review from NickKhalow September 24, 2025 14:29

@mikhail-dcl mikhail-dcl left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Everything looks good. I simply have minor requests

Comment thread Explorer/Assets/DCL/SDKComponents/TriggerArea/Systems/TriggerAreaHandlerSystem.cs Outdated
Comment thread Explorer/Assets/DCL/SDKEntityTriggerArea/SDKEntityTriggerArea.cs Outdated
Comment thread Explorer/Assets/DCL/SDKEntityTriggerArea/SDKEntityTriggerArea.cs Outdated
@mikhail-dcl
mikhail-dcl self-requested a review September 25, 2025 12:50
@pravusjif pravusjif moved this from In Progress to With QA / Awaiting Review in Explorer Alpha Sep 28, 2025
@pravusjif
pravusjif removed the request for review from Ludmilafantaniella September 28, 2025 16:17
@pravusjif

Copy link
Copy Markdown
Member Author

I'll update the protocol package to point to the latest experimental package once I have the changes in that other repo merged.

@DafGreco DafGreco left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

✔️ PR reviewed and approved by QA on both platforms following instructions playing both happy and un-happy path

Regressions for this ticket had been performed in order to verify that the normal flow is working as expected:

  • [✔️ ] Backpack and wearables in world
  • [✔️ ] Emotes in world and in backpack
  • [✔️ ] Teleport with map/coordinates/Jump In
  • [ ✔️] Chat and multiplayer
  • [✔️ ] Profile card
  • [✔️ ] Camera
  • [✔️ ] Skybox

Evidence of windows and macos :

20250929-0835-23.0295037.mp4
20250929-0837-41.1452312.mp4

Macos evidence

@github-project-automation github-project-automation Bot moved this from With QA / Awaiting Review to In Progress in Explorer Alpha Sep 29, 2025
@pravusjif pravusjif moved this from In Progress to With QA / Awaiting Review in Explorer Alpha Sep 29, 2025
@pravusjif
pravusjif enabled auto-merge (squash) September 29, 2025 20:43
@pravusjif
pravusjif merged commit 00fa48f into dev Sep 29, 2025
5 checks passed
@pravusjif
pravusjif deleted the feat/sdk-trigger-area branch September 29, 2025 21:15
@github-project-automation github-project-automation Bot moved this from With QA / Awaiting Review to Done in Explorer Alpha Sep 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants