Skip to content

Commit 9c15ebc

Browse files
rui914sfan5
authored andcommittedMar 29, 2015
Add max_hear_distance for fire
1 parent 525f467 commit 9c15ebc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

Diff for: ‎mods/fire/init.lua

+2-2
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ function fire.update_sounds_around(pos)
6363
if not sound then
6464
if should_have_sound then
6565
fire.sounds[p0_hash] = {
66-
handle = minetest.sound_play(wanted_sound, {pos=cp, loop=true}),
66+
handle = minetest.sound_play(wanted_sound, {pos=cp, max_hear_distance = 16, loop=true}),
6767
name = wanted_sound.name,
6868
}
6969
end
@@ -74,7 +74,7 @@ function fire.update_sounds_around(pos)
7474
elseif sound.name ~= wanted_sound.name then
7575
minetest.sound_stop(sound.handle)
7676
fire.sounds[p0_hash] = {
77-
handle = minetest.sound_play(wanted_sound, {pos=cp, loop=true}),
77+
handle = minetest.sound_play(wanted_sound, {pos=cp, max_hear_distance = 16, loop=true}),
7878
name = wanted_sound.name,
7979
}
8080
end

0 commit comments

Comments
 (0)
Please sign in to comment.