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

Admin menu custom Imput in Chat


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
rtk
Senior Member
Join Date: Dec 2009
Old 09-11-2012 , 17:49   Admin menu custom Imput in Chat
Reply With Quote #1

Hey, I wanted to know if there is any way to make the commands we put in adminmenu_custom.txt to use imput from chat in one or more parameters of the command.

Like Sourcebans, that has the option to imput the ban reason from chat I wanted to do something similar.

So I can use something like add_stamm_points <userid> <number>, where number is what I type in chat. It would be something like this:

Code:
        "Add Stamm Points"
        {
            "cmd"        "add_stamm_points #1 #2"
            "execute"    "server"
            "1"
            {
                "type"        "teamplayer"
                "method"    "name"
                "title"        "Player:"
            }
            "2"
            {
                "type"         "chat"
                "message"    "Type now the number of points to add:"
            }
        }
The command I gave was just a example, This would be extremely useful for a lot of commands and Cvars.

If there isn't a way to do this already then I think this is a MUST for a next SourceMod release.
__________________
Never argue with an idiot. He lowers you to his level and then wins on experience!
rtk is offline
asherkin
SourceMod Developer
Join Date: Aug 2009
Location: OnGameFrame()
Old 09-11-2012 , 19:23   Re: Admin menu custom Imput in Chat
Reply With Quote #2

Quote:
Originally Posted by rtk View Post
If there isn't a way to do this already then I think this is a MUST for a next SourceMod release.
You're welcome to contribute a patch for it.
__________________
asherkin is offline
rtk
Senior Member
Join Date: Dec 2009
Old 09-12-2012 , 12:07   Re: Admin menu custom Imput in Chat
Reply With Quote #3

I would have all the pleasure to help developing SourceMod but unfortunately I don't know enough about scripting to make it happen. And it kind of already exists since some plugins like SourceBans or Stamm use it so I think it's half done. I can try to give a look at it though.
I've already contributed with the idea, and for now that is all I can do. If I come up with something useful I'll tell.
__________________
Never argue with an idiot. He lowers you to his level and then wins on experience!
rtk 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 00:14.


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