You are not logged in.
Pages: 1
Hi there,
After long research I have found out that the only way to get players other than yourself involved in custom command is to use the [1] flag.
What's annoying about that is that it copies exactly what the executor of the command wrote. For example if my name is flipside on the server and someone will use a command on me typing !owned flip, the text will look like this:
I owned you, flip!
Is it somehow possible to get the server into seeing what player is meant and copying his name in the exact same fashion it actually is? So that my example would look like this: !owned flip would print 'I owned you, flipside!'
Also I've been wondering for a while how you would create a command that would make the server send a message to ONLY the player I want it to see. For example, !invite flip would send a message to me saying something: Congratulations, you have been invited to join our clan! But only I could see it.
If anyone can help me out on this I'd appreciate it big time.
Offline
After long research I have found out that the only way to get players other than yourself involved in custom command is to use the [1] flag.
What's annoying about that is that it copies exactly what the executor of the command wrote. For example if my name is flipside on the server and someone will use a command on me typing !owned flip, the text will look like this:
I owned you, flip!
Is it somehow possible to get the server into seeing what player is meant and copying his name in the exact same fashion it actually is? So that my example would look like this: !owned flip would print 'I owned you, flipside!'
There's a great thread on mygamingtalk.com, nicely supported by silEnT mod devs: http://mygamingtalk.com/forums/topic/23 … -questions
Why do I post this? Lua is something you should start working with.
Also I've been wondering for a while how you would create a command that would make the server send a message to ONLY the player I want it to see. For example, !invite flip would send a message to me saying something: Congratulations, you have been invited to join our clan! But only I could see it.
If anyone can help me out on this I'd appreciate it big time.
et.trap_SendConsoleCommand(et.EXEC_APPEND, string.format("m %s ^8Congratulations, you've been invited to join our clan!\n", userslot)) //sending private msg from the console
Last edited by Dragonji (05-Apr-13 18:51:42)
Offline
Well, I don't fancy learning a whole new type of language just for adding a handful of commands. I don't have the time to anyway. Could you please create a sample file of what I could use for my said issues and how I could combine it with custom shrubbot commands? I remember our server running a few scripts that worked with simple / commands so /rules would give you a list of rules etc. But this should be clearly defined for admins and not for everyone.
Last edited by flipside1993 (05-Apr-13 20:10:10)
Offline
At first I would like someone to confirm one thing as I'm not sure if it is available in N!tmod too.
In silEnT, if we've got a custom command defined like this:
[command]
command = sayname
exec = sayname [1] [i]
desc = Say a player's name
levels = 2 4 5
et.trap_Argc() equals 3
et.trap_Argv(0) = sayname
et.trap_Argv(1) = [1] which is a string entered by user
et.trap_Argv(2) = [i] which is a slot number of the player who called the command
If this is all available in N!tmod, I may write something useful for ya.
Offline
No one?
Offline
Should be possible with lua
Made Hide&Seek mod: http://forums.warchest.com/showthread.p … -Seek-pack
Creator of Infected Mod: http://forums.warchest.com/showthread.p … d-Infected
Offline
I figured that by reading Dragonji's post ...
Offline
At first I would like someone to confirm one thing as I'm not sure if it is available in N!tmod too.
In silEnT, if we've got a custom command defined like this:
[command] command = sayname exec = sayname [1] [i] desc = Say a player's name levels = 2 4 5
et.trap_Argc() equals 3
et.trap_Argv(0) = sayname
et.trap_Argv(1) = [1] which is a string entered by user
et.trap_Argv(2) = [i] which is a slot number of the player who called the commandIf this is all available in N!tmod, I may write something useful for ya.
Sorry for the (really) late reply...
It's working as you described, except for one thing:
In the current version [i] has no effect, but in the next build it will be replaced by the slot number of the player who used the command.
Offline
Better late than never. I'm glad you're going to add this feature in the next build.
Offline
Pages: 1