11.07.2014, 16:20
Hello
i have problem in Time , is all night [ Time 21:00 ] +rep for any helped me.
Pwn Code:
and when i edit this code , is changed in time 12:00[ is stoped in 12:00]
this edit i did
i have problem in Time , is all night [ Time 21:00 ] +rep for any helped me.
Pwn Code:
pawn Код:
[B] //Timers
gettime(ghour, gminute, gsecond);
FixHour(ghour);
ghour = shifthour;
if(!realtime)
{
if(wtime >= 7 && wtime <= 20)
{
wtime = 21;
}
SetWorldTime(wtime);[/B]
pawn Код:
[B] if (realtime)
{
new tmphour;
new tmpminute;
new tmpsecond;
gettime(tmphour, tmpminute, tmpsecond);
FixHour(tmphour);
tmphour = shifthour;
if(tmphour >= 7 && tmphour <= 20)
{
tmphour = 21;
}
SetWorldTime(tmphour);
}[/B]
pawn Код:
[B]public SyncTime()
{
new string[64];
new tmphour;
new tmpminute;
new tmpsecond;
gettime(tmphour, tmpminute, tmpsecond);
FixHour(tmphour);
tmphour = shifthour;
if ((tmphour > ghour) || (tmphour == 0 && ghour == 23))[/B]
pawn Код:
[B]public FixHour(hour)
{
hour = timeshift+hour;
if (hour < 0)
{
hour = hour+24;
}
if (hour > 23)
{
hour = hour-24;
}
if(hour >= 7 && hour <= 20)
{
hour = 21;
}
shifthour = hour;
return 1;[/B]
pawn Код:
public FixHour(hour)
{
hour = timeshift+hour;
if (hour < 0)
{
hour = hour+24;
}
if (hour > 23)
{
hour = hour-24;
}
if(hour >= 7 && hour <= 24)
shifthour = hour;
return 1;