getdate(); weird outputs - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: getdate(); weird outputs (
/showthread.php?tid=385290)
getdate(); weird outputs -
Kyle - 15.10.2012
Hi, I don't post here often but I've come across a problem.
I use this code when loading my houses but it outputs "289" in the print: "new date = getdate();"
Thanks
AW: getdate(); weird outputs -
BiosMarcel - 15.10.2012
send us sourcecode please
Re: getdate(); weird outputs -
Kyle - 15.10.2012
There is NO need. But okay:
Re: getdate(); weird outputs - Emmet_ - 15.10.2012
getdate() returns the day of the year if no parameters are used.
Re: getdate(); weird outputs -
Kyle - 15.10.2012
Quote:
Originally Posted by Emmet_
getdate() returns the day of the year if no parameters are used.
|
I thought it outputs a unix-timestamp of the date...
Re: getdate(); weird outputs - Jarnu - 15.10.2012
Lol!
Код:
new date = getdate();
printf("%d", date);
prints the days
Found this on WIKI
Код:
new Days = getdate();
printf("Days since the start of the year: %d", Days);
Must check this out:
https://sampwiki.blast.hk/wiki/Getdate
Re: getdate(); weird outputs - Emmet_ - 15.10.2012
Quote:
Originally Posted by KyleSmith
I thought it outputs a unix-timestamp of the date...
|
gettime() does.
AW: getdate(); weird outputs -
BiosMarcel - 15.10.2012
1: is this a picture?
2: Use a Codebox
PHP код:
new day,mon,year;
getdate(year,mon,day);
printf(%d.%d.%d,day,mon,year);
This should work
Re: getdate(); weird outputs -
Kyle - 15.10.2012
Quote:
Originally Posted by Emmet_
gettime() does.
|
Thanks, I'm blind. +repped