readd nvidium support
This commit is contained in:
22
build.gradle
22
build.gradle
@@ -26,6 +26,24 @@ repositories {
|
|||||||
}
|
}
|
||||||
maven { url = "https://maven.shedaniel.me/" }
|
maven { url = "https://maven.shedaniel.me/" }
|
||||||
maven { url = "https://maven.terraformersmc.com/releases/" }
|
maven { url = "https://maven.terraformersmc.com/releases/" }
|
||||||
|
|
||||||
|
exclusiveContent {
|
||||||
|
forRepository {
|
||||||
|
ivy {
|
||||||
|
name = "github"
|
||||||
|
url = "https://github.com/"
|
||||||
|
patternLayout {
|
||||||
|
artifact '/[organisation]/[module]/releases/download/[revision]/[module]-[revision]-[classifier].[ext]'
|
||||||
|
}
|
||||||
|
metadataSources {
|
||||||
|
artifact()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
filter {
|
||||||
|
includeModuleByRegex("[^\\.]+", "nvidium")
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -92,8 +110,8 @@ dependencies {
|
|||||||
|
|
||||||
modImplementation("maven.modrinth:lithium:mc1.21.6-0.17.0-fabric")
|
modImplementation("maven.modrinth:lithium:mc1.21.6-0.17.0-fabric")
|
||||||
|
|
||||||
//modRuntimeOnly "maven.modrinth:nvidium:0.2.6-beta"
|
modRuntimeOnlyMsk "drouarb:nvidium:0.4.1-beta4:1.21.6@jar"
|
||||||
//modCompileOnly "maven.modrinth:nvidium:0.2.8-beta"
|
modCompileOnly "drouarb:nvidium:0.4.1-beta4:1.21.6@jar"
|
||||||
|
|
||||||
modCompileOnly("maven.modrinth:modmenu:15.0.0-beta.1")
|
modCompileOnly("maven.modrinth:modmenu:15.0.0-beta.1")
|
||||||
modRuntimeOnlyMsk("maven.modrinth:modmenu:15.0.0-beta.1")
|
modRuntimeOnlyMsk("maven.modrinth:modmenu:15.0.0-beta.1")
|
||||||
|
|||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package me.cortex.voxy.client.mixin.nvidium;
|
||||||
|
|
||||||
|
import me.cortex.nvidium.RenderPipeline;
|
||||||
|
import me.cortex.voxy.client.core.IGetVoxyRenderSystem;
|
||||||
|
import net.caffeinemc.mods.sodium.client.render.chunk.ChunkRenderMatrices;
|
||||||
|
import net.caffeinemc.mods.sodium.client.render.chunk.terrain.TerrainRenderPass;
|
||||||
|
import net.caffeinemc.mods.sodium.client.render.viewport.Viewport;
|
||||||
|
import net.caffeinemc.mods.sodium.client.util.FogParameters;
|
||||||
|
import net.minecraft.client.MinecraftClient;
|
||||||
|
import org.spongepowered.asm.mixin.Mixin;
|
||||||
|
import org.spongepowered.asm.mixin.injection.At;
|
||||||
|
import org.spongepowered.asm.mixin.injection.Inject;
|
||||||
|
import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||||
|
|
||||||
|
@Mixin(RenderPipeline.class)
|
||||||
|
public class MixinRenderPipeline {
|
||||||
|
@Inject(method = "renderFrame", at = @At("RETURN"))
|
||||||
|
private void voxy$injectRender(TerrainRenderPass pass, Viewport frustum, FogParameters fogParameters, ChunkRenderMatrices crm, double px, double py, double pz, CallbackInfo ci) {
|
||||||
|
var renderer = ((IGetVoxyRenderSystem) MinecraftClient.getInstance().worldRenderer).getVoxyRenderSystem();
|
||||||
|
if (renderer != null) {
|
||||||
|
renderer.renderOpaque(crm, px, py, pz);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -14,9 +14,12 @@
|
|||||||
"minecraft.MixinWorldRenderer",
|
"minecraft.MixinWorldRenderer",
|
||||||
"sodium.MixinDefaultChunkRenderer",
|
"sodium.MixinDefaultChunkRenderer",
|
||||||
"sodium.MixinRenderSectionManager",
|
"sodium.MixinRenderSectionManager",
|
||||||
"sodium.MixinSodiumOptionsGUI"
|
"sodium.MixinSodiumOptionsGUI",
|
||||||
|
"nvidium.MixinRenderPipeline"
|
||||||
],
|
],
|
||||||
"injectors": {
|
"injectors": {
|
||||||
"defaultRequire": 1
|
"defaultRequire": 1
|
||||||
}
|
},
|
||||||
|
"mixins": [
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user