mirror of
https://github.com/LuckPerms/LuckPerms.git
synced 2026-11-27 03:53:06 +00:00
Update to Minecraft 26.1
This commit is contained in:
18 files changed
+52
-82
No files matched your search
@@ -3,7 +3,7 @@ plugins {
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile).configureEach {
|
||||
options.release = 21
|
||||
options.release = 25
|
||||
}
|
||||
|
||||
repositories {
|
||||
@@ -12,12 +12,6 @@ repositories {
|
||||
|
||||
dependencies {
|
||||
// https://modmuss50.me/fabric.html
|
||||
minecraft 'com.mojang:minecraft:1.21.11'
|
||||
mappings loom.officialMojangMappings()
|
||||
|
||||
minecraft 'com.mojang:minecraft:26.1'
|
||||
implementation project(':common')
|
||||
}
|
||||
|
||||
remapJar {
|
||||
targetNamespace = 'named'
|
||||
}
|
||||
+20
-28
@@ -10,18 +10,25 @@ base {
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile).configureEach {
|
||||
options.release = 21
|
||||
options.release = 25
|
||||
}
|
||||
|
||||
repositories {
|
||||
maven { url 'https://maven.fabricmc.net/' }
|
||||
}
|
||||
|
||||
configurations {
|
||||
shade
|
||||
implementation.extendsFrom shade
|
||||
|
||||
jarInJar
|
||||
implementation.extendsFrom jarInJar
|
||||
}
|
||||
|
||||
dependencies {
|
||||
// https://modmuss50.me/fabric.html
|
||||
minecraft 'com.mojang:minecraft:1.21.11'
|
||||
mappings loom.officialMojangMappings()
|
||||
modImplementation 'net.fabricmc:fabric-loader:0.18.4'
|
||||
minecraft 'com.mojang:minecraft:26.1'
|
||||
implementation 'net.fabricmc:fabric-loader:0.18.4'
|
||||
|
||||
Set<String> apiModules = [
|
||||
'fabric-api-base',
|
||||
@@ -32,15 +39,17 @@ dependencies {
|
||||
]
|
||||
|
||||
apiModules.forEach {
|
||||
modImplementation(fabricApi.module(it, '0.139.4+1.21.11'))
|
||||
implementation(fabricApi.module(it, '0.144.0+26.1'))
|
||||
}
|
||||
|
||||
include(modImplementation('me.lucko:fabric-permissions-api:0.6.1'))
|
||||
jarInJar 'me.lucko:fabric-permissions-api:0.7.0'
|
||||
|
||||
implementation project(':common')
|
||||
implementation project(':common:minecraft')
|
||||
shade project(':common')
|
||||
shade project(':common:minecraft')
|
||||
}
|
||||
|
||||
loom.nestJars(tasks.named("shadowJar"), configurations.jarInJar)
|
||||
|
||||
processResources {
|
||||
inputs.property 'version', project.ext.fullVersion
|
||||
filesMatching('**/fabric.mod.json') {
|
||||
@@ -49,15 +58,8 @@ processResources {
|
||||
}
|
||||
|
||||
shadowJar {
|
||||
archiveFileName = "luckpermsfabric-${project.ext.fullVersion}-dev.jar"
|
||||
|
||||
dependencies {
|
||||
exclude('net.fabricmc:.*')
|
||||
include(dependency('net.luckperms:.*'))
|
||||
include(dependency('me.lucko.luckperms:.*'))
|
||||
// We don't want to include the mappings in the jar do we?
|
||||
exclude '/mappings/*'
|
||||
}
|
||||
archiveFileName = "LuckPerms-Fabric-${project.ext.fullVersion}.jar"
|
||||
configurations = [project.configurations.shade]
|
||||
|
||||
relocate 'net.kyori.adventure', 'me.lucko.luckperms.lib.adventure'
|
||||
relocate 'net.kyori.event', 'me.lucko.luckperms.lib.eventbus'
|
||||
@@ -80,16 +82,6 @@ shadowJar {
|
||||
relocate 'org.yaml.snakeyaml', 'me.lucko.luckperms.lib.yaml'
|
||||
}
|
||||
|
||||
tasks.register('remappedShadowJar', RemapJarTask) {
|
||||
dependsOn tasks.shadowJar
|
||||
input = tasks.shadowJar.archiveFile
|
||||
addNestedDependencies = true
|
||||
archiveFileName = "LuckPerms-Fabric-${project.ext.fullVersion}.jar"
|
||||
}
|
||||
|
||||
tasks.assemble.dependsOn tasks.remappedShadowJar
|
||||
|
||||
artifacts {
|
||||
archives remappedShadowJar
|
||||
shadow shadowJar
|
||||
archives shadowJar
|
||||
}
|
||||
@@ -27,7 +27,7 @@ package me.lucko.luckperms.fabric.context;
|
||||
|
||||
import me.lucko.luckperms.common.minecraft.context.MinecraftPlayerCalculator;
|
||||
import me.lucko.luckperms.fabric.LPFabricPlugin;
|
||||
import net.fabricmc.fabric.api.entity.event.v1.ServerEntityWorldChangeEvents;
|
||||
import net.fabricmc.fabric.api.entity.event.v1.ServerEntityLevelChangeEvents;
|
||||
import net.minecraft.server.level.ServerLevel;
|
||||
import net.minecraft.server.level.ServerPlayer;
|
||||
|
||||
@@ -39,7 +39,7 @@ public class FabricPlayerCalculator extends MinecraftPlayerCalculator {
|
||||
}
|
||||
|
||||
public void registerListeners() {
|
||||
ServerEntityWorldChangeEvents.AFTER_PLAYER_CHANGE_WORLD.register(this::onWorldChange);
|
||||
ServerEntityLevelChangeEvents.AFTER_PLAYER_CHANGE_LEVEL.register(this::onWorldChange);
|
||||
}
|
||||
|
||||
private void onWorldChange(ServerPlayer player, ServerLevel origin, ServerLevel destination) {
|
||||
|
||||
+2
-2
@@ -55,8 +55,8 @@ public class PluginMessageMessenger extends AbstractPluginMessageMessenger imple
|
||||
}
|
||||
|
||||
public void init() {
|
||||
PayloadTypeRegistry.playS2C().register(PluginMessagePayload.TYPE, PluginMessagePayload.CODEC);
|
||||
PayloadTypeRegistry.playC2S().register(PluginMessagePayload.TYPE, PluginMessagePayload.CODEC);
|
||||
PayloadTypeRegistry.clientboundPlay().register(PluginMessagePayload.TYPE, PluginMessagePayload.CODEC);
|
||||
PayloadTypeRegistry.serverboundPlay().register(PluginMessagePayload.TYPE, PluginMessagePayload.CODEC);
|
||||
ServerPlayNetworking.registerGlobalReceiver(PluginMessagePayload.TYPE, this);
|
||||
}
|
||||
|
||||
|
||||
@@ -30,12 +30,13 @@
|
||||
"luckperms.mixins.json"
|
||||
],
|
||||
"depends": {
|
||||
"fabricloader": ">=0.9.0",
|
||||
"fabricloader": ">=0.18.4",
|
||||
"minecraft": ">=26.1",
|
||||
"fabric-api-base": "*",
|
||||
"fabric-command-api-v2": "*",
|
||||
"fabric-lifecycle-events-v1": "*",
|
||||
"fabric-networking-api-v1": "*",
|
||||
"fabric-permissions-api-v0": ">=0.3.1"
|
||||
"fabric-permissions-api-v0": ">=0.7.0"
|
||||
},
|
||||
"custom": {
|
||||
"modmenu:api": true
|
||||
|
||||
+1
-5
@@ -4,11 +4,7 @@ plugins {
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile).configureEach {
|
||||
options.release = 21
|
||||
}
|
||||
|
||||
minecraft {
|
||||
mappings channel: 'official', version: minecraftVersion
|
||||
options.release = 25
|
||||
}
|
||||
|
||||
repositories {
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
minecraftVersion=1.21.11
|
||||
forgeVersion=61.1.3
|
||||
minecraftVersion=26.1
|
||||
forgeVersion=62.0.1
|
||||
@@ -5,11 +5,7 @@ plugins {
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile).configureEach {
|
||||
options.release = 21
|
||||
}
|
||||
|
||||
minecraft {
|
||||
mappings channel: 'official', version: minecraftVersion
|
||||
options.release = 25
|
||||
}
|
||||
|
||||
repositories {
|
||||
|
||||
@@ -38,7 +38,7 @@ public class ForgeEventBus extends AbstractEventBus<ModContainer> {
|
||||
|
||||
@Override
|
||||
protected ModContainer checkPlugin(Object mod) throws IllegalArgumentException {
|
||||
ModContainer modContainer = ModList.get().getModContainerByObject(mod).orElse(null);
|
||||
ModContainer modContainer = ModList.getModContainerByObject(mod).orElse(null);
|
||||
if (modContainer != null) {
|
||||
return modContainer;
|
||||
}
|
||||
|
||||
@@ -222,7 +222,7 @@ public final class LPForgeBootstrap extends MinecraftLuckPermsBootstrap implemen
|
||||
|
||||
@Override
|
||||
public String getServerBrand() {
|
||||
return ModList.get().getModContainerById("forge")
|
||||
return ModList.getModContainerById("forge")
|
||||
.map(ModContainer::getModInfo)
|
||||
.map(IModInfo::getDisplayName)
|
||||
.orElse("null");
|
||||
@@ -230,7 +230,7 @@ public final class LPForgeBootstrap extends MinecraftLuckPermsBootstrap implemen
|
||||
|
||||
@Override
|
||||
public String getServerVersion() {
|
||||
String forgeVersion = ModList.get().getModContainerById("forge")
|
||||
String forgeVersion = ModList.getModContainerById("forge")
|
||||
.map(ModContainer::getModInfo)
|
||||
.map(IModInfo::getVersion)
|
||||
.map(ArtifactVersion::toString)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
[versions]
|
||||
shadow = "8.3.8"
|
||||
blossom = "2.2.0"
|
||||
moddevgradle = "2.0.140"
|
||||
moddevgradle = "2.0.141"
|
||||
forgegradle = "[7.0.13,8.0)"
|
||||
loom = "1.15-SNAPSHOT"
|
||||
licenser = "2.2.2"
|
||||
@@ -11,5 +11,5 @@ blossom = { id = "net.kyori.blossom", version.ref = "blossom" }
|
||||
shadow = { id = "com.gradleup.shadow", version.ref = "shadow" }
|
||||
moddevgradle = { id = "net.neoforged.moddev", version.ref = "moddevgradle" }
|
||||
forgegradle = { id = "net.minecraftforge.gradle", version.ref = "forgegradle" }
|
||||
loom = { id = "net.fabricmc.fabric-loom-remap", version.ref = "loom" }
|
||||
loom = { id = "net.fabricmc.fabric-loom", version.ref = "loom" }
|
||||
licenser = { id = "dev.yumi.gradle.licenser", version.ref = "licenser" }
|
||||
@@ -19,7 +19,10 @@ repositories {
|
||||
|
||||
processResources {
|
||||
filesMatching('manifest.json') {
|
||||
expand 'pluginVersion': project.ext.fullVersion
|
||||
expand (
|
||||
'pluginVersion': project.ext.fullVersion,
|
||||
'hytaleVersion': hytaleVersion
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"Description": "A permissions plugin",
|
||||
"Authors": [{"Name": "Luck"}],
|
||||
"Website": "https://luckperms.net",
|
||||
"ServerVersion": "2026.02.17-255364b8e",
|
||||
"ServerVersion": "${hytaleVersion}",
|
||||
"Dependencies": {},
|
||||
"OptionalDependencies": {},
|
||||
"DisabledByDefault": false,
|
||||
|
||||
@@ -15,7 +15,10 @@ repositories {
|
||||
|
||||
processResources {
|
||||
filesMatching('manifest.json') {
|
||||
expand 'pluginVersion': project.ext.fullVersion
|
||||
expand (
|
||||
'pluginVersion': project.ext.fullVersion,
|
||||
'hytaleVersion': hytaleVersion
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"Description": "A permissions plugin",
|
||||
"Authors": [{"Name": "Luck"}],
|
||||
"Website": "https://luckperms.net",
|
||||
"ServerVersion": "2026.02.17-255364b8e",
|
||||
"ServerVersion": "${hytaleVersion}",
|
||||
"Dependencies": {},
|
||||
"OptionalDependencies": {},
|
||||
"DisabledByDefault": false,
|
||||
|
||||
@@ -4,7 +4,7 @@ plugins {
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile).configureEach {
|
||||
options.release = 21
|
||||
options.release = 25
|
||||
}
|
||||
|
||||
configurations {
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
minecraftVersion=1.21.11
|
||||
neoForgeVersion=21.11.0-beta
|
||||
minecraftVersion=26.1
|
||||
neoForgeVersion=26.1.0.1-beta
|
||||
@@ -1,8 +1,3 @@
|
||||
import net.neoforged.moddevgradle.internal.RunGameTask
|
||||
|
||||
import java.nio.file.Files
|
||||
import java.nio.file.StandardCopyOption
|
||||
|
||||
plugins {
|
||||
alias(libs.plugins.shadow)
|
||||
alias(libs.plugins.moddevgradle)
|
||||
@@ -10,7 +5,7 @@ plugins {
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile).configureEach {
|
||||
options.release = 21
|
||||
options.release = 25
|
||||
}
|
||||
|
||||
neoForge {
|
||||
@@ -27,16 +22,6 @@ neoForge {
|
||||
}
|
||||
}
|
||||
|
||||
// Work around classpath issues by using the production jar for dev runs
|
||||
tasks.withType(RunGameTask).configureEach {
|
||||
dependsOn(tasks.shadowJar)
|
||||
doFirst {
|
||||
File jar = file("run/mods/main.jar")
|
||||
jar.parentFile.mkdirs()
|
||||
Files.copy(tasks.shadowJar.archiveFile.get().asFile.toPath(), jar.toPath(), StandardCopyOption.REPLACE_EXISTING)
|
||||
}
|
||||
}
|
||||
|
||||
configurations {
|
||||
shade
|
||||
implementation.extendsFrom shade
|
||||
|
||||
Reference in new issue
Block a user