20w13a
This commit is contained in:
parent
8679c9398f
commit
11290e89e7
28 changed files with 63 additions and 53 deletions
|
@ -127,8 +127,8 @@ public abstract class AbstractIronMachineBlockEntity extends MachineBaseBlockEnt
|
|||
|
||||
// MachineBaseBlockEntity
|
||||
@Override
|
||||
public void fromTag(CompoundTag compoundTag) {
|
||||
super.fromTag(compoundTag);
|
||||
public void fromTag(BlockState blockState, CompoundTag compoundTag) {
|
||||
super.fromTag(blockState, compoundTag);
|
||||
burnTime = compoundTag.getInt("BurnTime");
|
||||
totalBurnTime = compoundTag.getInt("TotalBurnTime");
|
||||
progress = compoundTag.getInt("Progress");
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
package techreborn.blockentity.machine.iron;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.entity.ExperienceOrbEntity;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
@ -125,8 +126,8 @@ public class IronFurnaceBlockEntity extends AbstractIronMachineBlockEntity imple
|
|||
}
|
||||
|
||||
@Override
|
||||
public void fromTag(CompoundTag compoundTag) {
|
||||
super.fromTag(compoundTag);
|
||||
public void fromTag(BlockState blockState, CompoundTag compoundTag) {
|
||||
super.fromTag(blockState, compoundTag);
|
||||
experience = compoundTag.getFloat("Experience");
|
||||
}
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
package techreborn.blockentity.machine.misc;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.block.entity.BlockEntity;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
@ -74,11 +75,11 @@ public class AlarmBlockEntity extends BlockEntity
|
|||
}
|
||||
|
||||
@Override
|
||||
public void fromTag(CompoundTag compound) {
|
||||
public void fromTag(BlockState blockState, CompoundTag compound) {
|
||||
if (compound != null && compound.contains("selectedSound")) {
|
||||
selectedSound = compound.getInt("selectedSound");
|
||||
}
|
||||
super.fromTag(compound);
|
||||
super.fromTag(blockState, compound);
|
||||
}
|
||||
|
||||
// ITickable
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
package techreborn.blockentity.machine.multiblock;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
|
@ -99,8 +100,8 @@ public class FluidReplicatorBlockEntity extends GenericMachineBlockEntity implem
|
|||
|
||||
// TilePowerAcceptor
|
||||
@Override
|
||||
public void fromTag(final CompoundTag tagCompound) {
|
||||
super.fromTag(tagCompound);
|
||||
public void fromTag(BlockState blockState, final CompoundTag tagCompound) {
|
||||
super.fromTag(blockState, tagCompound);
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
package techreborn.blockentity.machine.multiblock;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
|
@ -346,8 +347,8 @@ public class FusionControlComputerBlockEntity extends PowerAcceptorBlockEntity
|
|||
}
|
||||
|
||||
@Override
|
||||
public void fromTag(final CompoundTag tagCompound) {
|
||||
super.fromTag(tagCompound);
|
||||
public void fromTag(BlockState blockState, final CompoundTag tagCompound) {
|
||||
super.fromTag(blockState, tagCompound);
|
||||
this.crafingTickTime = tagCompound.getInt("crafingTickTime");
|
||||
this.neededPower = tagCompound.getInt("neededPower");
|
||||
this.hasStartedCrafting = tagCompound.getBoolean("hasStartedCrafting");
|
||||
|
|
|
@ -100,8 +100,8 @@ public class IndustrialGrinderBlockEntity extends GenericMachineBlockEntity impl
|
|||
}
|
||||
|
||||
@Override
|
||||
public void fromTag(final CompoundTag tagCompound) {
|
||||
super.fromTag(tagCompound);
|
||||
public void fromTag(BlockState blockState, final CompoundTag tagCompound) {
|
||||
super.fromTag(blockState, tagCompound);
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
|
|
|
@ -102,8 +102,8 @@ public class IndustrialSawmillBlockEntity extends GenericMachineBlockEntity impl
|
|||
|
||||
// TilePowerAcceptor
|
||||
@Override
|
||||
public void fromTag(final CompoundTag tagCompound) {
|
||||
super.fromTag(tagCompound);
|
||||
public void fromTag(BlockState blockState, final CompoundTag tagCompound) {
|
||||
super.fromTag(blockState, tagCompound);
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
package techreborn.blockentity.machine.tier1;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.inventory.CraftingInventory;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
@ -431,11 +432,11 @@ public class AutoCraftingTableBlockEntity extends PowerAcceptorBlockEntity
|
|||
}
|
||||
|
||||
@Override
|
||||
public void fromTag(CompoundTag tag) {
|
||||
public void fromTag(BlockState blockState, CompoundTag tag) {
|
||||
if (tag.contains("locked")) {
|
||||
locked = tag.getBoolean("locked");
|
||||
}
|
||||
super.fromTag(tag);
|
||||
super.fromTag(blockState, tag);
|
||||
}
|
||||
|
||||
// TileMachineBase
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
package techreborn.blockentity.machine.tier1;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
|
@ -110,8 +111,8 @@ public class PlayerDectectorBlockEntity extends PowerAcceptorBlockEntity impleme
|
|||
}
|
||||
|
||||
@Override
|
||||
public void fromTag(CompoundTag tag) {
|
||||
super.fromTag(tag);
|
||||
public void fromTag(BlockState blockState, CompoundTag tag) {
|
||||
super.fromTag(blockState, tag);
|
||||
owenerUdid = tag.getString("ownerID");
|
||||
}
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
|
||||
package techreborn.blockentity.machine.tier1;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.inventory.CraftingInventory;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
@ -348,8 +349,8 @@ public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
|||
}
|
||||
|
||||
@Override
|
||||
public void fromTag(final CompoundTag tagCompound) {
|
||||
super.fromTag(tagCompound);
|
||||
public void fromTag(BlockState blockState, final CompoundTag tagCompound) {
|
||||
super.fromTag(blockState, tagCompound);
|
||||
this.isRunning = tagCompound.getBoolean("isRunning");
|
||||
this.tickTime = tagCompound.getInt("tickTime");
|
||||
this.locked = tagCompound.getBoolean("locked");
|
||||
|
|
|
@ -140,8 +140,8 @@ public class ChunkLoaderBlockEntity extends MachineBaseBlockEntity implements IT
|
|||
}
|
||||
|
||||
@Override
|
||||
public void fromTag(CompoundTag nbttagcompound) {
|
||||
super.fromTag(nbttagcompound);
|
||||
public void fromTag(BlockState blockState, CompoundTag nbttagcompound) {
|
||||
super.fromTag(blockState, nbttagcompound);
|
||||
this.radius = nbttagcompound.getInt("radius");
|
||||
this.ownerUdid = nbttagcompound.getString("ownerUdid");
|
||||
if(!StringUtils.isBlank(ownerUdid)){
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue