fix compiling for MC 1.20 and older
This commit is contained in:
+5
@@ -1,5 +1,9 @@
|
|||||||
package com.seibel.distanthorizons.common.render.blaze.wrappers;
|
package com.seibel.distanthorizons.common.render.blaze.wrappers;
|
||||||
|
|
||||||
|
#if MC_VER <= MC_1_21_10
|
||||||
|
public class BlazeVertexFormatBuilder {}
|
||||||
|
#else
|
||||||
|
|
||||||
import com.mojang.blaze3d.vertex.VertexFormat;
|
import com.mojang.blaze3d.vertex.VertexFormat;
|
||||||
import com.mojang.blaze3d.vertex.VertexFormatElement;
|
import com.mojang.blaze3d.vertex.VertexFormatElement;
|
||||||
import com.seibel.distanthorizons.common.render.blaze.util.BlazeDhVertexFormatUtil;
|
import com.seibel.distanthorizons.common.render.blaze.util.BlazeDhVertexFormatUtil;
|
||||||
@@ -51,3 +55,4 @@ public class BlazeVertexFormatBuilder
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
+5
@@ -1,5 +1,9 @@
|
|||||||
package com.seibel.distanthorizons.common.render.blaze.wrappers;
|
package com.seibel.distanthorizons.common.render.blaze.wrappers;
|
||||||
|
|
||||||
|
#if MC_VER <= MC_1_21_10
|
||||||
|
public class RenderPassWrapper {}
|
||||||
|
#else
|
||||||
|
|
||||||
import com.mojang.blaze3d.buffers.GpuBuffer;
|
import com.mojang.blaze3d.buffers.GpuBuffer;
|
||||||
import com.mojang.blaze3d.pipeline.RenderPipeline;
|
import com.mojang.blaze3d.pipeline.RenderPipeline;
|
||||||
import com.mojang.blaze3d.systems.CommandEncoder;
|
import com.mojang.blaze3d.systems.CommandEncoder;
|
||||||
@@ -155,3 +159,4 @@ public class RenderPassWrapper implements AutoCloseable
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
+5
@@ -1,5 +1,9 @@
|
|||||||
package com.seibel.distanthorizons.common.render.blaze.wrappers.texture;
|
package com.seibel.distanthorizons.common.render.blaze.wrappers.texture;
|
||||||
|
|
||||||
|
#if MC_VER <= MC_1_21_10
|
||||||
|
public interface IDhBlazeTexture {}
|
||||||
|
#else
|
||||||
|
|
||||||
import com.mojang.blaze3d.textures.GpuSampler;
|
import com.mojang.blaze3d.textures.GpuSampler;
|
||||||
import com.mojang.blaze3d.textures.GpuTextureView;
|
import com.mojang.blaze3d.textures.GpuTextureView;
|
||||||
|
|
||||||
@@ -10,3 +14,4 @@ public interface IDhBlazeTexture
|
|||||||
GpuSampler getTextureSampler();
|
GpuSampler getTextureSampler();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
+2
-1
@@ -102,7 +102,7 @@ public class DependencySetup
|
|||||||
renderingApiEnum = versionConstants.getDefaultRenderingApi();
|
renderingApiEnum = versionConstants.getDefaultRenderingApi();
|
||||||
}
|
}
|
||||||
|
|
||||||
LOGGER.info("Setting DH Rendering API to: ["+renderingApiEnum+"].");
|
LOGGER.info("Setting DH Rendering API to: ["+renderingApiEnum+"]...");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -151,6 +151,7 @@ public class DependencySetup
|
|||||||
|
|
||||||
|
|
||||||
renderDefinition.bindRenderers();
|
renderDefinition.bindRenderers();
|
||||||
|
LOGGER.info("DH Rendering successfully bound to: ["+renderDefinition.getApiName()+"]...");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -48,7 +48,7 @@ versionStr=
|
|||||||
|
|
||||||
# This defines what MC version Intellij will use for the preprocessor
|
# This defines what MC version Intellij will use for the preprocessor
|
||||||
# and what version is used automatically by build and run commands
|
# and what version is used automatically by build and run commands
|
||||||
mcVer=26.2.0
|
mcVer=26.1.2
|
||||||
|
|
||||||
# Defines the maximum amount of memory Minecraft is allowed when run in a development environment
|
# Defines the maximum amount of memory Minecraft is allowed when run in a development environment
|
||||||
minecraftMemoryJavaArg=-Xmx6G
|
minecraftMemoryJavaArg=-Xmx6G
|
||||||
|
|||||||
+2
-2
@@ -23,7 +23,7 @@ public class NeoforgeMinecraftRenderWrapper extends MinecraftRenderWrapper
|
|||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getDepthTextureId()
|
public int getGlDepthTextureId()
|
||||||
{
|
{
|
||||||
#if MC_VER < MC_1_21_9
|
#if MC_VER < MC_1_21_9
|
||||||
// no special handling required,
|
// no special handling required,
|
||||||
@@ -50,7 +50,7 @@ public class NeoforgeMinecraftRenderWrapper extends MinecraftRenderWrapper
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getColorTextureId()
|
public int getGlColorTextureId()
|
||||||
{
|
{
|
||||||
#if MC_VER < MC_1_21_9
|
#if MC_VER < MC_1_21_9
|
||||||
// no special handling required,
|
// no special handling required,
|
||||||
|
|||||||
Reference in New Issue
Block a user