1696 - find + replace pass
This commit is contained in:
parent
368e2d48df
commit
b6312b124a
94 changed files with 418 additions and 419 deletions
|
@ -32,12 +32,12 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.world.gen.structure.MapGenStructureIO;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import net.minecraftforge.fluids.FluidRegistry;
|
||||
import net.minecraftforge.fml.common.Loader;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
import net.minecraftforge.fml.common.SidedProxy;
|
||||
import net.minecraftforge.fml.common.event.*;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.fml.common.network.NetworkRegistry;
|
||||
import net.minecraftforge.fml.common.registry.EntityRegistry;
|
||||
import net.minecraftforge.fml.common.registry.ForgeRegistries;
|
||||
|
|
|
@ -26,7 +26,7 @@ package techreborn.blocks;
|
|||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.block.properties.PropertyBool;
|
||||
import net.minecraft.block.properties.PropertyDirection;
|
||||
import net.minecraft.state.DirectionProperty;
|
||||
import net.minecraft.block.state.BlockStateContainer;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.client.resources.I18n;
|
||||
|
@ -55,13 +55,13 @@ import javax.annotation.Nullable;
|
|||
import java.util.List;
|
||||
|
||||
public class BlockAlarm extends BaseTileBlock {
|
||||
public static PropertyDirection FACING;
|
||||
public static DirectionProperty FACING;
|
||||
public static PropertyBool ACTIVE;
|
||||
private AxisAlignedBB[] bbs;
|
||||
|
||||
public BlockAlarm() {
|
||||
super(Material.ROCK);
|
||||
this.setDefaultState(this.blockState.getBaseState().withProperty(FACING, EnumFacing.NORTH).withProperty(ACTIVE, false));
|
||||
this.setDefaultState(this.blockState.getBaseState().with(FACING, EnumFacing.NORTH).with(ACTIVE, false));
|
||||
this.bbs = GenBoundingBoxes(0.19, 0.81);
|
||||
RebornModelRegistry.registerModel(new ModelCompound(TechReborn.MOD_ID, this, "machines/lighting"));
|
||||
BlockWrenchEventHandler.wrenableBlocks.add(this);
|
||||
|
@ -88,18 +88,18 @@ public class BlockAlarm extends BaseTileBlock {
|
|||
}
|
||||
|
||||
public static void setFacing(EnumFacing facing, World world, BlockPos pos) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(FACING, facing));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(FACING, facing));
|
||||
}
|
||||
|
||||
public static void setActive(boolean active, World world, BlockPos pos) {
|
||||
EnumFacing facing = world.getBlockState(pos).getValue(FACING);
|
||||
IBlockState state = world.getBlockState(pos).withProperty(ACTIVE, active).withProperty(FACING, facing);
|
||||
IBlockState state = world.getBlockState(pos).with(ACTIVE, active).with(FACING, facing);
|
||||
world.setBlockState(pos, state, 3);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected BlockStateContainer createBlockState() {
|
||||
FACING = PropertyDirection.create("facing");
|
||||
FACING = DirectionProperty.create("facing");
|
||||
ACTIVE = PropertyBool.create("active");
|
||||
return new BlockStateContainer(this, FACING, ACTIVE);
|
||||
}
|
||||
|
@ -141,7 +141,7 @@ public class BlockAlarm extends BaseTileBlock {
|
|||
public IBlockState getStateFromMeta(int meta) {
|
||||
Boolean active = (meta & 8) == 8;
|
||||
EnumFacing facing = EnumFacing.byIndex(meta & 7);
|
||||
return this.getDefaultState().withProperty(FACING, facing).withProperty(ACTIVE, active);
|
||||
return this.getDefaultState().with(FACING, facing).with(ACTIVE, active);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
|
@ -153,7 +153,7 @@ public class BlockAlarm extends BaseTileBlock {
|
|||
@Override
|
||||
public IBlockState getStateForPlacement(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY,
|
||||
float hitZ, int meta, EntityLivingBase placer, EnumHand hand) {
|
||||
return this.getDefaultState().withProperty(FACING, facing);
|
||||
return this.getDefaultState().with(FACING, facing);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -39,8 +39,8 @@ import net.minecraft.util.math.AxisAlignedBB;
|
|||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import techreborn.TechReborn;
|
||||
import techreborn.tiles.TileEntityFlare;
|
||||
import java.util.List;
|
||||
|
@ -58,7 +58,7 @@ public class BlockFlare extends BlockContainer {
|
|||
super(Material.REDSTONE_LIGHT);
|
||||
setCreativeTab(TechReborn.TAB);
|
||||
setTranslationKey("techreborn.flare");
|
||||
this.setDefaultState(this.blockState.getBaseState().withProperty(COLOR, EnumDyeColor.WHITE));
|
||||
this.setDefaultState(this.blockState.getBaseState().with(COLOR, EnumDyeColor.WHITE));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -74,7 +74,7 @@ public class BlockFlare extends BlockContainer {
|
|||
return (state.getValue(COLOR)).getMetadata();
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public void getSubBlocks(Item itemIn, CreativeTabs tab, List<ItemStack> list) {
|
||||
for (EnumDyeColor enumdyecolor : EnumDyeColor.values()) {
|
||||
list.add(new ItemStack(itemIn, 1, enumdyecolor.getMetadata()));
|
||||
|
@ -83,7 +83,7 @@ public class BlockFlare extends BlockContainer {
|
|||
|
||||
@Override
|
||||
public IBlockState getStateFromMeta(int meta) {
|
||||
return this.getDefaultState().withProperty(COLOR, EnumDyeColor.byMetadata(meta));
|
||||
return this.getDefaultState().with(COLOR, EnumDyeColor.byMetadata(meta));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -102,7 +102,7 @@ public class BlockFlare extends BlockContainer {
|
|||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public BlockRenderLayer getRenderLayer() {
|
||||
return BlockRenderLayer.CUTOUT;
|
||||
}
|
||||
|
|
|
@ -54,7 +54,7 @@ public class BlockNuke extends BaseBlock {
|
|||
|
||||
public BlockNuke() {
|
||||
super(Material.TNT);
|
||||
this.setDefaultState(this.blockState.getBaseState().withProperty(OVERLAY, false));
|
||||
this.setDefaultState(this.blockState.getBaseState().with(OVERLAY, false));
|
||||
RebornModelRegistry.registerModel(new ModelCompound(TechReborn.MOD_ID, this));
|
||||
}
|
||||
|
||||
|
@ -123,7 +123,7 @@ public class BlockNuke extends BaseBlock {
|
|||
|
||||
@Override
|
||||
public IBlockState getStateFromMeta(int meta) {
|
||||
return this.getDefaultState().withProperty(OVERLAY, (meta & 1) > 0);
|
||||
return this.getDefaultState().with(OVERLAY, (meta & 1) > 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -29,8 +29,8 @@ import net.minecraft.block.SoundType;
|
|||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.util.BlockRenderLayer;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.client.models.ModelCompound;
|
||||
import reborncore.client.models.RebornModelRegistry;
|
||||
import techreborn.TechReborn;
|
||||
|
@ -57,7 +57,7 @@ public class BlockReinforcedGlass extends BlockGlass {
|
|||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public BlockRenderLayer getRenderLayer() {
|
||||
return BlockRenderLayer.CUTOUT;
|
||||
}
|
||||
|
|
|
@ -36,8 +36,8 @@ import net.minecraft.util.BlockRenderLayer;
|
|||
import net.minecraft.util.EnumFacing;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.client.models.ModelCompound;
|
||||
import reborncore.client.models.RebornModelRegistry;
|
||||
import techreborn.TechReborn;
|
||||
|
@ -49,8 +49,8 @@ public class BlockRubberLeaves extends BlockLeaves {
|
|||
|
||||
public BlockRubberLeaves() {
|
||||
super();
|
||||
this.setDefaultState(this.getDefaultState().withProperty(CHECK_DECAY, true)
|
||||
.withProperty(DECAYABLE, true));
|
||||
this.setDefaultState(this.getDefaultState().with(CHECK_DECAY, true)
|
||||
.with(DECAYABLE, true));
|
||||
Blocks.FIRE.setFireInfo(this, 30, 60);
|
||||
RebornModelRegistry.registerModel(new ModelCompound(TechReborn.MOD_ID, this, CHECK_DECAY, DECAYABLE));
|
||||
}
|
||||
|
@ -90,8 +90,8 @@ public class BlockRubberLeaves extends BlockLeaves {
|
|||
|
||||
@Override
|
||||
public IBlockState getStateFromMeta(int meta) {
|
||||
return this.getDefaultState().withProperty(DECAYABLE, (meta & 1) == 0)
|
||||
.withProperty(CHECK_DECAY, (meta & 2) > 0);
|
||||
return this.getDefaultState().with(DECAYABLE, (meta & 1) == 0)
|
||||
.with(CHECK_DECAY, (meta & 2) > 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -106,17 +106,17 @@ public class BlockRubberLeaves extends BlockLeaves {
|
|||
return meta;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public int getBlockColor() {
|
||||
return 16777215;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public int getRenderColor(IBlockState state) {
|
||||
return 16777215;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public int colorMultiplier(IBlockAccess worldIn, BlockPos pos, int renderPass) {
|
||||
return 16777215;
|
||||
}
|
||||
|
|
|
@ -28,7 +28,7 @@ import net.minecraft.block.Block;
|
|||
import net.minecraft.block.SoundType;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.block.properties.PropertyBool;
|
||||
import net.minecraft.block.properties.PropertyDirection;
|
||||
import net.minecraft.state.DirectionProperty;
|
||||
import net.minecraft.block.state.BlockStateContainer;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
|
@ -63,14 +63,14 @@ import java.util.Random;
|
|||
*/
|
||||
public class BlockRubberLog extends Block {
|
||||
|
||||
public static PropertyDirection SAP_SIDE = PropertyDirection.create("sapside", EnumFacing.Plane.HORIZONTAL);
|
||||
public static DirectionProperty SAP_SIDE = DirectionProperty.create("sapside", EnumFacing.Plane.HORIZONTAL);
|
||||
public static PropertyBool HAS_SAP = PropertyBool.create("hassap");
|
||||
|
||||
public BlockRubberLog() {
|
||||
super(Material.WOOD);
|
||||
this.setHardness(2.0F);
|
||||
this.setDefaultState(
|
||||
this.getDefaultState().withProperty(SAP_SIDE, EnumFacing.NORTH).withProperty(HAS_SAP, false));
|
||||
this.getDefaultState().with(SAP_SIDE, EnumFacing.NORTH).with(HAS_SAP, false));
|
||||
this.setTickRandomly(true);
|
||||
this.setSoundType(SoundType.WOOD);
|
||||
Blocks.FIRE.setFireInfo(this, 5, 5);
|
||||
|
@ -91,7 +91,7 @@ public class BlockRubberLog extends Block {
|
|||
tempMeta -= 3;
|
||||
}
|
||||
EnumFacing facing = EnumFacing.byHorizontalIndex(tempMeta);
|
||||
return this.getDefaultState().withProperty(SAP_SIDE, facing).withProperty(HAS_SAP, hasSap);
|
||||
return this.getDefaultState().with(SAP_SIDE, facing).with(HAS_SAP, hasSap);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -155,7 +155,7 @@ public class BlockRubberLog extends Block {
|
|||
EnumFacing facing = EnumFacing.byHorizontalIndex(rand.nextInt(4));
|
||||
if (worldIn.getBlockState(pos.down()).getBlock() == this
|
||||
&& worldIn.getBlockState(pos.up()).getBlock() == this) {
|
||||
worldIn.setBlockState(pos, state.withProperty(HAS_SAP, true).withProperty(SAP_SIDE, facing));
|
||||
worldIn.setBlockState(pos, state.with(HAS_SAP, true).with(SAP_SIDE, facing));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -176,7 +176,7 @@ public class BlockRubberLog extends Block {
|
|||
if ((capEnergy != null && capEnergy.getEnergyStored() > 20) || stack.getItem() instanceof ItemTreeTap) {
|
||||
if (state.getValue(HAS_SAP) && state.getValue(SAP_SIDE) == side) {
|
||||
worldIn.setBlockState(pos,
|
||||
state.withProperty(HAS_SAP, false).withProperty(SAP_SIDE, EnumFacing.byHorizontalIndex(0)));
|
||||
state.with(HAS_SAP, false).with(SAP_SIDE, EnumFacing.byHorizontalIndex(0)));
|
||||
worldIn.playSound(null, pos.getX(), pos.getY(), pos.getZ(), ModSounds.SAP_EXTRACT, SoundCategory.BLOCKS,
|
||||
0.6F, 1F);
|
||||
if (!worldIn.isRemote) {
|
||||
|
|
|
@ -55,14 +55,14 @@ public abstract class BlockRubberPlankSlab extends BlockSlab {
|
|||
this.name = name;
|
||||
IBlockState iblockstate = this.blockState.getBaseState();
|
||||
if (!this.isDouble()) {
|
||||
iblockstate = iblockstate.withProperty(HALF, EnumBlockHalf.BOTTOM);
|
||||
iblockstate = iblockstate.with(HALF, EnumBlockHalf.BOTTOM);
|
||||
halfslab = this;
|
||||
}
|
||||
setHarvestLevel("axe", 0);
|
||||
setHardness(2.0F);
|
||||
setResistance(15);
|
||||
setSoundType(SoundType.WOOD);
|
||||
this.setDefaultState(iblockstate.withProperty(VARIANT, BlockRubberPlankSlab.Variant.DEFAULT));
|
||||
this.setDefaultState(iblockstate.with(VARIANT, BlockRubberPlankSlab.Variant.DEFAULT));
|
||||
useNeighborBrightness = true;
|
||||
RebornModelRegistry.registerModel(new ModelCompound(TechReborn.MOD_ID, this));
|
||||
}
|
||||
|
@ -84,10 +84,10 @@ public abstract class BlockRubberPlankSlab extends BlockSlab {
|
|||
|
||||
@Override
|
||||
public IBlockState getStateFromMeta(int meta) {
|
||||
IBlockState iblockstate = this.getDefaultState().withProperty(VARIANT, BlockRubberPlankSlab.Variant.DEFAULT);
|
||||
IBlockState iblockstate = this.getDefaultState().with(VARIANT, BlockRubberPlankSlab.Variant.DEFAULT);
|
||||
|
||||
if (!this.isDouble()) {
|
||||
iblockstate = iblockstate.withProperty(HALF, (meta & 8) == 0 ? EnumBlockHalf.BOTTOM : EnumBlockHalf.TOP);
|
||||
iblockstate = iblockstate.with(HALF, (meta & 8) == 0 ? EnumBlockHalf.BOTTOM : EnumBlockHalf.TOP);
|
||||
}
|
||||
|
||||
return iblockstate;
|
||||
|
|
|
@ -42,7 +42,7 @@ import java.util.Random;
|
|||
public class BlockRubberSapling extends BlockSapling {
|
||||
|
||||
public BlockRubberSapling() {
|
||||
this.setDefaultState(this.getDefaultState().withProperty(STAGE, 0));
|
||||
this.setDefaultState(this.getDefaultState().with(STAGE, 0));
|
||||
setSoundType(SoundType.PLANT);
|
||||
}
|
||||
|
||||
|
|
|
@ -64,7 +64,7 @@ public class BlockStorage extends BaseBlock {
|
|||
// if (meta > types.length) {
|
||||
// meta = 0;
|
||||
// }
|
||||
// return getBlockState().getBaseState().withProperty(TYPE, typesList.get(meta));
|
||||
// return getBlockState().getBaseState().with(TYPE, typesList.get(meta));
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
|
|
|
@ -85,7 +85,7 @@ public class BlockCable extends BlockContainer {
|
|||
this.type = type;
|
||||
setHardness(1F);
|
||||
setResistance(8F);
|
||||
setDefaultState(getDefaultState().withProperty(EAST, false).withProperty(WEST, false).withProperty(NORTH, false).withProperty(SOUTH, false).withProperty(UP, false).withProperty(DOWN, false));
|
||||
setDefaultState(getDefaultState().with(EAST, false).with(WEST, false).with(NORTH, false).with(SOUTH, false).with(UP, false).with(DOWN, false));
|
||||
BlockWrenchEventHandler.wrenableBlocks.add(this);
|
||||
}
|
||||
|
||||
|
@ -226,7 +226,7 @@ public class BlockCable extends BlockContainer {
|
|||
for (EnumFacing facing : EnumFacing.values()) {
|
||||
TileEntity tileEntity = getTileEntitySafely(worldIn, pos.offset(facing));
|
||||
if (tileEntity != null) {
|
||||
actualState = actualState.withProperty(getProperty(facing), tileEntity.hasCapability(CapabilityEnergy.ENERGY, facing.getOpposite()));
|
||||
actualState = actualState.with(getProperty(facing), tileEntity.hasCapability(CapabilityEnergy.ENERGY, facing.getOpposite()));
|
||||
}
|
||||
}
|
||||
return actualState;
|
||||
|
|
|
@ -37,8 +37,8 @@ import net.minecraft.util.EnumHand;
|
|||
import net.minecraft.util.SoundCategory;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.api.ToolManager;
|
||||
import reborncore.client.models.ModelCompound;
|
||||
import reborncore.client.models.RebornModelRegistry;
|
||||
|
@ -78,7 +78,7 @@ public class BlockFusionCoil extends Block {
|
|||
return false;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void addInformation(ItemStack stack, @Nullable World player, List<String> tooltip, ITooltipFlag advanced) {
|
||||
super.addInformation(stack, player, tooltip, advanced);
|
||||
|
|
|
@ -26,7 +26,7 @@ package techreborn.blocks.lighting;
|
|||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.block.properties.PropertyBool;
|
||||
import net.minecraft.block.properties.PropertyDirection;
|
||||
import net.minecraft.state.DirectionProperty;
|
||||
import net.minecraft.block.state.BlockFaceShape;
|
||||
import net.minecraft.block.state.BlockStateContainer;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
|
@ -52,7 +52,7 @@ import techreborn.tiles.lighting.TileLamp;
|
|||
|
||||
public class BlockLamp extends BaseTileBlock {
|
||||
|
||||
public static PropertyDirection FACING;
|
||||
public static DirectionProperty FACING;
|
||||
public static PropertyBool ACTIVE;
|
||||
private AxisAlignedBB[] bbs;
|
||||
|
||||
|
@ -61,7 +61,7 @@ public class BlockLamp extends BaseTileBlock {
|
|||
|
||||
public BlockLamp(int brightness, int cost, double depth, double width) {
|
||||
super(Material.REDSTONE_LIGHT);
|
||||
this.setDefaultState(this.blockState.getBaseState().withProperty(FACING, EnumFacing.NORTH).withProperty(ACTIVE, false));
|
||||
this.setDefaultState(this.blockState.getBaseState().with(FACING, EnumFacing.NORTH).with(ACTIVE, false));
|
||||
this.bbs = GenBoundingBoxes(depth, width);
|
||||
this.cost = cost;
|
||||
this.brightness = brightness;
|
||||
|
@ -93,12 +93,12 @@ public class BlockLamp extends BaseTileBlock {
|
|||
}
|
||||
|
||||
public static void setFacing(EnumFacing facing, World world, BlockPos pos) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(FACING, facing));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(FACING, facing));
|
||||
}
|
||||
|
||||
public static void setActive(Boolean active, World world, BlockPos pos) {
|
||||
EnumFacing facing = (EnumFacing)world.getBlockState(pos).getValue(FACING);
|
||||
IBlockState state = world.getBlockState(pos).withProperty(ACTIVE, active).withProperty(FACING, facing);
|
||||
IBlockState state = world.getBlockState(pos).with(ACTIVE, active).with(FACING, facing);
|
||||
world.setBlockState(pos, state, 3);
|
||||
}
|
||||
|
||||
|
@ -115,7 +115,7 @@ public class BlockLamp extends BaseTileBlock {
|
|||
// Block
|
||||
@Override
|
||||
protected BlockStateContainer createBlockState() {
|
||||
FACING = PropertyDirection.create("facing");
|
||||
FACING = DirectionProperty.create("facing");
|
||||
ACTIVE = PropertyBool.create("active");
|
||||
return new BlockStateContainer(this, FACING, ACTIVE);
|
||||
}
|
||||
|
@ -123,7 +123,7 @@ public class BlockLamp extends BaseTileBlock {
|
|||
@Override
|
||||
public IBlockState getStateForPlacement(World world, BlockPos pos, EnumFacing facing, float hitX, float hitY,
|
||||
float hitZ, int meta, EntityLivingBase placer, EnumHand hand) {
|
||||
return this.getDefaultState().withProperty(FACING, facing);
|
||||
return this.getDefaultState().with(FACING, facing);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -196,6 +196,6 @@ public class BlockLamp extends BaseTileBlock {
|
|||
public IBlockState getStateFromMeta(int meta) {
|
||||
Boolean active = (meta&8)==8;
|
||||
EnumFacing facing = EnumFacing.byIndex(meta&7);
|
||||
return this.getDefaultState().withProperty(FACING, facing).withProperty(ACTIVE, active);
|
||||
return this.getDefaultState().with(FACING, facing).with(ACTIVE, active);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,12 +28,12 @@ import com.google.common.base.Predicate;
|
|||
import com.google.common.collect.Iterators;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.block.properties.PropertyDirection;
|
||||
import net.minecraft.block.state.BlockStateContainer;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.state.DirectionProperty;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.EnumFacing;
|
||||
import net.minecraft.util.EnumHand;
|
||||
|
@ -53,14 +53,14 @@ import java.util.Random;
|
|||
* Created by Rushmead
|
||||
*/
|
||||
public abstract class BlockEnergyStorage extends BaseTileBlock {
|
||||
public static PropertyDirection FACING = PropertyDirection.create("facing", Facings.ALL);
|
||||
public static DirectionProperty FACING = DirectionProperty.create("facing", Facings.ALL);
|
||||
public String name;
|
||||
public int guiID;
|
||||
|
||||
public BlockEnergyStorage(String name, int guiID) {
|
||||
super(Material.IRON);
|
||||
setHardness(2f);
|
||||
this.setDefaultState(this.blockState.getBaseState().withProperty(FACING, EnumFacing.NORTH));
|
||||
this.setDefaultState(this.blockState.getBaseState().with(FACING, EnumFacing.NORTH));
|
||||
this.name = name;
|
||||
this.guiID = guiID;
|
||||
RebornModelRegistry.registerModel(new ModelCompound(TechReborn.MOD_ID, this, "machines/energy"));
|
||||
|
@ -68,7 +68,7 @@ public abstract class BlockEnergyStorage extends BaseTileBlock {
|
|||
}
|
||||
|
||||
public void setFacing(EnumFacing facing, World world, BlockPos pos) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(FACING, facing));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(FACING, facing));
|
||||
}
|
||||
|
||||
public EnumFacing getSideFromint(int i) {
|
||||
|
@ -143,7 +143,7 @@ public abstract class BlockEnergyStorage extends BaseTileBlock {
|
|||
} else {
|
||||
facing = side.getOpposite();
|
||||
}
|
||||
world.setBlockState(pos, state.withProperty(BlockEnergyStorage.FACING, facing));
|
||||
world.setBlockState(pos, state.with(BlockEnergyStorage.FACING, facing));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -177,7 +177,7 @@ public abstract class BlockEnergyStorage extends BaseTileBlock {
|
|||
|
||||
@Override
|
||||
protected BlockStateContainer createBlockState() {
|
||||
FACING = PropertyDirection.create("facing", Facings.ALL);
|
||||
FACING = DirectionProperty.create("facing", Facings.ALL);
|
||||
return new BlockStateContainer(this, FACING);
|
||||
}
|
||||
|
||||
|
@ -203,7 +203,7 @@ public abstract class BlockEnergyStorage extends BaseTileBlock {
|
|||
@Override
|
||||
public IBlockState getStateFromMeta(int meta) {
|
||||
EnumFacing facing = getSideFromint(meta);
|
||||
return this.getDefaultState().withProperty(FACING, facing);
|
||||
return this.getDefaultState().with(FACING, facing);
|
||||
}
|
||||
|
||||
public enum Facings implements Predicate<EnumFacing>, Iterable<EnumFacing> {
|
||||
|
|
|
@ -32,8 +32,8 @@ import net.minecraft.util.EnumParticleTypes;
|
|||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.api.tile.IMachineGuiHandler;
|
||||
import reborncore.client.models.ModelCompound;
|
||||
import reborncore.client.models.RebornModelRegistry;
|
||||
|
@ -52,7 +52,7 @@ public class BlockIronFurnace extends BlockMachineBase {
|
|||
RebornModelRegistry.registerModel(new ModelCompound(TechReborn.MOD_ID, this, "machines/tier0_machines"));
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@SuppressWarnings("incomplete-switch")
|
||||
public void randomDisplayTick(final World worldIn, final BlockPos pos, final IBlockState state, final Random rand) {
|
||||
if (this.isActive(state)) {
|
||||
|
|
|
@ -44,8 +44,8 @@ import net.minecraft.util.text.TextComponentString;
|
|||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.api.IToolDrop;
|
||||
import reborncore.api.ToolManager;
|
||||
import reborncore.api.tile.IMachineGuiHandler;
|
||||
|
@ -132,7 +132,7 @@ public class BlockPlayerDetector extends BlockMachineBase {
|
|||
} else if (type.equals("you")) {
|
||||
newType = "all";
|
||||
}
|
||||
worldIn.setBlockState(pos, state.withProperty(TYPE, newType));
|
||||
worldIn.setBlockState(pos, state.with(TYPE, newType));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -156,7 +156,7 @@ public class BlockPlayerDetector extends BlockMachineBase {
|
|||
if (meta > types.length) {
|
||||
meta = 0;
|
||||
}
|
||||
return getBlockState().getBaseState().withProperty(TYPE, typeNamesList.get(meta));
|
||||
return getBlockState().getBaseState().with(TYPE, typeNamesList.get(meta));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -181,7 +181,7 @@ public class BlockPlayerDetector extends BlockMachineBase {
|
|||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public void getSubBlocks(CreativeTabs creativeTabs, NonNullList<ItemStack> list) {
|
||||
for (int meta = 0; meta < types.length; meta++) {
|
||||
list.add(new ItemStack(this, 1, meta));
|
||||
|
|
|
@ -28,7 +28,7 @@ import com.google.common.base.Predicate;
|
|||
import com.google.common.collect.Iterators;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.block.properties.PropertyDirection;
|
||||
import net.minecraft.state.DirectionProperty;
|
||||
import net.minecraft.block.state.BlockStateContainer;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.entity.EntityLivingBase;
|
||||
|
@ -53,20 +53,20 @@ import java.util.Random;
|
|||
* Created by Rushmead
|
||||
*/
|
||||
public abstract class BlockTransformer extends BaseTileBlock {
|
||||
public static PropertyDirection FACING = PropertyDirection.create("facing", Facings.ALL);
|
||||
public static DirectionProperty FACING = DirectionProperty.create("facing", Facings.ALL);
|
||||
public String name;
|
||||
|
||||
public BlockTransformer(String name) {
|
||||
super(Material.IRON);
|
||||
setHardness(2f);
|
||||
this.setDefaultState(this.blockState.getBaseState().withProperty(FACING, EnumFacing.NORTH));
|
||||
this.setDefaultState(this.blockState.getBaseState().with(FACING, EnumFacing.NORTH));
|
||||
this.name = name;
|
||||
RebornModelRegistry.registerModel(new ModelCompound(TechReborn.MOD_ID, this, "machines/energy"));
|
||||
BlockWrenchEventHandler.wrenableBlocks.add(this);
|
||||
}
|
||||
|
||||
public void setFacing(EnumFacing facing, World world, BlockPos pos) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(FACING, facing));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(FACING, facing));
|
||||
}
|
||||
|
||||
public EnumFacing getFacing(IBlockState state) {
|
||||
|
@ -125,14 +125,14 @@ public abstract class BlockTransformer extends BaseTileBlock {
|
|||
enumfacing = EnumFacing.WEST;
|
||||
}
|
||||
|
||||
worldIn.setBlockState(pos, state.withProperty(FACING, enumfacing), 2);
|
||||
worldIn.setBlockState(pos, state.with(FACING, enumfacing), 2);
|
||||
}
|
||||
}
|
||||
|
||||
// Block
|
||||
@Override
|
||||
protected BlockStateContainer createBlockState() {
|
||||
FACING = PropertyDirection.create("facing", Facings.ALL);
|
||||
FACING = DirectionProperty.create("facing", Facings.ALL);
|
||||
return new BlockStateContainer(this, FACING);
|
||||
}
|
||||
|
||||
|
@ -186,7 +186,7 @@ public abstract class BlockTransformer extends BaseTileBlock {
|
|||
} else {
|
||||
facing = side.getOpposite();
|
||||
}
|
||||
world.setBlockState(pos, state.withProperty(BlockTransformer.FACING, facing));
|
||||
world.setBlockState(pos, state.with(BlockTransformer.FACING, facing));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -202,7 +202,7 @@ public abstract class BlockTransformer extends BaseTileBlock {
|
|||
@Override
|
||||
public IBlockState getStateFromMeta(int meta) {
|
||||
EnumFacing facing = getSideFromint(meta);
|
||||
return this.getDefaultState().withProperty(FACING, facing);
|
||||
return this.getDefaultState().with(FACING, facing);
|
||||
}
|
||||
|
||||
public enum Facings implements Predicate<EnumFacing>, Iterable<EnumFacing> {
|
||||
|
|
|
@ -28,7 +28,7 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||
import net.minecraft.inventory.EntityEquipmentSlot;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraftforge.client.event.RenderPlayerEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import techreborn.init.TRContent;
|
||||
|
||||
public class ClientEventHandler {
|
||||
|
|
|
@ -73,10 +73,10 @@ public class GuiAESU extends GuiBase {
|
|||
|
||||
builder.drawMultiEnergyBar(this, 81, 28, (int) tile.getEnergy(), (int) tile.getMaxPower(), mouseX, mouseY, 0, layer);
|
||||
|
||||
buttonList.add(new GuiButtonUpDown(300, 121, 79, this, layer));
|
||||
buttonList.add(new GuiButtonUpDown(301, 121 + 12, 79, this, layer));
|
||||
buttonList.add(new GuiButtonUpDown(302, 121 + 24, 79, this, layer));
|
||||
buttonList.add(new GuiButtonUpDown(303, 121 + 36, 79, this, layer));
|
||||
buttons.add(new GuiButtonUpDown(300, 121, 79, this, layer));
|
||||
buttons.add(new GuiButtonUpDown(301, 121 + 12, 79, this, layer));
|
||||
buttons.add(new GuiButtonUpDown(302, 121 + 24, 79, this, layer));
|
||||
buttons.add(new GuiButtonUpDown(303, 121 + 36, 79, this, layer));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -72,8 +72,8 @@ public class GuiAlloyFurnace extends GuiContainer {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float partialTicks) {
|
||||
super.drawScreen(mouseX, mouseY, partialTicks);
|
||||
public void render(int mouseX, int mouseY, float partialTicks) {
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
this.renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -62,7 +62,7 @@ public class GuiAutoCrafting extends GuiBase {
|
|||
GlStateManager.blendFunc(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA);
|
||||
RenderHelper.enableGUIStandardItemLighting();
|
||||
|
||||
RenderItem itemRenderer = Minecraft.getMinecraft().getRenderItem();
|
||||
RenderItem itemRenderer = Minecraft.getInstance().getRenderItem();
|
||||
itemRenderer.renderItemAndEffectIntoGUI(stack, x, y);
|
||||
|
||||
GlStateManager.disableLighting();
|
||||
|
|
|
@ -30,6 +30,7 @@ import net.minecraft.client.renderer.GlStateManager;
|
|||
import net.minecraft.client.resources.I18n;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import reborncore.client.gui.builder.widget.GuiButtonSimple;
|
||||
import techreborn.tiles.TileChunkLoader;
|
||||
|
||||
public class GuiChunkLoader extends GuiContainer {
|
||||
|
@ -54,16 +55,16 @@ public class GuiChunkLoader extends GuiContainer {
|
|||
super.initGui();
|
||||
this.guiLeft = this.width / 2 - this.xSize / 2;
|
||||
this.guiTop = this.height / 2 - this.ySize / 2;
|
||||
this.plusOneButton = new GuiButton(0, this.guiLeft + 5, this.guiTop + 37, 40, 20, "+1");
|
||||
this.plusTenButton = new GuiButton(0, this.guiLeft + 45, this.guiTop + 37, 40, 20, "+10");
|
||||
this.plusOneButton = new GuiButtonSimple(0, this.guiLeft + 5, this.guiTop + 37, 40, 20, "+1");
|
||||
this.plusTenButton = new GuiButtonSimple(0, this.guiLeft + 45, this.guiTop + 37, 40, 20, "+10");
|
||||
|
||||
this.minusOneButton = new GuiButton(0, this.guiLeft + 90, this.guiTop + 37, 40, 20, "-1");
|
||||
this.minusTenButton = new GuiButton(0, this.guiLeft + 130, this.guiTop + 37, 40, 20, "-10");
|
||||
this.minusOneButton = new GuiButtonSimple(0, this.guiLeft + 90, this.guiTop + 37, 40, 20, "-1");
|
||||
this.minusTenButton = new GuiButtonSimple(0, this.guiLeft + 130, this.guiTop + 37, 40, 20, "-10");
|
||||
|
||||
this.buttonList.add(this.plusOneButton);
|
||||
this.buttonList.add(this.plusTenButton);
|
||||
this.buttonList.add(this.minusOneButton);
|
||||
this.buttonList.add(this.minusTenButton);
|
||||
this.buttons.add(this.plusOneButton);
|
||||
this.buttons.add(this.plusTenButton);
|
||||
this.buttons.add(this.minusOneButton);
|
||||
this.buttons.add(this.minusTenButton);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -86,8 +87,8 @@ public class GuiChunkLoader extends GuiContainer {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float partialTicks) {
|
||||
super.drawScreen(mouseX, mouseY, partialTicks);
|
||||
public void render(int mouseX, int mouseY, float partialTicks) {
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
this.renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
|
|
|
@ -46,7 +46,7 @@ public class GuiDestructoPack extends GuiContainer {
|
|||
protected void drawGuiContainerBackgroundLayer(float arg0, int arg1, int arg2) {
|
||||
this.drawDefaultBackground();
|
||||
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
Minecraft.getMinecraft().renderEngine.bindTexture(texture);
|
||||
Minecraft.getInstance().renderEngine.bindTexture(texture);
|
||||
drawTexturedModalRect(guiLeft, guiTop, 0, 0, 176, 166);
|
||||
}
|
||||
|
||||
|
@ -60,8 +60,8 @@ public class GuiDestructoPack extends GuiContainer {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float partialTicks) {
|
||||
super.drawScreen(mouseX, mouseY, partialTicks);
|
||||
public void render(int mouseX, int mouseY, float partialTicks) {
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
this.renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,13 +25,13 @@
|
|||
package techreborn.client.gui;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.client.gui.builder.GuiBase;
|
||||
import reborncore.client.gui.guibuilder.GuiBuilder;
|
||||
import techreborn.tiles.generator.advanced.TileDieselGenerator;
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public class GuiDieselGenerator extends GuiBase {
|
||||
|
||||
TileDieselGenerator tile;
|
||||
|
|
|
@ -104,10 +104,10 @@ public class GuiFusionReactor extends GuiBase {
|
|||
drawString("Size: " + tile.size, 83, 81, 0xFFFFFF, layer);
|
||||
drawString("" + tile.getPowerMultiplier() + "x", 10, 81, 0xFFFFFF, layer);
|
||||
|
||||
buttonList.add(new GuiButtonUpDown(300, 121, 79, this, GuiBase.Layer.FOREGROUND));
|
||||
buttonList.add(new GuiButtonUpDown(301, 121 + 12, 79, this, GuiBase.Layer.FOREGROUND));
|
||||
buttonList.add(new GuiButtonUpDown(302, 121 + 24, 79, this, GuiBase.Layer.FOREGROUND));
|
||||
buttonList.add(new GuiButtonUpDown(303, 121 + 36, 79, this, GuiBase.Layer.FOREGROUND));
|
||||
buttons.add(new GuiButtonUpDown(300, 121, 79, this, GuiBase.Layer.FOREGROUND));
|
||||
buttons.add(new GuiButtonUpDown(301, 121 + 12, 79, this, GuiBase.Layer.FOREGROUND));
|
||||
buttons.add(new GuiButtonUpDown(302, 121 + 24, 79, this, GuiBase.Layer.FOREGROUND));
|
||||
buttons.add(new GuiButtonUpDown(303, 121 + 36, 79, this, GuiBase.Layer.FOREGROUND));
|
||||
|
||||
builder.drawMultiEnergyBar(this, 9, 19, (int) this.tile.getEnergy(), (int) this.tile.getMaxPower(), mouseX, mouseY, 0, layer);
|
||||
}
|
||||
|
|
|
@ -80,8 +80,8 @@ public class GuiIronFurnace extends GuiBase {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float partialTicks) {
|
||||
super.drawScreen(mouseX, mouseY, partialTicks);
|
||||
public void render(int mouseX, int mouseY, float partialTicks) {
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
|
|
|
@ -57,12 +57,12 @@ public class GuiManual extends GuiScreen {
|
|||
|
||||
@Override
|
||||
public void initGui() {
|
||||
buttonList.add(new GuiButton(1, (width / 2 - 30), (height / 2 - (guiHeight / 4)) + 17, 60, 20, I18n.format("techreborn.manual.wikibtn")));
|
||||
buttonList.add(new GuiButton(2, (width / 2 - 30), (height / 2) + 22, 60, 20, I18n.format("techreborn.manual.discordbtn")));
|
||||
buttons.add(new GuiButton(1, (width / 2 - 30), (height / 2 - (guiHeight / 4)) + 17, 60, 20, I18n.format("techreborn.manual.wikibtn")));
|
||||
buttons.add(new GuiButton(2, (width / 2 - 30), (height / 2) + 22, 60, 20, I18n.format("techreborn.manual.discordbtn")));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float partialTicks) {
|
||||
public void render(int mouseX, int mouseY, float partialTicks) {
|
||||
drawDefaultBackground();
|
||||
mc.getTextureManager().bindTexture(GuiManual.texture);
|
||||
int centerX = (width / 2) - guiWidth / 2;
|
||||
|
@ -70,7 +70,7 @@ public class GuiManual extends GuiScreen {
|
|||
drawTexturedModalRect(centerX, centerY, 0, 0, guiWidth, guiHeight);
|
||||
fontRenderer.drawString(text1, ((width / 2) - fontRenderer.getStringWidth(text1) / 2), height / 2 - (guiHeight / 4), 4210752);
|
||||
fontRenderer.drawString(text2, ((width / 2) - fontRenderer.getStringWidth(text2) / 2), height / 2 + 5, 4210752);
|
||||
super.drawScreen(mouseX, mouseY, partialTicks);
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -25,8 +25,8 @@
|
|||
package techreborn.client.gui;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.client.gui.builder.GuiBase;
|
||||
import reborncore.client.gui.guibuilder.GuiBuilder;
|
||||
import techreborn.tiles.generator.TilePlasmaGenerator;
|
||||
|
@ -35,7 +35,7 @@ import techreborn.tiles.generator.TilePlasmaGenerator;
|
|||
* @author drcrazy
|
||||
*
|
||||
*/
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public class GuiPlasmaGenerator extends GuiBase {
|
||||
|
||||
/**
|
||||
|
|
|
@ -64,8 +64,8 @@ public class GuiQuantumTank extends GuiBase {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float partialTicks) {
|
||||
super.drawScreen(mouseX, mouseY, partialTicks);
|
||||
public void render(int mouseX, int mouseY, float partialTicks) {
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -37,13 +37,13 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.util.EnumFacing;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.client.model.*;
|
||||
import net.minecraftforge.common.model.IModelState;
|
||||
import net.minecraftforge.common.model.TRSRTransformation;
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import techreborn.init.TRContent;
|
||||
import techreborn.items.DynamicCell;
|
||||
|
||||
|
@ -55,7 +55,7 @@ import java.util.List;
|
|||
import java.util.Optional;
|
||||
import java.util.function.Function;
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public class ModelDynamicCell implements IModel {
|
||||
|
||||
public static final ModelDynamicCell MODEL = new ModelDynamicCell(
|
||||
|
@ -210,7 +210,7 @@ public class ModelDynamicCell implements IModel {
|
|||
private final HashMap<String, IBakedModel> modelCache = new HashMap<>();
|
||||
|
||||
private final Function<ResourceLocation, TextureAtlasSprite> textureGetter = location ->
|
||||
Minecraft.getMinecraft().getTextureMapBlocks().getAtlasSprite(location.toString());
|
||||
Minecraft.getInstance().getTextureMapBlocks().getAtlasSprite(location.toString());
|
||||
|
||||
private OverrideHandler() {
|
||||
super(ImmutableList.of());
|
||||
|
|
|
@ -30,8 +30,8 @@ import net.minecraft.client.renderer.block.model.ItemCameraTransforms;
|
|||
import net.minecraft.client.renderer.block.model.ModelBlock;
|
||||
import net.minecraft.client.resources.IResource;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import techreborn.TechReborn;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
|
@ -42,7 +42,7 @@ import java.io.Reader;
|
|||
/*
|
||||
* Credits to JsonDestroyer
|
||||
*/
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public class ModelHelper {
|
||||
|
||||
public static final ItemCameraTransforms DEFAULT_ITEM_TRANSFORMS = loadTransformFromJson(new ResourceLocation("minecraft:models/item/generated"));
|
||||
|
@ -61,7 +61,7 @@ public class ModelHelper {
|
|||
|
||||
public static Reader getReaderForResource(ResourceLocation location) throws IOException {
|
||||
ResourceLocation file = new ResourceLocation(location.getNamespace(), location.getPath() + ".json");
|
||||
IResource iresource = Minecraft.getMinecraft().getResourceManager().getResource(file);
|
||||
IResource iresource = Minecraft.getInstance().getResourceManager().getResource(file);
|
||||
return new BufferedReader(new InputStreamReader(iresource.getInputStream(), Charsets.UTF_8));
|
||||
}
|
||||
|
||||
|
|
|
@ -48,7 +48,7 @@ public class RenderNukePrimed extends Render<EntityNukePrimed> {
|
|||
|
||||
@Override
|
||||
public void doRender(EntityNukePrimed entity, double x, double y, double z, float entityYaw, float partialTicks) {
|
||||
BlockRendererDispatcher blockrendererdispatcher = Minecraft.getMinecraft().getBlockRendererDispatcher();
|
||||
BlockRendererDispatcher blockrendererdispatcher = Minecraft.getInstance().getBlockRendererDispatcher();
|
||||
GlStateManager.pushMatrix();
|
||||
GlStateManager.translate((float) x, (float) y + 0.5F, (float) z);
|
||||
if ((float) entity.getFuse() - partialTicks + 1.0F < 10.0F) {
|
||||
|
@ -72,7 +72,7 @@ public class RenderNukePrimed extends Render<EntityNukePrimed> {
|
|||
GlStateManager.doPolygonOffset(-3.0F, -3.0F);
|
||||
GlStateManager.enablePolygonOffset();
|
||||
blockrendererdispatcher.renderBlockBrightness(
|
||||
TRContent.NUKE.getDefaultState().withProperty(BlockNuke.OVERLAY, true), 1.0F);
|
||||
TRContent.NUKE.getDefaultState().with(BlockNuke.OVERLAY, true), 1.0F);
|
||||
GlStateManager.doPolygonOffset(0.0F, 0.0F);
|
||||
GlStateManager.disablePolygonOffset();
|
||||
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
|
|
|
@ -32,7 +32,7 @@ import net.minecraft.util.math.BlockPos;
|
|||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.event.entity.player.PlayerEvent;
|
||||
import net.minecraftforge.event.world.BlockEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import reborncore.common.registration.RebornRegister;
|
||||
import reborncore.common.registration.impl.ConfigRegistry;
|
||||
import reborncore.common.util.OreDrop;
|
||||
|
|
|
@ -38,12 +38,12 @@ import net.minecraft.client.renderer.block.statemap.StateMapperBase;
|
|||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.client.event.ModelRegistryEvent;
|
||||
import net.minecraftforge.client.model.ModelLoader;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import reborncore.client.models.ModelCompound;
|
||||
import reborncore.client.models.RebornModelRegistry;
|
||||
import techreborn.TechReborn;
|
||||
|
@ -69,7 +69,7 @@ import techreborn.init.TRContent.Upgrades;
|
|||
* @author drcrazy
|
||||
*
|
||||
*/
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Mod.EventBusSubscriber(modid = TechReborn.MOD_ID)
|
||||
public class ModelRegistryEventHandler {
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ import net.minecraftforge.common.MinecraftForge;
|
|||
import net.minecraftforge.event.RegistryEvent;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
import net.minecraftforge.fml.common.eventhandler.EventPriority;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import reborncore.RebornRegistry;
|
||||
import reborncore.common.blocks.BlockMachineBase;
|
||||
import reborncore.common.util.BucketHandler;
|
||||
|
|
|
@ -32,12 +32,10 @@ import net.minecraft.item.Item;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.energy.IEnergyStorage;
|
||||
import net.minecraftforge.event.entity.player.ItemTooltipEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import org.lwjgl.input.Keyboard;
|
||||
import reborncore.api.IListInfoProvider;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.RebornCoreConfig;
|
||||
|
@ -49,7 +47,7 @@ import techreborn.TechReborn;
|
|||
public class StackToolTipEvent {
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@SubscribeEvent
|
||||
public void handleItemTooltipEvent(ItemTooltipEvent event) {
|
||||
if (event.getEntityPlayer() == null) {
|
||||
|
@ -87,12 +85,12 @@ public class StackToolTipEvent {
|
|||
Block block = Block.getBlockFromItem(item);
|
||||
if (block != null && (block instanceof BlockContainer || block instanceof ITileEntityProvider)
|
||||
&& block.getRegistryName().getNamespace().contains("techreborn")) {
|
||||
TileEntity tile = block.createTileEntity(Minecraft.getMinecraft().world,
|
||||
TileEntity tile = block.createTileEntity(Minecraft.getInstance().world,
|
||||
block.getStateFromMeta(event.getItemStack().getItemDamage()));
|
||||
boolean hasData = false;
|
||||
if(event.getItemStack().hasTagCompound() && event.getItemStack().getTagCompound().hasKey("tile_data")){
|
||||
NBTTagCompound tileData = event.getItemStack().getTagCompound().getCompoundTag("tile_data");
|
||||
tile.readFromNBT(tileData);
|
||||
if(event.getItemStack().hasTag() && event.getItemStack().getTag().hasKey("tile_data")){
|
||||
NBTTagCompound tileData = event.getItemStack().getTag().getCompoundTag("tile_data");
|
||||
tile.read(tileData);
|
||||
hasData = true;
|
||||
event.getToolTip().add(TextFormatting.DARK_GREEN + "Block data contained");
|
||||
}
|
||||
|
|
|
@ -30,7 +30,7 @@ import net.minecraft.item.crafting.IRecipe;
|
|||
import net.minecraft.item.crafting.Ingredient;
|
||||
import net.minecraftforge.common.util.FakePlayer;
|
||||
import net.minecraftforge.event.entity.player.EntityItemPickupEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import net.minecraftforge.registries.IForgeRegistryEntry;
|
||||
import reborncore.common.util.ItemUtils;
|
||||
import techreborn.TechReborn;
|
||||
|
|
|
@ -29,7 +29,7 @@ import net.minecraft.init.MobEffects;
|
|||
import net.minecraft.inventory.EntityEquipmentSlot;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraftforge.fml.common.eventhandler.EventPriority;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import net.minecraftforge.fml.common.gameevent.TickEvent;
|
||||
import techreborn.init.TRContent;
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@ import net.minecraft.util.ResourceLocation;
|
|||
import net.minecraft.world.storage.loot.*;
|
||||
import net.minecraft.world.storage.loot.conditions.LootCondition;
|
||||
import net.minecraftforge.event.LootTableLoadEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import techreborn.TechReborn;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
|
||||
|
|
|
@ -68,12 +68,12 @@ public class DynamicCell extends Item {
|
|||
//Clearing tag because ItemUtils.isItemEqual doesn't handle tags ForgeCaps and display
|
||||
//And breaks ability to use in recipes
|
||||
//TODO: Property ItemUtils.isItemEquals tags equality handling?
|
||||
if (stack.hasTagCompound()) {
|
||||
NBTTagCompound tag = stack.getTagCompound();
|
||||
if (stack.hasTag()) {
|
||||
NBTTagCompound tag = stack.getTag();
|
||||
if (tag.getSize() != 1 || tag.hasKey("Fluid")) {
|
||||
NBTTagCompound clearTag = new NBTTagCompound();
|
||||
clearTag.setTag("Fluid", tag.getCompoundTag("Fluid"));
|
||||
stack.setTagCompound(clearTag);
|
||||
stack.setTag(clearTag);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -194,10 +194,10 @@ public class DynamicCell extends Item {
|
|||
super(container, capacity);
|
||||
|
||||
//backwards compatibility
|
||||
if (container.hasTagCompound() && container.getTagCompound().hasKey("FluidName")) {
|
||||
FluidStack stack = FluidStack.loadFluidStackFromNBT(container.getTagCompound());
|
||||
if (container.hasTag() && container.getTag().hasKey("FluidName")) {
|
||||
FluidStack stack = FluidStack.loadFluidStackFromNBT(container.getTag());
|
||||
if (stack != null) {
|
||||
container.setTagCompound(new NBTTagCompound());
|
||||
container.setTag(new NBTTagCompound());
|
||||
fill(stack, true);
|
||||
}
|
||||
}
|
||||
|
@ -231,7 +231,7 @@ public class DynamicCell extends Item {
|
|||
@Override
|
||||
public ItemStack getContainer() {
|
||||
ItemStack cell;
|
||||
if (container.hasTagCompound() && container.getTagCompound().hasKey(FLUID_NBT_KEY)) {
|
||||
if (container.hasTag() && container.getTag().hasKey(FLUID_NBT_KEY)) {
|
||||
cell = super.getContainer();
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -57,10 +57,10 @@ public class ItemCells {
|
|||
if(stack1.isEmpty() || stack2.isEmpty()){
|
||||
return false;
|
||||
}
|
||||
if(stack1.getTagCompound() == null || stack2.getTagCompound() == null){
|
||||
if(stack1.getTag() == null || stack2.getTag() == null){
|
||||
return false;
|
||||
}
|
||||
return stack1.getTagCompound().equals(stack2.getTagCompound());
|
||||
return stack1.getTag().equals(stack2.getTag());
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -37,9 +37,9 @@ import net.minecraft.util.math.BlockPos;
|
|||
import net.minecraft.util.text.TextComponentString;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.DimensionManager;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.client.hud.StackInfoElement;
|
||||
import reborncore.common.util.ChatUtils;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -54,13 +54,13 @@ public class ItemFrequencyTransmitter extends Item {
|
|||
setMaxStackSize(1);
|
||||
this.addPropertyOverride(new ResourceLocation("techreborn", "coords"), new IItemPropertyGetter() {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public float apply(ItemStack stack,
|
||||
@Nullable
|
||||
World worldIn,
|
||||
@Nullable
|
||||
EntityLivingBase entityIn) {
|
||||
if (!stack.isEmpty() && stack.hasTagCompound() && stack.getTagCompound() != null && stack.getTagCompound().hasKey("x") && stack.getTagCompound().hasKey("y") && stack.getTagCompound().hasKey("z") && stack.getTagCompound().hasKey("dim")) {
|
||||
if (!stack.isEmpty() && stack.hasTag() && stack.getTag() != null && stack.getTag().hasKey("x") && stack.getTag().hasKey("y") && stack.getTag().hasKey("z") && stack.getTag().hasKey("dim")) {
|
||||
return 1.0F;
|
||||
}
|
||||
return 0.0F;
|
||||
|
@ -72,11 +72,11 @@ public class ItemFrequencyTransmitter extends Item {
|
|||
public EnumActionResult onItemUse(EntityPlayer player, World world, BlockPos pos,
|
||||
EnumHand hand, EnumFacing facing, float hitX, float hitY, float hitZ) {
|
||||
ItemStack stack = player.getHeldItem(hand);
|
||||
stack.setTagCompound(new NBTTagCompound());
|
||||
stack.getTagCompound().setInteger("x", pos.getX());
|
||||
stack.getTagCompound().setInteger("y", pos.getY());
|
||||
stack.getTagCompound().setInteger("z", pos.getZ());
|
||||
stack.getTagCompound().setInteger("dim", world.provider.getDimension());
|
||||
stack.setTag(new NBTTagCompound());
|
||||
stack.getTag().setInt("x", pos.getX());
|
||||
stack.getTag().setInt("y", pos.getY());
|
||||
stack.getTag().setInt("z", pos.getZ());
|
||||
stack.getTag().setInt("dim", world.provider.getDimension());
|
||||
|
||||
if (!world.isRemote) {
|
||||
ChatUtils.sendNoSpamMessages(MessageIDs.freqTransmitterID, new TextComponentString(
|
||||
|
@ -98,7 +98,7 @@ public class ItemFrequencyTransmitter extends Item {
|
|||
EnumHand hand) {
|
||||
ItemStack stack = player.getHeldItem(hand);
|
||||
if (player.isSneaking()) {
|
||||
stack.setTagCompound(null);
|
||||
stack.setTag(null);
|
||||
if (!world.isRemote) {
|
||||
ChatUtils.sendNoSpamMessages(MessageIDs.freqTransmitterID, new TextComponentString(
|
||||
TextFormatting.GRAY + I18n.format("techreborn.message.coordsHaveBeen") + " "
|
||||
|
@ -109,16 +109,16 @@ public class ItemFrequencyTransmitter extends Item {
|
|||
return new ActionResult<>(EnumActionResult.SUCCESS, stack);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void addInformation(ItemStack stack,
|
||||
@Nullable
|
||||
World worldIn, List<String> tooltip, ITooltipFlag flagIn) {
|
||||
if (stack.hasTagCompound() && stack.getTagCompound() != null && stack.getTagCompound().hasKey("x") && stack.getTagCompound().hasKey("y") && stack.getTagCompound().hasKey("z") && stack.getTagCompound().hasKey("dim")) {
|
||||
int x = stack.getTagCompound().getInteger("x");
|
||||
int y = stack.getTagCompound().getInteger("y");
|
||||
int z = stack.getTagCompound().getInteger("z");
|
||||
int dim = stack.getTagCompound().getInteger("dim");
|
||||
if (stack.hasTag() && stack.getTag() != null && stack.getTag().hasKey("x") && stack.getTag().hasKey("y") && stack.getTag().hasKey("z") && stack.getTag().hasKey("dim")) {
|
||||
int x = stack.getTag().getInt("x");
|
||||
int y = stack.getTag().getInt("y");
|
||||
int z = stack.getTag().getInt("z");
|
||||
int dim = stack.getTag().getInt("dim");
|
||||
|
||||
tooltip.add(TextFormatting.GRAY + "X: " + TextFormatting.GOLD + x);
|
||||
tooltip.add(TextFormatting.GRAY + "Y: " + TextFormatting.GOLD + y);
|
||||
|
@ -141,11 +141,11 @@ public class ItemFrequencyTransmitter extends Item {
|
|||
TextFormatting gold = TextFormatting.GOLD;
|
||||
TextFormatting grey = TextFormatting.GRAY;
|
||||
if (stack.getItem() instanceof ItemFrequencyTransmitter) {
|
||||
if (stack.hasTagCompound() && stack.getTagCompound() != null && stack.getTagCompound().hasKey("x") && stack.getTagCompound().hasKey("y") && stack.getTagCompound().hasKey("z") && stack.getTagCompound().hasKey("dim")) {
|
||||
int coordX = stack.getTagCompound().getInteger("x");
|
||||
int coordY = stack.getTagCompound().getInteger("y");
|
||||
int coordZ = stack.getTagCompound().getInteger("z");
|
||||
int coordDim = stack.getTagCompound().getInteger("dim");
|
||||
if (stack.hasTag() && stack.getTag() != null && stack.getTag().hasKey("x") && stack.getTag().hasKey("y") && stack.getTag().hasKey("z") && stack.getTag().hasKey("dim")) {
|
||||
int coordX = stack.getTag().getInt("x");
|
||||
int coordY = stack.getTag().getInt("y");
|
||||
int coordZ = stack.getTag().getInt("z");
|
||||
int coordDim = stack.getTag().getInt("dim");
|
||||
text = grey + "X: " + gold + coordX + grey + " Y: " + gold + coordY + grey + " Z: " + gold + coordZ + grey + " Dim: " + gold + DimensionManager.getProviderType(coordDim).getName() + " (" + coordDim + ")";
|
||||
} else {
|
||||
text = grey + I18n.format("techreborn.message.noCoordsSet");
|
||||
|
|
|
@ -33,10 +33,10 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.energy.IEnergyStorage;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
import reborncore.common.powerSystem.PoweredItemContainerProvider;
|
||||
|
@ -66,7 +66,7 @@ public class ItemCloakingDevice extends ItemTRArmour implements IEnergyItemInfo
|
|||
|
||||
// Item
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public String getArmorTexture(ItemStack stack, Entity entity, EntityEquipmentSlot slot, String type) {
|
||||
return "techreborn:" + "textures/models/cloaking.png";
|
||||
}
|
||||
|
@ -84,7 +84,7 @@ public class ItemCloakingDevice extends ItemTRArmour implements IEnergyItemInfo
|
|||
}
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -33,9 +33,9 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
import reborncore.common.powerSystem.PoweredItemContainerProvider;
|
||||
|
@ -58,7 +58,7 @@ public class ItemLapotronicOrbpack extends ItemArmor implements IEnergyItemInfo
|
|||
}
|
||||
|
||||
// Item
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
@ -101,7 +101,7 @@ public class ItemLapotronicOrbpack extends ItemArmor implements IEnergyItemInfo
|
|||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public String getArmorTexture(ItemStack stack, Entity entity, EntityEquipmentSlot slot, String type) {
|
||||
return "techreborn:" + "textures/models/lapotronpack.png";
|
||||
}
|
||||
|
|
|
@ -33,9 +33,9 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
|
@ -102,12 +102,12 @@ public class ItemLithiumIonBatpack extends ItemArmor implements IEnergyItemInfo
|
|||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public String getArmorTexture(ItemStack stack, Entity entity, EntityEquipmentSlot slot, String type) {
|
||||
return "techreborn:" + "textures/models/lithiumbatpack.png";
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -31,9 +31,9 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
import reborncore.common.powerSystem.PoweredItemContainerProvider;
|
||||
|
@ -55,7 +55,7 @@ public class ItemBattery extends Item implements IEnergyItemInfo {
|
|||
this.maxTransfer = maxTransfer;
|
||||
this.addPropertyOverride(new ResourceLocation("techreborn:empty"), new IItemPropertyGetter() {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public float apply(ItemStack stack, @Nullable World worldIn, @Nullable EntityLivingBase entityIn) {
|
||||
if (!stack.isEmpty() && new ForgePowerItemManager(stack).getEnergyStored() == 0) {
|
||||
return 1.0F;
|
||||
|
|
|
@ -27,8 +27,8 @@ package techreborn.items.battery;
|
|||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -40,7 +40,7 @@ public class ItemEnergyCrystal extends ItemBattery {
|
|||
super(ConfigTechReborn.EnergyCrystalMaxCharge, 1_000);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -27,8 +27,8 @@ package techreborn.items.battery;
|
|||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -40,7 +40,7 @@ public class ItemLapotronCrystal extends ItemBattery {
|
|||
super(ConfigTechReborn.LapotronCrystalMaxCharge, 10_000);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -27,8 +27,8 @@ package techreborn.items.battery;
|
|||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -40,7 +40,7 @@ public class ItemLapotronicOrb extends ItemBattery {
|
|||
super(ConfigTechReborn.LapotronicOrbMaxCharge, 100_000);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -27,8 +27,8 @@ package techreborn.items.battery;
|
|||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.init.TRContent;
|
||||
|
||||
|
@ -39,7 +39,7 @@ public class ItemLithiumIonBattery extends ItemBattery {
|
|||
super(400_000, 1_000);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -27,8 +27,8 @@ package techreborn.items.battery;
|
|||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.init.TRContent;
|
||||
|
||||
|
@ -39,7 +39,7 @@ public class ItemRedCellBattery extends ItemBattery {
|
|||
super(40_000, 100);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -36,9 +36,9 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
|
@ -66,7 +66,7 @@ public class ItemChainsaw extends ItemAxe implements IEnergyItemInfo {
|
|||
|
||||
this.addPropertyOverride(new ResourceLocation("techreborn", "animated"), new IItemPropertyGetter() {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public float apply(ItemStack stack, @Nullable World worldIn, @Nullable EntityLivingBase entityIn) {
|
||||
if (!stack.isEmpty() && new ForgePowerItemManager(stack).getEnergyStored() >= cost
|
||||
&& entityIn != null && entityIn.getHeldItemMainhand().equals(stack)) {
|
||||
|
|
|
@ -30,8 +30,8 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.util.EnumFacing;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.api.IToolHandler;
|
||||
|
||||
/**
|
||||
|
@ -44,7 +44,7 @@ public class ItemWrench extends Item implements IToolHandler {
|
|||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public boolean isFull3D() {
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -29,8 +29,8 @@ import net.minecraft.creativetab.CreativeTabs;
|
|||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -45,7 +45,7 @@ public class ItemAdvancedChainsaw extends ItemChainsaw {
|
|||
this.transferLimit = 1000;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -29,8 +29,8 @@ import net.minecraft.creativetab.CreativeTabs;
|
|||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -45,7 +45,7 @@ public class ItemAdvancedDrill extends ItemDrill {
|
|||
this.transferLimit = 1000;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -27,8 +27,8 @@ package techreborn.items.tool.advanced;
|
|||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -44,7 +44,7 @@ public class ItemAdvancedJackhammer extends ItemJackhammer {
|
|||
this.transferLimit = 1000;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -37,9 +37,9 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
|
@ -143,7 +143,7 @@ public class ItemRockCutter extends ItemPickaxe implements IEnergyItemInfo {
|
|||
return !(newStack.isItemEqual(oldStack));
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -29,8 +29,8 @@ import net.minecraft.creativetab.CreativeTabs;
|
|||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -43,7 +43,7 @@ public class ItemBasicChainsaw extends ItemChainsaw {
|
|||
this.cost = 50;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(
|
||||
CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
|
|
|
@ -29,8 +29,8 @@ import net.minecraft.creativetab.CreativeTabs;
|
|||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -43,7 +43,7 @@ public class ItemBasicDrill extends ItemDrill {
|
|||
this.cost = 50;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(
|
||||
CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
|
|
|
@ -27,8 +27,8 @@ package techreborn.items.tool.basic;
|
|||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -42,7 +42,7 @@ public class ItemBasicJackhammer extends ItemJackhammer {
|
|||
this.efficiency = 12F;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -36,9 +36,9 @@ import net.minecraft.util.EnumHand;
|
|||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
|
@ -99,7 +99,7 @@ public class ItemElectricTreetap extends Item implements IEnergyItemInfo {
|
|||
return new PoweredItemContainerProvider(stack);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -33,8 +33,8 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
|
@ -49,8 +49,8 @@ public class ItemIndustrialChainsaw extends ItemChainsaw {
|
|||
this.cost = 250;
|
||||
this.transferLimit = 1000;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -36,8 +36,8 @@ import net.minecraft.util.NonNullList;
|
|||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.util.math.RayTraceResult;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
|
@ -155,7 +155,7 @@ public class ItemIndustrialDrill extends ItemDrill {
|
|||
}
|
||||
|
||||
// Item
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
if (!isInCreativeTab(par2CreativeTabs)) {
|
||||
|
|
|
@ -27,8 +27,8 @@ package techreborn.items.tool.industrial;
|
|||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.powerSystem.forge.ForgePowerItemManager;
|
||||
import techreborn.config.ConfigTechReborn;
|
||||
import techreborn.init.TRContent;
|
||||
|
@ -44,7 +44,7 @@ public class ItemIndustrialJackhammer extends ItemJackhammer {
|
|||
this.transferLimit = 1000;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(
|
||||
CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
|
|
|
@ -43,9 +43,9 @@ import net.minecraft.util.*;
|
|||
import net.minecraft.util.text.TextComponentString;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
|
@ -72,7 +72,7 @@ public class ItemNanosaber extends ItemSword implements IEnergyItemInfo {
|
|||
setMaxStackSize(1);
|
||||
this.addPropertyOverride(new ResourceLocation("techreborn:active"), new IItemPropertyGetter() {
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public float apply(ItemStack stack,
|
||||
@Nullable
|
||||
World worldIn,
|
||||
|
@ -132,10 +132,10 @@ public class ItemNanosaber extends ItemSword implements IEnergyItemInfo {
|
|||
.format("techreborn.message.nanosaberActivate")));
|
||||
} else {
|
||||
if (!ItemUtils.isActive(stack)) {
|
||||
if (stack.getTagCompound() == null) {
|
||||
stack.setTagCompound(new NBTTagCompound());
|
||||
if (stack.getTag() == null) {
|
||||
stack.setTag(new NBTTagCompound());
|
||||
}
|
||||
stack.getTagCompound().setBoolean("isActive", true);
|
||||
stack.getTag().setBoolean("isActive", true);
|
||||
if (world.isRemote) {
|
||||
ChatUtils.sendNoSpamMessages(MessageIDs.nanosaberID, new TextComponentString(
|
||||
TextFormatting.GRAY + I18n.format("techreborn.message.setTo") + " "
|
||||
|
@ -143,7 +143,7 @@ public class ItemNanosaber extends ItemSword implements IEnergyItemInfo {
|
|||
.format("techreborn.message.nanosaberActive")));
|
||||
}
|
||||
} else {
|
||||
stack.getTagCompound().setBoolean("isActive", false);
|
||||
stack.getTag().setBoolean("isActive", false);
|
||||
if (world.isRemote) {
|
||||
ChatUtils.sendNoSpamMessages(MessageIDs.nanosaberID, new TextComponentString(
|
||||
TextFormatting.GRAY + I18n.format("techreborn.message.setTo") + " "
|
||||
|
@ -166,7 +166,7 @@ public class ItemNanosaber extends ItemSword implements IEnergyItemInfo {
|
|||
+ TextFormatting.GOLD + I18n
|
||||
.format("techreborn.message.nanosaberDeactivating")));
|
||||
}
|
||||
stack.getTagCompound().setBoolean("isActive", false);
|
||||
stack.getTag().setBoolean("isActive", false);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -198,7 +198,7 @@ public class ItemNanosaber extends ItemSword implements IEnergyItemInfo {
|
|||
return new PoweredItemContainerProvider(stack);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(
|
||||
CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
|
@ -206,18 +206,18 @@ public class ItemNanosaber extends ItemSword implements IEnergyItemInfo {
|
|||
return;
|
||||
}
|
||||
ItemStack inactiveUncharged = new ItemStack(this);
|
||||
inactiveUncharged.setTagCompound(new NBTTagCompound());
|
||||
inactiveUncharged.getTagCompound().setBoolean("isActive", false);
|
||||
inactiveUncharged.setTag(new NBTTagCompound());
|
||||
inactiveUncharged.getTag().setBoolean("isActive", false);
|
||||
|
||||
ItemStack inactiveCharged = new ItemStack(TRContent.NANOSABER);
|
||||
inactiveCharged.setTagCompound(new NBTTagCompound());
|
||||
inactiveCharged.getTagCompound().setBoolean("isActive", false);
|
||||
inactiveCharged.setTag(new NBTTagCompound());
|
||||
inactiveCharged.getTag().setBoolean("isActive", false);
|
||||
ForgePowerItemManager capEnergy = new ForgePowerItemManager(inactiveCharged);
|
||||
capEnergy.setEnergyStored(capEnergy.getMaxEnergyStored());
|
||||
|
||||
ItemStack activeCharged = new ItemStack(TRContent.NANOSABER);
|
||||
activeCharged.setTagCompound(new NBTTagCompound());
|
||||
activeCharged.getTagCompound().setBoolean("isActive", true);
|
||||
activeCharged.setTag(new NBTTagCompound());
|
||||
activeCharged.getTag().setBoolean("isActive", true);
|
||||
ForgePowerItemManager capEnergy2 = new ForgePowerItemManager(activeCharged);
|
||||
capEnergy2.setEnergyStored(capEnergy2.getMaxEnergyStored());
|
||||
|
||||
|
@ -226,7 +226,7 @@ public class ItemNanosaber extends ItemSword implements IEnergyItemInfo {
|
|||
itemList.add(activeCharged);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void addInformation(ItemStack stack,
|
||||
@Nullable
|
||||
|
|
|
@ -37,9 +37,9 @@ import net.minecraft.util.*;
|
|||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import reborncore.api.power.IEnergyItemInfo;
|
||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
|
@ -157,8 +157,8 @@ public class ItemOmniTool extends ItemPickaxe implements IEnergyItemInfo {
|
|||
public ICapabilityProvider initCapabilities(ItemStack stack, @Nullable NBTTagCompound nbt) {
|
||||
return new PoweredItemContainerProvider(stack);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@Override
|
||||
public void getSubItems(
|
||||
CreativeTabs par2CreativeTabs, NonNullList<ItemStack> itemList) {
|
||||
|
|
|
@ -26,8 +26,8 @@ package techreborn.items.tool.vanilla;
|
|||
|
||||
import net.minecraft.item.ItemHoe;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import reborncore.common.util.ItemUtils;
|
||||
|
||||
public class ItemTRHoe extends ItemHoe {
|
||||
|
@ -44,7 +44,7 @@ public class ItemTRHoe extends ItemHoe {
|
|||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public boolean isFull3D() {
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -300,12 +300,12 @@ public class MultiBlockCasing extends RectangularMultiblockControllerBase {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void writeToNBT(NBTTagCompound data) {
|
||||
public void write(NBTTagCompound data) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound data) {
|
||||
public void read(NBTTagCompound data) {
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -88,8 +88,8 @@ public class ClientProxy extends CommonProxy {
|
|||
|
||||
@Override
|
||||
public String getUpgradeConfigText() {
|
||||
if (Minecraft.getMinecraft().currentScreen instanceof GuiBase) {
|
||||
GuiBase base = (GuiBase) Minecraft.getMinecraft().currentScreen;
|
||||
if (Minecraft.getInstance().currentScreen instanceof GuiBase) {
|
||||
GuiBase base = (GuiBase) Minecraft.getInstance().currentScreen;
|
||||
if (base.tile instanceof IUpgradeable) {
|
||||
if (((IUpgradeable) base.tile).canBeUpgraded()) {
|
||||
return TextFormatting.LIGHT_PURPLE + "Right click to configure";
|
||||
|
@ -109,7 +109,7 @@ public class ClientProxy extends CommonProxy {
|
|||
|
||||
@Override
|
||||
public boolean fancyGraphics() {
|
||||
return Minecraft.getMinecraft().gameSettings.fancyGraphics;
|
||||
return Minecraft.getInstance().gameSettings.fancyGraphics;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -60,20 +60,20 @@ public class TileAlarm extends TileEntity
|
|||
|
||||
// TileEntity
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound compound) {
|
||||
public NBTTagCompound write(NBTTagCompound compound) {
|
||||
if (compound == null) {
|
||||
compound = new NBTTagCompound();
|
||||
}
|
||||
compound.setInteger("selectedSound", this.selectedSound);
|
||||
return super.writeToNBT(compound);
|
||||
compound.setInt("selectedSound", this.selectedSound);
|
||||
return super.write(compound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound compound) {
|
||||
public void read(NBTTagCompound compound) {
|
||||
if (compound != null && compound.hasKey("selectedSound")) {
|
||||
selectedSound = compound.getInteger("selectedSound");
|
||||
selectedSound = compound.getInt("selectedSound");
|
||||
}
|
||||
super.readFromNBT(compound);
|
||||
super.read(compound);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -54,7 +54,7 @@ public class TileEntityFlare extends TileEntity implements ITickable {
|
|||
}
|
||||
particleSmokeLarge.multipleParticleScaleBy(0.5F);
|
||||
|
||||
Minecraft.getMinecraft().effectRenderer.addEffect(particleSmokeLarge);
|
||||
Minecraft.getInstance().effectRenderer.addEffect(particleSmokeLarge);
|
||||
|
||||
world.spawnParticle(EnumParticleTypes.FLAME, pos.getX() + 0.5, pos.getY() + 0.3, pos.getZ() + 0.5, 0.0D, 0.0D, 0.0D);
|
||||
}
|
||||
|
|
|
@ -137,26 +137,26 @@ public class TilePump extends TilePowerAcceptor {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
readFromNBTWithoutCoords(tagCompound);
|
||||
public void read(NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
readWithoutCoords(tagCompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBTWithoutCoords(NBTTagCompound tagCompound) {
|
||||
tank.readFromNBT(tagCompound);
|
||||
public void readWithoutCoords(NBTTagCompound tagCompound) {
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
writeToNBTWithoutCoords(tagCompound);
|
||||
public NBTTagCompound write(NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
writeWithoutCoords(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBTWithoutCoords(NBTTagCompound tagCompound) {
|
||||
tank.writeToNBT(tagCompound);
|
||||
public NBTTagCompound writeWithoutCoords(NBTTagCompound tagCompound) {
|
||||
tank.write(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
|
|
|
@ -57,21 +57,21 @@ public class TileQuantumTank extends TileMachineBase
|
|||
public Tank tank = new Tank("TileQuantumTank", maxStorage, this);
|
||||
public Inventory<TileQuantumTank> inventory = new Inventory<>(3, "TileQuantumTank", 64, this).withConfiguredAccess();
|
||||
|
||||
public void readFromNBTWithoutCoords(final NBTTagCompound tagCompound) {
|
||||
tank.readFromNBT(tagCompound);
|
||||
public void readWithoutCoords(final NBTTagCompound tagCompound) {
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
public NBTTagCompound writeToNBTWithoutCoords(final NBTTagCompound tagCompound) {
|
||||
tank.writeToNBT(tagCompound);
|
||||
public NBTTagCompound writeWithoutCoords(final NBTTagCompound tagCompound) {
|
||||
tank.write(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
public ItemStack getDropWithNBT() {
|
||||
final NBTTagCompound tileEntity = new NBTTagCompound();
|
||||
final ItemStack dropStack = TRContent.Machine.QUANTUM_TANK.getStack();
|
||||
this.writeToNBTWithoutCoords(tileEntity);
|
||||
dropStack.setTagCompound(new NBTTagCompound());
|
||||
dropStack.getTagCompound().setTag("tileEntity", tileEntity);
|
||||
this.writeWithoutCoords(tileEntity);
|
||||
dropStack.setTag(new NBTTagCompound());
|
||||
dropStack.getTag().setTag("tileEntity", tileEntity);
|
||||
return dropStack;
|
||||
}
|
||||
|
||||
|
@ -93,22 +93,22 @@ public class TileQuantumTank extends TileMachineBase
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(final NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
readFromNBTWithoutCoords(tagCompound);
|
||||
public void read(final NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
readWithoutCoords(tagCompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(final NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
writeToNBTWithoutCoords(tagCompound);
|
||||
public NBTTagCompound write(final NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
writeWithoutCoords(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDataPacket(final NetworkManager net, final SPacketUpdateTileEntity packet) {
|
||||
world.markBlockRangeForRenderUpdate(pos.getX(), pos.getY(), pos.getZ(), pos.getX(), pos.getY(), pos.getZ());
|
||||
readFromNBT(packet.getNbtCompound());
|
||||
read(packet.getNbtCompound());
|
||||
}
|
||||
|
||||
// ItemHandlerProvider
|
||||
|
|
|
@ -56,7 +56,7 @@ public class TileTechStorageBase extends TileMachineBase
|
|||
inventory = new Inventory<>(3, name, maxCapacity, this).withConfiguredAccess();
|
||||
}
|
||||
|
||||
public void readFromNBTWithoutCoords(NBTTagCompound tagCompound) {
|
||||
public void readWithoutCoords(NBTTagCompound tagCompound) {
|
||||
|
||||
storedItem = ItemStack.EMPTY;
|
||||
|
||||
|
@ -65,33 +65,33 @@ public class TileTechStorageBase extends TileMachineBase
|
|||
}
|
||||
|
||||
if (!storedItem.isEmpty()) {
|
||||
storedItem.setCount(Math.min(tagCompound.getInteger("storedQuantity"), this.maxCapacity));
|
||||
storedItem.setCount(Math.min(tagCompound.getInt("storedQuantity"), this.maxCapacity));
|
||||
}
|
||||
|
||||
inventory.readFromNBT(tagCompound);
|
||||
inventory.read(tagCompound);
|
||||
}
|
||||
|
||||
public NBTTagCompound writeToNBTWithoutCoords(NBTTagCompound tagCompound) {
|
||||
public NBTTagCompound writeWithoutCoords(NBTTagCompound tagCompound) {
|
||||
if (!storedItem.isEmpty()) {
|
||||
ItemStack temp = storedItem.copy();
|
||||
if (storedItem.getCount() > storedItem.getMaxStackSize()) {
|
||||
temp.setCount(storedItem.getMaxStackSize());
|
||||
}
|
||||
tagCompound.setTag("storedStack", temp.writeToNBT(new NBTTagCompound()));
|
||||
tagCompound.setInteger("storedQuantity", Math.min(storedItem.getCount(), maxCapacity));
|
||||
tagCompound.setTag("storedStack", temp.write(new NBTTagCompound()));
|
||||
tagCompound.setInt("storedQuantity", Math.min(storedItem.getCount(), maxCapacity));
|
||||
} else {
|
||||
tagCompound.setInteger("storedQuantity", 0);
|
||||
tagCompound.setInt("storedQuantity", 0);
|
||||
}
|
||||
inventory.writeToNBT(tagCompound);
|
||||
inventory.write(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
public ItemStack getDropWithNBT() {
|
||||
NBTTagCompound tileEntity = new NBTTagCompound();
|
||||
ItemStack dropStack = new ItemStack(getBlockType(), 1);
|
||||
writeToNBTWithoutCoords(tileEntity);
|
||||
dropStack.setTagCompound(new NBTTagCompound());
|
||||
dropStack.getTagCompound().setTag("tileEntity", tileEntity);
|
||||
writeWithoutCoords(tileEntity);
|
||||
dropStack.setTag(new NBTTagCompound());
|
||||
dropStack.getTag().setTag("tileEntity", tileEntity);
|
||||
storedItem.setCount(0);
|
||||
inventory.setStackInSlot(1, ItemStack.EMPTY);
|
||||
syncWithAll();
|
||||
|
@ -197,19 +197,19 @@ public class TileTechStorageBase extends TileMachineBase
|
|||
@Override
|
||||
public void onDataPacket(NetworkManager net, SPacketUpdateTileEntity packet) {
|
||||
world.markBlockRangeForRenderUpdate(pos.getX(), pos.getY(), pos.getZ(), pos.getX(), pos.getY(), pos.getZ());
|
||||
readFromNBT(packet.getNbtCompound());
|
||||
read(packet.getNbtCompound());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
readFromNBTWithoutCoords(tagCompound);
|
||||
public void read(NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
readWithoutCoords(tagCompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
writeToNBTWithoutCoords(tagCompound);
|
||||
public NBTTagCompound write(NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
writeWithoutCoords(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
|
|
|
@ -96,35 +96,35 @@ public class TileCable extends TileEntity
|
|||
|
||||
@Override
|
||||
public NBTTagCompound getUpdateTag() {
|
||||
return writeToNBT(new NBTTagCompound());
|
||||
return write(new NBTTagCompound());
|
||||
}
|
||||
|
||||
@Override
|
||||
public SPacketUpdateTileEntity getUpdatePacket() {
|
||||
NBTTagCompound nbtTag = new NBTTagCompound();
|
||||
writeToNBT(nbtTag);
|
||||
write(nbtTag);
|
||||
return new SPacketUpdateTileEntity(getPos(), 1, nbtTag);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDataPacket(NetworkManager net, SPacketUpdateTileEntity packet) {
|
||||
readFromNBT(packet.getNbtCompound());
|
||||
read(packet.getNbtCompound());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound compound) {
|
||||
super.readFromNBT(compound);
|
||||
public void read(NBTTagCompound compound) {
|
||||
super.read(compound);
|
||||
if (compound.hasKey("TileCable")) {
|
||||
power = compound.getCompoundTag("TileCable").getInteger("power");
|
||||
power = compound.getCompoundTag("TileCable").getInt("power");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound compound) {
|
||||
super.writeToNBT(compound);
|
||||
public NBTTagCompound write(NBTTagCompound compound) {
|
||||
super.write(compound);
|
||||
if (power > 0) {
|
||||
NBTTagCompound data = new NBTTagCompound();
|
||||
data.setInteger("power", getEnergyStored());
|
||||
data.setInt("power", getEnergyStored());
|
||||
compound.setTag("TileCable", data);
|
||||
}
|
||||
return compound;
|
||||
|
|
|
@ -313,11 +313,11 @@ public class TileFusionControlComputer extends TilePowerAcceptor
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(final NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
this.crafingTickTime = tagCompound.getInteger("crafingTickTime");
|
||||
this.finalTickTime = tagCompound.getInteger("finalTickTime");
|
||||
this.neededPower = tagCompound.getInteger("neededPower");
|
||||
public void read(final NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
this.crafingTickTime = tagCompound.getInt("crafingTickTime");
|
||||
this.finalTickTime = tagCompound.getInt("finalTickTime");
|
||||
this.neededPower = tagCompound.getInt("neededPower");
|
||||
this.hasStartedCrafting = tagCompound.getBoolean("hasStartedCrafting");
|
||||
if(tagCompound.hasKey("hasActiveRecipe") && tagCompound.getBoolean("hasActiveRecipe") && this.currentRecipe == null){
|
||||
for (final FusionReactorRecipe reactorRecipe : FusionReactorRecipeHelper.reactorRecipes) {
|
||||
|
@ -327,20 +327,20 @@ public class TileFusionControlComputer extends TilePowerAcceptor
|
|||
}
|
||||
}
|
||||
if(tagCompound.hasKey("size")){
|
||||
this.size = tagCompound.getInteger("size");
|
||||
this.size = tagCompound.getInt("size");
|
||||
}
|
||||
this.size = Math.min(size, maxCoilSize);//Done here to force the samller size, will be useful if people lag out on a large one.
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(final NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
tagCompound.setInteger("crafingTickTime", this.crafingTickTime);
|
||||
tagCompound.setInteger("finalTickTime", this.finalTickTime);
|
||||
tagCompound.setInteger("neededPower", this.neededPower);
|
||||
public NBTTagCompound write(final NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
tagCompound.setInt("crafingTickTime", this.crafingTickTime);
|
||||
tagCompound.setInt("finalTickTime", this.finalTickTime);
|
||||
tagCompound.setInt("neededPower", this.neededPower);
|
||||
tagCompound.setBoolean("hasStartedCrafting", this.hasStartedCrafting);
|
||||
tagCompound.setBoolean("hasActiveRecipe", this.currentRecipe != null);
|
||||
tagCompound.setInteger("size", size);
|
||||
tagCompound.setInt("size", size);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
|
|
|
@ -108,10 +108,10 @@ public abstract class TileBaseFluidGenerator extends TilePowerAcceptor implement
|
|||
}
|
||||
|
||||
if (world.getTotalWorldTime() - lastOutput < 30 && !isActive()) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(BlockMachineBase.ACTIVE, true));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockMachineBase.ACTIVE, true));
|
||||
}
|
||||
else if (world.getTotalWorldTime() - lastOutput > 30 && isActive()) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(BlockMachineBase.ACTIVE, false));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockMachineBase.ACTIVE, false));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -173,15 +173,15 @@ public abstract class TileBaseFluidGenerator extends TilePowerAcceptor implement
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
tank.readFromNBT(tagCompound);
|
||||
public void read(NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
tank.writeToNBT(tagCompound);
|
||||
public NBTTagCompound write(NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
tank.write(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
|
|
|
@ -65,7 +65,7 @@ public class TileSolarPanel extends TilePowerAcceptor implements IToolDrop {
|
|||
if (world.getTotalWorldTime() % 20 == 0) {
|
||||
canSeeSky = world.canBlockSeeSky(pos.up());
|
||||
if (lastState != isSunOut()) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(BlockSolarPanel.ACTIVE, isSunOut()));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockSolarPanel.ACTIVE, isSunOut()));
|
||||
lastState = isSunOut();
|
||||
}
|
||||
}
|
||||
|
@ -138,12 +138,12 @@ public class TileSolarPanel extends TilePowerAcceptor implements IToolDrop {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound tag) {
|
||||
public void read(NBTTagCompound tag) {
|
||||
if (world == null) {
|
||||
// We are in TileEntity.create method during chunk load.
|
||||
this.checkOverfill = false;
|
||||
}
|
||||
super.readFromNBT(tag);
|
||||
super.read(tag);
|
||||
}
|
||||
|
||||
// TileMachineBase
|
||||
|
|
|
@ -81,9 +81,9 @@ public class TileDragonEggSyphon extends TilePowerAcceptor
|
|||
}
|
||||
|
||||
if (world.getTotalWorldTime() - lastOutput < 30 && !isActive()) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(BlockMachineBase.ACTIVE, true));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockMachineBase.ACTIVE, true));
|
||||
} else if (world.getTotalWorldTime() - lastOutput > 30 && isActive()) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(BlockMachineBase.ACTIVE, false));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockMachineBase.ACTIVE, false));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -64,10 +64,10 @@ public class TileWaterMill extends TilePowerAcceptor implements IToolDrop {
|
|||
}
|
||||
if (waterblocks > 0) {
|
||||
addEnergy(waterblocks * energyMultiplier);
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(BlockWindMill.ACTIVE, true));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockWindMill.ACTIVE, true));
|
||||
}
|
||||
else {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(BlockWindMill.ACTIVE, false));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockWindMill.ACTIVE, false));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -110,15 +110,15 @@ public class TileFluidReplicator extends TileGenericMachine implements IContaine
|
|||
|
||||
// TilePowerAcceptor
|
||||
@Override
|
||||
public void readFromNBT(final NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
tank.readFromNBT(tagCompound);
|
||||
public void read(final NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(final NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
tank.writeToNBT(tagCompound);
|
||||
public NBTTagCompound write(final NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
tank.write(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
|
|
|
@ -142,7 +142,7 @@ public class TileIndustrialBlastFurnace extends TileGenericMachine implements IC
|
|||
@Override
|
||||
public void onDataPacket(final NetworkManager net, final SPacketUpdateTileEntity packet) {
|
||||
world.markBlockRangeForRenderUpdate(pos.getX(), pos.getY(), pos.getZ(), pos.getX(), pos.getY(), pos.getZ());
|
||||
readFromNBT(packet.getNbtCompound());
|
||||
read(packet.getNbtCompound());
|
||||
}
|
||||
|
||||
// IContainerProvider
|
||||
|
|
|
@ -125,15 +125,15 @@ public class TileIndustrialGrinder extends TileGenericMachine implements IContai
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(final NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
tank.readFromNBT(tagCompound);
|
||||
public void read(final NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(final NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
tank.writeToNBT(tagCompound);
|
||||
public NBTTagCompound write(final NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
tank.write(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
|
|
|
@ -116,15 +116,15 @@ public class TileIndustrialSawmill extends TileGenericMachine implements IContai
|
|||
|
||||
// TilePowerAcceptor
|
||||
@Override
|
||||
public void readFromNBT(final NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
tank.readFromNBT(tagCompound);
|
||||
public void read(final NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
tank.read(tagCompound);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(final NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
tank.writeToNBT(tagCompound);
|
||||
public NBTTagCompound write(final NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
tank.write(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
|
|
|
@ -378,17 +378,17 @@ public class TileAutoCraftingTable extends TilePowerAcceptor
|
|||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound tag) {
|
||||
public NBTTagCompound write(NBTTagCompound tag) {
|
||||
tag.setBoolean("locked", locked);
|
||||
return super.writeToNBT(tag);
|
||||
return super.write(tag);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound tag) {
|
||||
public void read(NBTTagCompound tag) {
|
||||
if (tag.hasKey("locked")) {
|
||||
locked = tag.getBoolean("locked");
|
||||
}
|
||||
super.readFromNBT(tag);
|
||||
super.read(tag);
|
||||
}
|
||||
|
||||
// TileMachineBase
|
||||
|
|
|
@ -123,14 +123,14 @@ public class TilePlayerDectector extends TilePowerAcceptor implements IToolDrop
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound tag) {
|
||||
super.readFromNBT(tag);
|
||||
public void read(NBTTagCompound tag) {
|
||||
super.read(tag);
|
||||
owenerUdid = tag.getString("ownerID");
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound tag) {
|
||||
super.writeToNBT(tag);
|
||||
public NBTTagCompound write(NBTTagCompound tag) {
|
||||
super.write(tag);
|
||||
tag.setString("ownerID", owenerUdid);
|
||||
return tag;
|
||||
}
|
||||
|
|
|
@ -278,18 +278,18 @@ public class TileRollingMachine extends TilePowerAcceptor
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(final NBTTagCompound tagCompound) {
|
||||
super.readFromNBT(tagCompound);
|
||||
public void read(final NBTTagCompound tagCompound) {
|
||||
super.read(tagCompound);
|
||||
this.isRunning = tagCompound.getBoolean("isRunning");
|
||||
this.tickTime = tagCompound.getInteger("tickTime");
|
||||
this.tickTime = tagCompound.getInt("tickTime");
|
||||
this.locked = tagCompound.getBoolean("locked");
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(final NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
public NBTTagCompound write(final NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
tagCompound.setBoolean("isRunning", this.isRunning);
|
||||
tagCompound.setInteger("tickTime", this.tickTime);
|
||||
tagCompound.setInt("tickTime", this.tickTime);
|
||||
tagCompound.setBoolean("locked", locked);
|
||||
return tagCompound;
|
||||
}
|
||||
|
|
|
@ -78,9 +78,9 @@ public class TileAdjustableSU extends TileEnergyStorage implements IContainerPro
|
|||
public ItemStack getDropWithNBT() {
|
||||
NBTTagCompound tileEntity = new NBTTagCompound();
|
||||
ItemStack dropStack = TRContent.Machine.ADJUSTABLE_SU.getStack();
|
||||
writeToNBTWithoutCoords(tileEntity);
|
||||
dropStack.setTagCompound(new NBTTagCompound());
|
||||
dropStack.getTagCompound().setTag("tileEntity", tileEntity);
|
||||
writeWithoutCoords(tileEntity);
|
||||
dropStack.setTag(new NBTTagCompound());
|
||||
dropStack.getTag().setTag("tileEntity", tileEntity);
|
||||
return dropStack;
|
||||
}
|
||||
|
||||
|
@ -105,18 +105,18 @@ public class TileAdjustableSU extends TileEnergyStorage implements IContainerPro
|
|||
|
||||
// TilePowerAcceptor
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound tagCompound) {
|
||||
super.writeToNBT(tagCompound);
|
||||
tagCompound.setInteger("output", OUTPUT);
|
||||
inventory.writeToNBT(tagCompound);
|
||||
public NBTTagCompound write(NBTTagCompound tagCompound) {
|
||||
super.write(tagCompound);
|
||||
tagCompound.setInt("output", OUTPUT);
|
||||
inventory.write(tagCompound);
|
||||
return tagCompound;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound nbttagcompound) {
|
||||
super.readFromNBT(nbttagcompound);
|
||||
this.OUTPUT = nbttagcompound.getInteger("output");
|
||||
inventory.readFromNBT(nbttagcompound);
|
||||
public void read(NBTTagCompound nbttagcompound) {
|
||||
super.read(nbttagcompound);
|
||||
this.OUTPUT = nbttagcompound.getInt("output");
|
||||
inventory.read(nbttagcompound);
|
||||
}
|
||||
|
||||
// IContainerProvider
|
||||
|
|
|
@ -110,7 +110,7 @@ public class TileEnergyStorage extends TilePowerAcceptor
|
|||
// TileMachineBase
|
||||
@Override
|
||||
public void setFacing(EnumFacing enumFacing) {
|
||||
world.setBlockState(pos, world.getBlockState(pos).withProperty(BlockEnergyStorage.FACING, enumFacing));
|
||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockEnergyStorage.FACING, enumFacing));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -37,12 +37,12 @@ public class IDSUSaveManger extends WorldSavedData implements IDataIDSU {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound nbt) {
|
||||
public void read(NBTTagCompound nbt) {
|
||||
power = nbt.getDouble("power");
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound compound) {
|
||||
public NBTTagCompound write(NBTTagCompound compound) {
|
||||
compound.setDouble("power", power);
|
||||
return compound;
|
||||
}
|
||||
|
|
|
@ -93,14 +93,14 @@ public class TileInterdimensionalSU extends TileEnergyStorage implements IContai
|
|||
}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound nbttagcompound) {
|
||||
super.readFromNBT(nbttagcompound);
|
||||
public void read(NBTTagCompound nbttagcompound) {
|
||||
super.read(nbttagcompound);
|
||||
this.ownerUdid = nbttagcompound.getString("ownerUdid");
|
||||
}
|
||||
|
||||
@Override
|
||||
public NBTTagCompound writeToNBT(NBTTagCompound nbttagcompound) {
|
||||
super.writeToNBT(nbttagcompound);
|
||||
public NBTTagCompound write(NBTTagCompound nbttagcompound) {
|
||||
super.write(nbttagcompound);
|
||||
if (ownerUdid == null && StringUtils.isBlank(ownerUdid) || StringUtils.isEmpty(ownerUdid)) {
|
||||
return nbttagcompound;
|
||||
}
|
||||
|
|
|
@ -30,10 +30,10 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.nbt.NBTTagString;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import net.minecraftforge.event.entity.player.ItemTooltipEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import techreborn.init.TRContent;
|
||||
import reborncore.common.util.StringUtils;
|
||||
|
||||
|
@ -59,12 +59,12 @@ public class StackWIPHandler {
|
|||
|
||||
private void addHead(String name) {
|
||||
ItemStack head = new ItemStack(Items.SKULL, 1, 3);
|
||||
head.setTagCompound(new NBTTagCompound());
|
||||
head.getTagCompound().setTag("SkullOwner", new NBTTagString(name));
|
||||
head.setTag(new NBTTagCompound());
|
||||
head.getTag().setTag("SkullOwner", new NBTTagString(name));
|
||||
devHeads.add(head);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@SubscribeEvent
|
||||
public void toolTip(ItemTooltipEvent event) {
|
||||
Block block = Block.getBlockFromItem(event.getItemStack().getItem());
|
||||
|
|
|
@ -130,7 +130,7 @@ public class RubberTreeGenerator extends WorldGenerator {
|
|||
|| block.canBeReplacedByLeaves(state1, world,
|
||||
new BlockPos(xOffset, yOffset, zOffset)))) {
|
||||
this.setBlockAndNotifyAdequately(world, new BlockPos(xOffset, yOffset, zOffset),
|
||||
TRContent.RUBBER_LEAVES.getDefaultState().withProperty(BlockRubberLeaves.DECAYABLE, true).withProperty(BlockRubberLeaves.CHECK_DECAY, false));
|
||||
TRContent.RUBBER_LEAVES.getDefaultState().with(BlockRubberLeaves.DECAYABLE, true).with(BlockRubberLeaves.CHECK_DECAY, false));
|
||||
hasPlacedBlock = true;
|
||||
}
|
||||
}
|
||||
|
@ -147,8 +147,8 @@ public class RubberTreeGenerator extends WorldGenerator {
|
|||
IBlockState newState = TRContent.RUBBER_LOG.getDefaultState();
|
||||
boolean isAddingSap = false;
|
||||
if (rand.nextInt(TechReborn.worldGen.config.rubberTreeConfig.sapRarity) == 0) {
|
||||
newState = newState.withProperty(BlockRubberLog.HAS_SAP, true)
|
||||
.withProperty(BlockRubberLog.SAP_SIDE, EnumFacing.byHorizontalIndex(rand.nextInt(4)));
|
||||
newState = newState.with(BlockRubberLog.HAS_SAP, true)
|
||||
.with(BlockRubberLog.SAP_SIDE, EnumFacing.byHorizontalIndex(rand.nextInt(4)));
|
||||
isAddingSap = true;
|
||||
}
|
||||
if (isAddingSap) {
|
||||
|
@ -164,7 +164,7 @@ public class RubberTreeGenerator extends WorldGenerator {
|
|||
for (int i = 0; i < TechReborn.worldGen.config.rubberTreeConfig.spireHeight; i++) {
|
||||
BlockPos spikePos = topLogPos.up(i);
|
||||
this.setBlockAndNotifyAdequately(world, spikePos, TRContent.RUBBER_LEAVES.getDefaultState()
|
||||
.withProperty(BlockRubberLeaves.DECAYABLE, true).withProperty(BlockRubberLeaves.CHECK_DECAY, false));
|
||||
.with(BlockRubberLeaves.DECAYABLE, true).with(BlockRubberLeaves.CHECK_DECAY, false));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,7 +28,7 @@ import com.google.common.base.MoreObjects;
|
|||
import com.google.common.collect.Sets;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.event.world.ChunkDataEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import net.minecraftforge.fml.common.gameevent.TickEvent;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import reborncore.common.misc.ChunkCoord;
|
||||
|
|
Loading…
Reference in a new issue