[Pedido] Sistema BБSICO De Level - 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: [Pedido] Sistema BБSICO De Level (
/showthread.php?tid=312892)
[Pedido] Sistema BБSICO De Level -
shadauer - 23.01.2012
Bom Dia.
Ao Pedido:
Preciso De Um Sistema Que Apareзa No Canto Superior A Esquerda Da Tela Se Possнvel:
Lйvel: 01
Pontos De Respeito: 0/5
Que Os Pontos Subam De 5 Em 5 Minuto E Salvem.
Depois De 25 Minutos.
Lйvel: 02
Pontos De Respeito: 5/10 Ou 0/5 Novamente.
Й Possнvel?
Nгo Precisa Ser No Canto Da Esquerda Sу Tendo O Sisteminha Ai Ja Ta Bom, Q Ai Eu Mesmo Boto No Topo Da Tela.
Re: [Pedido] Sistema BБSICO De Level -
Cristhian - 23.01.2012
pawn Код:
#include <Dini>
new Level[MAX_PLAYERS]
new Pontos[MAXPLAYERS]
pawn Код:
OnPlayerConnect(playerid)
{
SetTimer("pts", 5 * 60000, true, "d", playerid)
SetarPlayer(playerid);
return 1;
}
forward pts(playerid);
public pts(playerid)
{
Pontos[playerid]++;
if(Pontos[playerid] == 5)
{
Pontos[playerid] = 0;
Level[playerid] ++;
SalvarPlayer(playerid);
return 1;
}
return 1;
}
stock SetarPlayer(playerid)
{
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
new String[50];
format(String, sizeof(String), "players/%s", Nome); //edite o caminho
Level[playerid] = dini_Int(String, "Level");
Pontos[playerid] = dini_Int(String, "Pontos");
return 1;
}
stock SalvarPlayer(playerid)
{
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
new String[50];
format(String, sizeof(String), "players/%s", Nome); //edite o caminho
dini_IntSet(String,"Level", Level[playerid]);
Pontos[playerid] = dini_Int(String, "Pontos");
return 1;
}
Re: [Pedido] Sistema BБSICO De Level -
shadauer - 23.01.2012
Testarei Depois Das 18:00 Assim Lhe Dou A Resposta A Noite.
Obrigado
Re: [Pedido] Sistema BБSICO De Level -
Cristhian - 23.01.2012
Okay .