mirror of
https://github.com/GTNewHorizons/Binnie.git
synced 2026-11-22 21:19:56 +00:00
Clean up some null annotations
This commit is contained in:
1 parent
cc20e2d339
commit
3bb678258f
29 files changed
+97
-38
No files matched your search
@@ -34,6 +34,7 @@ import net.minecraftforge.common.IShearable;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
@@ -221,7 +222,7 @@ public abstract class BlockETDecorativeLeaves extends Block implements IItemMode
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int colorMultiplier(IBlockState state, IBlockAccess worldIn, BlockPos pos, int tintIndex) {
|
||||
public int colorMultiplier(IBlockState state, @Nullable IBlockAccess worldIn, @Nullable BlockPos pos, int tintIndex) {
|
||||
ETTreeDefinition treeDefinition = state.getValue(getVariant());
|
||||
|
||||
ITreeGenome genome = treeDefinition.getGenome();
|
||||
|
||||
@@ -176,7 +176,7 @@ public class BlockHedge extends Block implements IBlockFence, IColoredBlock {
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public int colorMultiplier(IBlockState state, IBlockAccess world, BlockPos pos, int tintIndex) {
|
||||
public int colorMultiplier(IBlockState state, @Nullable IBlockAccess world, @Nullable BlockPos pos, int tintIndex) {
|
||||
return getColor(getMetaFromState(state));
|
||||
}
|
||||
|
||||
|
||||
@@ -120,7 +120,7 @@ public abstract class BlockDesign extends BlockMetadata implements IMultipassBlo
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public int colorMultiplier(IBlockState state, IBlockAccess world, BlockPos pos, int tintIndex) {
|
||||
public int colorMultiplier(IBlockState state, @Nullable IBlockAccess world, @Nullable BlockPos pos, int tintIndex) {
|
||||
if (world == null || pos == null) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
@ParametersAreNonnullByDefault
|
||||
@FieldsAreNonnullByDefault
|
||||
@MethodsReturnNonnullByDefault
|
||||
package binnie.extratrees.integration.jei.multifence;
|
||||
|
||||
import binnie.core.util.FieldsAreNonnullByDefault;
|
||||
import mcp.MethodsReturnNonnullByDefault;
|
||||
|
||||
import javax.annotation.ParametersAreNonnullByDefault;
|
||||
@@ -64,7 +64,7 @@ public class TileEntityNursery extends TileEntityMachine implements IButterflyNu
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setCaterpillar(final IButterfly butterfly) {
|
||||
public void setCaterpillar(@Nullable final IButterfly butterfly) {
|
||||
IButterflyNursery nursery = this.getNursery();
|
||||
if (nursery != null) {
|
||||
nursery.setCaterpillar(butterfly);
|
||||
|
||||
Reference in new issue
Block a user