Need help with change command syntax
Hi men! I made some command to set player's team. (I needed it and I made it) It works cool, but not as I wanted first.
Syntax now: setteam <team: t|ct|spec> [name or #userid] [kill] Is it possible to make it like this: setteam [name or #userid] <team: t|ct|spec> [kill] I think it is possible but players can't have names like in teams' tokens, am i right? PHP Code:
|
Re: Need help with change command syntax
If you made it then you should be more than capable of switching the indices inside read_argv.
|
Re: Need help with change command syntax
Quote:
|
Re: Need help with change command syntax
Quote:
|
Re: Need help with change command syntax
Quote:
|
Re: Need help with change command syntax
Oh, I see now. All required arguments must be before optional argument if you don't have a definitive way to differentiate between the two types. But if you do have a way to definitively differentiate between them, you would just have a single argument anyways.
I know that some plugins look for "@team" in a player name argument to apply an action to a whole team. However, this relies on a player never having that string in their name and you, as the executer of the function, not trying to apply it to a player using that string. |
| All times are GMT -4. The time now is 11:35. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.