fix: Jade crash sometimes causing resource reload failures
This commit is contained in:
@@ -126,6 +126,7 @@ fun innerJarsOf(name: String, dependency: Dependency): Provider<FileTree> {
|
||||
|
||||
val collectTranslations by tasks.registering(CollectTranslations::class) {
|
||||
this.baseTranslations.from(file("translations/en_us.json"))
|
||||
this.baseTranslations.from(file("translations/extra.json"))
|
||||
this.classes.from(sourceSets.main.get().kotlin.classesDirectory)
|
||||
}
|
||||
|
||||
|
||||
@@ -16,7 +16,8 @@ import org.spongepowered.asm.mixin.injection.At;
|
||||
|
||||
@Mixin(ClientPlayerInteractionManager.class)
|
||||
public class ReplaceBlockHitSoundPatch {
|
||||
@WrapOperation(method = "updateBlockBreakingProgress", at = @At(value = "NEW", target = "(Lnet/minecraft/sound/SoundEvent;Lnet/minecraft/sound/SoundCategory;FFLnet/minecraft/util/math/random/Random;Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/client/sound/PositionedSoundInstance;"))
|
||||
@WrapOperation(method = "updateBlockBreakingProgress",
|
||||
at = @At(value = "NEW", target = "(Lnet/minecraft/sound/SoundEvent;Lnet/minecraft/sound/SoundCategory;FFLnet/minecraft/util/math/random/Random;Lnet/minecraft/util/math/BlockPos;)Lnet/minecraft/client/sound/PositionedSoundInstance;"))
|
||||
private PositionedSoundInstance replaceSound(
|
||||
SoundEvent sound, SoundCategory category, float volume, float pitch,
|
||||
Random random, BlockPos pos, Operation<PositionedSoundInstance> original,
|
||||
|
||||
6
translations/extra.json
Normal file
6
translations/extra.json
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
// These are require by jade, but i don't think they are actually rendered in game.
|
||||
// Jade throws exceptions if they are not present however.
|
||||
"config.jade.plugin_firmament.toolprovider": "Firmament Tool Provider",
|
||||
"config.jade.plugin_firmament.custom_mining_hardness": "Firmament Mining Hardness"
|
||||
}
|
||||
Reference in New Issue
Block a user