mirror of
https://github.com/GTNewHorizons/MagicBees.git
synced 2026-11-17 11:05:02 +00:00
Fixes.
Upped forge to latest. Now requires Forestry 3. Hopefully fixed Thaumcraft and ExtraBees integration
This commit is contained in:
1 parent
e9c423579b
commit
0e0eaac495
8 files changed
+46
-28
No files matched your search
@@ -260,4 +260,9 @@ public class Allele implements IAllele
|
||||
return LocalizationManager.getLocalizedString(getUID());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getUnlocalizedName() {
|
||||
return this.uid;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -52,7 +52,7 @@ public class BeeMutation implements IBeeMutation
|
||||
{
|
||||
for (String str : binnieMundane)
|
||||
{
|
||||
LogHelper.info("Registering %s" + str);
|
||||
LogHelper.info("Registering " + str);
|
||||
try {
|
||||
new BeeMutation(species, Allele.getExtraSpecies(str), ForestryHelper.getTemplateForestryForSpecies("Common"), 15);
|
||||
} catch (Exception e) {
|
||||
@@ -374,10 +374,10 @@ public class BeeMutation implements IBeeMutation
|
||||
|
||||
if (this.requiredBlockOreDictEntry != null)
|
||||
{
|
||||
int dicId = OreDictionary.getOreID(new ItemStack(blockBelow, 1, blockMeta));
|
||||
if (dicId != -1)
|
||||
int[] dicId = OreDictionary.getOreIDs(new ItemStack(blockBelow, 1, blockMeta));
|
||||
if (dicId.length != 0)
|
||||
{
|
||||
if (!OreDictionary.getOreName(dicId).equals(this.requiredBlockOreDictEntry))
|
||||
if (!OreDictionary.getOreName(dicId[1]).equals(this.requiredBlockOreDictEntry))
|
||||
{
|
||||
chance = 0;
|
||||
}
|
||||
|
||||
@@ -1788,6 +1788,12 @@ public enum BeeSpecies implements IAlleleBeeSpecies, IIconProvider
|
||||
return LocalizationManager.getLocalizedString(getUID() + ".description");
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getUnlocalizedName()
|
||||
{
|
||||
return getUID();
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumTemperature getTemperature()
|
||||
{
|
||||
|
||||
@@ -207,6 +207,7 @@ public class Config
|
||||
this.doMiscConfig();
|
||||
|
||||
this.ForestryDebugEnabled = (new File("./config/forestry/DEBUG.ON")).exists();
|
||||
this.configuration.save();
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
@@ -231,7 +232,8 @@ public class Config
|
||||
{
|
||||
if (ThaumcraftHelper.isActive())
|
||||
{
|
||||
planksWood = new BlockPlanks();
|
||||
/**
|
||||
planksWood = new BlockPlanks();
|
||||
planksWood.setBlockName("planks");
|
||||
|
||||
//Item.itemsList[planksWood.blockID] = null;
|
||||
@@ -255,8 +257,9 @@ public class Config
|
||||
Item.itemsList[slabWoodFull.blockID] = new ItemSlab(slabWoodFull.blockID - 256, slabWoodHalf,
|
||||
slabWoodFull, true);*/
|
||||
|
||||
OreDictionary.registerOre("plankWood", new ItemStack(planksWood, 1, -1));
|
||||
OreDictionary.registerOre("slabWood", new ItemStack(slabWoodHalf, 1, -1));
|
||||
//OreDictionary.registerOre("plankWood", new ItemStack(planksWood, 1, -1));
|
||||
//OreDictionary.registerOre("slabWood", new ItemStack(slabWoodHalf, 1, -1));
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -3,12 +3,15 @@ package magicbees.main.utils.compat;
|
||||
import cpw.mods.fml.common.registry.GameRegistry;
|
||||
import forestry.api.core.EnumHumidity;
|
||||
import forestry.api.core.EnumTemperature;
|
||||
import forestry.core.config.ForestryBlock;
|
||||
import forestry.core.config.ForestryItem;
|
||||
import magicbees.main.utils.BlockInterface;
|
||||
import magicbees.main.utils.ItemInterface;
|
||||
import forestry.api.genetics.IAllele;
|
||||
import magicbees.bees.BeeManager;
|
||||
import magicbees.main.Config;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.oredict.OreDictionary;
|
||||
|
||||
public class ForestryHelper
|
||||
|
||||
@@ -2,6 +2,8 @@ package magicbees.main.utils.compat;
|
||||
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.common.registry.GameRegistry;
|
||||
import forestry.core.config.ForestryBlock;
|
||||
import forestry.core.config.ForestryItem;
|
||||
import magicbees.main.utils.ItemInterface;
|
||||
import magicbees.main.utils.BlockInterface;
|
||||
import magicbees.item.types.PollenType;
|
||||
@@ -11,6 +13,7 @@ import magicbees.item.types.WaxType;
|
||||
import magicbees.main.CommonProxy;
|
||||
import magicbees.main.Config;
|
||||
import magicbees.main.utils.LocalizationManager;
|
||||
import magicbees.main.utils.LogHelper;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -521,40 +524,40 @@ public class ThaumcraftHelper
|
||||
item = new ItemStack(Config.fHiveBlock);
|
||||
ThaumcraftApi.registerObjectTag(item, list);
|
||||
ThaumcraftApi.registerObjectTag(new ItemStack(Config.hive), list);
|
||||
|
||||
|
||||
list = new AspectList().add(Aspect.LIGHT, 1);
|
||||
item = ItemInterface.getItemStack("candle");
|
||||
item = ForestryBlock.candle.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(item, new int[] { item.getItemDamage() }, list);
|
||||
|
||||
list = new AspectList().add(Aspect.DARKNESS, 1);
|
||||
item = ItemInterface.getItemStack("stump");
|
||||
item = ForestryBlock.stump.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(item, new int[] { item.getItemDamage() }, list);
|
||||
|
||||
list = new AspectList(new ItemStack(Blocks.glass)).add(Aspect.SENSES, 1);
|
||||
item = ItemInterface.getItemStack("glass");
|
||||
item = ForestryBlock.glass.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(item, list);
|
||||
|
||||
list = new AspectList().add(Aspect.EARTH, 2).add(Aspect.WATER, 2);
|
||||
item = ItemInterface.getItemStack("soil");
|
||||
item = ForestryBlock.soil.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(item, new int[]{1}, list);
|
||||
|
||||
list = new AspectList(new ItemStack(Blocks.leaves));
|
||||
item = ItemInterface.getItemStack("leaves");
|
||||
item = ForestryBlock.leaves.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(item, new int[] { item.getItemDamage() }, list);
|
||||
|
||||
list = new AspectList(new ItemStack(Blocks.sapling));
|
||||
item = ItemInterface.getItemStack("saplingGE");
|
||||
item = ForestryBlock.saplingGE.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(item, list);
|
||||
|
||||
list = new AspectList()/*.add(Aspect.SEED, 1)*/.add(Aspect.PLANT, 1);
|
||||
item = ItemInterface.getItemStack("pollenFertile");
|
||||
item = ForestryItem.pollenFertile.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(item, list);
|
||||
|
||||
list = new AspectList().add(Aspect.CRYSTAL, 1).add(Aspect.EARTH, 2);
|
||||
item = ItemInterface.getItemStack("resources");
|
||||
item = ForestryItem.apatite.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(new ItemStack(item.getItem(), 1, ForestryHelper.BlockResource.APATITE.ordinal()),
|
||||
list.copy()/*.add(Aspect.STONE, 2)*/);
|
||||
item = ItemInterface.getItemStack("apatite");
|
||||
item = ForestryItem.apatite.getItemStack();
|
||||
ThaumcraftApi.registerObjectTag(new ItemStack(item.getItem(), 1, item.getItemDamage()),
|
||||
list.copy().add(Aspect.CRYSTAL, 2));
|
||||
|
||||
|
||||
@@ -39,7 +39,12 @@ public class BackpackDefinition implements IBackpackDefinition
|
||||
return this.name;
|
||||
}
|
||||
|
||||
@Override
|
||||
@Override
|
||||
public String getName(ItemStack backpack) {
|
||||
return backpack.getDisplayName();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getPrimaryColour()
|
||||
{
|
||||
return this.colour;
|
||||
@@ -60,12 +65,6 @@ public class BackpackDefinition implements IBackpackDefinition
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public Collection<ItemStack> getValidItems(EntityPlayer player)
|
||||
{
|
||||
return this.items;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isValidItem(EntityPlayer player, ItemStack itemStack)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user