help please.
#1

Код:
dcmd_jail(playerid,params[])
{
if(gTeam[playerid] != TEAM_COP)
	return SendClientMessage(playerid,COLOR_RED,"LSPD only!");
new giveplayer = strval(params);
if (strlen(params)<=0)
	return SendClientMessage(playerid,COLOR_WHITE,"/jail [ID]");
if (!IsPlayerConnected(giveplayer))
	return SendClientMessage(playerid,COLOR_RED,"This player is not connected.");
else
{
new string[256],pidname[MAX_PLAYER_NAME],pname[MAX_PLAYER_NAME];
GetPlayerName(playerid,pidname,256);
GetPlayerName(giveplayer,pname,256);
format(string,sizeof(string),"Cop %s jailed you!",pidname);
SendClientMessage(giveplayer,COLOR_GREY,string);
format(string,sizeof(string),"You jailed %s!",pname);
SendClientMessage(playerid,COLOR_GREY,string);
SetPlayerPos(giveplayer,264.8447,77.5486,1001.0391);
SetPlayerInterior(giveplayer,6);
SetPlayerFacingAngle(giveplayer,266.6938);
ResetPlayerWeapons(giveplayer);
SetPlayerArmour(giveplayer,0.0);
SendClientMessage(giveplayer, COLOR_WHITE, "Your items where confiscated and destroyed!");
return true;
}
new pName[MAX_PLAYER_NAME];
new string[48];
GetPlayerName(playerid, pName, sizeof(pName));
format(string, sizeof(string), "%s has joined the server.", pName);
SendClientMessageToAll(0xAAAAAAAA, string);
SetPlayerColor(playerid,COLOR_WHITE);
GivePlayerMoney(playerid,2000);
return 1;
}
Where should this be ^^
and this is OnPlayerCommandText
Код:
dcmd(jail,4,cmdtext);
Yes i have the #defines
Reply


Messages In This Thread
help please. - by harly - 07.03.2009, 12:25
Re: help please. - by harly - 07.03.2009, 13:59
Re: help please. - by ICECOLDKILLAK8 - 07.03.2009, 14:00
Re: help please. - by harly - 07.03.2009, 14:02
Re: help please. - by harly - 07.03.2009, 15:39
Re: help please. - by harly - 07.03.2009, 18:12
Re: help please. - by saiberfun - 07.03.2009, 18:28
Re: help please. - by ICECOLDKILLAK8 - 08.03.2009, 15:17

Forum Jump:


Users browsing this thread: 1 Guest(s)