[Guide] Working with dates
Hi, when I need use dates in sourcemod, I don't see any tutorial or guide for use it. So, I decided make a simple guide for working with dates.
It's very simple, do you need this function: PHP Code:
(You can see all information in the API: https://sm.alliedmods.net/new-api/sourcemod/FormatTime So, using this link: http://www.cplusplus.com/reference/ctime/strftime/ we can obtain all the values that we want. Example: PHP Code:
Regards |
Re: [Guide] Working with dates
GetTime returns the number of seconds since 1970 January 1 00:00:00 UTC. Might be easier to do math on that instead.
|
Re: [Guide] Working with dates
Nice tutorial. I was going to write a guide eventually on using time/dates and using them in reference to the future/past but I can see you did a good 30% of that.
|
Re: [Guide] Working with dates
Quote:
|
Re: [Guide] Working with dates
Quote:
|
| All times are GMT -4. The time now is 18:33. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.