Raised This Month: $ Target: $400
 0% 

Help Menu


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Styles
Veteran Member
Join Date: Jul 2004
Location: California
Old 01-04-2006 , 02:21   Help Menu
Reply With Quote #1

Is it possible to not allow a register_clcmd to showup in the amx_help? If so please help me out. thanks!
Styles is offline
Send a message via AIM to Styles
Charr
Senior Member
Join Date: Jul 2005
Location: Long Island, New York, U
Old 01-04-2006 , 08:33  
Reply With Quote #2

Instead of registering it in plugin_init(), put in client_command(id):
Code:
public client_command(id) {     new cmd[32],arg[32]     read_argv(0,cmd,31)     read_argv(1,arg,31)     if(equali(cmd,"...")) {         ...     }     return PLUGIN_CONTINUE }
Charr is offline
Send a message via AIM to Charr Send a message via MSN to Charr
Styles
Veteran Member
Join Date: Jul 2004
Location: California
Old 01-04-2006 , 21:40  
Reply With Quote #3

Ok guys wait this isant working

Code:
public client_command(id) {     new cmd[32]     read_argv(0,cmd,31)     read_argv(1,pass,31)         if(equali(cmd, "pass")) { //This line has to many errors.      console_print(id,"[Hax0r] ")     }if(equali(cmd,logged_a)){      console_print(id,"[Hax0r] ")       }else if(!equali(cmd, pass)) {       console_print(id, "[Hax0r] ")     }     return PLUGIN_CONTINUE }
Styles is offline
Send a message via AIM to Styles
Jordan
Veteran Member
Join Date: Aug 2005
Old 01-04-2006 , 22:39  
Reply With Quote #4

Code:
#include <amxmodx> #include <amxmisc> public client_command(id) {     new cmd[32]     new pass[32]     read_argv(0,cmd,31)     read_argv(1,pass,31)         if(equali(cmd, "pass")) { //This line has to many errors.      console_print(id,"[Hax0r] ")     }if(equali(cmd,logged_a)){      console_print(id,"[Hax0r] ")         }else if(!equali(cmd, pass)) {       console_print(id, "[Hax0r] ")     }     return PLUGIN_CONTINUE }

I don't know what logged_a is so I can't really help you with that...

All the errors are fixed except for logged_a o.O
Jordan is offline
Styles
Veteran Member
Join Date: Jul 2004
Location: California
Old 01-04-2006 , 23:09  
Reply With Quote #5

Ok heres what i want
a command

amx_secretlogin <PASSWORD>
--I dont want it to be shown in amx_help--

How do you do that? I dont understand
Styles is offline
Send a message via AIM to Styles
ShAyA
Member
Join Date: Oct 2005
Old 01-04-2006 , 23:52  
Reply With Quote #6

Make the command only seeable by Admins:

register_concmd("command","pluginMethod",ADMI N_KICK,"whatever")

If its suppose to only be used by admins.

or register_clcmd("say", "pluginMethod")

and then read_argv etc.
ShAyA is offline
teame06
i have a hat
Join Date: Feb 2005
Location: Hat City
Old 01-05-2006 , 00:09  
Reply With Quote #7

http://forums.alliedmods.net/showthr...p?t=21280+help

You have to modify the adminhelp.sma

It been done here.. Follow that link to know how.
__________________
No private support via Instant Message
GunGame:SM Released
teame06 is offline
Send a message via AIM to teame06
Styles
Veteran Member
Join Date: Jul 2004
Location: California
Old 01-05-2006 , 14:20  
Reply With Quote #8

You dont get it. Im trying to make a plugin where the command to type in console is secret and doesnt show in amx_help.

so you type amx_helper <Name> Gives you w/e.
Styles is offline
Send a message via AIM to Styles
Charr
Senior Member
Join Date: Jul 2005
Location: Long Island, New York, U
Old 01-05-2006 , 14:48  
Reply With Quote #9

You can either changed adminhelp.sma to skip your command, or you can use client_command. In your case, I would recommend that you use client_command.
When you use equali, you compare two arrayed varibles. If you are comparing it to a constant expersion (something that remains the same all the time, you need to put it in quotes.
This is wrong:
Code:
if(equali(cmd,password))
ERROR: Undefined symbol 'password'

This is correct:
Code:
if(equali(cmd,"password"))
Charr is offline
Send a message via AIM to Charr Send a message via MSN to Charr
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 16:01.


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