Hellp me fix errors! - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Hellp me fix errors! (
/showthread.php?tid=598353)
Hellp me fix errors! -
ricardsvv - 11.01.2016
Код HTML:
public OnPlayerSpawn(playerid)
{
if(PlayerLogged[playerid] == 0) return SetTimerEx("Kicks", 2000, false, "i", playerid);
for(new i = 1;i<=TOTALGZ;i++)
{
if(ZoneOnBattle[i] == 1 && IsAGang(playerid))
{
IsDead[playerid] = 0;
SetHealth(playerid, 100);
DeadMute[playerid] = 0;
SecsToGo[playerid] = 0;
KillTimer(AfterLifeTimer);<----------------Error ther
TogglePlayerControllable(playerid,true);
}
}
for(new i = 1;i<=TOTALMAFIA;i++)
{
if(ZoneOnBattlem[i] == 1 && IsAMafia(playerid))
{
IsDead[playerid] = 0;
DeadMute[playerid] = 0;
SetHealth(playerid, 100);
SecsToGo[playerid] = 0;
KillTimer(AfterLifeTimer);<----------------Error ther
TogglePlayerControllable(playerid,true);
}
}
Hellp me fix tihis errors
C:\Users\ricad_000\Desktop\RP-SAMP Serveris\gamemodes\MGC.pwn(1159

: error 035: argument type mismatch (argument 1)
C:\Users\ricad_000\Desktop\RP-SAMP Serveris\gamemodes\MGC.pwn(11611) : error 035: argument type mismatch (argument 1)
Re: Hellp me fix errors! -
FreAkeD - 11.01.2016
https://sampwiki.blast.hk/wiki/KillTimer
It will show where you went wrong.
Re: Hellp me fix errors! -
saffierr - 11.01.2016
You have to create variables for the timers
Re: Hellp me fix errors! -
Amunra - 11.01.2016
You have a unknown variable time , You must try
Example
PHP код:
new AfterLifeTimer;
AfterLifeTimer = SetTimerEx("TimeLimit", 600000, 0, "d", playerid);// you can change this
forward TimeLimit(playerid);// you can change variable
public TimeLimit(playerid)// you can change variable folowing forward
{
//your code here
return 1;
}