mirror of
https://github.com/GTNewHorizons/Angelica.git
synced 2026-11-22 21:29:44 +00:00
Handle logging of ISBRH exception and multiple exception types
This commit is contained in:
1 parent
cfd2388c85
commit
cf5bf2e2e7
4 files changed
+49
-13
No files matched your search
@@ -2,9 +2,11 @@ package com.gtnewhorizons.angelica.common;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import it.unimi.dsi.fastutil.objects.Object2IntOpenHashMap;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.util.IIcon;
|
||||
|
||||
/**
|
||||
* This Block is not actually getting registered. A static instance is created in AngelicaMod.
|
||||
@@ -19,6 +21,8 @@ import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
|
||||
public class BlockError extends Block {
|
||||
|
||||
public static final IIcon[] icons = new IIcon[2];
|
||||
|
||||
public BlockError() {
|
||||
super(Material.rock);
|
||||
}
|
||||
@@ -27,7 +31,15 @@ public class BlockError extends Block {
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void registerBlockIcons(IIconRegister reg)
|
||||
{
|
||||
this.blockIcon = reg.registerIcon("angelica:error_block");
|
||||
for (int i = 0; i < icons.length; i++) {
|
||||
icons[i] = reg.registerIcon("angelica:error_block_" + i);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIcon(int side, int meta) {
|
||||
return icons[meta];
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user