if you put lava flowing down wards in an open space you can see squids spawning and falling
Please change the "How to reproduce" to this:
How to reproduce
Create a "Redstone Ready" superflat world
Go away from spawn (maybe about 1000 blocks)
Set
/gamerule doDaylightCycle false
to prevent monsters from spawningUse the following commands
/fill ~ ~-12 ~ ~50 ~-13 ~50 structure_void
/fill ~ ~-1 ~ ~50 ~-11 ~50 lava
Go below the lava
→ Squids will spawn and fall down
From MC-62856:
Steps to reproduce
1.Create superflat world
2. /fill ~50 ~-2 ~50 Lava
3.Go down 3 blocks
4./fill ~50 ~-2 ~50 Piston_Extension
5. Watch
Mod edit
Code analysis by @unknown in this comment
Linked issues
is duplicated by 8
Attachments
Comments 21
Still in 30c / 31a (MC-64604).
Please change the "How to reproduce" to this:
How to reproduce
Create a "Redstone Ready" superflat world
Go away from spawn (maybe about 1000 blocks)
Set
/gamerule doDaylightCycle false
to prevent monsters from spawningUse the following commands
/fill ~ ~-12 ~ ~50 ~-13 ~50 structure_void
/fill ~ ~-1 ~ ~50 ~-11 ~50 lava
Go below the lava
→ Squids will spawn and fall down
Please link to this comment in the description
The following is based on a decompiled version of Minecraft 1.10 using MCP 9.30.
The reason for this is very likely that the method net.minecraft.world.WorldEntitySpawner.canCreatureTypeSpawnAtLocation(SpawnPlacementType, World, BlockPos)
tests in case the SpawnPlacementType
is IN_WATER
(used by Guardians and Squids) only if the blocks are liquids. Instead it should test if the material of the block is water.
public static boolean canCreatureTypeSpawnAtLocation(EntityLiving.SpawnPlacementType spawnPlacementTypeIn, World worldIn, BlockPos pos)
{
if (!worldIn.getWorldBorder().contains(pos))
{
return false;
}
else
{
IBlockState iblockstate = worldIn.getBlockState(pos);
if (spawnPlacementTypeIn == EntityLiving.SpawnPlacementType.IN_WATER)
{
// Replaced this
// Imported "net.minecraft.block.material.Material"
//return iblockstate.getMaterial().isLiquid() && worldIn.getBlockState(pos.down()).getMaterial().isLiquid() && !worldIn.getBlockState(pos.up()).isNormalCube();
return iblockstate.getMaterial() == Material.WATER && worldIn.getBlockState(pos.down()).getMaterial() == Material.WATER && !worldIn.getBlockState(pos.up()).isNormalCube();
}
else
{
BlockPos blockpos = pos.down();
if (!worldIn.getBlockState(blockpos).isFullyOpaque())
{
return false;
}
else
{
Block block = worldIn.getBlockState(blockpos).getBlock();
boolean flag = block != Blocks.BEDROCK && block != Blocks.BARRIER;
return flag && isValidEmptySpawnBlock(iblockstate) && isValidEmptySpawnBlock(worldIn.getBlockState(pos.up()));
}
}
}
}
Can confirm this. They are spawning inside of lava.