Fix CuboidClipboard-Chaos
Dieser Commit ist enthalten in:
Ursprung
de2e880e0e
Commit
0fe01c40e5
@ -49,7 +49,6 @@
|
||||
<groupId>steamwar</groupId>
|
||||
<artifactId>SpigotCore_API</artifactId>
|
||||
<version>2.0</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>steamwar</groupId>
|
||||
|
@ -43,7 +43,6 @@
|
||||
<groupId>steamwar</groupId>
|
||||
<artifactId>SpigotCore_API</artifactId>
|
||||
<version>2.0</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
@ -1,14 +1,12 @@
|
||||
package de.steamwar.sql;
|
||||
|
||||
import com.sk89q.worldedit.EmptyClipboardException;
|
||||
import com.sk89q.worldedit.WorldEdit;
|
||||
import com.sk89q.worldedit.bukkit.BukkitWorld;
|
||||
import com.sk89q.worldedit.bukkit.WorldEditPlugin;
|
||||
import com.sk89q.worldedit.data.DataException;
|
||||
import com.sk89q.worldedit.extension.platform.Actor;
|
||||
import com.sk89q.worldedit.extent.clipboard.Clipboard;
|
||||
import com.sk89q.worldedit.extent.clipboard.io.ClipboardFormat;
|
||||
import com.sk89q.worldedit.schematic.MCEditSchematicFormat;
|
||||
import com.sk89q.worldedit.schematic.SchematicFormat;
|
||||
import com.sk89q.worldedit.session.ClipboardHolder;
|
||||
import com.sk89q.worldedit.world.registry.WorldData;
|
||||
import org.bukkit.Bukkit;
|
||||
@ -46,12 +44,8 @@ class Schematic_8 {
|
||||
getWorldEditPlugin().getWorldEdit().getSessionManager().get(actor).setClipboard(new ClipboardHolder(clipboard, world));
|
||||
}
|
||||
|
||||
static Clipboard getClipboard(InputStream is) throws IOException, NoClipboardException {
|
||||
try {
|
||||
return (Clipboard) ((MCEditSchematicFormat)SchematicFormat.getFormat("mcedit")).load(is);
|
||||
} catch (DataException e) {
|
||||
throw new NoClipboardException();
|
||||
}
|
||||
static Clipboard getClipboard(InputStream is) throws IOException {
|
||||
return ClipboardFormat.findByAlias("mcedit").getReader(is).read(WorldEdit.getInstance().getServer().getWorlds().get(0).getWorldData());
|
||||
}
|
||||
|
||||
private static WorldEditPlugin getWorldEditPlugin() {
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren