Whenever I load the game, the map won't load because of this error? I have no idea why, Can someone help me?
Here is the script,
local function set_lighting(mname)
local dolist={"Ambient","ColorShift_Bottom","ColorShift_Top","OutdoorAmbient"}
for i=1, #dolist do
light[dolist[i]]=color(lightset[mname][dolist[i]][1]/255,lightset[mname][dolist[i]][2]/255,lightset[mname][dolist[i]][3]/255)
end
mapname.Value=lightset[mname].Name
end
Here is the error that occurs when I load the game.
20:53:34.461 - ServerScriptService.server:2152: attempt to index field '?' (a nil value)
Any help?

2 comments
The 4th line is cut off a bit, It says this. light[dolist[i]]=color(lightset[mname][dolist[i]][1]/255,lightset[mname][dolist[i]][2]/255,lightset[mname][dolist[i]][3]/255).
this code looks oddly familiar...