%d Wanteds
#1

Hey,

how to get the Wanteds from a Player (Enum)

enum PlayerInfo
{
Adminlevel,
Level,
Fraction,
Team,
sLogin,
Banned,
Prison,
Skin,
pMuted,
aPrison,
Wanteds
};


ocmd: su(playerid,params[])
{
if(IsPlayerCop(playerid))
{
new pid,wid,reason[64];
if(sscanf(params,"uis",pid,wid,reason))return SendClientMessage(playerid,BLAU,"/su [ID] [Wanteds] [Reason]");
if(IsPlayerConnected(playerid))
{
new string[128];
format(string, sizeof(string), "Officer %s has given you %d Wanteds", GetName(playerid),wid);
SendClientMessage(pid, -1, string);
sPlayer[playerid][Wanteds]=sSpieler[playerid][Wanteds]+wid;
}
}
return 1;
}

How to give out the Wanteds?

ocmd:mywtds(playerid,params[])
{
new wid;
new string[128];
format(string, sizeof(string), "You have %d Wanteds!", sSpieler[Wanteds]); I do not know how to query the number of "wanteds"
SendClientMessage(playerid, -1, string);
}
Reply


Messages In This Thread
%d Wanteds - by pulsare - 27.10.2017, 17:26
Re: %d Wanteds - by Danisoni - 27.10.2017, 18:04
Re: %d Wanteds - by pulsare - 27.10.2017, 18:18
Re: %d Wanteds - by Mencent - 28.10.2017, 12:26

Forum Jump:


Users browsing this thread: 1 Guest(s)