AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Autobind (https://forums.alliedmods.net/showthread.php?t=168630)

kamild1996 10-01-2011 18:21

Autobind
 
Hi.
I want to add an auto-bind - when somebody joins the server, /menu is automatically binded to V key.
Quote:

#include <amxmodx>
#include <amxmisc>

#define PLUGIN "Menu serwera"
#define VERSION "1.0"
#define AUTHOR "Redux"

public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_clcmd("say /menu","mymenu");
}
public mymenu(id)
{
new MyMenu=menu_create("\wMenu serwera [\rDeathrun\w]","cbMyMenu");

menu_additem(MyMenu,"Zmien serwer");//item=0
menu_additem(MyMenu,"Sklep DR");//item=1
menu_additem(MyMenu,"Wylacz widocznosc CT");//item=2
menu_additem(MyMenu,"Punkty");//item=3
menu_additem(MyMenu,"Menu Admina");//item=4
menu_additem(MyMenu,"Wylacz/wlacz RS");//item=5

menu_setprop(MyMenu,MPROP_EXITNAME,"Wyjscie") ;
menu_setprop(MyMenu,MPROP_EXIT,MEXIT_ALL);
menu_setprop(MyMenu,MPROP_NUMBER_COLOR,"\y");


menu_display(id, MyMenu,0);
return PLUGIN_HANDLED;
}
public cbMyMenu(id, menu, item)
{
switch(item)
{
case 0:
{
client_cmd(id, "say /serwer");

}
case 1:
{
client_cmd(id, "say /drshop");

}
case 2:
{
client_cmd(id, "say /invis");

}
case 3:
{
client_cmd(id, "say /mypoints");

}
case 4:
{
client_cmd(id, "amxmodmenu");

}
case 5:
{
client_cmd(id, "say /roundsound");

}

}
menu_destroy(menu);
return PLUGIN_HANDLED;
}
Can you help me to add this to this plugin?

Napoleon_be 10-01-2011 18:33

Re: Autobind
 
That's called slowhacking and that's not allowed.

nikhilgupta345 10-01-2011 18:34

Re: Autobind
 
Quote:

Originally Posted by Napoleon_be (Post 1566756)
That's called slowhacking and that's not allowed.

You're not allowed to assist people in slowhacking.

kamild1996 10-01-2011 18:39

Re: Autobind
 
Slowhacking? What is it?

kamild1996 10-01-2011 19:05

Re: Autobind
 
I added this:
Quote:

snip
And it's working. Thanks for help, Napoleon_be!

Napoleon_be 10-01-2011 20:17

Re: Autobind
 
Quote:

Originally Posted by kamild1996 (Post 1566769)
I added this:

And it's working. Thanks for help, Napoleon_be!

No problem, normally it's not allowed, but it's your server and you do what you want.

fysiks 10-01-2011 22:28

Re: Autobind
 
Quote:

Originally Posted by Napoleon_be (Post 1566791)
No problem, normally it's not allowed, but it's your server and you do what you want.

You need to respect the rules of the forum.

kamild1996 10-02-2011 04:40

Re: Autobind
 
Can anyone explain me, what is slowhacking and why help with autobinds are unallowed? I can't get it...

drekes 10-02-2011 05:19

Re: Autobind
 
Slowhacking is changing a client's settings (cvars, binds, ...) without his permission.

fysiks 10-02-2011 13:44

Re: Autobind
 
Quote:

Originally Posted by drekes (Post 1566935)
Slowhacking is changing a client's settings (cvars, binds, ...) without his permission.

That's what I think it should be because of the ease of removing "permission" code.


All times are GMT -4. The time now is 19:33.

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