mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2025-06-28 03:34:42 +02:00
Sponge fixes
This commit is contained in:
@ -178,8 +178,6 @@ public class EntityWrapper {
|
||||
this.x = loc.getX();
|
||||
this.y = loc.getY();
|
||||
this.z = loc.getZ();
|
||||
System.out.print("ENTITY: " + entity.getType());
|
||||
System.out.print("ENTITY: " + entity.getType().getTypeId());
|
||||
this.id = entity.getType().getTypeId();
|
||||
if (depth == 0) {
|
||||
return;
|
||||
|
@ -494,7 +494,6 @@ public class BukkitChunkManager extends ChunkManager {
|
||||
public static void restoreEntities(final World world, final int x_offset, final int z_offset) {
|
||||
for (final EntityWrapper entity : entities) {
|
||||
try {
|
||||
System.out.print("RESTORING ENTITIE!: " + EntityType.fromId(entity.id));
|
||||
entity.spawn(world, x_offset, z_offset);
|
||||
} catch (final Exception e) {
|
||||
PS.debug("Failed to restore entity (e): " + entity.x + "," + entity.y + "," + entity.z + " : " + entity.id + " : " + EntityType.fromId(entity.id));
|
||||
|
@ -103,7 +103,6 @@ public class BukkitSetupUtils extends SetupUtils {
|
||||
return;
|
||||
}
|
||||
File file = new File("bukkit.yml").getAbsoluteFile();
|
||||
System.out.print(file.getAbsolutePath());
|
||||
YamlConfiguration yml = YamlConfiguration.loadConfiguration(file);
|
||||
yml.set("worlds." + world + ".generator", generator);
|
||||
try {
|
||||
|
@ -131,7 +131,11 @@ public class SpongeBlockManager extends BlockManager {
|
||||
|
||||
@Override
|
||||
public Location getSpawn(String world) {
|
||||
return SpongeUtil.getLocation(world, SpongeUtil.getWorld(world).getSpawnLocation());
|
||||
World worldObj = SpongeUtil.getWorld(world);
|
||||
org.spongepowered.api.world.Location loc = worldObj.getSpawnLocation();
|
||||
Location result = SpongeUtil.getLocation(world, SpongeUtil.getWorld(world).getSpawnLocation());
|
||||
result.setY(getHeighestBlock(world, result.getX(), result.getZ()));
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Reference in New Issue
Block a user