Posts: 46
Threads: 18
Joined: Dec 2017
Reputation:
0
How can I do this?
When player type /order
He gets 'amount' order
When player type /buyorder
The order amount removed
The order amount then added to vehicle like for example " HasOrderStuffs[pCar] += 'amount he order'; "
Posts: 491
Threads: 112
Joined: Jan 2016
Reputation:
0
Give us your codes to help you.
Posts: 46
Threads: 18
Joined: Dec 2017
Reputation:
0
Sorry i don't have code, i just need some example code to do it then I'll do my ownway.
Posts: 716
Threads: 92
Joined: May 2018
pawn Код:
CMD:order(playerid, params[])
{
new amount;
if (sscanf(params, "i", amount)) return SendClientMessage(playerid, -1, "USAGE: /order [amount]");
Player[playerid][Order] += amount; //Change it with your user system.
new string[80];
format(string, sizeof(string), "* You got %i of amount", amount);
SendClientMessage(playerid, -1, string);
return 1;
}
CMD:removeorder(playerid, params[])
{
new amount;
if (sscanf(params, "i", amount)) return SendClientMessage(playerid, -1, "USAGE: /removeorder [amount]");
Player[playerid][Order] -= amount; //Change it with your user system.
new string[80];
format(string, sizeof(string), "* You removed %i of amount", amount);
SendClientMessage(playerid, -1, string);
return 1;
}