Mirror von
https://github.com/IntellectualSites/FastAsyncWorldEdit.git
synchronisiert 2024-11-07 12:00:07 +01:00
Fixed regen
Dieser Commit ist enthalten in:
Ursprung
1844d4dba7
Commit
97a4d2e103
@ -192,7 +192,7 @@ public class BukkitWorld extends AbstractWorld {
|
||||
public boolean regenerate(Region region, EditSession editSession) {
|
||||
BukkitImplAdapter adapter = WorldEditPlugin.getInstance().getBukkitImplAdapter();
|
||||
if (adapter != null) {
|
||||
return adapter.regenerate(this, region, editSession);
|
||||
return adapter.regenerate(getWorld(), region, editSession);
|
||||
}
|
||||
/*
|
||||
BaseBlock[] history = new BaseBlock[16 * 16 * (getMaxY() + 1)];
|
||||
|
@ -235,7 +235,7 @@ public interface BukkitImplAdapter<T> extends IBukkitAdapter {
|
||||
throw new UnsupportedOperationException("Cannot send fake chunks");
|
||||
}
|
||||
|
||||
default boolean regenerate(com.sk89q.worldedit.world.World world, Region region, EditSession editSession) {
|
||||
default boolean regenerate(org.bukkit.World world, Region region, EditSession editSession) {
|
||||
return editSession.regenerate(region);
|
||||
}
|
||||
}
|
@ -378,7 +378,7 @@ public final class FAWE_Spigot_v1_14_R4 extends CachedBukkitAdapter implements I
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean regenerate(com.sk89q.worldedit.world.World world, Region region, EditSession editSession) {
|
||||
public boolean regenerate(org.bukkit.World world, Region region, EditSession editSession) {
|
||||
WorldServer originalWorld = ((CraftWorld) world).getHandle();
|
||||
ChunkProviderServer provider = originalWorld.getChunkProvider();
|
||||
if (!(provider instanceof ChunkProviderServer)) {
|
||||
|
@ -223,7 +223,7 @@ public class WorldWrapper extends AbstractWorld {
|
||||
|
||||
@Override
|
||||
public boolean regenerate(Region region, EditSession session) {
|
||||
return session.regenerate(region);
|
||||
return parent.regenerate(region, session);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -330,7 +330,7 @@ public class HistorySubCommands {
|
||||
RollbackOptimizedHistory edit = input.get();
|
||||
UUID uuid = edit.getUUID();
|
||||
int index = edit.getIndex();
|
||||
if (!edit.getBDFile().exists()) {
|
||||
if (!edit.isEmpty()) {
|
||||
database.delete(uuid, index);
|
||||
return TextComponent.empty();
|
||||
}
|
||||
|
@ -656,13 +656,14 @@ public class RegionCommands {
|
||||
@CommandPermissions("worldedit.regen")
|
||||
@Logging(REGION)
|
||||
@Confirm(Confirm.Processor.REGION)
|
||||
public void regenerateChunk(Actor actor, LocalSession session, EditSession editSession, @Selection Region region,
|
||||
public void regenerateChunk(Actor actor, World world, LocalSession session, EditSession editSession, @Selection Region region,
|
||||
@Arg(def = "", desc = "Regenerate with biome") BiomeType biome,
|
||||
@Arg(def = "", desc = "Regenerate with seed") Long seed) throws WorldEditException {
|
||||
Mask mask = session.getMask();
|
||||
session.setMask((Mask) null);
|
||||
session.setSourceMask((Mask) null);
|
||||
editSession.regenerate(region, biome, seed);
|
||||
world.regenerate(region, editSession);
|
||||
// editSession.regenerate(region, biome, seed);
|
||||
session.setMask(mask);
|
||||
session.setSourceMask(mask);
|
||||
actor.printInfo(TranslatableComponent.of("worldedit.regen.regenerated"));
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren