Skip to content

Crafter PrepareItemCraftEvents always have null recipe #14428

Description

@JustAHuman-xD

Expected behavior

PrepareItemCraftEvent#getRecipe to return the recipe currently within the crafter.

Observed/Actual behavior

PrepareItemCraftEvent#getRecipe always returns null

Steps/models to reproduce

  1. Create a listener for the PrepareItemCraftEvent
  2. Setup recipes inside of a crafter menu
  3. Observe the result of getRecipe

Plugin and Datapack List

Image Image

(recreated it with running the paper dev server & just adding a listener to log the recipe)

Paper version

Image (running with the latest commit 7f9c797)

Other

The root cause of this seems to be that the bukkit method CraftingInventory#getRecipe relies on the nms method CraftingContainer#getCurrentRecipe which defaults to returning null and CrafterBlockEntity does not override it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: acceptedDisputed bug is accepted as valid or Feature accepted as desired to be added.version: 26.3Game version 26.3

    Type

    Fields

    MC Issue

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions