SetWorldTime to your own time possible?
#1

Hi guys,

I was wondering if its possible to set the WorldTime on your server to your real time?
Example: When its 9:00 PM at your country, how do i set that in-game too?

Thank you,
Meebly.
Reply
#2

Quote:
Originally Posted by Seif_
gettime will get the host's time. Check his location and find out his GMT, then find out yours and do the math.
Well i have checked a Roleplay script that includes it, but is it right?
I got this at the moment:

Код:
if (realtime)
{
new tmphour;
new tmpminute;
new tmpsecond;
gettime(tmphour, tmpminute, tmpsecond);
FixHour(tmphour);
tmphour = shifthour;
SetWorldTime(tmphour);
	}
return 1;
}
Its from SAGC.
Reply
#3

ex.:
Код:
tmphour+=1;
tmphour-=1;
If it's 12am for ex. it will make 1pm the other one make 11 am..
Reply
#4

Thanks guys i got the SetWorldTime to the real time working.
It works very fine.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)