2016-02-29 21:33:06 +00:00
|
|
|
From 82fbb6298f22d11a2ed1c53d3f47c21f7e7e3e78 Mon Sep 17 00:00:00 2001
|
2014-07-21 20:46:54 +00:00
|
|
|
From: md_5 <md_5@live.com.au>
|
|
|
|
Date: Sat, 21 Sep 2013 12:33:09 +1000
|
|
|
|
Subject: [PATCH] Allow Disabling of 1.6.3 Structure Saving
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/StructureGenerator.java b/src/main/java/net/minecraft/server/StructureGenerator.java
|
2016-02-29 21:33:06 +00:00
|
|
|
index dacba33..4a4d2af 100644
|
2014-07-21 20:46:54 +00:00
|
|
|
--- a/src/main/java/net/minecraft/server/StructureGenerator.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/StructureGenerator.java
|
2016-02-29 21:33:06 +00:00
|
|
|
@@ -197,7 +197,13 @@ public abstract class StructureGenerator extends WorldGenBase {
|
2014-07-21 20:46:54 +00:00
|
|
|
|
2016-02-29 21:33:06 +00:00
|
|
|
protected void a(World world) {
|
|
|
|
if (this.a == null) {
|
|
|
|
- this.a = (PersistentStructure) world.a(PersistentStructure.class, this.a());
|
2014-07-21 20:46:54 +00:00
|
|
|
+ // Spigot Start
|
2016-02-29 21:33:06 +00:00
|
|
|
+ if (world.spigotConfig.saveStructureInfo) {
|
|
|
|
+ this.a = (PersistentStructure) world.a(PersistentStructure.class, this.a());
|
|
|
|
+ } else {
|
|
|
|
+ this.a = new PersistentStructure(this.a());
|
2014-07-21 20:46:54 +00:00
|
|
|
+ }
|
|
|
|
+ // Spigot End
|
2016-02-29 21:33:06 +00:00
|
|
|
if (this.a == null) {
|
|
|
|
this.a = new PersistentStructure(this.a());
|
|
|
|
world.a(this.a(), (PersistentBase) this.a);
|
2014-07-21 20:46:54 +00:00
|
|
|
diff --git a/src/main/java/org/spigotmc/SpigotWorldConfig.java b/src/main/java/org/spigotmc/SpigotWorldConfig.java
|
2016-02-29 21:33:06 +00:00
|
|
|
index c2452d6..89f9bc3 100644
|
2014-07-21 20:46:54 +00:00
|
|
|
--- a/src/main/java/org/spigotmc/SpigotWorldConfig.java
|
|
|
|
+++ b/src/main/java/org/spigotmc/SpigotWorldConfig.java
|
2016-02-29 21:33:06 +00:00
|
|
|
@@ -184,4 +184,16 @@ public class SpigotWorldConfig
|
2014-07-21 20:46:54 +00:00
|
|
|
randomLightUpdates = getBoolean( "random-light-updates", false );
|
|
|
|
log( "Random Lighting Updates: " + randomLightUpdates );
|
|
|
|
}
|
|
|
|
+
|
|
|
|
+ public boolean saveStructureInfo;
|
|
|
|
+ private void structureInfo()
|
|
|
|
+ {
|
|
|
|
+ saveStructureInfo = getBoolean( "save-structure-info", true );
|
|
|
|
+ log( "Structure Info Saving: " + saveStructureInfo );
|
|
|
|
+ if ( !saveStructureInfo )
|
|
|
|
+ {
|
2015-01-25 14:35:55 +00:00
|
|
|
+ log( "*** WARNING *** You have selected to NOT save structure info. This may cause structures such as fortresses to not spawn mobs!" );
|
2014-07-21 20:46:54 +00:00
|
|
|
+ log( "*** WARNING *** Please use this option with caution, SpigotMC is not responsible for any issues this option may cause in the future!" );
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
}
|
|
|
|
--
|
2016-02-29 21:33:06 +00:00
|
|
|
2.5.0
|
2014-07-21 20:46:54 +00:00
|
|
|
|