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

self removing of sub elements component #27

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Tiska
Copy link

@Tiska Tiska commented Nov 6, 2017

When the environment is removed, shouldn't we remove the sub elements from the scene ?

I try to remove the environment to set another sky in my scene, but i still have some content on my scene even after removing this sub elements (for example with the forest, i have a still have a green sky).

@vincentfretin
Copy link
Contributor

@Tiska you should remove the generated files from your PR.

@Tiska
Copy link
Author

Tiska commented Nov 13, 2017

Done ! Have you an idea about the sky color that stays after removing the component from the scene ?

@vincentfretin
Copy link
Contributor

I forgot about this PR.
In my current project I'm doing

sceneEl.removeAttribute("environment");
sceneEl.querySelectorAll(".environment").forEach((e) => e.remove());

that is similar.
Note in this PR, stars mesh, geometry, material are not properly disposed, only the entity is removed.

@vincentfretin
Copy link
Contributor

More complete version in #94

@vincentfretin
Copy link
Contributor

@dmarcos please close this one.

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.

None yet

2 participants