I have this function towards the top of my script.
function maps() for i,v in ipairs(game.Lighting.Maps:GetChildren()) do wait(1) return i end end
I currently have a group in Lighting called 'Maps'. I have 2 maps in the Map group.
A little way down the script I have this now,
local Num = math.random(1,maps())
wait(3)
message("Welcome to Speed Runner! | V"..ver.." | Game Setting Up...",5)
message("Maps Loaded: "..maps().."",2)
message("Choosing Map",3)
(I have a message function at the top but that's not the problem.)
In the center the "Maps Loaded:" only says one. I can't get it to say two although I have 2 maps in lighting. What I don't understand is why is the function maps() only returning 1 map? Is there a way around this? It's probably an easy fix but for the life of me I cant figure this out.
