Talk:CommandBook/Commands

From SK's Wiki
Jump to: navigation, search

Contents

[edit] /warp and /tp command improvement suggestions

Ok, so the overall the command system here is pretty good and much better than Essentials, however this is room for improvement and I'd like to make some suggestions.

My users in SMP and I have found that some commands are confusing due to required verbosity and strictness. I'm talking about things like if you want to go to a different world in a multi-world server, there is no good easy /MOVE-ME-HERE WORLD-NAME syntax. The easiest I've found is /tp #spawn:world. I have a few suggestions to make things easier for everyone.

First of all, /warp and /tp do the same thing. The move a target to a destination. Part of what's confusing is the two command use different syntax and take different arguments. Let's merge those two commands and make them take the same argument set. Better yet, let's get rid of /warp (but I can see the value in keeping it since some people may expect that command).

In addition, while the syntax for those two commands is powerful, there are too few abbreviated versions to be useful in some common situations like jumping to a world. If I name a world using /warp WORLD then I expect to end up at either the spawn point in that world or the last location I was at in that world with the default being the spawn point. The latter is more difficult to implement but also more useful, so I would strongly suggest it.

So, in the interest of simplification of the syntax, I would suggest this: If the user enters anything that could be a destination then take that user to that destination. What does it mean to be a destination? Well, it breaks down into a coordinate and a world name. If the user types out a coordinate (and please allow spaces and allow leaving out the height-coordinate-portion. It's so much easier to use with both are ok. Here's a regular expression to help: /(-?[0-9]+)(,| ) *(-?[0-9]+)((,| ) *(-?[0-9]+))?/; matching forms: [x,z] [x,y,z] [x, z] [x, y, z] [x z] [x y z]; capture-buck numbers: $1 == x; if $6 is empty { $3 == z; calculate height } else { $3 == y; $6 == z }) then assume the current world. In addition, it would be nice if two coordinates were allowed and just put the player at the highest land at that point.

So, in conclusion this might work better as a 'get to a place' command set:

Command Description Permissions
/warp destination
/tp destination
Moves the current player directly to the specified destination. The destination may be any of the following:
  • A player name - Moves to the named players location and world.
  • X and Z coordinate - Moves to the highest solid block at that location in the current world.
  • X, Y and Z coordinate - Moves to that location in the current world.
  • A world name - Moves to the spawn point in the named world (or possibly the last location of the current player in that world).
  • A world name and a coordinate set (coordinate as above) - Moves to that location in the named world.
  • A coordinate set and world name - same as above
  • A warp name - Moves to the warp location and world.
  • commandbook.tp.use - Permits moving only yourself.
  • commandbook.tp.other - Permits moving a player other than the player who entered the command.
  • commandbook.tp.other.permission-group, player-name or world-name
    • Permits moving a player who is in the named permissions group, who is the named player or the who is in the named world.
  • commandbook.tp.other.home
    • Permits moving to another players home.
  • commandbook.tp.other.home.permission-group, player-name or world-name
    • Permits moving to another players home who is in the named permissions group, who is the named player or who is in the named world.
  • commandbook.tp.use.coordinate
    • Permits use of coordinates.
  • commandbook.tp.use.coordinate.world-name
    • Permits use of coordinates only in the named world.
  • commandbook.tp.use.warp
    • Permits moving to any warp.
  • commandbook.tp.use.warp.*
    • Permits moving to any warp.
  • commandbook.tp.use.warp.warp-name
    • Permits moving to the named warp.
  • commandbook.tp.use.world
    • Permits moving to any world.
  • commandbook.tp.use.world.*
    • Permits moving to any world.
  • commandbook.tp.use.world.world-name
    • Permits moving to the named world.
  • commandbook.tp.home
    • Permits moving to his or her home.
/warp target destination Moves the specified target directly to the specified destination. Destination as above. Target may be any of the following
  • A named player
  • (I can't think of anything else off the top of my head...)

[edit] Examples

[edit] Some conflict resolution

[edit] Some restrictions

So, this is all quite complicated to implement and I don't expect it all. Just take a look and let me know what you all think.

Servel333 07:08, 29 December 2011 (PST)

[edit] How to give enchanted items?

I've been trying to use /give and /item(/i) to give tools with multiple enchantments, but I am having no success. How would I give, for example, a diamond axe with Efficiency V, Unbreaking III, and Fortune III? Please help me :D How to give a tool with ONE enchantment at least?

do \item diamondaxe|digspeed:5,durability:3,loot_bonus_blocks:3


I've been struggling with this too and looked at the CommandBook to figure it out.

based on Enchantment.java

Servel333 18:08, 29 February 2012 (PST)

Personal tools
Namespaces
Variants
Actions
Sections
Navigation
Toolbox