Here is probably the culprit :
Code: Select all
function MAJ()
local r,g,b = castle_arena_sky_1.light:getColor()
for i =1,100 do
local entity = findEntity("lumieres_fenetre_minimal_save_state_"..i)
if entity ~= nil then entity.light:setColor(r,g,b) end
end
end
Is the findEntity function efficient ? Or should I copy/paste
Code: Select all
lumieres_fenetre_minimal_save_state_1.light:setColor(r,g,b)