Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix personal space bubble opacity #3951

Merged
merged 5 commits into from
Feb 24, 2021
Merged

Conversation

robertlong
Copy link
Contributor

This PR fixes a bug where the personal space bubble would set the opacity/transparent property of an already transparent object when leaving it's bounds. It also improves the space bubble so that avatars with multiple meshes will turn transparent when entering their bounds. To do this without turning the ui transparent, I added a new tag ignoreSpaceBubble that can be applied to the root of objects that should not be affected by the space bubble.

Copy link
Contributor

@netpro2k netpro2k left a comment

Choose a reason for hiding this comment

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

lgtm. This has been an issue for far too long, thanks for getting a fix in.

src/hub.html Outdated Show resolved Hide resolved
src/systems/personal-space-bubble.js Outdated Show resolved Hide resolved
@@ -19,7 +19,8 @@ AFRAME.registerComponent("tags", {
isHoverMenuChild: { default: false },
isStatic: { default: false },
inspectable: { default: false },
preventAudioBoost: { default: false }
preventAudioBoost: { default: false },
ignoreSpaceBubble: { default: false }
Copy link
Contributor

Choose a reason for hiding this comment

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

Probably warants thinking through the product implications, so maybe we don't need it in this PR, but wonder if we should expose this to gltfs like

AFRAME.GLTFModelPlus.registerComponent("ignore-space-bubble", "tags", el => {
  el.setAttribute("tags", { ignoreSpaceBubble: true });
});

So people could make things in their avatars that ignore the space bubble effect.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think this could be abused and we probably want to keep it internal. Happy to have a separate discussion about this at a later point though.

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.

2 participants