MinecraftTransportSimulator
MinecraftTransportSimulator copied to clipboard
sound config
Adding new features to the sound config:
- Randomization of sounds
- Setting the range for sound playback
- Doppler pitch effect switch.
Example: "sounds": [ { "name": "id:shot", "activeAnimations": [...], "forceSound": true, "minDistance": 2, "maxDistance": 32, "dopplerPitch": true, "randomSounds":["id:shot2","id:shot3","id:shot4"] } ]
Good first PR, but a few comments on logic. I can for sure see some good use out of this.
I will update the wiki article about this.
Doppler effect should be opt-out instead of opt-in by the way
Doppler effect should be opt-out instead of opt-in by the way
I mentioned that in the change requests. I gotchu mate.
Without these requirements, the PR will not be approved, do I understand correctly?
You understand incorrectly. See my notes on that requirement.
Once you check the max sound distance, I'm good. I want to make sure that no existing sounds play when you are more than 64 blocks away, since that will confuse PAs who had their sounds play that far previously. Horns and sirens and engines are the ones I would check.
Alternately, you could just check if both are 0, and if so, ignore distance entirely. TBH, that's a bit cleaner since it won't cause a new JSON parameter in every JSON. But I'm not married to the idea so I won't force you to do that.