mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-05 14:42:22 -07:00
Added API for manipulating map items. Thanks SpaceManiac, codename_B, sk89q and dested!
By: EvilSeph <evilseph@gmail.com>
This commit is contained in:
@@ -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();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user