mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-26 23:03:01 +00:00
Of course, the issue isn't on Minecraft's end, it has to do with Coord4D hashing. Coord4D no longer extends BlockPos to prevent hash issues
This commit is contained in:
1 parent
c6f3c162f9
commit
ddfe83c495
70 files changed
+458
-1032
No files matched your search
@@ -37,7 +37,7 @@ public class LaserManager
|
||||
if(mop != null)
|
||||
{
|
||||
to = new Pos3D(mop.hitVec);
|
||||
Coord4D toCoord = new Coord4D(mop.getBlockPos());
|
||||
Coord4D toCoord = new Coord4D(mop.getBlockPos(), world);
|
||||
TileEntity tile = toCoord.getTileEntity(world);
|
||||
|
||||
if(tile instanceof ILaserReceptor)
|
||||
@@ -83,8 +83,8 @@ public class LaserManager
|
||||
IBlockState state = blockCoord.getBlockState(world);
|
||||
Block blockHit = state.getBlock();
|
||||
|
||||
EntityPlayer dummy = Mekanism.proxy.getDummyPlayer((WorldServer)world, blockCoord.getX(), blockCoord.getY(), blockCoord.getZ()).get();
|
||||
BlockEvent.BreakEvent event = new BlockEvent.BreakEvent(world, blockCoord, state, dummy);
|
||||
EntityPlayer dummy = Mekanism.proxy.getDummyPlayer((WorldServer)world, blockCoord.xCoord, blockCoord.yCoord, blockCoord.zCoord).get();
|
||||
BlockEvent.BreakEvent event = new BlockEvent.BreakEvent(world, blockCoord.getPos(), state, dummy);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
|
||||
if(event.isCanceled())
|
||||
@@ -94,15 +94,15 @@ public class LaserManager
|
||||
|
||||
if(dropAtBlock)
|
||||
{
|
||||
blockHit.dropBlockAsItem(world, blockCoord, state, 0);
|
||||
blockHit.dropBlockAsItem(world, blockCoord.getPos(), state, 0);
|
||||
}
|
||||
else {
|
||||
ret = blockHit.getDrops(world, blockCoord, state, 0);
|
||||
ret = blockHit.getDrops(world, blockCoord.getPos(), state, 0);
|
||||
}
|
||||
|
||||
blockHit.breakBlock(world, blockCoord, state);
|
||||
world.setBlockToAir(blockCoord);
|
||||
world.playAuxSFX(2001, blockCoord, Block.getIdFromBlock(blockHit));
|
||||
blockHit.breakBlock(world, blockCoord.getPos(), state);
|
||||
world.setBlockToAir(blockCoord.getPos());
|
||||
world.playAuxSFX(2001, blockCoord.getPos(), Block.getIdFromBlock(blockHit));
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user