make no CMD`s in DM - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: make no CMD`s in DM (
/showthread.php?tid=73987)
make no CMD`s in DM -
CAMERON_BANFIELD - 19.04.2009
Hi, i have my deathmatch area that works fine but i dont know how to make it so you cant do commands in there.
Please can someone tell me how to do this
Thanks
Cameron
Re: make no CMD`s in DM -
elci - 19.04.2009
this in the top of your script:
new in_dm[MAX_PLAYERS];
this in OnPlayerCommandText
if(strcmp(cmdtext,"/dm",true));
{
dm[playerid]=1;
}
put this where you wanna block command:
if(in_dm[playerid]==1)return SendClientMessage(playerid,0xFF0000FF,"You Cant Use Commands In Dm Area!!");
Re: make no CMD`s in DM -
Rks25 - 19.04.2009
or put a check at top of onplayercommandtext..
pawn Код:
public OnPlayerCommandText(playerid,cmdtext[])
{
if(iamatdm == 0)
{
// commands
}
else
{
SendClientMessage(playerid,0xFF0000FF,"You Cant Use Commands In Dm Area!!");
}
return 0;
}
Re: make no CMD`s in DM -
CAMERON_BANFIELD - 19.04.2009
Thanks For reply!
Re: make no CMD`s in DM -
Rks25 - 19.04.2009
Your welcome.