1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-02-14 18:10:05 +00:00

Send block updates to client when the turtle moves #1167 (#1170)

Fixes #1167
This commit is contained in:
roland-a 2022-09-29 13:49:02 -04:00 committed by GitHub
parent c3b7302108
commit 0b7fbcde53
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -323,8 +323,9 @@ public class TurtleBrain implements ITurtleAccess
try
{
// Create a new turtle
if( world.setBlock( pos, newState, 0 ) )
// We use Block.UPDATE_CLIENTS here to ensure that neighbour updates caused in Block.updateNeighbourShapes
// are sent to the client. We want to avoid doing a full block update until the turtle state is copied over.
if( world.setBlock( pos, newState, 2 ) )
{
Block block = world.getBlockState( pos ).getBlock();
if( block == oldBlock.getBlock() )