var
AccTime = time2text(world.timeofday,"hh:mm:ss")
TimeofDay = ""
world
New()
..()
spawn(5)
Loop()
Update()
proc
Loop()
while(src)
sleep(10)
world.Repop()
Update()
..()
proc
Update()
while(src)
sleep(5)
AccTime = time2text(world.timeofday,"hh:mm:ss")
..()
area
icon = 'Floor.dmi'
icon_state = "night"
layer = EFFECTS_LAYER
New()
..()
spawn(5)
src.TimeoDay()
src.reboot()
proc
TimeoDay()
spawn(600)
if(AccTime=="4:00:00")
TimeofDay = "Morning"
..()
if(AccTime=="10:00:00")
TimeofDay = "Day"
..()
if(AccTime=="17:00:00")
TimeofDay = "Afternoon"
..()
if(AccTime=="20:00:00")
TimeofDay = "Evening"
..()
if(AccTime=="0:00:00")
TimeofDay = "Night"
..()
spawn(5)
src.reboot()
reboot()
spawn(5)
src.TimeoDay()
ok, so a couple of days ago, i realized how to create an effect(i note i didn't include all of the code, just what was directly imperative to the problem) on the world that it is night, and later that day, i had perfected turning it from day to night.
unfortunately that's where my good luck stopped.
As soon as i tried adding more 'Times of Day'(such as Morning, Afternoon, and Evening) the proc i used stopped working like it did.
originally the code called for the time having to be between certain hours of of the day, by using world.timeofday("hh:mm:ss") as a reference every minute.
i then switched it so that it was a one off at the time that it would change, nothing
then, to fix a slight error i saw in having it every minute, i changed it to update every second[spawn(10)], still didn't work
this is frustrating me to no end. None of my friends that code know any ideas to help, so i went to the one place i knew where a bunch of coders could provide some insight onto my headache