jatl8
|
  |
| Joined: 07 Aug 2009 |
| Total Posts: 17439 |
|
|
| 06 Dec 2013 10:46 PM |
Ok so I want this GUI to show the time of Lighting. I dont want it to show like this though:
XX:XX:XX
I want it to show it like this
XX:XX
And if its possible to be 12 hrs. not 24.
The script of the GUI is this:
local GUI = script.Parent
while true do GUI.Text = game.Lighting.TimeOfDay wait(0.1) end
|
|
|
| Report Abuse |
|
|
|
| 06 Dec 2013 10:50 PM |
If game.Lighting.TimeOfDay == 13 then script.Parent.Text = game.lighting.timeofday - 12 Else
Code End |
|
|
| Report Abuse |
|
|
|
| 06 Dec 2013 10:51 PM |
| Unfortunalty I dunno know how to block out minutes |
|
|
| Report Abuse |
|
|
jatl8
|
  |
| Joined: 07 Aug 2009 |
| Total Posts: 17439 |
|
| |
|
wazap
|
  |
| Joined: 29 Jun 2007 |
| Total Posts: 23234 |
|
|
| 07 Dec 2013 12:07 AM |
So many problems with night's script
local GUI = script.Parent
while true do if tonumber(game.Lighting.TimeOfDay:sub(1,2))> 12 then GUI.Text = tonumber(game.Lighting.TimeOfDay:sub(1,2))-12..game.Lighting.TimeOfDay:sub(3,5) elseif tonumber(game.Lighting.TimeOfDay:sub(1,2))==0 then GUI.Text = "12"..game.Lighting.TimeOfDay:sub(3,5) else GUI.Text = game.Lighting.TimeOfDay:sub(1,5) end wait(0.1) end |
|
|
| Report Abuse |
|
|
|
| 07 Dec 2013 10:06 PM |
| Sorry, I wrote on mobile, id do more efficiently on cp |
|
|
| Report Abuse |
|
|