mojira.dev
MC-313832

Trades that give very high amounts of experience empty the experience bars of villagers instead of leveling them up

The Bug:

Trades that give very high amounts of experience empty the experience bars of villagers instead of leveling them up.

Steps to Reproduce:

  1. Summon a farmer with some experience and a trade that gives a very high amount of experience by using the command provided below.

    /summon minecraft:villager ~ ~ ~2 {VillagerData:{profession:"minecraft:farmer"},Xp:1,Offers:{Recipes:[{buy:{id:"minecraft:emerald"},sell:{id:"minecraft:apple"},xp:2147483647}]}}
  2. Obtain an emerald and trade it to the farmer for the apple.

  3. Close the trading screen, wait a few seconds, and then reopen it.

  4. Observe if the farmer levels up.

Observed Behavior:

Trades that give very high amounts of experience empty the experience bars of villagers.

Expected Behavior:

Trades that give very high amounts of experience would level up villagers.

Attachments

Comments 1

Avoma

(Unassigned)

Unconfirmed

Trading

26.3, 26.4 Release Candidate 1

Retrieved