[RELEASE] Time & Date Function
Hi All! I am new to MPGH. I'll throw u guys some functions 
Includes:
[php]#include <time.h>[/php]
Time:
[php]/*****************The Time*******************/
char *TheTime()
{
char *logbuf = new char[ 256 ];
struct tm *newtime;
char am_pm[] = "AM";
time_t long_time;
time( &long_time );
newtime = localtime( &long_time );
if( newtime->tm_hour > 12 )
strcpy( am_pm, "PM" );
if( newtime->tm_hour > 12 )
newtime->tm_hour -= 12;
if( newtime->tm_hour == 0 )
newtime->tm_hour = 12;
sprintf( logbuf, "[ %02d:%02d:%02d %s ]", newtime->tm_hour, newtime->tm_min, newtime->tm_sec, am_pm );
return logbuf;
}
/*****************The Time*******************/[/php]
Date:
[php]/*****************The Date*******************/
char *TheDate()
{
time_t curtime = time(0);
tm now=*localtime(&curtime);
char dest[BUFSIZ]={0};
const char format[]="[ %d:%b:%Y ]";
if (strftime(dest, sizeof(dest)-1, format, &now)>0)
return dest;
}
/*****************The Date*******************/[/php]
If you have any C++ Common sense, you'd know how to draw it

I am not out to post "Copy and Paste" code. Figure it out yourself
IF YOU ARE GOING TO USE IN YOUR HACK, REMEMBER TO GIVE ME CREDITS
Remember to Thank Me!
It works. i just added it and compiled and got it to work.
thanks bro
they both work. seals is a alittle easier for a noob to understand
It works either way, thats just my method.
can you put one for C# and VB? i am going to try something with this later
Lol. You can do that yourself. Copy the code. Like you were going to anyways. Except instead of copying and pasting into C++. Go to google, and find a C++/C# Code Converter, and place it in there to convert it into a C# Code.
those converters are so expensive though