mojira.dev
MC-73178

Villagers' "CanPickUpLoot" tag cannot be set to zero

The Bug:

Villagers' "CanPickUpLoot" tag cannot be set to zero.

Steps to Reproduce:

  1. Summon a villager with its "CanPickUpLoot" tag set to "0b" by using the command provided below.

    /summon minecraft:villager ~ ~ ~ {CanPickUpLoot:0b}
  2. Inspect the value of the "CanPickUpLoot" tag by using the command provided below.

    /data get entity @e[type=minecraft:villager,limit=1,sort=nearest] CanPickUpLoot
  3. Take note as to whether or not villagers' "CanPickUpLoot" tag can be set to zero.

Observed Behavior:

Villagers' "CanPickUpLoot" tag cannot be set to zero.

Expected Behavior:

Villagers' "CanPickUpLoot" tag would be able to be set to zero.

Linked issues

Attachments

Comments

kumasasa

Do you have mobGriefing set to false?

Ai Akaishi

Regardless of mobGriefing, Villager's CanPickUpLoot is always true and cannot be set to false.
If mobGriefing is false, Villagers cannot pick up bread because the gamerule precedes their CanPickUpLoot.

Sonicwave

Confirmed.

Smokey95dog

Confirmed in 1.8.8 and the newest 1.9 snapshot 15w42a

Andy

to disable villagers from taking your entity's do mobgriefing of
i tink that they have to make a other gamerule for villagers entities stealing and farming becaus when i set mobgriefing false i want no explosions no enderman but i want farmers and food giving to villagers allowed

Irbis

20w06a affected

pulpetti

In 1.16.1 and 20w28a

Avoma

Can confirm in 20w51a.

Avoma

Can confirm in 21w03a.

Avoma

Can confirm in 21w05b.

Avoma

Can confirm in 21w11a.

ampolive

Can confirm in 1.17.1.

Avoma

Can confirm this behavior in 21w41a. Here are some extra details regarding this problem.

The Bug:

Villagers' "CanPickUpLoot" tag cannot be set to 0.

Steps to Reproduce:

  • Summon a villager with its "CanPickUpLoot" tag set to "0b".

/summon minecraft:villager ~ ~ ~ {CanPickUpLoot:0b}
  • Inspect the value of the "CanPickUpLoot" tag by using the "data" command.

/data get entity @e[type=minecraft:villager,limit=1,sort=nearest] CanPickUpLoot
  • Take note as to whether or not villagers' "CanPickUpLoot" tag can be set to 0.

Observed Behavior:

Villagers' "CanPickUpLoot" tag cannot be set to 0.

Expected Behavior:

Villagers' "CanPickUpLoot" tag would be able to be set to 0.

Avoma

Can confirm in 1.18.2.

Avoma

Can confirm in 1.19.

Ai Akaishi

Avoma

etanaratsastaja

Confirmed

Platform

Low

Commands, Entities

CanPickUpLoot, villager

Minecraft 1.8, Minecraft 1.8.1-pre2, Minecraft 1.8.8, Minecraft 15w42a, Minecraft 1.9, ..., 1.19.4, 1.20, 1.20.1, 24w11a, 1.21

24w34a

Retrieved