[Ajuda] Sistema de Nivel Bugado ? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: Non-English (
https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (
https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (
https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Sistema de Nivel Bugado ? (
/showthread.php?tid=528791)
Sistema de Nivel Bugado ? -
Nenzittow - 29.07.2014
Boas pessoal, criei esse sistema de nнvel, mas sу estб a adicionar o score para mim '-'
Alguйm me pode ajudar?
pawn Код:
SetTimer("UP",180000,true);
pawn Код:
forward UP(playerid);
public UP(playerid)
{
new Score[256];
SetPlayerScore(playerid, GetPlayerScore(playerid) +1);
format(Score,sizeof(Score),"| UP | Vocк ganhou +1 level ( %d )", GetPlayerScore(playerid));
SendClientMessage(playerid, VerdeC, Score);
return 1;
}
Re: Sistema de Nivel Bugado ? -
MultiKill - 29.07.2014
Onde vocк colocou o timer?
Tente usar o SetTimerEx:
pawn Код:
SetTimerEx("UP",180000,true, "d", playerid);
Re: Sistema de Nivel Bugado ? -
Nenzittow - 29.07.2014
Coloquei no OnGameModeInit.
Agora coloquei esse que vc disse e deu este erro:
Quote:
error 017: undefined symbol "playerid"
|
Re: Sistema de Nivel Bugado ? -
MultiKill - 29.07.2014
Faзa o seguinte, use o SetTimer, e dentro da callback crie uma loop.
Ficando:
pawn Код:
SetTimer("UP",180000,true);
forward UP();
public UP()
{
for(new i=0; i<500; i++)
{
if(IsPlayerConected(i))
{
new Score[256];
SetPlayerScore(i, GetPlayerScore(i) +1);
format(Score,sizeof(Score),"| UP | Vocк ganhou +1 level ( %d )", GetPlayerScore(i));
SendClientMessage(i, VerdeC, Score);
}
}
return 1;
}
Re: Sistema de Nivel Bugado ? -
Nenzittow - 29.07.2014
Vou testar. Vlw