Commit 037db864 by Jonathan Thomas

- Fixing onItemGiven to trigger every single time, instead of only when the item is needed.

parent 3f6d7479
Pipeline #12021 passed with stage
in 21 seconds
......@@ -21,11 +21,6 @@ public class MixinMobEntity {
@Inject(method = "interact", at = @At(value = "RETURN"))
private void onItemGiven(PlayerEntity player, Hand hand, CallbackInfoReturnable<ActionResult> cir) {
if (!cir.getReturnValue().isAccepted() || player.getWorld().isClient()) {
// If interaction was not successful, return early
return;
}
ItemStack itemStack = player.getStackInHand(hand);
MobEntity thisEntity = (MobEntity) (Object) this;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment