AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Menu to chooseteam key (https://forums.alliedmods.net/showthread.php?t=233388)

Estland 01-14-2014 07:29

Menu to chooseteam key
 
How can I replace default chooseteam menu with a new one?

Code:

public plugin_init()
{
register_clcmd("chooseteam", "function", 0);
}

Like that?

Estland 01-15-2014 08:53

Re: Menu to chooseteam key
 
Anyone?

Blizzard_87 01-15-2014 15:43

Re: Menu to chooseteam key
 
Code:
Public plugin_init( ) { Register_clcmd( "chooseteam", "CmdChooseteam" ); } Public CmdChooseteam( index ) { // put in your menu function hook here return PLUGIN_HANDLED; }

I'm on mobile so code isn't indented

Verknupfung 01-20-2014 04:58

Re: Menu to chooseteam key
 
Code:

#include <amxmodx>
#include <cstrike>

#define PLUGIN "ChooseTeam"
#define VERSION "1.0"
#define AUTHOR "Amx"

public plugin_init()
{
        register_plugin(PLUGIN, VERSION, AUTHOR)
        register_clcmd("chooseteam", "CmdChooseteam")
        register_clcmd("jointeam", "CmdChooseteam")
}

public CmdChooseteam(id)
{
        if (cs_get_user_team(id) == CS_TEAM_UNASSIGNED || cs_get_user_team(id) == CS_TEAM_SPECTATOR)
        return PLUGIN_CONTINUE

        client_cmd(id,"say menu") // Code... CmdMenu(id)
        return PLUGIN_HANDLED
}

Try this, sorry for my english. :3


All times are GMT -4. The time now is 10:09.

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