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
TNT explosion custom sound #1823
Conversation
This adds the ability to customise explosion sound when using tnt.boom()
Needs documentation: https://github.com/minetest/minetest_game/blob/master/game_api.txt#L290 |
add tnt sound info
Why? None of our other registered items have this ability, and an explosion sound works for all explosions. |
Someone might want different explosion sounds - may it be for fun or to make it more realistic. |
The ability to add a custom sound is easily done here, give modders the option. |
No objection. |
@paramat - would it be find if I added the sound distance fix in here also, to save a new pull ? |
What needs fixing about the sound distance? And yes fine as a separate commit. |
This fixes max_hear_distance so it's not always set to 128, instead it uses radius * 20 with a max of 128 in total.
added missing bracket
👍 but either this should be squashed to 1 or to 2 commits, now it's 4 commits. |
Squash to 1 i think on merge. |
This adds the ability to customise explosion sound when using tnt.boom() which can be used when creating custom tnt or when using other mods directly, it also fixes the 128 node max_hear_distance always being used by calculating the sound distance using the explosion radius.