Merge branch 'main' of https://gitlab.com/jeseibel/minecraft-lod-mod
This commit is contained in:
+1
-1
@@ -234,7 +234,7 @@ subprojects { p ->
|
||||
forgeShadowMe("io.netty:netty-all:${rootProject.netty_version}")
|
||||
|
||||
// Remember, for lwjgl dependencies that arent included in Minecraft, you need to also need to add it to the ShadowJar thing
|
||||
forgeShadowMe("org.lwjgl:lwjgl-jawt:3.2.2") {
|
||||
forgeShadowMe("org.lwjgl:lwjgl-jawt:${rootProject.lwjgl_version}") {
|
||||
exclude group: "org.lwjgl", module: "lwjgl" // This module is imported by Minecraft so exclude it
|
||||
}
|
||||
|
||||
|
||||
+9
-1
@@ -20,6 +20,7 @@
|
||||
package com.seibel.distanthorizons.common.wrappers.block;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.HashSet;
|
||||
import java.util.Objects;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
import java.util.concurrent.ConcurrentMap;
|
||||
@@ -74,6 +75,9 @@ public class BiomeWrapper implements IBiomeWrapper
|
||||
public static final String EMPTY_STRING = "EMPTY";
|
||||
public static final BiomeWrapper EMPTY_WRAPPER = new BiomeWrapper(null, null);
|
||||
|
||||
/** keep track of broken biomes so we don't log every time */
|
||||
private static final HashSet<String> BrokenResourceLocationStrings = new HashSet<>();
|
||||
|
||||
|
||||
|
||||
// properties //
|
||||
@@ -266,7 +270,11 @@ public class BiomeWrapper implements IBiomeWrapper
|
||||
|
||||
if (!success)
|
||||
{
|
||||
LOGGER.warn("Unable to deserialize biome from string: [" + resourceLocationString + "]");
|
||||
if (!BrokenResourceLocationStrings.contains(resourceLocationString))
|
||||
{
|
||||
BrokenResourceLocationStrings.add(resourceLocationString);
|
||||
LOGGER.warn("Unable to deserialize biome from string: [" + resourceLocationString + "]");
|
||||
}
|
||||
return EMPTY_WRAPPER;
|
||||
}
|
||||
|
||||
|
||||
+13
-3
@@ -67,9 +67,11 @@ public class BlockStateWrapper implements IBlockStateWrapper
|
||||
|
||||
// TODO: Make this changeable through the config
|
||||
public static final String[] RENDERER_IGNORED_BLOCKS_RESOURCE_LOCATIONS = { AIR_STRING, "minecraft:barrier", "minecraft:structure_void", "minecraft:light", "minecraft:tripwire" };
|
||||
|
||||
public static HashSet<IBlockStateWrapper> rendererIgnoredBlocks = null;
|
||||
|
||||
/** keep track of broken blocks so we don't log every time */
|
||||
private static final HashSet<ResourceLocation> BrokenResourceLocations = new HashSet<>();
|
||||
|
||||
|
||||
|
||||
// properties //
|
||||
@@ -345,7 +347,11 @@ public class BlockStateWrapper implements IBlockStateWrapper
|
||||
if (block == null)
|
||||
{
|
||||
// shouldn't normally happen, but here to make the compiler happy
|
||||
LOGGER.warn("Unable to find BlockState with the resourceLocation [" + resourceLocation + "] and properties: [" + blockStatePropertiesString + "]. Air will be used instead, some data may be lost.");
|
||||
if (!BrokenResourceLocations.contains(resourceLocation))
|
||||
{
|
||||
BrokenResourceLocations.add(resourceLocation);
|
||||
LOGGER.warn("Unable to find BlockState with the resourceLocation [" + resourceLocation + "] and properties: [" + blockStatePropertiesString + "]. Air will be used instead, some data may be lost.");
|
||||
}
|
||||
return AIR;
|
||||
}
|
||||
|
||||
@@ -372,7 +378,11 @@ public class BlockStateWrapper implements IBlockStateWrapper
|
||||
if (blockStatePropertiesString != null)
|
||||
{
|
||||
// we should have found a blockstate, but didn't
|
||||
LOGGER.warn("Unable to find BlockState for Block [" + resourceLocation + "] with properties: [" + blockStatePropertiesString + "]. Using the default block state.");
|
||||
if (!BrokenResourceLocations.contains(resourceLocation))
|
||||
{
|
||||
BrokenResourceLocations.add(resourceLocation);
|
||||
LOGGER.warn("Unable to find BlockState for Block [" + resourceLocation + "] with properties: [" + blockStatePropertiesString + "]. Using the default block state.");
|
||||
}
|
||||
}
|
||||
|
||||
foundState = block.defaultBlockState();
|
||||
|
||||
+1
-1
Submodule coreSubProjects updated: 880abd0124...9cfcf37fb3
@@ -47,8 +47,6 @@ import net.minecraftforge.event.level.LevelEvent;
|
||||
|
||||
#if POST_MC_1_18_2
|
||||
import net.minecraftforge.client.event.RenderLevelStageEvent;
|
||||
#else
|
||||
import net.minecraftforge.client.event.RenderBlockOverlayEvent;
|
||||
#endif
|
||||
import net.minecraftforge.event.entity.player.PlayerInteractEvent;
|
||||
import net.minecraft.world.level.chunk.ChunkAccess;
|
||||
@@ -304,7 +302,7 @@ public class ForgeClientProxy
|
||||
#if POST_MC_1_18_2
|
||||
public void afterLevelRenderEvent(RenderLevelStageEvent event)
|
||||
#else
|
||||
public void afterLevelRenderEvent(RenderBlockOverlayEvent event)
|
||||
public void afterLevelRenderEvent(TickEvent.RenderTickEvent event)
|
||||
#endif
|
||||
{
|
||||
#if POST_MC_1_20_1
|
||||
@@ -314,7 +312,7 @@ public class ForgeClientProxy
|
||||
#else
|
||||
// FIXME: Is this the correct location for 1.16 & 1.17???
|
||||
// I couldnt find anything for rendering after the level, so is rendering after overlays ok?
|
||||
if (event.getOverlayType() == RenderBlockOverlayEvent.OverlayType.BLOCK)
|
||||
if (event.type.equals(TickEvent.RenderTickEvent.Type.WORLD))
|
||||
#endif
|
||||
{
|
||||
try
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ sqlite_jdbc_version=3.43.0.0
|
||||
# Minecraft related libaries (included in MC's jar)
|
||||
log4j_version=2.20.0
|
||||
netty_version=4.1.94.Final
|
||||
lwjgl_version=3.2.3
|
||||
lwjgl_version=3.3.1
|
||||
joml_version=1.10.2
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user