Difference between revisions of "Gettime"
From Hercules Wiki
(Created page with "==Syntax== *'''gettime'''(<type>); ==Description== This function retrieves current system time and date values depending on parameter ''type'': #Seconds (0 - 59) #Minutes (0 ...") |
(Marked as outdated. Should use constants) |
||
Line 1: | Line 1: | ||
+ | {{outdated}} | ||
+ | |||
==Syntax== | ==Syntax== | ||
*'''gettime'''(<type>); | *'''gettime'''(<type>); |
Latest revision as of 18:31, 16 September 2016
Contents |
Syntax
- gettime(<type>);
Description
This function retrieves current system time and date values depending on parameter type:
- Seconds (0 - 59)
- Minutes (0 - 59)
- Hours (0 - 23)
- Day of Week (0: Sunday - 6: Saturday)
- Day of Month (1 - 31)
- Month (1 - 12)
- Year (1970 - 2038)
- Day of Year (1 - 366)
Any other value will cause the function to return -1. Only numbers are returned.
Examples
if(gettime(4)==6) { mes "It's a Saturday. I don't work on Saturdays."; close; }