Az lenne a problemam hogy a imer nem szamol vissza...Hogyan lehet megoldani ?Egy /lecsuk parancsrol van szo! Script:
CMD:lecsuk(playerid,params[])
{
new ora,perc,mperc;
gettime(ora,perc,mperc);
new pId;
if(sscanf(params, \"dddds\", pId,ora, perc,mperc, params[3])) return SendClientMessage(playerid, 0xFF0000AA, \"Hasznalat: /lecsuk [iD] [ora,perc,mperc][indok]\");
else if(!IsPlayerConnected(pId)) return SendClientMessage(playerid, 0xFF0000AA, \"Nincs ilyen ID-ju jatekos.\");
else
{
new pnamme[MAX_PLAYER_NAME], jnamme[MAX_PLAYER_NAME], string1[250];
GetPlayerName(playerid, pnamme, sizeof(pnamme));
GetPlayerName(pId, jnamme, sizeof(jnamme));
SetPlayerInterior(pId, 3);
new rand = random(sizeof(JailCellSpawns));
SetPlayerPos(pId, JailCellSpawns[rand][0], JailCellSpawns[rand][1], JailCellSpawns[rand][2]);
borton[playerid] = SetTimerEx(\"UnJail\",ora*perc*mperc*1000*60,false,\"i\",pId);
mennyi[playerid] = ora*perc*mperc;
mennyi[playerid]--;
new string[128];
format(string,sizeof(string),\"Borton:{00FF00} %d ora,%d perc,%d masodperc\",ora,perc,mperc);
SendClientMessage(pId,narancs,string);
InJail[pId] = 1;
SetPlayerWantedLevel(pId, 0);
format(string1, sizeof(string1), \"%s(%d) Börtönbe zárta: %s(%d) Indok: %s\", jnamme, pId, pnamme, playerid, params[3]);
SendClientMessageToAll(0xFF0000AA, string1);
new str1[128];
format(str1,sizeof(str1),\"Börtön idõ: %d ora,%d perc,%d maperc\",ora,perc,mperc);
TextDrawSetString(Text:borton1,str1);
TextDrawShowForPlayer(pId,Text:borton1);
bor[playerid] = SetTimerEx(\"Ido\",1000,true,\"i\",pId);
mperc--;
if(mperc == 0)
{
perc--;
mperc = 60;
}
if(perc == 0)
{
ora--;
perc = 60;
}
return 1;
}
}
forward Ido(playerid);
public Ido(playerid)
{
new ora,perc,mperc = mennyi[playerid];
new str1[128];
mperc--;
if(mperc == 0)
{
perc--;
mperc = 60;
}
if(perc == 0)
{
ora--;
perc = 60;
}
if(ora == 0)
{
perc--;
perc = 60;
}
format(str1,sizeof(str1),\"Börtön idõ:%d ora,%d perc,%d mperc\",ora,perc,mperc);
TextDrawSetString(Text:borton1,str1);
TextDrawShowForPlayer(playerid,Text:borton1);
}