POV-Ray : Newsgroups : povray.bugreports : Error in datetime (now) ? Server Time
31 Oct 2024 06:14:55 EDT (-0400)
  Error in datetime (now) ? (Message 1 to 3 of 3)  
From: Bald Eagle
Subject: Error in datetime (now) ?
Date: 9 Jan 2017 08:10:01
Message: <web.587389b1b2cdf18dc437ac910@news.povray.org>
I tried using this over the weekend (v3.7), and at 7:37 pm, I got 00:37 as the
output.
I tried a few variations and played with the 'string' optional argument, but to
no avail.

Can someone check the behaviour of this?


Post a reply to this message

From: omniverse
Subject: Re: Error in datetime (now) ?
Date: 9 Jan 2017 09:20:01
Message: <web.58739b8c48507b719c5d6c810@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:
> I tried using this over the weekend (v3.7), and at 7:37 pm, I got 00:37 as the
> output.
> I tried a few variations and played with the 'string' optional argument, but to
> no avail.
>
> Can someone check the behaviour of this?

Only found another message from a couple years ago telling of subtracting from
'now' to correct for the time zone. In your case that looks like 5 hours, or
0.208333 of 24 hours (5 divided by 24).
So apparently it reads the Coordinated Universal Time, UTC.

#debug concat("The day, date and time is ",datetime(now-0.208333,"%A %m/%d/%Y
%I:%M %p %Z"),"\n\n")


Post a reply to this message

From: Bald Eagle
Subject: Re: Error in datetime (now) ?
Date: 9 Jan 2017 10:15:01
Message: <web.5873a89848507b71c437ac910@news.povray.org>
Aha.
I guess I was thinking that it ought to be reading the time-zone corrected
Windows system time, but maybe it's not.

I'll play around with it a bit more, at different times of day and see what I
can get worked out.

Thanks for the tip!   :)


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.