[Include] uDate
#1

Welcome!

I want to show my new include. I think a lot of people had that problem, that s/he can't convert the famous Unix time to date. It wasn't be possible, because the SA-MP didn't insured a function for this. With this code you can convert the Unix time easily to date. (hour, and minute GMT are contain)

But let's see the code while using it:
Код:
	new
		time = gettime(),
		y, mo, d, h, mi, s
	;
	printf("Unix: %d", time);
	uDate(time, y, mo, d, h, mi, s);
	printf("%d|%d|%d|%d|%d|%d|", y, mo, d, h, mi, s);
The code will print this:
Код:
[22:44:12] Unix: 1356471852
[22:44:12] 2012|12|25|22|44|12|
Download:
http://pastebin.com/Lzrt8jrZ

If you find any bug in the code, please post the bug in this topic, or please send me a private message!

(Sorry for the English mistake)
Reply


Messages In This Thread
uDate - by Drake1994 - 27.12.2012, 20:34
Re: uDate - by TheArcher - 27.12.2012, 21:04
Re: uDate - by paulor - 27.12.2012, 21:22
Re: uDate - by Drake1994 - 28.12.2012, 11:40
Re: uDate - by Prumpuz - 28.12.2012, 12:00
Re: uDate - by Ballu Miaa - 28.12.2012, 12:57
Re: uDate - by Drake1994 - 28.12.2012, 13:08
Re: uDate - by Ballu Miaa - 28.12.2012, 13:32
Re: uDate - by Drake1994 - 28.12.2012, 13:38
Re: uDate - by Ballu Miaa - 29.12.2012, 03:45

Forum Jump:


Users browsing this thread: 1 Guest(s)