Disable using all commands
#1

Hi,

I was thinking about, is there any way how to disable all commands usage while I'm in (Example: Minigun DM) ? Or i have to do it on harder way! + REP tnx
Reply
#2

Quote:
Originally Posted by Hunud
Посмотреть сообщение
Hi,

I was thinking about, is there any way how to disable all commands usage while I'm in (Example: Minigun DM) ? Or i have to do it on harder way! + REP tnx
PHP код:
public OnPlayerCommandReceived(playeridcmdtext[]) //this is in the zcmd include
{
    if(!
strcmp("/exitminigun"cmdtexttrue9))
    {
        return 
1;
    }
    if(
inminigun[playerid] == true//if the player is in the minigun event
    
{
        
SendClientMessage(playeridCOLOR_RED"You must leave the the minigun in order to use commands");
        return 
0//block all commands.
    
}
    return 
1//allows a command, while return 0 blocks a command. cmdtext is the command text with /. "/slap" for example

Make sure that u have zcmd
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)