Thread: Name reward
View Single Post
MBf
Member
Join Date: Aug 2016
Old 07-31-2017 , 20:01   Re: Name reward
Reply With Quote #3

Goes, blocks commands but once added Arena.LaLeagane.Ro in name still does not unlock my 2 commands

Quote:
Originally Posted by Papero View Post
Try this:
PHP Code:
#include <sourcemod>

#pragma semicolon 1
#pragma newdecls required

#define PLUGIN_AUTHOR "Hexah"
#define PLUGIN_VERSION "1.00"


#define NAME " Arena.LaLeagane.Ro "

public Plugin myinfo 
{
    
name ""
    
author PLUGIN_AUTHOR
    
description ""
    
version PLUGIN_VERSION
    
url "csitajb.it"
};

public 
void OnPluginStart()
{
    
AddCommandListener(OnNameCmd"sm_rtd");
    
AddCommandListener(OnNameCmd"sm_lvl");
}

public 
Action OnNameCmd(int client, const char[] nameint argc)
{
    
char sName[128];
    
GetClientName(clientsNamesizeof(sName));
    if (
StrContains(sNameNAME) != -1)
    {
        return 
Plugin_Continue;
    }
    
ReplyToCommand(client"[SM] You need to have"NAME"in your name in order to use this command!");
    return 
Plugin_Stop;

I assume that the cmds already exists.
__________________
PLAY.ACEARENA.RO
WWW.ACEARENA.RO
MBf is offline