03.02.2017, 16:29
Hi there !
I have a problem with some fields.
Some fields are updated but not at all.
I use:
For example clanDays is not updated, playerCar4Days, playerCar5Days. What's wrong?
I have a problem with some fields.
Some fields are updated but not at all.
I use:
Код HTML:
public SyncTime() { //new string[64]; new tmphour; new tmpminute; new tmpsecond; new query[1000]; new query2[1000]; gettime(tmphour, tmpminute, tmpsecond); FixHour(tmphour); tmphour = shifthour; if ((tmphour > ghour) || (tmphour == 0 && ghour == 23)) { ghour = tmphour; PayDay(); if (realtime) { SetWorldTime(tmphour); } } if(tmphour == 22 && tmpminute == 58) { mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `playerDonateTime` = `playerDonateTime`+1"); mysql_tquery(handle, query2); mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `pZileAmanet` = `pZileAmanet`+1"); mysql_tquery(handle, query2); } if(tmphour == 22 && tmpminute == 55) { mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `playerCar1Days` = `playerCar1Days`+1"); mysql_tquery(handle, query2); mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `playerCar2Days` = `playerCar2Days`+1"); mysql_tquery(handle, query2); mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `playerCar3Days` = `playerCar3Days`+1"); mysql_tquery(handle, query2); mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `playerCar4Days` = `playerCar4Days`+1"); mysql_tquery(handle, query2); mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `playerCar5Days` = `playerCar5Days`+1"); mysql_tquery(handle, query2); } if(tmphour == 22 && tmpminute == 59) { for(new xf = 0; xf < MAX_GROUPS; xf++) { mysql_format(handle, query, 500, "UPDATE `playeraccounts` SET `playerDays` = `playerDays`+1 WHERE `playerGroup` = '%d'", xf); mysql_tquery(handle, query); mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `player24` = `player24`+1"); mysql_tquery(handle, query2); } } if(tmphour == 23 && tmpminute == 0) { for(new c = 0; c < MAX_CLANS; c++) { mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `playerClanDays` = `playerClanDays`+1 WHERE `playerClan` = '%d'", c); mysql_tquery(handle, query2); } mysql_format(handle, query2, 500, "UPDATE `houses` SET `houseLastOn` = `houseLastOn`+1"); mysql_tquery(handle, query2); mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `playerAnuntat` = `playerAnuntat`+1"); mysql_tquery(handle, query2); mysql_format(handle, query2, 500, "UPDATE `playeraccounts` SET `samposcop` = `samposcop`+1"); mysql_tquery(handle, query2); mysql_format(handle, query2, 500, "UPDATE `clans` SET `clanDays` = `clanDays`+1"); mysql_tquery(handle, query2); } }