Current date and time?
by Alexandre Ribeiro de Sa · in Torque Game Builder · 05/19/2007 (11:14 pm) · 4 replies
Hi, there any way to get the current day and time with TGB Script?
Thanks
Thanks
About the author
now with an iPod :D
#2
07/02/2007 (2:55 pm)
Unfortunately, system epoch is, most of the time (depending on the computer), the boot time. So, no, there's no way to know the currant time with only script.
#3
Might want to verify that though.
07/02/2007 (5:59 pm)
I was pretty sure that getRealTime get's the time in seconds since the epoch ... not the boot ... epoch being like 1/1/1970 or whatever it was ... Might want to verify that though.
#4
07/03/2007 (2:00 pm)
If you have the source, there's a fairly simple fix you can add to the engine to make the full date accessible. Alternately, you can get the time from a server with a TCP object. Both methods are at: www.garagegames.com/mg/forums/result.thread.php?qt=30391
Associate David Higgins
DPHCoders.com
I believe there are a few resources that return strings and other such values you can use for display though ... however, I think they are C++ resources and require Pro licensing.