Raised This Month: $ Target: $400
 0% 

Commands Don't Execute


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 05-23-2010 , 19:06   Commands Don't Execute
Reply With Quote #1

PHP Code:
public plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
RegisterHam(Ham_Spawn"player""user_connect")
    
register_clcmd("say /guns""WeaponMenu"ADMIN_USER)
}

public 
user_connect(id)
{
    if(
is_user_alive(id)) {
        new 
CsTeams:team cs_get_user_team(id);
        if(
team == CS_TEAM_T)
        {
            
fm_strip_user_weapons(id);
            
give_item(id"weapon_knife");
            
ColorChat(id"^4%s^1As a terrorist, you will be a ninja!");
            
fm_set_user_rendering(idkRenderFxGlowShell000kRenderTransAlpha25);
            
fm_set_user_health(id200);
            
fm_set_user_gravity(id0.5);
            
fm_set_user_maxspeed(id375.0);
            
ColorChat(id"^4%s^1Your objective is to kill all humans, good luck!");
        }
        if(
team == CS_TEAM_CT)
        {
            
ColorChat(id"^4%s^1As a counter-terrorist, you will be a human!");
            
fm_set_user_rendering(idkRenderFxGlowShell255255255kRenderTransAlpha125);
            
set_task(1.0"WeaponMenu");
            
ColorChat(id"^4%s^1Your objective is to kill the ninjas, good luck!");
        }
    }

Whats wrong here? It wont display the messages or execute anything.
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.

Last edited by GXLZPGX; 05-23-2010 at 19:15.
GXLZPGX is offline
Kreation
Veteran Member
Join Date: Jan 2010
Location: Illinois
Old 05-23-2010 , 19:30   Re: Commands Don't Execute
Reply With Quote #2

Why not just take the fm_ away from all the functions?
__________________
Hi.
Kreation is offline
FlyingHorse
Senior Member
Join Date: Apr 2010
Location: Under your bed.
Old 05-23-2010 , 19:50   Re: Commands Don't Execute
Reply With Quote #3

PHP Code:
public plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
RegisterHam(Ham_Spawn"player""user_connect")
    
register_clcmd("say /guns""WeaponMenu"ADMIN_USER)
}

public 
user_connect(id)
{
    if(
is_user_alive(id)) {
        new 
CsTeams:team cs_get_user_team(id);
        if(
team == CS_TEAM_T)
        {
            
strip_user_weapons(id);
            
give_item(id"weapon_knife");
            
ColorChat(id"^4%s^1As a terrorist, you will be a ninja!");
            
set_user_rendering(idkRenderFxGlowShell000kRenderTransAlpha25);
            
set_user_health(id200);
            
set_user_gravity(id0.5);
            
set_user_maxspeed(id375.0);
            
ColorChat(id"^4%s^1Your objective is to kill all humans, good luck!");
        }
        if(
team == CS_TEAM_CT)
        {
            
ColorChat(id"^4%s^1As a counter-terrorist, you will be a human!");
            
set_user_rendering(idkRenderFxGlowShell255255255kRenderTransAlpha125);
            
set_task(1.0"WeaponMenu");
            
ColorChat(id"^4%s^1Your objective is to kill the ninjas, good luck!");
        }
    }

FlyingHorse is offline
Send a message via Skype™ to FlyingHorse
JaGareN
Senior Member
Join Date: Mar 2009
Old 05-23-2010 , 19:55   Re: Commands Don't Execute
Reply With Quote #4

Quote:
Originally Posted by Kreation View Post
Why not just take the fm_ away from all the functions?
He maybe want to use fakemeta?

EDIT: the colorchat messages are wrong.

Last edited by JaGareN; 05-23-2010 at 19:58.
JaGareN is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 05-23-2010 , 19:58   Re: Commands Don't Execute
Reply With Quote #5

Those fm_ functions are less efficient than the ones they are replacing.
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
JaGareN
Senior Member
Join Date: Mar 2009
Old 05-23-2010 , 20:12   Re: Commands Don't Execute
Reply With Quote #6

Quote:
Originally Posted by Exolent[jNr] View Post
Those fm_ functions are less efficient than the ones they are replacing.
What do you mean?
JaGareN is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 05-23-2010 , 20:32   Re: Commands Don't Execute
Reply With Quote #7

Quote:
Originally Posted by JaGareN View Post
What do you mean?
http://forums.alliedmods.net/showthread.php?t=88792
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 05-23-2010 , 20:25   Re: Commands Don't Execute
Reply With Quote #8

Quote:
Originally Posted by JaGareN View Post
He maybe want to use fakemeta?

EDIT: the colorchat messages are wrong.
No, the ColorChat message are fine. I used my own custom stock for colorchat. Now everything works, except it wont set the speed.
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.
GXLZPGX is offline
Brreaker
Senior Member
Join Date: Oct 2009
Location: Constanta, Romania
Old 05-24-2010 , 06:56   Re: Commands Don't Execute
Reply With Quote #9

Aren't ninjas humans too?!
__________________
There are 10 kinds of people.Those who understand binary, and those who don't.
Also, for those who understand binary, there is a donation tab too!
No steam || PM support!
Brreaker is offline
Send a message via MSN to Brreaker Send a message via Yahoo to Brreaker
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 05-24-2010 , 08:16   Re: Commands Don't Execute
Reply With Quote #10

Quote:
Originally Posted by Brreaker View Post
Aren't ninjas humans too?!
No, they are super psychotic Asian monkeys. Complete difference. Moving on, I did exactly what it said, "Exolent," but there was no change.
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.
GXLZPGX 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 05:22.


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