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

Server side particle spawning does not create particles for client

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Resolution: Fixed
    • Affects Version/s: Snapshot 13w09a, Snapshot 13w09b, Snapshot 13w09c, Snapshot 13w10a, Snapshot 13w10b, Minecraft 1.5, Snapshot 13w11a, Minecraft 1.5.1, Snapshot 13w16a, Snapshot 13w16b, Minecraft 1.5.2, Snapshot 13w17a, Minecraft 1.6.2, Minecraft 1.7.4, Minecraft 14w05b, Minecraft 14w06b, Minecraft 14w07a, Minecraft 1.8, Minecraft 1.8.1-pre2, Minecraft 1.8.8, Minecraft 15w47c, Minecraft 1.8.9, Minecraft 16w06a, Minecraft 1.9, Minecraft 1.9.1 Pre-Release 3, Minecraft 1.10.2, Minecraft 16w32b, Minecraft 1.11.2, Minecraft 1.12 Pre-Release 6, Minecraft 1.12.1, Minecraft 1.12.2, Minecraft 17w50a, Minecraft 18w05a, Minecraft 18w08b, Minecraft 18w11a, Minecraft 1.13-pre1, Minecraft 1.13-pre6, Minecraft 1.13.1
    • Fix Version/s: Minecraft 19w14a
    • Confirmation Status:
      Confirmed
    • Category:
      (Unassigned)

      Description

      The bug

      Particle creation triggered for the server does not send a particle packets to the client.

      Affected situations

      The following is based on decompiled version of Minecraft 1.9 using MCP 9.24 beta. All method and class names are the names used in the decompiled version.

      Iron and snow Golem creation
      • Affected method: net.minecraft.block.BlockPumpkin.trySpawnGolem(World, BlockPos)
      • Suggested fix: See comment
      Wither boss creation
      • Affected method: net.minecraft.block.BlockSkull.checkWitherSpawn(World, BlockPos, TileEntitySkull)
      • Suggested fix: See comment
      Water and lava colliding
      • Affected method: net.minecraft.block.BlockLiquid.triggerMixEffects(World, BlockPos)
      • Suggested fix: See comment
      Redstone torch burning out
      • Affected method: net.minecraft.block.BlockRedstoneTorch.updateTick(World, BlockPos, IBlockState, Random)
      • Suggested fix: See comment
      Armor breaking on mob
      • Affected method: net.minecraft.entity.EntityLivingBase.renderBrokenItemStack(ItemStack)
      • How to reproduce: See description of MC-96974
      Placing eye of ender in end portal frame
      • Affected method: net.minecraft.item.ItemEnderEye.onItemUse(ItemStack, EntityPlayer, World, BlockPos, EnumHand, EnumFacing, float, float, float)
      • Suggested fix: See comment
      Animal being born
      • Affected method: net.minecraft.entity.ai.EntityAIMate.spawnBaby()
      Ender dragon destroying blocks
      • Affected method: net.minecraft.entity.boss.EntityDragon.destroyBlocksInAABB(AxisAlignedBB)
      Explosion particles for EntityLiving spawned by spawner
      • Affected method: net.minecraft.tileentity.MobSpawnerBaseLogic.updateSpawner()

      The reason

      The following is based on decompiled version of Minecraft 1.9 using MCP 9.24 beta. All method and class names are the names used in the decompiled version.

      The reason why this is happening is because the abstract method net.minecraft.world.IWorldEventListener.spawnParticle(int, boolean, double, double, double, double, double, double, int...) is called for particle creation. Calling this method calls for the client the net.minecraft.client.renderer.RenderGlobal.spawnParticle(int, boolean, double, double, double, double, double, double, int...) method which creates the particle. However, for the server it calls the net.minecraft.world.WorldManager.spawnParticle(int, boolean, double, double, double, double, double, double, int...) method which does nothing. The change of using an integrated server for the client might have caused this bug.
      It is probably not a good decision to fix this by having the net.minecraft.world.WorldManager class sending particle packets every time the method is called because this method does not support a count parameter, which means that for example for the creation of an iron or snow golem 120 packets are being sent. Instead the method net.minecraft.world.WorldServer.spawnParticle(EnumParticleTypes, double, double, double, int, double, double, double, double, int...) should be used which has a particle count parameter and uses the value for creating the particle packet.

      Comparing with old behaviour

      If you would like to test how it was in 1.2.5, you can download the 1.2.5 jar file from here:
      http://www.minecraftwiki.net/wiki/Version_history/Development_versions#Minecraft_1.2_Snapshots_.26_Pre-releases
      Or you can create a new profile in the launcher with the version "release 1.2.5"
      Replace your current jar file with the 1.2.5 one and spawn each Golem to see the particles.

        Attachments

        1. 1.2.5 Iron Golem.png
          1.2.5 Iron Golem.png
          734 kB
        2. 1.2.5 Snow Golem.png
          1.2.5 Snow Golem.png
          484 kB
        3. 13w09a Iron Golem.png
          13w09a Iron Golem.png
          207 kB
        4. 13w09a Snow Golem.png
          13w09a Snow Golem.png
          212 kB
        5. Fixed Server Particles-Chorus Fruit.PNG
          Fixed Server Particles-Chorus Fruit.PNG
          2.19 MB

          Issue Links

            Activity

              People

              • Assignee:
                boq [Mojang] Bartosz Bok
                Reporter:
                marcono1234 [Mod] Marcono1234
              • Votes:
                31 Vote for this issue
                Watchers:
                16 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  CHK: