forked from your-land/yl_cinema
your-land/bugtracker#5187 Missing entity properties no longer lead to crash.
This commit is contained in:
parent
5f5c73e11f
commit
66bbc45a45
@ -19,8 +19,5 @@ yl_cinema.settings.enable_craft_bigscreen_recipe = minetest.settings:get("yl_cin
|
||||
yl_cinema.settings.enable_craft_flatscreen_recipe = minetest.settings:get("yl_cinema.enable_craft_flatscreen_recipe") or
|
||||
"wool:grey,wool:grey,wool:grey,wool:grey,wool:grey,wool:grey,wool:black,,wool:black"
|
||||
|
||||
--yl_cinema.settings.enable_craft_moviereel_recipe = minetest.settings:get("yl_cinema.enable_craft_moviereel_recipe") or
|
||||
--"default:steel_ingot,cottages:wagon_wheel,default:steel_ingot,default:mese_crystal_fragment,basic_materials:empty_spool,default:paper,default:steel_ingot,cottages:wagon_wheel,default:steel_ingot"
|
||||
|
||||
yl_cinema.settings.enable_craft_moviereel_recipe = minetest.settings:get("yl_cinema.enable_craft_moviereel_recipe") or
|
||||
"wool:grey,wool:grey,wool:grey,wool:grey,wool:grey,wool:grey,wool:black,,wool:green"
|
||||
"default:steel_ingot,cottages:wagon_wheel,default:steel_ingot,default:mese_crystal_fragment,basic_materials:empty_spool,default:paper,default:steel_ingot,cottages:wagon_wheel,default:steel_ingot"
|
@ -99,6 +99,10 @@ local function showpage(ent_obj, movie_id, pagenum)
|
||||
end
|
||||
|
||||
local ent_properties = ent_obj:get_properties()
|
||||
if not ent_properties then
|
||||
warn("Cinema Screen Properties not found, movie_id=" .. dump(movie_id))
|
||||
return ""
|
||||
end
|
||||
if ent_properties._playing == true then
|
||||
warn("Tried to play movie on running projector, movie_id=" .. dump(movie_id))
|
||||
return ""
|
||||
|
Loading…
Reference in New Issue
Block a user