i am made this code that would make instant time guis but every single time this happens *I get no errors *JUST NOT WORKING??
function module.create_time_gui(env)
local main = Instance.new('TextLabel',env)
--Layout code
main.Size = UDim2.new(0, 115,0, 41)
main.Position = UDim2.new(1, -160,1, -44)
main.TextColor3 = Color3.new(1, 1, 1)
main.BackgroundTransparency = 1
main.TextScaled = true
main.Font = Enum.Font.Ubuntu
--Time code
while wait() do
local main_data = os.date("*t")
main.Text = (main_data.hour..':'..main_data.min)
end
return(main)
end
what did i do wrong with my code?

3 comments
Seems to not work
It is stuck at 1 time and only one time
I'll try fixing it!