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
#2

help
Reply
#3

Whats the problem?
Reply
#4

i get errors

Код:
C:\Program Files\Rockstar Games\GTA San Andreas\samp02Xserver.win32\gamemodes\gang chat.pwn(118) : error 017: undefined symbol "dcmd_jail"
C:\Program Files\Rockstar Games\GTA San Andreas\samp02Xserver.win32\gamemodes\gang chat.pwn(118) : error 029: invalid expression, assumed zero
C:\Program Files\Rockstar Games\GTA San Andreas\samp02Xserver.win32\gamemodes\gang chat.pwn(118) : error 029: invalid expression, assumed zero
C:\Program Files\Rockstar Games\GTA San Andreas\samp02Xserver.win32\gamemodes\gang chat.pwn(118) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Reply
#5

help ?
Reply
#6

Can someone help my script is here

http://pastebin.com/m725e8292
Reply
#7

u forgot to put the dcmd in in OnPlayerCommandText
Reply
#8

Quote:
Originally Posted by saiberfun
u forgot to put the dcmd in in OnPlayerCommandText
Quote:
Originally Posted by harly
Where should this be ^^
and this is OnPlayerCommandText
Код:
dcmd(jail,4,cmdtext);
Yes i have the #defines
Read next time
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)