mirror of
https://codeberg.org/tenplus1/ambience.git
synced 2025-07-07 19:00:45 +02:00
nil check in after()
This commit is contained in:
5
init.lua
5
init.lua
@ -119,7 +119,10 @@ local get_ambience = function(player, tod, name)
|
||||
|
||||
-- reset music timer after 10 minutes
|
||||
minetest.after(60 * 10, function(name)
|
||||
playing[name].music = -1
|
||||
|
||||
if playing[name] then
|
||||
playing[name].music = -1
|
||||
end
|
||||
end, name)
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user