Fix block updating.
This commit is contained in:
		| @@ -98,7 +98,8 @@ public abstract class BlockBase extends Block | |||||||
|  |  | ||||||
| 			((TileBase) tile).setDirection(EnumFacing.getFront(newDir)); | 			((TileBase) tile).setDirection(EnumFacing.getFront(newDir)); | ||||||
|  |  | ||||||
| 			// @TODO: world.markBlockForUpdate(pos); | 			world.notifyBlockUpdate(pos, world.getBlockState(pos), world.getBlockState(pos), 2 | 4); | ||||||
|  |  | ||||||
| 			return true; | 			return true; | ||||||
| 		} | 		} | ||||||
|  |  | ||||||
|   | |||||||
| @@ -432,7 +432,7 @@ public class TileController extends TileBase implements IEnergyReceiver, INetwor | |||||||
|  |  | ||||||
| 		if (lastEnergy != energy.getEnergyStored()) | 		if (lastEnergy != energy.getEnergyStored()) | ||||||
| 		{ | 		{ | ||||||
| 			// @TODO: worldObj.markBlockForUpdate(pos); | 			worldObj.notifyBlockUpdate(pos, worldObj.getBlockState(pos), worldObj.getBlockState(pos), 2 | 4); | ||||||
| 		} | 		} | ||||||
|  |  | ||||||
| 		energyUsage = buf.readInt(); | 		energyUsage = buf.readInt(); | ||||||
|   | |||||||
| @@ -204,7 +204,7 @@ public class TileDetector extends TileMachine implements ICompareSetting | |||||||
|  |  | ||||||
| 		if (powered != lastPowered) | 		if (powered != lastPowered) | ||||||
| 		{ | 		{ | ||||||
| 			// @TODO: worldObj.markBlockForUpdate(pos); | 			worldObj.notifyBlockUpdate(pos, worldObj.getBlockState(pos), worldObj.getBlockState(pos), 2 | 4); | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
|   | |||||||
| @@ -125,7 +125,6 @@ public class TileGrid extends TileMachine | |||||||
|  |  | ||||||
| 			onCraftingMatrixChanged(); | 			onCraftingMatrixChanged(); | ||||||
|  |  | ||||||
| 			// @TODO: HACK! |  | ||||||
| 			TargetPoint target = new TargetPoint(worldObj.provider.getDimensionType().getId(), pos.getX(), pos.getY(), pos.getZ(), UPDATE_RANGE); | 			TargetPoint target = new TargetPoint(worldObj.provider.getDimensionType().getId(), pos.getX(), pos.getY(), pos.getZ(), UPDATE_RANGE); | ||||||
|  |  | ||||||
| 			StorageCraft.NETWORK.sendToAllAround(new MessageGridCraftingUpdate(this), target); | 			StorageCraft.NETWORK.sendToAllAround(new MessageGridCraftingUpdate(this), target); | ||||||
|   | |||||||
| @@ -116,7 +116,7 @@ public abstract class TileMachine extends TileBase implements INetworkTile, IRed | |||||||
|  |  | ||||||
| 		if (lastConnected != connected) | 		if (lastConnected != connected) | ||||||
| 		{ | 		{ | ||||||
| 			// @TODO: worldObj.markBlockForUpdate(pos); | 			worldObj.notifyBlockUpdate(pos, worldObj.getBlockState(pos), worldObj.getBlockState(pos), 2 | 4); | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
|   | |||||||
| @@ -154,7 +154,7 @@ public class TileWirelessTransmitter extends TileMachine implements IInventory | |||||||
|  |  | ||||||
| 		if (lastWorking != working) | 		if (lastWorking != working) | ||||||
| 		{ | 		{ | ||||||
| 			// @TODO: worldObj.markBlockForUpdate(pos); | 			worldObj.notifyBlockUpdate(pos, worldObj.getBlockState(pos), worldObj.getBlockState(pos), 2 | 4); | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Raoul Van den Berge
					Raoul Van den Berge