This commit is contained in:
Brian Neumann-Fopiano
2026-08-01 22:39:09 -04:00
parent 324cf9e095
commit a8217b42e9
220 changed files with 10626 additions and 1661 deletions
@@ -43,7 +43,7 @@ import java.nio.file.Path;
public final class ForgeModdedLoader implements ModdedLoader {
public static final PermissionNode<Boolean> TREE_FELLER_PERMISSION = new PermissionNode<>(
"iris",
"irisworldgen",
"treefeller",
PermissionTypes.BOOLEAN,
(player, playerId, contexts) ->
@@ -75,7 +75,10 @@ public final class ForgeProtocolNetworking {
@Override
public boolean canReceive(ServerPlayer player) {
return true;
// Forge tracks the channels the remote side announced during handshake. Without this the
// server pushes Iris payloads at vanilla clients, which drop them as unknown custom
// payloads. Mirrors the NeoForge ICommonPacketListener.hasChannel check.
return channel.isRemotePresent(player.connection.getConnection());
}
@Override
@@ -70,6 +70,10 @@ public final class IrisForgeBootstrap {
ForgeProtocolNetworking.register();
// Dist gate for every client-tainted class. DistExecutor is gone in Forge 26.2 (65.x) - only
// net.minecraftforge.api.distmarker.Dist survives, from mergetool-api - so the guard is this branch.
// It is equally safe: IrisForgeClient appears only as an invokestatic target, so the JVM resolves the
// constant-pool entry lazily on first execution and a dedicated server never loads the class.
if (FMLEnvironment.dist == Dist.CLIENT) {
IrisForgeClient.init();
}
@@ -47,8 +47,11 @@ public final class IrisForgeClient {
ClientPlayerNetworkEvent.LoggingIn.BUS.addListener((ClientPlayerNetworkEvent.LoggingIn event) -> IrisClient.onWorldJoin());
ClientPlayerNetworkEvent.LoggingOut.BUS.addListener((ClientPlayerNetworkEvent.LoggingOut event) -> IrisClient.onDisconnect());
InputEvent.Key.BUS.addListener((InputEvent.Key event) -> IrisClientKeybinds.pollToggle());
TickEvent.ClientTickEvent.Post.BUS.addListener(
(TickEvent.ClientTickEvent.Post event) -> IrisClient.tick());
TickEvent.ClientTickEvent.Post.BUS.addListener((TickEvent.ClientTickEvent.Post event) -> {
IrisClientKeybinds.pollToggle();
IrisClient.tick();
IrisClientHud.tick();
});
}
private static void sendToServer(byte[] frame) {
@@ -1,6 +1,7 @@
modLoader = "javafml"
loaderVersion = "[65,)"
loaderVersion = "[65,66)"
license = "GPL-3.0"
issueTrackerURL = "https://github.com/VolmitSoftware/Iris/issues"
[[mods]]
modId = "irisworldgen"
@@ -8,11 +9,14 @@ version = "${version}"
displayName = "Iris"
description = "Iris World Generation Engine (Forge adapter - native chunk generator, explicit Iris world datapack workflow, engine lifecycle)"
authors = "Arcane Arts (Volmit Software)"
credits = "cyberpwn, NextdoorPsycho, Vatuu"
displayURL = "https://docs.volmit.com/iris/"
logoFile = "assets/irisworldgen/icon.png"
[[dependencies.irisworldgen]]
modId = "forge"
mandatory = true
versionRange = "[65,)"
versionRange = "[65,66)"
ordering = "NONE"
side = "BOTH"
@@ -1,10 +0,0 @@
{
"pack": {
"description": "Iris World Generation Engine resources",
"max_format": 101,
"min_format": [
101,
1
]
}
}