[AJUDA]Recompensas
#1

Ola galera criei um simples sistema de recompenзa mais ela nao reseta quando morre e nem seta o dinheiro:

pawn Код:
new granastatus[MAX_PLAYERS];
pawn Код:
new nomedofd[MAX_PLAYER_NAME];GetPlayerName(killerid, nomedofd, sizeof(nomedofd));
    if(granastatus[playerid] > 0 && (GetPlayerTeam(killerid) == 0 || GetPlayerTeam(playerid) != GetPlayerTeam(killerid))) {
        format(string, sizeof(string), "[RECOMPENSAS]: %s recebeu a recompensa de $%d mil euros por matar %s.", nomedofd, granastatus[playerid], PlayerName(playerid));
        SendClientMessageToAll(0x33AA33AA,string);
        GivePlayerMoney(killerid, granastatus[playerid]);
        granastatus[killerid]++;
        granastatus[playerid] = 0;
    }
pawn Код:
if(GetPlayerTeam(killerid) != GetPlayerTeam(playerid))
        {
        granastatus[killerid] = Mortes[killerid] * 1000;
        granastatus[playerid] = 0;
        GivePlayerMoney(killerid, granastatus[playerid]);
        Mortes[killerid]++;
        PlayerInfo[playerid][pMorreu]++;
        PlayerInfo[killerid][pMatou]++;
        SetPlayerScore(killerid,GetPlayerScore(killerid) +1);
        GivePlayerMoney(killerid, 2500);
        GameTextForPlayer(killerid, "~y~Voce matou um ~w~emo!", 2500, 5);
    }
Reply


Messages In This Thread
[AJUDA]Recompensas - by Victor_Souz4 - 25.11.2011, 16:16
Re: [AJUDA]Recompensas - by Pharrel - 25.11.2011, 16:50
Re: [AJUDA]Recompensas - by Victor_Souz4 - 25.11.2011, 16:51
Re: [AJUDA]Recompensas - by Pharrel - 25.11.2011, 17:01
Re: [AJUDA]Recompensas - by |_MeGaTroN_| - 25.11.2011, 17:09
Re: [AJUDA]Recompensas - by Victor_Souz4 - 25.11.2011, 17:33

Forum Jump:


Users browsing this thread: 4 Guest(s)