Skip to content

fix(InterestManagementBase): Hide WorldSpace Canvas in SetHostVisibility - #4005

Merged
miwarnec merged 2 commits into
masterfrom
SetHostVisibilityCanvas
Apr 5, 2025
Merged

fix(InterestManagementBase): Hide WorldSpace Canvas in SetHostVisibility#4005
miwarnec merged 2 commits into
masterfrom
SetHostVisibilityCanvas

Conversation

@MrGadget1024

@MrGadget1024 MrGadget1024 commented Mar 31, 2025

Copy link
Copy Markdown
Collaborator

Tested by adding a world canvas with NI into Additive Levels subscene...works as expected.

Fixes #4003

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull Request Overview

This PR updates the InterestManagementBase by adding logic to hide or show Canvas components along with AudioSource and Terrain components when SetHostVisibility is called.

  • Added iteration over Canvas components in SetHostVisibility to toggle their enabled state.
  • Ensured consistency with similar component toggling logic (AudioSource and Terrain).

@miwarnec

Copy link
Copy Markdown
Collaborator

I don't think AOI should depend on any type of UI system, that's a little bit too much of dependencies

@MrGadget1024

MrGadget1024 commented Mar 31, 2025

Copy link
Copy Markdown
Collaborator Author

I don't think AOI should depend on any type of UI system, that's a little bit too much of dependencies

I just limited it to Canvas with WorldSpace selected, but just like lights and terrain and sounds and particles, UI can definitely exist in each subscene of additive scenes, or be out of range in distance, or be exclusive to team / match IM.

WorldSpace UI could be healthbar or name tags on players too. It woudn't be right to have those floating around attached to nothing because they were on players in a different subscene.

@MrGadget1024

Copy link
Copy Markdown
Collaborator Author

I don't think AOI should depend on any type of UI system, that's a little bit too much of dependencies

Without this PR, the host client sees the WorldSpace scroll view and the other client's name tag that are both in a different subscene in the image below

image

@miwarnec
miwarnec merged commit 5eb3122 into master Apr 5, 2025
@miwarnec
miwarnec deleted the SetHostVisibilityCanvas branch April 5, 2025 11:23
@MrGadget1024 MrGadget1024 changed the title fix(InterestManagementBase): Hide Canvas in SetHostVisibility fix(InterestManagementBase): Hide WorldSpace Canvas in SetHostVisibility Apr 5, 2025
MrGadget1024 added a commit that referenced this pull request Apr 17, 2025
* fix(InterestManagementBase):Hide Canvas in SetHostVisibility
Fixes #4003

* WorldSpace only
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Canvas visible In InterestManagementBase

3 participants