Help !
#3

Код:
COMMAND:giveweapon(playerid, params)
{
	new id,weaponid, ammo, msg[128], name1[MAX_PLAYER_NAME];
	if(sscanf(params,"uii", id, weaponid, ammo)) return SCM(PID, -1, "Usage: /giveweapon [ID] [WeaponId] [Ammo]");
	if(PlayerInfo[playerid][pAdmin] < 4) return SCM(PID, COLOR_RED, "You must be level 4 admin!");
	if(PlayerInfo[playerid][pAdmin] == 0) return SCM(PID, COLOR_RED,"You are not allowed to use this command!");
	if(id == INVALID_PLAYER_ID) return SCM(PID, COLOR_RED, "That Player is not connected");
	{
	    GivePlayerWeapon(id, weaponid, ammo);
	    GPN(PID, name1, sizeof(name1));
	    format(msg, sizeof(msg),"Admin %s gave you gun! ammo: %d", name1, ammo);
	    SCM(id, COLOR_YELLOW, msg);
	}
	return 1;
}
Reply


Messages In This Thread
Help ! - by SoltutioN - 22.08.2016, 10:47
Re: Help ! - by DarkSkull - 22.08.2016, 11:20
Re: Help ! - by SoltutioN - 22.08.2016, 11:56
Re: Help ! - by SoltutioN - 22.08.2016, 12:01
Re: Help ! - by DarkSkull - 22.08.2016, 12:03

Forum Jump:


Users browsing this thread: 1 Guest(s)