Jump to content

GetTimeProperty: Difference between revisions

Added an example
(Remove Devfeature)
(Added an example)
Line 48: Line 48:


Note that due to ACS's limitations, the timestamp is suspectible to the [http://en.wikipedia.org/wiki/Year_2038_problem year 2038 problem].
Note that due to ACS's limitations, the timestamp is suspectible to the [http://en.wikipedia.org/wiki/Year_2038_problem year 2038 problem].
== Examples ==
The following script checks if the game is being played on a Thursday the 20th.
<syntaxhighlight lang="c" line="1">
script 1 OPEN
{
    if (GetTimeProperty(SystemTime(), TM_WEEKDAY) == 4 && GetTimeProperty(SystemTime(), TM_DAY) == 20)
        PrintBold(s:"Happy Thursday the 20th!");
}
</syntaxhighlight>


== See Also ==
== See Also ==
*[[SystemTime]]
*[[SystemTime]]
*[[Strftime]]
*[[Strftime]]