PaperMC / PaperMC/Paper

PlayerItemConsumeEvent triggering issue

Open
#13,138 5 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

status: accepted
Dominant language
Java
Stars
12.7k
Forks
3.5k
Avg merge
3d 13h
Merged PRs (30d)
11

Description

Expected behavior

item with consumable component and consume seconds = 0 trigger PlayerItemConsumeEvent after consumed

Observed/Actual behavior

item with consumable component and consume seconds = 0 don't trigger PlayerItemConsumeEvent

Steps/models to reproduce

/give @s stone[consumable={consume_seconds:0}]
listen to PlayerItemConsumeEvent

Plugin and Datapack List

not related

Paper version

1.21.8-60

Other

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with /give @s stone[consumable={consume_seconds:0}] while listening for PlayerItemConsumeEvent, then trace the consume-event handling path for zero-second consumables. Done means the event is triggered after the item is consumed, matching the behavior for consumables with a positive duration.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
api, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
62/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.