Added API for manipulating map items. Thanks SpaceManiac, codename_B, sk89q and dested!

By: EvilSeph <evilseph@gmail.com>
This commit is contained in:
Bukkit/Spigot
2011-08-12 21:59:10 -04:00
parent df275c8376
commit cd7da9630a
14 changed files with 1181 additions and 1 deletions

View File

@@ -12,6 +12,7 @@ import java.util.logging.Logger;
import org.bukkit.command.PluginCommand;
import org.bukkit.command.CommandSender;
import org.bukkit.map.MapView;
import org.bukkit.plugin.PluginManager;
import org.bukkit.plugin.ServicesManager;
import org.bukkit.scheduler.BukkitScheduler;
@@ -246,6 +247,22 @@ public interface Server {
* @return World with the given Unique ID, or null if none exists.
*/
public World getWorld(UUID uid);
/**
* Gets the map from the given item ID.
*
* @param id ID of the map to get.
* @return The MapView if it exists, or null otherwise.
*/
public MapView getMap(short id);
/**
* Create a new map with an automatically assigned ID.
*
* @param world The world the map will belong to.
* @return The MapView just created.
*/
public MapView createMap(World world);
/**
* Reloads the server, refreshing settings and plugin information
@@ -329,4 +346,4 @@ public interface Server {
* @return Whether this server allows flying or not.
*/
public boolean getAllowFlight();
}
}