Fabric API

Fabric API

108M Downloads

1.19.1-rc1 message-api PlayerManager mixin needs updating for changes in broadcast method

warjort opened this issue ยท 5 comments

commented

Caused by: org.spongepowered.asm.mixin.injection.throwables.InvalidInjectionException: Critical injection failure: @Inject annotation on onSendGameMessage could not find any targets matching 'Lnet/minecraft/server/PlayerManager;method_43512(Lnet/minecraft/text/Text;Ljava/util/function/Function;Z)V' in net.minecraft.server.PlayerManager. Using refmap fabric-message-api-v1-refmap.json [PREINJECT Applicator Phase -> fabric-message-api-v1.mixins.json:PlayerManagerMixin from mod fabric-message-api-v1 -> Prepare Injections -> -> handler$zek000$onSendGameMessage(Lnet/minecraft/text/Text;Ljava/util/function/Function;ZLorg/spongepowered/asm/mixin/injection/callback/CallbackInfo;)V -> Parse]

Looks like PlayerManager.broadcast(Text, Function) should be broadcast(Text, Function, RegistryKey)

@Inject(method = "broadcast(Lnet/minecraft/text/Text;Ljava/util/function/Function;Z)V", at = @At("HEAD"), cancellable = true)

See #2374

commented

0.57.1+1.19.1 is designed for pre2 and not the older rc1. For pre1 and rc1 use the 1.19.0 version of fabric API, and for rc2 use the new 1.19.1 branch.

Mojang going backwards on version numbers mades this a bit of a mess/confusing.

commented

Isn't rc1 the latest at this point? Or is pre2 to the latest? I'm confused.

commented

Mojang released pre2 after rc1. It contains further changes to the chat reporting system.

commented

Yes, he probably meant pre2.

In order: 1.19 > 1.19.1-pre1 > 1.19.1-rc1 > 1.19.1-pre2

commented

got it.

this was confusing me.
Screen Shot 2022-07-02 at 1 18 05 PM