diff options
author | Namikon <namikon@gmx.net> | 2015-10-29 14:13:38 +0100 |
---|---|---|
committer | Namikon <namikon@gmx.net> | 2015-10-29 14:13:38 +0100 |
commit | 8f86be389bb7b1f9a9d17c0d009602834ff1d93a (patch) | |
tree | 842ffd2c10e36619f4b82fbe3183c8007c80764c | |
parent | 7a021c55d0e44e6f3dc46acf0040ead2df7a3846 (diff) | |
download | GT5-Unofficial-8f86be389bb7b1f9a9d17c0d009602834ff1d93a.tar.gz GT5-Unofficial-8f86be389bb7b1f9a9d17c0d009602834ff1d93a.tar.bz2 GT5-Unofficial-8f86be389bb7b1f9a9d17c0d009602834ff1d93a.zip |
Removed SpaceDim registration. This is supposed to be done by an external mod.
Also removed the warning about misconfiguration, as this mod alone won't do anything by itself now
-rw-r--r-- | build.gradle | 2 | ||||
-rw-r--r-- | src/main/java/bloodasp/galacticgreg/GalacticGreg.java | 53 | ||||
-rw-r--r-- | src/main/java/bloodasp/galacticgreg/ModRegisterer.java | 7 | ||||
-rw-r--r-- | src/main/java/bloodasp/galacticgreg/auxiliary/GalacticGregConfig.java | 17 |
4 files changed, 26 insertions, 53 deletions
diff --git a/build.gradle b/build.gradle index f0ea1788af..df35f601b8 100644 --- a/build.gradle +++ b/build.gradle @@ -19,7 +19,7 @@ apply plugin: 'forge' // Never remove the MC version or you will break autobuild! // New 3-segment versioning. 0.9 MUST remain static, as this indicates "GT5" mode of this mod -version = "1.7.10-0.9.3" +version = "1.7.10-0.9.4" group= "bloodasp.galactigreg" // http://maven.apache.org/guides/mini/guide-naming-conventions.html archivesBaseName = "GalacticGreg" diff --git a/src/main/java/bloodasp/galacticgreg/GalacticGreg.java b/src/main/java/bloodasp/galacticgreg/GalacticGreg.java index 02f45a1187..f9a280bfc3 100644 --- a/src/main/java/bloodasp/galacticgreg/GalacticGreg.java +++ b/src/main/java/bloodasp/galacticgreg/GalacticGreg.java @@ -1,7 +1,5 @@ package bloodasp.galacticgreg; -import gregtech.api.GregTech_API; - import java.util.ArrayList; import java.util.List; import java.util.Random; @@ -12,8 +10,6 @@ import bloodasp.galacticgreg.auxiliary.ProfilingStorage; import bloodasp.galacticgreg.command.AEStorageCommand; import bloodasp.galacticgreg.command.ProfilingCommand; import bloodasp.galacticgreg.registry.GalacticGregRegistry; -import bloodasp.galacticgreg.schematics.SpaceSchematic; -import bloodasp.galacticgreg.schematics.SpaceSchematicFactory; import bloodasp.galacticgreg.schematics.SpaceSchematicHandler; import cpw.mods.fml.common.Loader; import cpw.mods.fml.common.Mod; @@ -50,15 +46,10 @@ public class GalacticGreg { if (!GalacticConfig.LoadConfig()) GalacticGreg.Logger.warn("Something went wrong while reading GalacticGregs config file. Things will be wonky.."); - if (GalacticConfig.ProperConfigured) - { - GalacticRandom = new Random(System.currentTimeMillis()); - - if (GalacticConfig.SchematicsEnabled) - SchematicHandler = new SpaceSchematicHandler(aEvent.getModConfigurationDirectory()); - } - else - GalacticGreg.Logger.error("GalacticGreg will NOT continue to load. Please read the warnings and configure your config file!"); + GalacticRandom = new Random(System.currentTimeMillis()); + + if (GalacticConfig.SchematicsEnabled) + SchematicHandler = new SpaceSchematicHandler(aEvent.getModConfigurationDirectory()); Logger.trace("Leaving PRELOAD"); } @@ -72,21 +63,14 @@ public class GalacticGreg { @EventHandler public void onPostLoad(FMLPostInitializationEvent aEvent) { Logger.trace("Entering POSTLOAD"); - if (GalacticConfig.ProperConfigured) - { - ModRegisterer atc = new ModRegisterer(); - if (atc.Init()) - atc.Register(); - - if (!GalacticGregRegistry.InitRegistry()) - throw new RuntimeException("GalacticGreg registry has been finalized from a 3rd-party mod, this is forbidden!"); + + if (!GalacticGregRegistry.InitRegistry()) + throw new RuntimeException("GalacticGreg registry has been finalized from a 3rd-party mod, this is forbidden!"); + + new WorldGenGaGT().run(); + + GalacticConfig.serverPostInit(); - new WorldGenGaGT().run(); - - GalacticConfig.serverPostInit(); - } - else - GalacticGreg.Logger.error("GalacticGreg will NOT continue to load. Please read the warnings and configure your config file!"); Logger.trace("Leaving POSTLOAD"); } @@ -98,14 +82,13 @@ public class GalacticGreg { public void serverLoad(FMLServerStartingEvent pEvent) { Logger.trace("Entering SERVERLOAD"); - if (GalacticConfig.ProperConfigured) - { - if (GalacticConfig.ProfileOreGen) - pEvent.registerServerCommand(new ProfilingCommand()); - - if (Loader.isModLoaded("appliedenergistics2") && GalacticConfig.EnableAEExportCommand && GalacticConfig.SchematicsEnabled) - pEvent.registerServerCommand(new AEStorageCommand()); - } + + if (GalacticConfig.ProfileOreGen) + pEvent.registerServerCommand(new ProfilingCommand()); + + if (Loader.isModLoaded("appliedenergistics2") && GalacticConfig.EnableAEExportCommand && GalacticConfig.SchematicsEnabled) + pEvent.registerServerCommand(new AEStorageCommand()); + Logger.trace("Leaving SERVERLOAD"); } } diff --git a/src/main/java/bloodasp/galacticgreg/ModRegisterer.java b/src/main/java/bloodasp/galacticgreg/ModRegisterer.java index 96bc2c45bb..d599c7a210 100644 --- a/src/main/java/bloodasp/galacticgreg/ModRegisterer.java +++ b/src/main/java/bloodasp/galacticgreg/ModRegisterer.java @@ -40,11 +40,13 @@ public class ModRegisterer */ public static void registerModContainer(ModContainer pModContainer) { + /* try { registerModContainer.invoke(null, pModContainer); } catch (Exception e) { e.printStackTrace(); } + */ } /** @@ -53,6 +55,8 @@ public class ModRegisterer */ public boolean Init() { + return false; + /* try { Class gGregRegistry = Class.forName("bloodasp.galacticgreg.registry.GalacticGregRegistry"); @@ -65,10 +69,12 @@ public class ModRegisterer // GalacticGreg is not installed or something is wrong return false; } + */ } public void Register() { + /* if (GalacticGreg.GalacticConfig.RegisterVanillaDim) registerModContainer(Setup_Vanilla()); @@ -80,6 +86,7 @@ public class ModRegisterer if (GalacticGreg.GalacticConfig.RegisterGalaxySpace) registerModContainer(Setup_GalaxySpace()); + */ } /** diff --git a/src/main/java/bloodasp/galacticgreg/auxiliary/GalacticGregConfig.java b/src/main/java/bloodasp/galacticgreg/auxiliary/GalacticGregConfig.java index f640f61193..54d20f395f 100644 --- a/src/main/java/bloodasp/galacticgreg/auxiliary/GalacticGregConfig.java +++ b/src/main/java/bloodasp/galacticgreg/auxiliary/GalacticGregConfig.java @@ -21,14 +21,9 @@ public class GalacticGregConfig extends ConfigManager { public boolean PrintDebugMessagesToFMLLog; public boolean PrintTraceMessagesToFMLLog; - public boolean RegisterVanillaDim; - public boolean RegisterGalacticCraftCore; - public boolean RegisterGalacticCraftPlanets; - public boolean RegisterGalaxySpace; public boolean LootChestsEnabled; public boolean EnableAEExportCommand; public boolean SchematicsEnabled; - public boolean ProperConfigured; public String LootChestItemOverride; public boolean QuietMode; @@ -43,16 +38,10 @@ public class GalacticGregConfig extends ConfigManager { LootChestsEnabled = true; - RegisterVanillaDim = true; - RegisterGalacticCraftCore = true; - RegisterGalacticCraftPlanets = true; - RegisterGalaxySpace = true; - // Default false, as it is WiP EnableAEExportCommand = false; SchematicsEnabled = false; - ProperConfigured = false; LootChestItemOverride = ""; QuietMode = false; } @@ -65,15 +54,9 @@ public class GalacticGregConfig extends ConfigManager { PrintTraceMessagesToFMLLog = _mainConfig.getBoolean("PrintTraceMessagesToFMLLog", "Debug", PrintTraceMessagesToFMLLog, "Enable trace output. Warning: This will produce gazillions of log entries"); QuietMode = _mainConfig.getBoolean("QuietMode", "Debug", QuietMode, "In quiet-mode only errors, warnings and fatals will be printed to the logfile/console"); - RegisterVanillaDim = _mainConfig.getBoolean("RegisterVanillaDim", "BuildInMods", RegisterVanillaDim, "Enable to register the build-in dimension definition for TheEnd - Asteroids"); - RegisterGalacticCraftCore = _mainConfig.getBoolean("RegisterGalacticCraftCore", "BuildInMods", RegisterGalacticCraftCore, "Enable to register the build-in dimension definition for GalacticCraft Core (The moon)"); - RegisterGalacticCraftPlanets = _mainConfig.getBoolean("RegisterGalacticCraftPlanets", "BuildInMods", RegisterGalacticCraftPlanets, "Enable to register the build-in dimension definition for GalacticCraft Planets (Mars, asteroids)"); - RegisterGalaxySpace = _mainConfig.getBoolean("RegisterGalaxySpace", "BuildInMods", RegisterGalaxySpace, "Enable to register the build-in dimension definition for GalaxySpace by BlesseNtumble"); - LootChestsEnabled = _mainConfig.getBoolean("LootChestsEnabled", "Extras", LootChestsEnabled, "Enables/disables the dungeon-chest generator system for asteroids. New config values will be generated if set to true"); EnableAEExportCommand = _mainConfig.getBoolean("EnableAEExportCommand", "Extras", EnableAEExportCommand, "If set to true, you can export any structure stored on a AE2 spatial storage disk. (Can't be spawned yet, WiP). Requires SchematicsEnabled to be true"); SchematicsEnabled = _mainConfig.getBoolean("SchematicsEnabled", "Extras", SchematicsEnabled, "Enable the experimental Schematics-handler to spawn exported schematics in dimensions. This is WiP, use at own risk"); - ProperConfigured = _mainConfig.getBoolean("IHaveConfiguredEverything", "main", ProperConfigured, "Set this to true to confirm that you've read the warnings about the massive change in WorldConfig.cfg and you backed-up / configured everything properly"); LootChestItemOverride = _mainConfig.getString("CustomLootChest", "Extras", LootChestItemOverride, "Define the chest you wish to use as LootChest. use the <ModID>:<Name>:<meta> format or leave empty for the default Minecraft Chest"); GalacticGreg.Logger.setDebugOutput(PrintDebugMessagesToFMLLog); |