Closed MattSturgeon closed 9 months ago
Not sure why I was having issues before, but I've tested my original code again without the workaround and everything is working fine now.
Other than the mod icon being missing from the mod menu, this issue appears to be invalid.
The
sourceJar
task adds sources & resources from the:common
project, however nothing does this when running via IDE run tasks or (I assume) therunClient
gradle task.This means resources (such as icons and textures) are missing when debugging.
Oddly, i18n still seems to work, despite
lang
files also being missing from the build, which is odd...Workaround
Original workaround
I'm currently "fixing" this by manually tweaking the sourceSet: ```groovy sourceSets { main { resources { resources.srcDir tasks.getByPath(":common:processResources").outputs } } } ``` But that means I end up having to set `DuplicatesStrategy.EXCLUDE` in `sourcesJar`'s `commonSources` map, which feels a bit hacky.
EDIT: the workaround above breaks production's mixin
refMaps
, I ended up moving all my assets into a separate source set, and include that instead:This works in production and also doesn't need the
sourcesJar
workaround.