mirror of
https://github.com/Jozufozu/Flywheel.git
synced 2024-11-14 22:43:56 +01:00
Sodium 0.6
This commit is contained in:
parent
4e1a4b6490
commit
c32fccc133
@ -32,5 +32,5 @@ gradlePlugin {
|
||||
|
||||
dependencies {
|
||||
// FIXME: This should not hard-code the Loom version.
|
||||
implementation("dev.architectury.loom:dev.architectury.loom.gradle.plugin:1.6.397")
|
||||
implementation("dev.architectury.loom:dev.architectury.loom.gradle.plugin:1.7.+")
|
||||
}
|
||||
|
@ -64,8 +64,8 @@ dependencies {
|
||||
modImplementation("net.fabricmc:fabric-loader:${property("fabric_loader_version")}")
|
||||
modApi("net.fabricmc.fabric-api:fabric-api:${property("fabric_api_version")}")
|
||||
|
||||
modCompileOnly("maven.modrinth:sodium:${property("sodium_version")}")
|
||||
modCompileOnly("maven.modrinth:iris:${property("iris_version")}")
|
||||
modCompileOnly("maven.modrinth:sodium:${property("sodium_version")}-fabric")
|
||||
modCompileOnly("maven.modrinth:iris:${property("iris_version")}-fabric")
|
||||
|
||||
"forApi"(project(path = ":common", configuration = "commonApiOnly"))
|
||||
"forLib"(project(path = ":common", configuration = "commonLib"))
|
||||
|
@ -5,14 +5,14 @@ import org.spongepowered.asm.mixin.injection.At;
|
||||
import org.spongepowered.asm.mixin.injection.Redirect;
|
||||
|
||||
import dev.engine_room.flywheel.lib.visualization.VisualizationHelper;
|
||||
import me.jellysquid.mods.sodium.client.render.chunk.compile.tasks.ChunkBuilderMeshingTask;
|
||||
import net.caffeinemc.mods.sodium.client.render.chunk.compile.tasks.ChunkBuilderMeshingTask;
|
||||
import net.minecraft.client.renderer.blockentity.BlockEntityRenderDispatcher;
|
||||
import net.minecraft.client.renderer.blockentity.BlockEntityRenderer;
|
||||
import net.minecraft.world.level.block.entity.BlockEntity;
|
||||
|
||||
@Mixin(value = ChunkBuilderMeshingTask.class, remap = false)
|
||||
abstract class ChunkBuilderMeshingTaskMixin {
|
||||
@Redirect(method = "execute", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/renderer/blockentity/BlockEntityRenderDispatcher;getRenderer(Lnet/minecraft/world/level/block/entity/BlockEntity;)Lnet/minecraft/client/renderer/blockentity/BlockEntityRenderer;", remap = true))
|
||||
@Redirect(method = "execute(Lnet/caffeinemc/mods/sodium/client/render/chunk/compile/ChunkBuildContext;Lnet/caffeinemc/mods/sodium/client/util/task/CancellationToken;)Lnet/caffeinemc/mods/sodium/client/render/chunk/compile/ChunkBuildOutput;", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/renderer/blockentity/BlockEntityRenderDispatcher;getRenderer(Lnet/minecraft/world/level/block/entity/BlockEntity;)Lnet/minecraft/client/renderer/blockentity/BlockEntityRenderer;", remap = true))
|
||||
private BlockEntityRenderer<?> flywheel$redirectGetRenderer(BlockEntityRenderDispatcher dispatcher, BlockEntity blockEntity) {
|
||||
if (VisualizationHelper.tryAddBlockEntity(blockEntity)) {
|
||||
return null;
|
||||
|
@ -76,8 +76,11 @@ repositories {
|
||||
dependencies {
|
||||
neoForge("net.neoforged:neoforge:${property("neoforge_version")}")
|
||||
|
||||
modCompileOnly("maven.modrinth:embeddium:${property("embeddium_version")}")
|
||||
modCompileOnly("maven.modrinth:oculus:${property("oculus_version")}")
|
||||
modCompileOnly("maven.modrinth:sodium:${property("sodium_version")}-neoforge")
|
||||
modCompileOnly("maven.modrinth:iris:${property("iris_version")}-neoforge")
|
||||
|
||||
//modCompileOnly("maven.modrinth:embeddium:${property("embeddium_version")}")
|
||||
//modCompileOnly("maven.modrinth:oculus:${property("oculus_version")}")
|
||||
|
||||
"forApi"(project(path = ":common", configuration = "commonApiOnly"))
|
||||
"forLib"(project(path = ":common", configuration = "commonLib"))
|
||||
|
@ -1,18 +1,18 @@
|
||||
package dev.engine_room.flywheel.impl.mixin.sodium;
|
||||
|
||||
import org.embeddedt.embeddium.impl.render.chunk.compile.tasks.ChunkBuilderMeshingTask;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.injection.At;
|
||||
import org.spongepowered.asm.mixin.injection.Redirect;
|
||||
|
||||
import dev.engine_room.flywheel.lib.visualization.VisualizationHelper;
|
||||
import net.caffeinemc.mods.sodium.client.render.chunk.compile.tasks.ChunkBuilderMeshingTask;
|
||||
import net.minecraft.client.renderer.blockentity.BlockEntityRenderDispatcher;
|
||||
import net.minecraft.client.renderer.blockentity.BlockEntityRenderer;
|
||||
import net.minecraft.world.level.block.entity.BlockEntity;
|
||||
|
||||
@Mixin(value = ChunkBuilderMeshingTask.class, remap = false)
|
||||
abstract class ChunkBuilderMeshingTaskMixin {
|
||||
@Redirect(method = "execute(Lorg/embeddedt/embeddium/impl/render/chunk/compile/ChunkBuildContext;Lorg/embeddedt/embeddium/impl/util/task/CancellationToken;)Lorg/embeddedt/embeddium/impl/render/chunk/compile/ChunkBuildOutput;", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/renderer/blockentity/BlockEntityRenderDispatcher;getRenderer(Lnet/minecraft/world/level/block/entity/BlockEntity;)Lnet/minecraft/client/renderer/blockentity/BlockEntityRenderer;", remap = true))
|
||||
@Redirect(method = "execute(Lnet/caffeinemc/mods/sodium/client/render/chunk/compile/ChunkBuildContext;Lnet/caffeinemc/mods/sodium/client/util/task/CancellationToken;)Lnet/caffeinemc/mods/sodium/client/render/chunk/compile/ChunkBuildOutput;", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/renderer/blockentity/BlockEntityRenderDispatcher;getRenderer(Lnet/minecraft/world/level/block/entity/BlockEntity;)Lnet/minecraft/client/renderer/blockentity/BlockEntityRenderer;", remap = true))
|
||||
private BlockEntityRenderer<?> flywheel$redirectGetRenderer(BlockEntityRenderDispatcher dispatcher, BlockEntity blockEntity) {
|
||||
if (VisualizationHelper.tryAddBlockEntity(blockEntity)) {
|
||||
return null;
|
||||
|
@ -13,7 +13,7 @@ import com.google.common.base.Suppliers;
|
||||
import net.neoforged.fml.loading.LoadingModList;
|
||||
|
||||
public class SodiumMixinPlugin implements IMixinConfigPlugin {
|
||||
private static final Supplier<Boolean> IS_SODIUM_LOADED = Suppliers.memoize(() -> LoadingModList.get().getModFileById("embeddium") != null);
|
||||
private static final Supplier<Boolean> IS_SODIUM_LOADED = Suppliers.memoize(() -> LoadingModList.get().getModFileById("sodium") != null);
|
||||
|
||||
@Override
|
||||
public void onLoad(String mixinPackage) {
|
||||
|
@ -30,11 +30,11 @@ fabric_loader_version = 0.15.11
|
||||
fabric_api_version = 0.100.6+1.21
|
||||
|
||||
# Build dependency mod versions
|
||||
sodium_version = mc1.21-0.5.11
|
||||
iris_version = 1.7.3+1.21
|
||||
embeddium_version = 1.0.4+mc1.21
|
||||
sodium_version = mc1.21-0.6.0-beta.1
|
||||
iris_version = 1.8.0-beta.1+1.21
|
||||
#embeddium_version = 1.0.4+mc1.21
|
||||
# no 1.21 :(
|
||||
oculus_version = 1.20.1-1.6.15a
|
||||
#oculus_version = 1.20.1-1.6.15a
|
||||
|
||||
# Publication info
|
||||
group = dev.engine_room.flywheel
|
||||
|
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,6 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-all.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10-bin.zip
|
||||
networkTimeout=10000
|
||||
validateDistributionUrl=true
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
|
7
gradlew
vendored
7
gradlew
vendored
@ -15,6 +15,8 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
##############################################################################
|
||||
#
|
||||
@ -55,7 +57,7 @@
|
||||
# Darwin, MinGW, and NonStop.
|
||||
#
|
||||
# (3) This script is generated from the Groovy template
|
||||
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||
# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||
# within the Gradle project.
|
||||
#
|
||||
# You can find Gradle at https://github.com/gradle/gradle/.
|
||||
@ -84,7 +86,8 @@ done
|
||||
# shellcheck disable=SC2034
|
||||
APP_BASE_NAME=${0##*/}
|
||||
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
|
||||
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
|
||||
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s
|
||||
' "$PWD" ) || exit
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD=maximum
|
||||
|
2
gradlew.bat
vendored
2
gradlew.bat
vendored
@ -13,6 +13,8 @@
|
||||
@rem See the License for the specific language governing permissions and
|
||||
@rem limitations under the License.
|
||||
@rem
|
||||
@rem SPDX-License-Identifier: Apache-2.0
|
||||
@rem
|
||||
|
||||
@if "%DEBUG%"=="" @echo off
|
||||
@rem ##########################################################################
|
||||
|
Loading…
Reference in New Issue
Block a user