Increase/Decrease Score Stocks
#1

can somebody tell me how to script Increase/Decrease Score Stocks?

pawn Код:
IncreaseScore(playerid, 1); //Increase player's score by 1
DecreaseScore(playerid, 1); //Decrease player's score by 1

instead of:

SetPlayerScore(playerid, GetPlayerScore(playerid)+1);
SetPlayerScore(playerid, GetPlayerScore(playerid)-1);
Reply
#2

Код:
stock IncreaseScore(playerid)
{
        SetPlayerScore(playerid, +1);
}

stock DecreaseScore(playerid)
{
         SetPlayerScore(playerid, -1);
}
This should work.
Reply
#3

pawn Код:
stock IncreaseScore(playerid, amount)
{
    SetPlayerScore(playerid, GetPlayerScore(playerid) + amount);
}

stock DecreaseScore(playerid, amount)
{
    SetPlayerScore(playerid, GetPlayerScore(playerid) - amount);
}
Reply
#4

thanks
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)