Skip to content

Fix setElementModel resets goggle effect #3521

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

Merged
merged 4 commits into from
Jun 30, 2024

Conversation

Proxy-99
Copy link
Contributor

Fixes #2441

@tederis
Copy link
Member

tederis commented Jun 29, 2024

This PR doesn't take into account a possibility of manual goggle effects change. For example, a player may put nightvision goggles on, then execute setCameraGoggleEffect("nightvision", false), change a model and it will give a nightvision effect with the noise enabled, although there should be an effect without any noise.

@Proxy-99
Copy link
Contributor Author

Proxy-99 commented Jun 29, 2024

This PR doesn't take into account a possibility of manual goggle effects change. For example, a player may wear nightvision goggles up, then execute setCameraGoggleEffect("nightvision", false), change a model and it will give a nightvision effect with the noise enabled, although there should be an effect without any noise.

I think if we already have the effect enabled there is no need to play the sound again so should all of them be false
see this sound played once
https://youtu.be/-45qz-iUuJI?si=W7YIFVIKv4h5pX4w

@Proxy-99 Proxy-99 requested a review from FileEX June 29, 2024 08:40
@tederis tederis added the bugfix Solution to a bug of any kind label Jun 29, 2024
@Dutchman101 Dutchman101 merged commit 1dd2914 into multitheftauto:master Jun 30, 2024
6 checks passed
@botder botder added this to the 1.6.1 milestone Jun 30, 2024
MTABot pushed a commit that referenced this pull request Jun 30, 2024
1dd2914 Fix setElementModel resets goggle effect (#3521)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix Solution to a bug of any kind
Projects
None yet
Development

Successfully merging this pull request may close these issues.

setElementModel resets goggle effect
5 participants