aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/repo
diff options
context:
space:
mode:
authorLinnea Gräf <nea@nea.moe>2025-02-17 20:47:56 +0100
committerLinnea Gräf <nea@nea.moe>2025-02-17 20:47:56 +0100
commit9cce9ddf26b44871e08a1d5d95f39d5e9b99c524 (patch)
tree2cd249ae647e8860b8db9e2df93144899f1e6a83 /src/main/kotlin/repo
parenta23ac73272da14c0a126c44580ea45014e05a9ad (diff)
downloadFirmament-9cce9ddf26b44871e08a1d5d95f39d5e9b99c524.tar.gz
Firmament-9cce9ddf26b44871e08a1d5d95f39d5e9b99c524.tar.bz2
Firmament-9cce9ddf26b44871e08a1d5d95f39d5e9b99c524.zip
fix: Don't crash with newer fabric versions anymore
Diffstat (limited to 'src/main/kotlin/repo')
-rw-r--r--src/main/kotlin/repo/RepoModResourcePack.kt5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/kotlin/repo/RepoModResourcePack.kt b/src/main/kotlin/repo/RepoModResourcePack.kt
index 617efec..2fdf710 100644
--- a/src/main/kotlin/repo/RepoModResourcePack.kt
+++ b/src/main/kotlin/repo/RepoModResourcePack.kt
@@ -5,6 +5,7 @@ import java.nio.file.Files
import java.nio.file.Path
import java.util.*
import net.fabricmc.fabric.api.resource.ModResourcePack
+import net.fabricmc.fabric.impl.resource.loader.ModResourcePackSorter
import net.fabricmc.loader.api.FabricLoader
import net.fabricmc.loader.api.metadata.ModMetadata
import kotlin.io.path.exists
@@ -28,9 +29,9 @@ import moe.nea.firmament.Firmament
class RepoModResourcePack(val basePath: Path) : ModResourcePack {
companion object {
- fun append(packs: MutableList<in ModResourcePack>) {
+ fun append(packs: ModResourcePackSorter) {
Firmament.logger.info("Registering mod resource pack")
- packs.add(RepoModResourcePack(RepoDownloadManager.repoSavedLocation))
+ packs.addPack(RepoModResourcePack(RepoDownloadManager.repoSavedLocation))
}
fun createResourceDirectly(identifier: Identifier): Optional<Resource> {