Fixes #675 No disabled feature should log spam or crash anymore.
Deprecates the old usage of the AEItemDefinitions via the direct method access of * blocks() * parts() * items() * materials() and thus use the new re-direct via definitions(). All definitions are now initialized, no matter what. But SubItems, Items and Blocks are not registered, if by chance are disabled.
This commit is contained in:
@@ -21,13 +21,13 @@ package appeng.items.tools.quartz;
|
||||
|
||||
import java.util.EnumSet;
|
||||
|
||||
import com.google.common.base.Optional;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import com.google.common.base.Optional;
|
||||
|
||||
import appeng.api.implementations.guiobjects.IGuiItem;
|
||||
import appeng.api.implementations.guiobjects.IGuiItemObject;
|
||||
import appeng.core.features.AEFeature;
|
||||
@@ -39,14 +39,14 @@ import appeng.util.Platform;
|
||||
|
||||
public class ToolQuartzCuttingKnife extends AEBaseItem implements IGuiItem
|
||||
{
|
||||
private final AEFeature type;
|
||||
|
||||
final AEFeature type;
|
||||
|
||||
public ToolQuartzCuttingKnife( AEFeature Type )
|
||||
public ToolQuartzCuttingKnife( AEFeature type )
|
||||
{
|
||||
super( ToolQuartzCuttingKnife.class, Optional.of( Type.name() ) );
|
||||
super( Optional.of( type.name() ) );
|
||||
|
||||
this.setFeature( EnumSet.of( this.type = Type, AEFeature.QuartzKnife ) );
|
||||
this.type = type;
|
||||
this.setFeature( EnumSet.of( type, AEFeature.QuartzKnife ) );
|
||||
this.setMaxDamage( 50 );
|
||||
this.setMaxStackSize( 1 );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user