mojira.dev

CodeCorrecter

Assigned

No issues.

Comments

[media: Don't drop xp upon death.mp4]
[media: Affected by poison and regen.mp4]

Here’s more proof. Low quality to preserve space.

[media: Wither tries to attack.mp4]
[media: Armadillos and piglins aren't scared.mp4]
[media: Aren't attacked by iron and snow golems.mp4]

I also forgot to mention that these broken zombified piglins also don’t drop xp upon death.

Here’s some proof, that Smite doesn’t work on them. Please do note that a resource pack is being used.

[media: Unaffected by Smite.mp4]

This bug also prevents them from infecting villagers into zombie villagers, creating disparity with Java Edition.

This is because in the zombie’s client_entity JSON files, they have and animate the bow_and_arrow animation, so a way to fix this bug would be to remove them from the client entity files.

Another way to fix this would be to change controller.animation.bow_and_arrow from this:

"controller.animation.humanoid.bow_and_arrow": {
            "initial_state": "default",
            "states": {
                "bow_and_arrow": {
                    "animations": [ "bow_and_arrow" ],
                    "transitions": [
                        {
                            "default": "!query.has_target"
                        }
                    ]
                },
                "default": {
                    "transitions": [
                        {
                            "bow_and_arrow": "query.has_target"
                        }
                    ]
                }
            }
        }

to this:

"controller.animation.humanoid.bow_and_arrow": {
            "initial_state": "default",
            "states": {
                "bow_and_arrow": {
                    "animations": [ "bow_and_arrow" ],
                    "transitions": [
                        {
                            "default": "!query.has_target || !query.facing_target_to_range_attack"
                        }
                    ]
                },
                "default": {
                    "transitions": [
                        {
                            "bow_and_arrow": "query.has_target && query.facing_target_to_range_attack"
                        }
                    ]
                }
            }
        }

To add more info, the spawn_baby_jockey event does not exist in the zombie_pigman.json file, resulting in no component groups being added. So, @tryashtar, these broken zombified piglins aren’t actually missing the minecraft:pig_zombie_adult and minecraft:pig_zombie_calm component groups, but are actually missing the minecraft:pig_zombie_baby, minecraft:pig_zombie_jockey and minecraft:pig_zombie_calm component groups instead.

This has not been fixed for saddled striders that have naturally spawned with a zombified piglin rider, or have just naturally spawned due to MCPE-236161.

Baby husks could not mount any mob because of a typo in their minecraft:type_family component, where baby_undead had an extra space at the end. That typo has been fixed in 26.10.24.

Baby zombie villagers do have the baby_undead family in their minecraft:type_family component, correctly spelt.

But the actual reason that they cannot mount any mob, is because other families from the profession component groups override baby_undead, like unskilled, armorer, librarian, etc. preventing them from finding mounts.

This is because in the zombie_villager_v2.json file, in the minecraft:entity_spawned event, in the section where profession component groups are added, there is a filter: { "test": "has_component", "operator": "!=", "value": "minecraft:is_baby" }. That filter tries to prevent baby zombie villagers from gaining professions, but doesn’t. So the actual bug, isn’t that baby zombie villagers can’t ride mobs, but baby zombie villagers can spawn with professions.

Additionally, in the minecraft:as_baby event, there is a non-existent spawn event specified which is minecraft:randomize_job. Since the event doesn’t exist, this results in “infected“ baby zombie villagers spawned by right-clicking their corresponding spawn egg on the adult able to ride mobs. If it does exist, then they can’t.

I attached a video which shows how to fix this bug and as well as MCPE-234691.

[media: Fix MCPE-234690 and MCPE-234691.mp4]

Affects 26.60.

This issue should be reopened as I provided a fix for this.

You’re right Sniper1.1. This bug is super easy to fix.

First, go to the villager_v2.json file, then go to the baby component group and add these lines of code of the minecraft:type_family component.

"minecraft:type_family": {
  "family": [
    "baby_villager",
    "villager",
    "mob"
  ]
}

And go to the minecraft:entity_born event and remove the unskilled component group from it. From this:

"add": {
  "component_groups": [
    "baby",
    "unskilled",
    "child_schedule"
  ]
}

to this:

"add": {
  "component_groups": [
    "baby",
    "child_schedule"
  ]
}

Then go to the vindicator.json and change minecraft:behavior.nearest_attackable_target component in minecraft:vindicator_johnny from this:

"minecraft:vindicator_johnny": {
        "minecraft:behavior.nearest_attackable_target": {
          "must_see": true,
          "within_radius": 12,
          "must_see_forget_duration": 40,
          "entity_types": [
            {
              "filters": {
                "AND": [
                  {
                    "test": "is_family",
                    "subject": 1,
                    "operator": 1,
                    "value": "illager"
                  }
                ]
              },
              "max_dist": 12
            }
          ],
          "priority": 2
        }
      }

to this:

"minecraft:vindicator_johnny": {
        "minecraft:behavior.nearest_attackable_target": {
          "must_see": true,
          "within_radius": 12,
          "must_see_forget_duration": 40,
          "entity_types": [
            {
              "filters": {
                "all_of": [
                  {
                    "test": "is_family",
                    "subject": "other",
                    "operator": "!=",
                    "value": "illager"
                  },
                  {
                    "test": "is_family",
                    "subject": "other",
                    "operator": "!=",
                    "value": "baby_villager"
                  }
                ]
              },
              "max_dist": 12
            }
          ],
          "priority": 2
        }
      }

Crazy how we can fix these bugs but Mojang can’t.

Zombies, Skeletons, Creepers, and other naturally spawning hostile mobs, are all hardcoded to only spawn at light level 0. So the minecraft:brightness_filter’s min and max fields have no effect on them. But I can assume that they forgot to add this hardcoded behavior to Camel Husks and Zombie Horses. In their JSON files, they have this copied and pasted brightness filter component from zombies.

"minecraft:brightness_filter": {
  "min": 0,
  "max": 7,
  "adjust_for_weather": true
},

So another workaround would be to change max’s value from 7 to 0.

Also, why is this bug report still marked as ‘Plausible', even when there’s clear proof shown?

The reason for cause of this bug is actually pretty simple.

Since 26.0, zombie nautiluses have been added to the monster family. But iron golems and snow golems attack any mob that are in the monster family. So the way to fix this would be to add this filter into their minecraft:behavior.nearest_attackable_target component.

{ "test": "is_family", "subject": "other", "operator": "not", "value": "zombie_nautilus" }

The reason is actually a lot more complicated than it is.

When Preview 26.0.27 released, they added baby zombified piglins to the baby_undead family, and they had to move the minecraft:type_family component from the base components to the pig_zombie_adult and pig_zombie_baby component groups.

Why did they make this change?

Well, they supposedly fixed MCPE-223845, where some zombie variants do not find mobs to mount, including zombified piglins. But the truth is that they actually didn’t. In the minecraft:entity_spawned event, they added the spawn_baby_jockey event in there as a trigger. But they actually forgot to add the event itself. And the minecraft:type_family component got moved to separate component groups instead of remaining as a base component, these baby zombified piglin jockeys aren’t even babies. And since these broken zombified piglins aren’t in any family, it doesn’t just affect riding, but also some of their other attributes.

  • They cannot be affected by Smite, as they aren’t in the undead family.

  • They aren’t attacked by snow golems and iron golems, as they aren’t in the monster family.

  • Armadillos don’t roll up when near them, as they aren’t in the undead family.

  • Piglins and wandering traders, aren’t scared of them, as they aren’t in the zombie_pigman family. Additionally, they also don’t avoid baby zombified piglins, as they are in the baby_zombie_pigman family instead.

  • They are also able to be affected by poison and regeneration, and be attacked by the Wither, as they aren’t in the undead family.

I attached a video on how to fix this bug. It is edited and made faster to consume less space.

Can I also request that the title should be changed to 'Zombified Piglins occasionally spawn with missing attributes'?

[media: Fix MCPE-236034 and MCPE-236161.mp4]

Btw I’m new to the bug tracker.