Start worlds.txt edit commands - add /dmap worldlist and /dmap worldset

This commit is contained in:
Mike Primm 2012-02-05 15:53:24 -06:00
parent 3b19d11694
commit 86c7dee750
2 changed files with 23 additions and 0 deletions

View File

@ -240,6 +240,14 @@ public class DynmapPlugin extends JavaPlugin implements DynmapAPI {
public void resetCacheStats() { public void resetCacheStats() {
sscache.resetStats(); sscache.resetStats();
} }
@Override
public DynmapWorld getWorldByName(String wname) {
World w = getServer().getWorld(wname); /* FInd world */
if(w != null) {
return new BukkitWorld(w);
}
return null;
}
} }
/** /**
* Player access abstraction class * Player access abstraction class

View File

@ -73,6 +73,13 @@ commands:
/<command> listareas - list details of all areas /<command> listareas - list details of all areas
/<command> updatearea <label> <arg>:<value> ... - update attributes of area with given label /<command> updatearea <label> <arg>:<value> ... - update attributes of area with given label
/<command> updatearea id:<id> <arg>:<value> ... - update attributes of area with given ID /<command> updatearea id:<id> <arg>:<value> ... - update attributes of area with given ID
dmap:
description: List and modify dynmap configuration
usage: |
/<command> worldlist - list all worlds configured (enabled or disabled)
/<command> worldset worldname enabled:<true|false> - enable or disable a world
/<command> worldset worldname center:<x/y/z|here|default> - set map center for given world
/<command> worldset worldname extrazoomout:<N> - set extra zoom out levels for given world
permissions: permissions:
dynmap.*: dynmap.*:
@ -113,6 +120,8 @@ permissions:
dynmap.marker.updatearea: true dynmap.marker.updatearea: true
dynmap.marker.listareas: true dynmap.marker.listareas: true
dynmap.marker.deletearea: true dynmap.marker.deletearea: true
dynmap.dmap.worldlist: true
dynmap.dmap.worldset: true
dynmap.render: dynmap.render:
description: Allows /dynmap render command description: Allows /dynmap render command
default: true default: true
@ -218,4 +227,10 @@ permissions:
dynmap.marker.deletearea: dynmap.marker.deletearea:
description: Allows /dmarker deletearea description: Allows /dmarker deletearea
default: op default: op
dynmap.dmap.worldlist:
description: Allows /dmap worldlist
default: op
dynmap.dmap.worldset:
description: Allows /dmap worldset
default: op