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 bug when loading models on child entities of controllers #5415

Merged
merged 1 commit into from
Dec 17, 2023

Conversation

mrxz
Copy link
Contributor

@mrxz mrxz commented Dec 17, 2023

Description:
The various controls components handle the model-loaded event to configure the controller models. However, they don't check where the model-loaded event originates from. In case a child entity loads a model, the controls components would incorrectly assume it's the controller model that just loaded in.

This actually causes issues in A-Painter where the model-loaded event of the brush-tip would trigger the onModelLoaded for the oculus-touch-controls (and others).

Changes proposed:

  • Include a guard in onModelLoaded checking that the event didn't originate from any child element

@dmarcos
Copy link
Member

dmarcos commented Dec 17, 2023

Thanks!

@dmarcos dmarcos merged commit e0f0372 into aframevr:master Dec 17, 2023
1 check passed
Elettrotecnica pushed a commit to Elettrotecnica/a-painter that referenced this pull request Mar 22, 2024
Elettrotecnica pushed a commit to Elettrotecnica/a-painter that referenced this pull request Mar 24, 2024
Elettrotecnica added a commit to Elettrotecnica/a-painter that referenced this pull request Mar 25, 2024
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