Need help with my Score Script
#2

Try:
pawn Код:
#include <a_samp>
#define COLOR_BLUE 0x1229FAFF

new ScoreTimer1[MAX_PLAYERS];
new ScoreTimer2[MAX_PLAYERS];

forward AddScore1(playerid);
forward AddScore2(playerid);

public OnPlayerConnect(playerid)
{
    ScoreTimer1[playerid] = SetTimerEx("AddScore1", 1000, true, "i", playerid);
    ScoreTimer2[playerid] = SetTimerEx("AddScore2", 5000, true, "i", playerid);
    return 1;
}

public AddScore1(playerid)
{
    SetPlayerScore(playerid, GetPlayerScore(playerid)+1);
    new string[200];
    format(string, sizeof(string), "~g~U're now level 1 Congratz");
    GameTextForPlayer(playerid, string, 1000, 0);
    KillTimer(ScoreTimer1[playerid]);
    if(GetPlayerScore(playerid) < 2)
    {
        KillTimer(ScoreTimer1[playerid]);
    }
    return 1;
}

public AddScore2(playerid)
{
    SetPlayerScore(playerid, GetPlayerScore(playerid)+1);
    new string[200];
    format(string, sizeof(string), "~g~U're now level 2 Congratz");
    GameTextForPlayer(playerid, string, 1000, 0);
    KillTimer(ScoreTimer2[playerid]);
    if(GetPlayerScore(playerid) < 2) // Change the < 2 of the numbers to the number of scoretimers u got
    {
        KillTimer(ScoreTimer2[playerid]);
    }
    return 1;
}
Reply


Messages In This Thread
Need help with my Score Script - by Stefand - 13.11.2011, 10:01
Re: Need help with my Score Script - by Stigg - 13.11.2011, 10:14
Re: Need help with my Score Script - by Kostas' - 13.11.2011, 10:18
Re: Need help with my Score Script - by Stefand - 13.11.2011, 10:27
Re: Need help with my Score Script - by Stigg - 13.11.2011, 10:31

Forum Jump:


Users browsing this thread: 5 Guest(s)