mirror of
https://github.com/GTNewHorizons/MagicBees.git
synced 2026-11-14 01:04:21 +00:00
Merge pull request #48 from chochem/add-null-check
Add a couple of null checks
This commit is contained in:
2 files changed
+15
-11
No files matched your search
@@ -426,14 +426,16 @@ public class CraftingManager {
|
||||
GameRegistry.addRecipe(
|
||||
new ShapedOreRecipe(new ItemStack(Items.emerald), "xxx", "xxx", "xxx", 'x', "nuggetEmerald"));
|
||||
|
||||
GameRegistry.addRecipe(
|
||||
new ShapedOreRecipe(
|
||||
ItemInterface.getItemStack("apatite"),
|
||||
"xxx",
|
||||
"xxx",
|
||||
"xxx",
|
||||
'x',
|
||||
Config.nuggets.getStackForType(NuggetType.APATITE)));
|
||||
if (ItemInterface.getItemStack("apatite") != null) {
|
||||
GameRegistry.addRecipe(
|
||||
new ShapedOreRecipe(
|
||||
ItemInterface.getItemStack("apatite"),
|
||||
"xxx",
|
||||
"xxx",
|
||||
"xxx",
|
||||
'x',
|
||||
Config.nuggets.getStackForType(NuggetType.APATITE)));
|
||||
}
|
||||
|
||||
output = Config.miscResources.getStackForType(ResourceType.DIMENSIONAL_SINGULARITY);
|
||||
GameRegistry.addRecipe(
|
||||
|
||||
@@ -638,9 +638,11 @@ public class ThaumcraftHelper implements IModHelper {
|
||||
new ItemStack(item.getItem(), 1, ForestryHelper.BlockResource.APATITE.ordinal()),
|
||||
list.copy());
|
||||
item = ItemInterface.getItemStack(ForestryHelper.Name, "apatite");
|
||||
ThaumcraftApi.registerObjectTag(
|
||||
new ItemStack(item.getItem(), 1, item.getItemDamage()),
|
||||
list.copy().add(Aspect.CRYSTAL, 2));
|
||||
if (item != null) {
|
||||
ThaumcraftApi.registerObjectTag(
|
||||
new ItemStack(item.getItem(), 1, item.getItemDamage()),
|
||||
list.copy().add(Aspect.CRYSTAL, 2));
|
||||
}
|
||||
|
||||
list = new AspectList().add(Aspect.MOTION, 2).add(Aspect.FLIGHT, 1);
|
||||
item = ItemInterface.getItemStack("beeDroneGE");
|
||||
|
||||
Reference in new issue
Block a user