Raised This Month: $51 Target: $400
 12% 

Need Help With Something Basic...


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
MaSTeR64
Member
Join Date: Apr 2015
Location: Serbia <3
Old 07-09-2015 , 10:34   Need Help With Something Basic...
Reply With Quote #1

Hey all. Im trying to make a thing to troll a player. Lets say somebody types in "troll_slow" and then has to type in the name of the player. Now, ive done that, but im having problems. When i type in the name it just does the same (Sends In Console "Usage : troll_slow <name> - Slows The Player")

Heres the code

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <fun>


public plugin_init()
{
    
register_plugin("Troll Test Plugin""v1.0""MaSTeR64");
    
    
register_concmd("troll_slow""TROLL_SLOW"ADMIN_IMMUNITY"<name> - Slows The Player");
}
public 
TROLL_SLOW(idlevelcid)
{
    if(!
cmd_access(idlevelcid3))
         return 
PLUGIN_HANDLED;
    
    new 
target[32]
    
    
read_argv(1target31)
    
    new 
player cmd_target(idtargetCMDTARGET_OBEY_IMMUNITY CMDTARGET_NO_BOTS CMDTARGET_ALLOW_SELF)
    
    if (!
player)
        return 
PLUGIN_HANDLED;
    
    
set_user_maxspeed(player100.0);
    return 
PLUGIN_HANDLED;

MaSTeR64 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 20:00.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode