Skip to content

Commit 5b78d54

Browse files
committed
Start working on the Hurricane-Modded merge
1 parent a7e7a28 commit 5b78d54

39 files changed

+851
-60
lines changed

.github/workflows/build-workflow.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ jobs:
2626
with:
2727
artifacts: |
2828
spigot/build/libs/hurricane-spigot.jar
29+
fabric/build/libs/hurricane-fabric.jar
30+
neoforge/build/libs/hurricane-neoforge.jar
2931
3032
- name: Get Version
3133
if: ${{ success() && github.repository == 'GeyserMC/Hurricane' && github.ref_name == 'master' }}
@@ -43,6 +45,8 @@ jobs:
4345
appPrivateKey: ${{ secrets.RELEASE_APP_PK }}
4446
files: |
4547
spigot:spigot/build/libs/hurricane-spigot.jar
48+
fabric:fabric/build/libs/hurricane-fabric.jar
49+
neoforge:neoforge/build/libs/hurricane-neoforge.jar
4650
releaseEnabled: false
4751
saveMetadata: true
4852
releaseProject: 'hurricane'
@@ -57,6 +61,8 @@ jobs:
5761
host: ${{ secrets.DOWNLOADS_SERVER_IP }}
5862
files: |
5963
spigot/build/libs/hurricane-spigot.jar
64+
fabric/build/libs/hurricane-fabric.jar
65+
neoforge/build/libs/hurricane-neoforge.jar
6066
changelog: ${{ steps.metadata.outputs.body }}
6167

6268
- name: Notify Discord

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2023 Camotoy
3+
Copyright (c) 2025 GeyserMC
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Hurricane
2-
Various workarounds for Geyser players that modify the server in order to achieve their goal.
2+
Various workarounds for Bedrock players playing on Java servers through Geyser that modify the server in order to achieve their goal.
33

44
Issues with each workaround are listed in the plugin's config. **Please take your time to read them as the workarounds in this plugin can be used for exploitative purposes.**
55

build-logic/build.gradle.kts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,20 @@ plugins {
44

55
repositories {
66
gradlePluginPortal()
7+
mavenCentral()
8+
maven("https://maven.architectury.dev/")
9+
maven("https://maven.fabricmc.net/")
10+
maven("https://maven.neoforged.net/releases/")
711
}
812

913
dependencies {
14+
// this is OK as long as the same version catalog is used in the main build and build-logic
15+
// see https://github.com/gradle/gradle/issues/15383#issuecomment-779893192
16+
implementation(files(libs.javaClass.superclass.protectionDomain.codeSource.location))
1017
implementation(libs.shadow)
1118
implementation(libs.paperweight)
1219
implementation(libs.javadowngrader)
20+
implementation(libs.architectury.plugin)
21+
implementation(libs.architectury.loom)
22+
implementation(libs.minotaur)
1323
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import org.gradle.accessors.dm.LibrariesForLibs
2+
import org.gradle.api.Project
3+
import org.gradle.kotlin.dsl.getByType
4+
5+
val Project.libs: LibrariesForLibs
6+
get() = rootProject.extensions.getByType()
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
plugins {
2+
`java-library`
3+
`maven-publish`
4+
}
5+
6+
tasks.withType<JavaCompile> {
7+
options.encoding = "UTF-8"
8+
}
9+
10+
tasks {
11+
processResources {
12+
filesMatching(listOf("fabric.mod.json", "META-INF/neoforge.mods.toml")) {
13+
expand(
14+
"id" to "hurricane",
15+
"name" to "Hurricane",
16+
"version" to project.version,
17+
"description" to "Hacky fixes to make Bedrock players that join via Geyser happy."
18+
)
19+
}
20+
filesMatching(listOf("plugin.yml")) {
21+
expand(
22+
"version" to properties["version"]
23+
)
24+
}
25+
}
26+
}
27+
28+
repositories {
29+
// mavenLocal()
30+
mavenCentral()
31+
maven("https://maven.fabricmc.net/")
32+
maven("https://maven.neoforged.net/releases")
33+
maven("https://repo.opencollab.dev/main/")
34+
maven("https://repo.papermc.io/repository/maven-public/")
35+
maven("https://jitpack.io") {
36+
content {
37+
includeGroupByRegex("com.github.*")
38+
}
39+
}
40+
}
41+
42+
group = properties["group"] as String
43+
version = properties["version"] as String
44+
java.sourceCompatibility = JavaVersion.VERSION_21
45+
46+
publishing {
47+
publications.create<MavenPublication>("maven") {
48+
from(components["java"])
49+
}
50+
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
plugins {
2+
id("hurricane.build-logic")
3+
id("com.gradleup.shadow")
4+
id("xyz.wagyourtail.jvmdowngrader")
5+
}
6+
7+
tasks {
8+
downgradeJar {
9+
mustRunAfter(shadowJar)
10+
inputFile.set(shadowJar.get().archiveFile)
11+
archiveClassifier.set("")
12+
archiveVersion.set("")
13+
}
14+
15+
build {
16+
dependsOn(downgradeJar)
17+
}
18+
}
19+
20+
jvmdg {
21+
downgradeTo = JavaVersion.VERSION_1_8
22+
}

build-logic/src/main/kotlin/hurricane.java-conventions.gradle.kts

Lines changed: 0 additions & 36 deletions
This file was deleted.
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
import net.fabricmc.loom.task.RemapJarTask
2+
3+
plugins {
4+
id("hurricane.shadow-conventions")
5+
id("architectury-plugin")
6+
id("dev.architectury.loom")
7+
}
8+
9+
architectury {
10+
minecraft = libs.versions.minecraft.version.get()
11+
}
12+
13+
java {
14+
withSourcesJar()
15+
}
16+
17+
loom {
18+
silentMojangMappingsLicense()
19+
}
20+
21+
dependencies {
22+
minecraft(libs.minecraft)
23+
mappings(loom.officialMojangMappings())
24+
}
25+
26+
tasks {
27+
shadowJar {
28+
// Mirrors the example fabric project, otherwise tons of dependencies are shaded that shouldn't be
29+
configurations = listOf(project.configurations.shadow.get())
30+
31+
// The remapped shadowJar is the final desired mod jar
32+
archiveVersion.set("")
33+
}
34+
35+
remapJar {
36+
dependsOn(shadowJar)
37+
inputFile.set(shadowJar.get().archiveFile)
38+
archiveClassifier.set("")
39+
archiveVersion.set(project.version.toString())
40+
}
41+
42+
// // TODO can we make this not stupid pls
43+
// register("remapModrinthJar", RemapJarTask::class) {
44+
// dependsOn(shadowJar)
45+
// inputFile.set(shadowJar.get().archiveFile)
46+
// archiveVersion.set(project.version.toString() + "+build." + System.getenv("GITHUB_RUN_NUMBER"))
47+
// archiveClassifier.set("")
48+
// }
49+
50+
build {
51+
dependsOn(remapJar)
52+
}
53+
}
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
plugins {
2+
id("com.modrinth.minotaur")
3+
}
4+
5+
modrinth {
6+
token.set(System.getenv("MODRINTH_TOKEN")) // Even though this is the default value, apparently this prevents GitHub Actions caching the token?
7+
projectId.set("hurricane")
8+
//versionNumber.set(project.version as String + "-" + System.getenv("GITHUB_RUN_NUMBER"))
9+
versionType.set("release")
10+
11+
syncBodyFrom.set(rootProject.file("README.md").readText())
12+
//changelog.set(rootProject.file("CHANGELOG.md").readText())
13+
14+
//uploadFile.set(tasks.getByPath("remapModrinthJar"))
15+
//gameVersions.addAll("1.21.3")
16+
failSilently.set(false)
17+
}

0 commit comments

Comments
 (0)