Switch to special-purpose loom fork & quilt + mojang layered mappings

main
Charlotte Som 2022-02-04 18:03:35 +00:00
parent 3736a86842
commit f9e0df935c
9 changed files with 54 additions and 22 deletions

2
.gitignore vendored
View File

@ -9,5 +9,3 @@
*.iws
/run/
/vendor/

9
.gitmodules vendored Normal file
View File

@ -0,0 +1,9 @@
[submodule "build_src/quilt-mappings-on-loom"]
path = build_src/quilt-mappings-on-loom
url = https://git.lavender.software/hibiscus-client/quilt-mappings-on-loom.git
[submodule "build_src/fabric-loom"]
path = build_src/fabric-loom
url = https://git.lavender.software/hibiscus-client/fabric-loom.git
[submodule "vendor"]
path = vendor
url = https://git.lavender.software/hibiscus-client/vendored-jars.git

View File

@ -1,3 +1,30 @@
# hibiscus client
:)
## Setup
```shell
$ git clone --recursive "https://git.lavender.software/hibiscus-client/hibiscus.git"
$ cd hibiscus/
hibiscus/ $ # [open IntelliJ IDEA or something here, otherwise:]
hibiscus/ $ ./gradlew runClient
```
**Make sure you clone recursive!** If you didn't, just:
```shell
hibiscus/ $ git submodule update --init
```
You may want to also mark the `run` and `vendor` folders as excluded in IntelliJ.
To authenticate from the IDE, you can create a lastlogin.txt file in `run/` (already gitignored) with the following structure.
```text
me@example.com
my super secure minecraft password
```
This is handled by *unknit*'s `MixinMinecraftMain`, and logs your account in at game start-up.
If you do not trust having the file within the project directory, you can set the `LOGIN_FILE` environment variable.

View File

@ -3,9 +3,10 @@ import org.quiltmc.quiltmappings.loom.QuiltMappingsOnLoomPlugin
plugins {
id("fabric-loom")
id("org.quiltmc.quilt-mappings-on-loom")
val kotlinVersion: String by System.getProperties()
kotlin("jvm").version(kotlinVersion)
id("org.quiltmc.quilt-mappings-on-loom").version("3.1.1")
}
base {
@ -18,18 +19,12 @@ version = modVersion
val mavenGroup: String by project
group = mavenGroup
minecraft {}
repositories {}
dependencies {
val minecraftVersion: String by project
minecraft("com.mojang:minecraft:$minecraftVersion")
val USE_QUILT_MAPPINGS = false
if (USE_QUILT_MAPPINGS) {
// Seems to crash on startup right now
val quiltMappings: String by project
mappings(loom.layered {
officialMojangMappings {
@ -39,10 +34,6 @@ dependencies {
val qm = extensionOf(project, "quiltMappings") as QuiltMappingsOnLoomPlugin.QuiltMappingsOnLoomExtension
addLayer(qm.mappings("org.quiltmc:quilt-mappings:${quiltMappings}:v2"))
})
} else {
val yarnMappings: String by project
mappings("net.fabricmc:yarn:$yarnMappings:v2")
}
val loaderVersion: String by project
modImplementation("net.fabricmc:fabric-loader:$loaderVersion")

1
build_src/fabric-loom Submodule

@ -0,0 +1 @@
Subproject commit 71c28bbcd075d6d0c45dcdde71246e61ccb661e3

@ -0,0 +1 @@
Subproject commit c635aeea01c722ac27c8f1d81796415d4096fa7c

View File

@ -1,3 +1,6 @@
includeBuild("build_src/fabric-loom")
includeBuild("build_src/quilt-mappings-on-loom")
pluginManagement {
repositories {
maven("https://maven.fabricmc.net") { name = "Fabric" }
@ -8,6 +11,7 @@ pluginManagement {
plugins {
val loomVersion: String by settings
id("fabric-loom").version(loomVersion)
val kotlinVersion: String by System.getProperties()
kotlin("jvm").version(kotlinVersion)
}

View File

@ -11,5 +11,5 @@ object ImGuiScreen : Screen(Text.of("hacker menu")) {
ModuleControlsUI.render(delta)
}
override fun shouldPause() = false
override fun isPauseScreen() = false
}

1
vendor Submodule

@ -0,0 +1 @@
Subproject commit 717d6a90f064371fb15e2bc33a6d86cf2552a6ec