Skip to content

Commit 3c00ad3

Browse files
committed
Fix handling of old forge-specific blockstate
1 parent 686a2ef commit 3c00ad3

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

core/src/main/java/org/dynmapblockscan/core/blockstate/ForgeVariantV1.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ public Variant generateVanilla(Map<String, BlockModel> models) {
224224
// Add model to model table
225225
models.put(modid, bm);
226226
// Switch our model reference to corresponding blockstate level model reference
227-
mod = "dynmapblockscan:forgemodel" + idx;
227+
mod = "dynmapblockscan:block/forgemodel" + idx;
228228
}
229229
// Now build vanilla variant
230230
Variant var = new Variant(mod, this.x, this.y, this.z, this.uvlock, this.weight);

forge-1.12.2/src/main/java/org/dynmapblockscan/DynmapBlockScanMod.java

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
package org.dynmapblockscan;
22

33
import java.io.File;
4+
import java.util.Arrays;
5+
import java.util.List;
46
import java.util.Map;
57

68
import net.minecraft.server.MinecraftServer;
@@ -33,6 +35,8 @@ public class DynmapBlockScanMod
3335
public static DynmapBlockScanPlugin plugin;
3436
public static File jarfile;
3537
public static boolean verboselogging = false;
38+
public static String[] excludeModules = { "minecraft" };
39+
public static String[] excludeBlockNames = { };
3640

3741
public DynmapBlockScanMod() {
3842
}
@@ -47,6 +51,10 @@ public void preInit(FMLPreInitializationEvent event)
4751
cfg.load();
4852

4953
verboselogging = cfg.get("Settings", "verboselog", false).getBoolean(false);
54+
55+
excludeModules = cfg.get("Settings", "exclude_modules", new String[] { "minecraft" }).getStringList();
56+
excludeBlockNames = cfg.get("Settings", "exclude_blocknames", new String[0]).getStringList();
57+
5058
}
5159
finally
5260
{
@@ -70,6 +78,8 @@ public void serverStarting(FMLServerStartingEvent event) {
7078
server = event.getServer();
7179
if(plugin == null)
7280
plugin = proxy.startServer(server);
81+
plugin.setDisabledModules(Arrays.asList(excludeModules));
82+
plugin.setDisabledBlockNames(Arrays.asList(excludeBlockNames));
7383
plugin.serverStarting();
7484
}
7585

0 commit comments

Comments
 (0)