//*************************** Inicio do GM **********************
new Score[MAX_PLAYERS], Matou[MAX_PLAYERS];
//*************************** OnPlayerDeath ********************
Matou[killerid] ++;
if(Matou[killerid] >= 10)
{
SendClientMessage(killerid, 0xFFFFFFFF, "Vocк subiu de nнvel o/");
Score[killerid] += 2;
Matou[killerid] = 0;
return 1;
}
//*************************** OnPlayerCommandText ********************
if(strcmp(cmd, "/score", true) == 0)
{
#define Branco 0xFFFFFFFF
new tmp[20], PlayerB, string[30], Manolo[MAX_PLAYER_NAME];
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) return SendClientMessage(playerid, Branco, "Uso correto: /Score [id]");
PlayerB = strval(tmp);
GetPlayerName(PlayerB, Manolo, sizeof(Manolo));
format(string, sizeof(string), "%s: %d", Manolo, Score[PlayerB]);
SendClientMessage(playerid, Branco, string);
return 1;
}
//LEVEL UP================================================ ===================================== if(dini_Int(file, "EXP") >=5){ dini_IntSet(file, "Level", dini_Int(file, "Level")+1); new string[256]; format(string, sizeof(string), "[Info-RedBull] Vocк Juntou 5 De Respeito, e Ganhou +1 Level",dini_Int(file, "Level")); SendClientMessage(i, 0x75EA00AA, string); PlayerPlaySound(i, 1057, 0, 0, 0); dini_IntSet(file, "EXP",0); dini_IntSet(file, "rouboubanco", 0); jasequestro[i] = 0; } |
Josma й Isso Sim Mais Veja
No Meu +1 Up Level Ta Assim, Sou Meio Novato Pawno Intao Como Faz Para Fazer Esse Seu Comando Ai o UP Ser Por Base Desse |
//**************** Troca o script no OnPlayerDeath antigo por este *************************
Matou[killerid] ++;
if(Matou[killerid] >= 10)
{
SendClientMessage(killerid, 0xFFFFFFFF, "Vocк subiu de nнvel o/");
Score[killerid] += 1;
dini_IntSet(file, "Level", dini_Int(file, "Level")+1);
Matou[killerid] = 0;
return 1;
}
//************************* Troca o comando antigo por este ********************************
if(strcmp(cmd, "/score", true) == 0)
{
#define Branco 0xFFFFFFFF
new tmp[20], PlayerB, string[30], Manolo[MAX_PLAYER_NAME];
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) return SendClientMessage(playerid, Branco, "Uso correto: /Score [id]");
PlayerB = strval(tmp);
GetPlayerName(PlayerB, Manolo, sizeof(Manolo));
format(string, sizeof(string), "%s: %d", Manolo, dini_Int(file, "Level"));
SendClientMessage(playerid, Branco, string);
return 1;
}
3 Erros xD
(3569) : error 017: undefined symbol "cmd" (3572) : error 017: undefined symbol "idx" (3572) : error 047: array sizes do not match, or destination array is too small |
new cmd[256], idx;
Leia meu tutorial cara, serб mais fбcil vocк aprender do que pegar essa base do Josma, nгo que esteja ruim, Josma um grande coder!
https://sampforum.blast.hk/showthread.php?tid=243018 |