Massive rework of configs, items and blocks.

I redone where the items/blocsks are stored and how the configs are
handled to clean up it and give space. You can change the config line to
AWWayofTime if you want to keep the compatibility with old configs. Now
you reference the blocks from the ModBlocks and Items from the ModItems.
This commit is contained in:
Fenn 2014-01-17 21:05:38 +00:00
parent 8601e9faff
commit e3644f2d2b
304 changed files with 3941 additions and 5108 deletions

View file

@ -1,20 +1,18 @@
package thaumcraft.api;
import cpw.mods.fml.common.FMLLog;
import net.minecraft.block.Block;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import cpw.mods.fml.common.FMLLog;
/**
* @author Azanor
*
* This is used to gain access to the items in my mod.
* I only give some examples and it will probably still
* require a bit of work for you to get hold of everything you need.
*
* <p/>
* This is used to gain access to the items in my mod.
* I only give some examples and it will probably still
* require a bit of work for you to get hold of everything you need.
*/
public class ItemApi
{
public class ItemApi {
public static ItemStack getItem(String itemString, int meta)
{
ItemStack item = null;
@ -27,13 +25,11 @@ public class ItemApi
if (obj instanceof Item)
{
item = new ItemStack((Item) obj, 1, meta);
}
else if (obj instanceof ItemStack)
} else if (obj instanceof ItemStack)
{
item = (ItemStack) obj;
}
}
catch (Exception ex)
} catch (Exception ex)
{
FMLLog.warning("[Thaumcraft] Could not retrieve item identified by: " + itemString);
}
@ -53,13 +49,11 @@ public class ItemApi
if (obj instanceof Block)
{
item = new ItemStack((Block) obj, 1, meta);
}
else if (obj instanceof ItemStack)
} else if (obj instanceof ItemStack)
{
item = (ItemStack) obj;
}
}
catch (Exception ex)
} catch (Exception ex)
{
FMLLog.warning("[Thaumcraft] Could not retrieve block identified by: " + itemString);
}