Closed RubixDev closed 3 months ago
This mod utilizes fabric loader's versioning api for version check, which should be the only place that relies on fabric
I've started implementing support for forge, but stumbled upon a rather big problem: the version predicates that conditional mixin uses is directly the one from the Fabric loader, and it relies on its parser. Forge on the other hand declares version ranges according to the apache version spec. That means that in a forge environment the parser for the currently used version predicate strings is unavailable. So to add cross-platform support we would have to decouple the version predicate stuff from the fabric loader. What are your thoughts on this?
yeah, as you pointed out, to make it multi-loader support, it's necessary to extract and separate the mod version related stuffs from the main codebase. One possible approach is refactoring the project into a common subproject (requires mixin only) + serveral platform specialized subproject (for fabric, forge, etc.)
Another problem is about the versionPredicate syntax design. Possible workarounds:
Close as PR #5 is merged
It would be really nice to have this available for Forge and NeoForge as well. I have a multiplatform Architectury project but sadly cannot use this as it only works for Fabric atm.
As far as I can tell, most of this mods code doesn't really depend on Fabric already, so I might give this a go myself.