Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-265933

Stray conversion timer resets upon reloading the skeleton

XMLWordPrintable

    • Community Consensus
    • Mob behaviour, Save Data
    • Low
    • Gameplay

      When a skeleton in powder snow begins to shake, the StrayConversionTime starts to count down, and this behavior is correct.
      However, if you unload the skeleton and load it back in (eg by re-entering the world), the skeleton no longer is converting, and the StrayConversionTime is set back to -1.

      Steps to Reproduce:

      1. Spawn a skeleton in powdered snow
      2. Wait ~8 seconds
      3. Check the skeleton's conversion timer
        → Note value
        /data get entity @e[type=minecraft:skeleton,limit=1,sort=nearest] StrayConversionTime
        
      4. Leave, and re-enter the world
      5. Repeat step 3
        → Note value

      Expected & Observed Results:

      - The first check for the skeleton's `StrayConversionTime` will be in the hundreds starting from 300 and counting down, when the player leaves the world and rejoins, the value will be reset to `-1` indicating that the timer was not properly saved to NBT.
      - The skeleton would properly have it's conversion timer saved to NBT data, allowing the player to leave and rejoin the world.

      Notes:

      1. Code analysis can be found in the pinned comment of this issue.
      2. It appears there's another timer that's not written to NBT: the time spent in the powder snow. Because it is not written, the skeleton believes it hasn't been in powder snow for at least 3 seconds, and stops the conversion.
        Zombies have their respective timer written to NBT as InWaterTime.
      3. This issue has been updated by Jingy on 3/13/2024 to include more information, but retains all information from the original issue description.

            Unassigned Unassigned
            Jingy Jiingy
            Votes:
            4 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              CHK: