summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLance5057 <Lance5057@gmail.com>2017-04-29 22:20:58 -0500
committerLance5057 <Lance5057@gmail.com>2017-04-29 22:20:58 -0500
commitb4b05403fda50307e2b35de91296ab9bb53c2baa (patch)
treeb69a17f58673e8d4ac5d9da6503608649da4cc28 /src
parentf692d8983ee8787843d874ae1aa329c1439e3223 (diff)
Updated to TiCo 2.6.3
Added Zweihander Partially added Sheathe Partially added Crest Mount Partially added materials
Diffstat (limited to 'src')
-rw-r--r--src/api/java/buildcraft/api/tools/IToolWrench.java41
-rw-r--r--src/api/java/cofh/api/block/IDismantleable.java28
-rw-r--r--src/api/java/cofh/api/energy/EnergyStorage.java187
-rw-r--r--src/api/java/cofh/api/energy/IEnergyConnection.java22
-rw-r--r--src/api/java/cofh/api/energy/IEnergyContainerItem.java53
-rw-r--r--src/api/java/cofh/api/energy/IEnergyHandler.java58
-rw-r--r--src/api/java/cofh/api/energy/IEnergyProvider.java39
-rw-r--r--src/api/java/cofh/api/energy/IEnergyReceiver.java39
-rw-r--r--src/api/java/cofh/api/energy/IEnergyStorage.java47
-rw-r--r--src/api/java/cofh/api/energy/ItemEnergyContainer.java128
-rw-r--r--src/api/java/cofh/api/energy/TileEnergyHandler.java73
-rw-r--r--src/api/java/cofh/api/item/IToolHammer.java45
-rw-r--r--src/api/java/cofh/core/item/IEqualityOverrideItem.java10
-rw-r--r--src/api/java/cofh/lib/util/helpers/BlockHelper.java650
-rw-r--r--src/api/java/dynamicswordskills/api/ISword.java28
-rw-r--r--src/api/java/exterminatorJeff/undergroundBiomes/api/UBAPIHook.java12
-rw-r--r--src/api/java/exterminatorJeff/undergroundBiomes/api/UBOreTexturizer.java84
-rw-r--r--src/api/java/ic2/api/Direction.java151
-rw-r--r--src/api/java/ic2/api/crops/BaseSeed.java88
-rw-r--r--src/api/java/ic2/api/crops/CropCard.java491
-rw-r--r--src/api/java/ic2/api/crops/Crops.java149
-rw-r--r--src/api/java/ic2/api/crops/ICropTile.java290
-rw-r--r--src/api/java/ic2/api/crops/package-info.java5
-rw-r--r--src/api/java/ic2/api/energy/EnergyNet.java17
-rw-r--r--src/api/java/ic2/api/energy/IEnergyNet.java86
-rw-r--r--src/api/java/ic2/api/energy/NodeStats.java30
-rw-r--r--src/api/java/ic2/api/energy/event/EnergyTileEvent.java27
-rw-r--r--src/api/java/ic2/api/energy/event/EnergyTileLoadEvent.java27
-rw-r--r--src/api/java/ic2/api/energy/event/EnergyTileUnloadEvent.java28
-rw-r--r--src/api/java/ic2/api/energy/event/package-info.java5
-rw-r--r--src/api/java/ic2/api/energy/package-info.java5
-rw-r--r--src/api/java/ic2/api/energy/prefab/BasicSink.java410
-rw-r--r--src/api/java/ic2/api/energy/prefab/BasicSource.java416
-rw-r--r--src/api/java/ic2/api/energy/prefab/package-info.java5
-rw-r--r--src/api/java/ic2/api/energy/tile/IEnergyAcceptor.java26
-rw-r--r--src/api/java/ic2/api/energy/tile/IEnergyConductor.java53
-rw-r--r--src/api/java/ic2/api/energy/tile/IEnergyEmitter.java27
-rw-r--r--src/api/java/ic2/api/energy/tile/IEnergySink.java45
-rw-r--r--src/api/java/ic2/api/energy/tile/IEnergySource.java38
-rw-r--r--src/api/java/ic2/api/energy/tile/IEnergyTile.java15
-rw-r--r--src/api/java/ic2/api/energy/tile/IHeatSource.java24
-rw-r--r--src/api/java/ic2/api/energy/tile/IKineticSource.java23
-rw-r--r--src/api/java/ic2/api/energy/tile/IMetaDelegate.java37
-rw-r--r--src/api/java/ic2/api/energy/tile/package-info.java5
-rw-r--r--src/api/java/ic2/api/energy/usage.txt144
-rw-r--r--src/api/java/ic2/api/event/ExplosionEvent.java40
-rw-r--r--src/api/java/ic2/api/event/LaserEvent.java123
-rw-r--r--src/api/java/ic2/api/event/PaintEvent.java32
-rw-r--r--src/api/java/ic2/api/event/RetextureEvent.java37
-rw-r--r--src/api/java/ic2/api/event/package-info.java5
-rw-r--r--src/api/java/ic2/api/info/IEnergyValueProvider.java18
-rw-r--r--src/api/java/ic2/api/info/IFuelValueProvider.java16
-rw-r--r--src/api/java/ic2/api/info/Info.java45
-rw-r--r--src/api/java/ic2/api/info/package-info.java5
-rw-r--r--src/api/java/ic2/api/item/ElectricItem.java64
-rw-r--r--src/api/java/ic2/api/item/IBackupElectricItemManager.java13
-rw-r--r--src/api/java/ic2/api/item/IBlockCuttingBlade.java6
-rw-r--r--src/api/java/ic2/api/item/IBoxable.java14
-rw-r--r--src/api/java/ic2/api/item/IC2Items.java608
-rw-r--r--src/api/java/ic2/api/item/ICustomDamageItem.java57
-rw-r--r--src/api/java/ic2/api/item/IDebuggable.java22
-rw-r--r--src/api/java/ic2/api/item/IElectricItem.java57
-rw-r--r--src/api/java/ic2/api/item/IElectricItemManager.java96
-rw-r--r--src/api/java/ic2/api/item/IItemHudInfo.java25
-rw-r--r--src/api/java/ic2/api/item/IKineticRotor.java24
-rw-r--r--src/api/java/ic2/api/item/ILatheItem.java71
-rw-r--r--src/api/java/ic2/api/item/IMetalArmor.java21
-rw-r--r--src/api/java/ic2/api/item/ISpecialElectricItem.java14
-rw-r--r--src/api/java/ic2/api/item/ITerraformingBP.java35
-rw-r--r--src/api/java/ic2/api/item/ItemWrapper.java69
-rw-r--r--src/api/java/ic2/api/item/package-info.java5
-rw-r--r--src/api/java/ic2/api/network/INetworkClientTileEntityEventListener.java17
-rw-r--r--src/api/java/ic2/api/network/INetworkDataProvider.java18
-rw-r--r--src/api/java/ic2/api/network/INetworkItemEventListener.java19
-rw-r--r--src/api/java/ic2/api/network/INetworkTileEntityEventListener.java14
-rw-r--r--src/api/java/ic2/api/network/INetworkUpdateListener.java14
-rw-r--r--src/api/java/ic2/api/network/NetworkHelper.java248
-rw-r--r--src/api/java/ic2/api/network/package-info.java5
-rw-r--r--src/api/java/ic2/api/package-info.java5
-rw-r--r--src/api/java/ic2/api/reactor/IReactor.java158
-rw-r--r--src/api/java/ic2/api/reactor/IReactorChamber.java21
-rw-r--r--src/api/java/ic2/api/reactor/IReactorComponent.java99
-rw-r--r--src/api/java/ic2/api/reactor/package-info.java5
-rw-r--r--src/api/java/ic2/api/recipe/ICannerBottleRecipeManager.java54
-rw-r--r--src/api/java/ic2/api/recipe/ICannerEnrichRecipeManager.java55
-rw-r--r--src/api/java/ic2/api/recipe/ICraftingRecipeManager.java27
-rw-r--r--src/api/java/ic2/api/recipe/IFluidHeatManager.java33
-rw-r--r--src/api/java/ic2/api/recipe/ILiquidAcceptManager.java12
-rw-r--r--src/api/java/ic2/api/recipe/ILiquidHeatExchangerManager.java42
-rw-r--r--src/api/java/ic2/api/recipe/IListRecipeManager.java42
-rw-r--r--src/api/java/ic2/api/recipe/IMachineRecipeManager.java45
-rw-r--r--src/api/java/ic2/api/recipe/IMachineRecipeManagerExt.java23
-rw-r--r--src/api/java/ic2/api/recipe/IPatternStorage.java12
-rw-r--r--src/api/java/ic2/api/recipe/IRecipeInput.java32
-rw-r--r--src/api/java/ic2/api/recipe/IScrapboxManager.java14
-rw-r--r--src/api/java/ic2/api/recipe/ISemiFluidFuelManager.java33
-rw-r--r--src/api/java/ic2/api/recipe/RecipeInputFluidContainer.java67
-rw-r--r--src/api/java/ic2/api/recipe/RecipeInputItemStack.java55
-rw-r--r--src/api/java/ic2/api/recipe/RecipeInputOreDict.java134
-rw-r--r--src/api/java/ic2/api/recipe/RecipeOutput.java63
-rw-r--r--src/api/java/ic2/api/recipe/Recipes.java68
-rw-r--r--src/api/java/ic2/api/recipe/package-info.java5
-rw-r--r--src/api/java/ic2/api/tile/ExplosionWhitelist.java50
-rw-r--r--src/api/java/ic2/api/tile/IEnergyStorage.java62
-rw-r--r--src/api/java/ic2/api/tile/IWrenchable.java61
-rw-r--r--src/api/java/ic2/api/tile/package-info.java5
-rw-r--r--src/api/java/ic2/api/util/IKeyboard.java22
-rw-r--r--src/api/java/ic2/api/util/Keys.java6
-rw-r--r--src/api/java/ic2/api/util/package-info.java5
-rw-r--r--src/api/java/invtweaks/api/container/ChestContainer.java41
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaBlock.java37
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaBlockDecorator.java10
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaConfigHandler.java29
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaDataAccessor.java46
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaDataProvider.java36
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaEntityAccessor.java32
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaEntityProvider.java19
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaFMPAccessor.java36
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaFMPDecorator.java8
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaFMPProvider.java15
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaRegistrar.java57
-rw-r--r--src/api/java/mcp/mobius/waila/api/IWailaSummaryProvider.java22
-rw-r--r--src/api/java/mcp/mobius/waila/api/SpecialChars.java41
-rw-r--r--src/api/java/mcp/mobius/waila/api/package-info.java5
-rw-r--r--src/api/java/mekanism/api/Chunk3D.java115
-rw-r--r--src/api/java/mekanism/api/Coord4D.java425
-rw-r--r--src/api/java/mekanism/api/EnumColor.java96
-rw-r--r--src/api/java/mekanism/api/IClientTicker.java8
-rw-r--r--src/api/java/mekanism/api/IConfigurable.java27
-rw-r--r--src/api/java/mekanism/api/IFilterAccess.java31
-rw-r--r--src/api/java/mekanism/api/IHeatTransfer.java28
-rw-r--r--src/api/java/mekanism/api/IMekWrench.java8
-rw-r--r--src/api/java/mekanism/api/ISalinationSolar.java11
-rw-r--r--src/api/java/mekanism/api/ItemRetriever.java120
-rw-r--r--src/api/java/mekanism/api/MekanismAPI.java51
-rw-r--r--src/api/java/mekanism/api/MekanismConfig.java137
-rw-r--r--src/api/java/mekanism/api/Pos3D.java458
-rw-r--r--src/api/java/mekanism/api/Range4D.java107
-rw-r--r--src/api/java/mekanism/api/TabProxy.java45
-rw-r--r--src/api/java/mekanism/api/energy/EnergizedItemManager.java60
-rw-r--r--src/api/java/mekanism/api/energy/EnergyStack.java14
-rw-r--r--src/api/java/mekanism/api/energy/ICableOutputter.java18
-rw-r--r--src/api/java/mekanism/api/energy/IEnergizedItem.java59
-rw-r--r--src/api/java/mekanism/api/energy/IStrictEnergyAcceptor.java25
-rw-r--r--src/api/java/mekanism/api/energy/IStrictEnergyStorage.java27
-rw-r--r--src/api/java/mekanism/api/energy/package-info.java5
-rw-r--r--src/api/java/mekanism/api/gas/Gas.java222
-rw-r--r--src/api/java/mekanism/api/gas/GasNetwork.java373
-rw-r--r--src/api/java/mekanism/api/gas/GasRegistry.java113
-rw-r--r--src/api/java/mekanism/api/gas/GasStack.java134
-rw-r--r--src/api/java/mekanism/api/gas/GasTank.java256
-rw-r--r--src/api/java/mekanism/api/gas/GasTransmission.java181
-rw-r--r--src/api/java/mekanism/api/gas/IGasHandler.java47
-rw-r--r--src/api/java/mekanism/api/gas/IGasItem.java81
-rw-r--r--src/api/java/mekanism/api/gas/IGasTransmitter.java9
-rw-r--r--src/api/java/mekanism/api/gas/ITubeConnection.java18
-rw-r--r--src/api/java/mekanism/api/gas/OreGas.java38
-rw-r--r--src/api/java/mekanism/api/gas/package-info.java5
-rw-r--r--src/api/java/mekanism/api/infuse/InfuseObject.java21
-rw-r--r--src/api/java/mekanism/api/infuse/InfuseRegistry.java113
-rw-r--r--src/api/java/mekanism/api/infuse/InfuseType.java47
-rw-r--r--src/api/java/mekanism/api/infuse/package-info.java5
-rw-r--r--src/api/java/mekanism/api/lasers/ILaserReceptor.java10
-rw-r--r--src/api/java/mekanism/api/lasers/package-info.java5
-rw-r--r--src/api/java/mekanism/api/package-info.java5
-rw-r--r--src/api/java/mekanism/api/reactor/IFusionReactor.java65
-rw-r--r--src/api/java/mekanism/api/reactor/INeutronCapture.java6
-rw-r--r--src/api/java/mekanism/api/reactor/IReactorBlock.java11
-rw-r--r--src/api/java/mekanism/api/reactor/package-info.java5
-rw-r--r--src/api/java/mekanism/api/recipe/RecipeHelper.java372
-rw-r--r--src/api/java/mekanism/api/recipe/package-info.java5
-rw-r--r--src/api/java/mekanism/api/transmitters/DynamicNetwork.java498
-rw-r--r--src/api/java/mekanism/api/transmitters/IBlockableConnection.java10
-rw-r--r--src/api/java/mekanism/api/transmitters/IGridTransmitter.java64
-rw-r--r--src/api/java/mekanism/api/transmitters/INetworkDataHandler.java10
-rw-r--r--src/api/java/mekanism/api/transmitters/ITransmitter.java11
-rw-r--r--src/api/java/mekanism/api/transmitters/ITransmitterTile.java6
-rw-r--r--src/api/java/mekanism/api/transmitters/TransmissionType.java75
-rw-r--r--src/api/java/mekanism/api/transmitters/TransmitterNetworkRegistry.java294
-rw-r--r--src/api/java/mekanism/api/transmitters/package-info.java5
-rw-r--r--src/api/java/mekanism/api/util/BlockInfo.java37
-rw-r--r--src/api/java/mekanism/api/util/ItemInfo.java36
-rw-r--r--src/api/java/mekanism/api/util/ListUtils.java293
-rw-r--r--src/api/java/mekanism/api/util/StackUtils.java255
-rw-r--r--src/api/java/mekanism/api/util/UnitDisplayUtils.java271
-rw-r--r--src/api/java/mekanism/api/util/package-info.java5
-rw-r--r--src/api/java/mods/battlegear2/api/IAllowItem.java12
-rw-r--r--src/api/java/mods/battlegear2/api/IOffhandDual.java63
-rw-r--r--src/api/java/mods/battlegear2/api/ISheathed.java21
-rw-r--r--src/api/java/mods/battlegear2/api/PlayerEventChild.java306
-rw-r--r--src/api/java/mods/battlegear2/api/package-info.java5
-rw-r--r--src/api/java/mods/battlegear2/api/weapons/IBattlegearWeapon.java14
-rw-r--r--src/api/java/mods/battlegear2/api/weapons/package-info.java5
-rw-r--r--src/api/java/modwarriors/notenoughkeys/api/Api.java44
-rw-r--r--src/api/java/modwarriors/notenoughkeys/api/KeyBindingPressedEvent.java46
-rw-r--r--src/api/java/modwarriors/notenoughkeys/api/package-info.java5
-rw-r--r--src/api/java/morph/api/Ability.java227
-rw-r--r--src/api/java/morph/api/Api.java203
-rw-r--r--src/api/java/powercrystals/minefactoryreloaded/api/FactoryRegistry.java114
-rw-r--r--src/api/java/powercrystals/minefactoryreloaded/api/HarvestType.java44
-rw-r--r--src/api/java/powercrystals/minefactoryreloaded/api/IFactoryGrindable.java35
-rw-r--r--src/api/java/powercrystals/minefactoryreloaded/api/IFactoryHarvestable.java71
-rw-r--r--src/api/java/powercrystals/minefactoryreloaded/api/ILiquidDrinkHandler.java8
-rw-r--r--src/api/java/powercrystals/minefactoryreloaded/api/MobDrop.java24
-rw-r--r--src/api/java/powercrystals/minefactoryreloaded/api/ValuedItem.java72
-rw-r--r--src/api/java/thaumcraft/api/BlockCoordinates.java115
-rw-r--r--src/api/java/thaumcraft/api/IArchitect.java28
-rw-r--r--src/api/java/thaumcraft/api/IGoggles.java23
-rw-r--r--src/api/java/thaumcraft/api/IRepairable.java11
-rw-r--r--src/api/java/thaumcraft/api/IRepairableExtended.java16
-rw-r--r--src/api/java/thaumcraft/api/IRunicArmor.java22
-rw-r--r--src/api/java/thaumcraft/api/IScribeTools.java14
-rw-r--r--src/api/java/thaumcraft/api/IVisDiscountGear.java18
-rw-r--r--src/api/java/thaumcraft/api/IWarpingGear.java22
-rw-r--r--src/api/java/thaumcraft/api/ItemApi.java85
-rw-r--r--src/api/java/thaumcraft/api/ItemRunic.java23
-rw-r--r--src/api/java/thaumcraft/api/ThaumcraftApi.java716
-rw-r--r--src/api/java/thaumcraft/api/ThaumcraftApiHelper.java523
-rw-r--r--src/api/java/thaumcraft/api/TileThaumcraft.java64
-rw-r--r--src/api/java/thaumcraft/api/WorldCoordinates.java123
-rw-r--r--src/api/java/thaumcraft/api/aspects/Aspect.java377
-rw-r--r--src/api/java/thaumcraft/api/aspects/AspectList.java358
-rw-r--r--src/api/java/thaumcraft/api/aspects/AspectSourceHelper.java70
-rw-r--r--src/api/java/thaumcraft/api/aspects/IAspectContainer.java75
-rw-r--r--src/api/java/thaumcraft/api/aspects/IAspectSource.java13
-rw-r--r--src/api/java/thaumcraft/api/aspects/IEssentiaContainerItem.java38
-rw-r--r--src/api/java/thaumcraft/api/aspects/IEssentiaTransport.java95
-rw-r--r--src/api/java/thaumcraft/api/crafting/CrucibleRecipe.java116
-rw-r--r--src/api/java/thaumcraft/api/crafting/IArcaneRecipe.java36
-rw-r--r--src/api/java/thaumcraft/api/crafting/IInfusionStabiliser.java20
-rw-r--r--src/api/java/thaumcraft/api/crafting/InfusionEnchantmentRecipe.java188
-rw-r--r--src/api/java/thaumcraft/api/crafting/InfusionRecipe.java174
-rw-r--r--src/api/java/thaumcraft/api/crafting/ShapedArcaneRecipe.java281
-rw-r--r--src/api/java/thaumcraft/api/crafting/ShapelessArcaneRecipe.java179
-rw-r--r--src/api/java/thaumcraft/api/damagesource/DamageSourceIndirectThaumcraftEntity.java26
-rw-r--r--src/api/java/thaumcraft/api/damagesource/DamageSourceThaumcraft.java34
-rw-r--r--src/api/java/thaumcraft/api/entities/IEldritchMob.java6
-rw-r--r--src/api/java/thaumcraft/api/entities/ITaintedMob.java6
-rw-r--r--src/api/java/thaumcraft/api/internal/DummyInternalMethodHandler.java88
-rw-r--r--src/api/java/thaumcraft/api/internal/IInternalMethodHandler.java38
-rw-r--r--src/api/java/thaumcraft/api/internal/WeightedRandomLoot.java24
-rw-r--r--src/api/java/thaumcraft/api/nodes/INode.java54
-rw-r--r--src/api/java/thaumcraft/api/nodes/IRevealer.java22
-rw-r--r--src/api/java/thaumcraft/api/nodes/NodeModifier.java6
-rw-r--r--src/api/java/thaumcraft/api/nodes/NodeType.java6
-rw-r--r--src/api/java/thaumcraft/api/package-info.java5
-rw-r--r--src/api/java/thaumcraft/api/potions/PotionFluxTaint.java70
-rw-r--r--src/api/java/thaumcraft/api/potions/PotionVisExhaust.java49
-rw-r--r--src/api/java/thaumcraft/api/research/IScanEventHandler.java10
-rw-r--r--src/api/java/thaumcraft/api/research/ResearchCategories.java116
-rw-r--r--src/api/java/thaumcraft/api/research/ResearchCategoryList.java36
-rw-r--r--src/api/java/thaumcraft/api/research/ResearchItem.java394
-rw-r--r--src/api/java/thaumcraft/api/research/ResearchPage.java206
-rw-r--r--src/api/java/thaumcraft/api/research/ScanResult.java49
-rw-r--r--src/api/java/thaumcraft/api/visnet/TileVisNode.java217
-rw-r--r--src/api/java/thaumcraft/api/visnet/VisNetHandler.java317
-rw-r--r--src/api/java/thaumcraft/api/wands/FocusUpgradeType.java159
-rw-r--r--src/api/java/thaumcraft/api/wands/IWandRodOnUpdate.java17
-rw-r--r--src/api/java/thaumcraft/api/wands/IWandTriggerManager.java15
-rw-r--r--src/api/java/thaumcraft/api/wands/IWandable.java26
-rw-r--r--src/api/java/thaumcraft/api/wands/ItemFocusBasic.java314
-rw-r--r--src/api/java/thaumcraft/api/wands/StaffRod.java53
-rw-r--r--src/api/java/thaumcraft/api/wands/WandCap.java145
-rw-r--r--src/api/java/thaumcraft/api/wands/WandRod.java179
-rw-r--r--src/api/java/thaumcraft/api/wands/WandTriggerRegistry.java158
-rw-r--r--src/api/java/zeldaswordskills/api/item/ISword.java31
-rw-r--r--src/api/java/zeldaswordskills/api/item/package-info.java5
-rw-r--r--src/api/java/zeldaswordskills/api/package-info.java5
-rw-r--r--src/main/java/lance5057/tDefense/PacketHandler.java18
-rw-r--r--src/main/java/lance5057/tDefense/Reference.java2
-rw-r--r--src/main/java/lance5057/tDefense/TDIntegration.java31
-rw-r--r--src/main/java/lance5057/tDefense/TD_Commands.java21
-rw-r--r--src/main/java/lance5057/tDefense/TinkersDefense.java27
-rw-r--r--src/main/java/lance5057/tDefense/armor/ArmorCore.java511
-rw-r--r--src/main/java/lance5057/tDefense/armor/TDArmorAddon.java385
-rw-r--r--src/main/java/lance5057/tDefense/armor/blocks/GlowstoneCrumbs.java115
-rw-r--r--src/main/java/lance5057/tDefense/armor/blocks/UnstableBlock.java123
-rw-r--r--src/main/java/lance5057/tDefense/armor/blocks/UnstableItemBlock.java20
-rw-r--r--src/main/java/lance5057/tDefense/armor/events/ArmorModEvents.java201
-rw-r--r--src/main/java/lance5057/tDefense/armor/events/ArmorRenderEvent.java188
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/Sheath.java106
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/TinkersGauntlets.java264
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/cloth/TinkersHood.java368
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/cloth/TinkersRobe.java300
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShawl.java304
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShoes.java298
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/heavy/TinkersBreastplate.java143
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/heavy/TinkersGrieves.java268
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/heavy/TinkersHelm.java342
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/heavy/TinkersSabatons.java268
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/light/TinkersBoots.java264
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/light/TinkersChausses.java284
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/light/TinkersCoif.java358
-rw-r--r--src/main/java/lance5057/tDefense/armor/items/light/TinkersHauberk.java266
-rw-r--r--src/main/java/lance5057/tDefense/armor/modifiers/ArmorMods.java1120
-rw-r--r--src/main/java/lance5057/tDefense/armor/modifiers/BloodMagic/BloodArmorMods.java112
-rw-r--r--src/main/java/lance5057/tDefense/armor/modifiers/Botania/BotaniaArmorMods.java132
-rw-r--r--src/main/java/lance5057/tDefense/armor/modifiers/Thaumcraft/ThaumArmorMods.java118
-rw-r--r--src/main/java/lance5057/tDefense/armor/modifiers/modifierProtection.java190
-rw-r--r--src/main/java/lance5057/tDefense/armor/parts/Cloth.java92
-rw-r--r--src/main/java/lance5057/tDefense/armor/parts/ClothMaterial.java28
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/ArmorRenderer.java23
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/ModelSheath.java73
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersGauntlets.java482
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersTabard.java144
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersHood.java338
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersRobe.java758
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShawl.java352
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShoes.java158
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersBreastplate.java2
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersGrieves.java428
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersHelm.java470
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersSabatons.java376
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersBoots.java222
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersChausses.java276
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersCoif.java200
-rw-r--r--src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersHauberk.java396
-rw-r--r--src/main/java/lance5057/tDefense/baubles/BaublesBase.java32
-rw-r--r--src/main/java/lance5057/tDefense/baubles/BaublesClientProxy.java91
-rw-r--r--src/main/java/lance5057/tDefense/baubles/BaublesItems.java25
-rw-r--r--src/main/java/lance5057/tDefense/baubles/blocks/JewelersBench.java57
-rw-r--r--src/main/java/lance5057/tDefense/baubles/models/ModelJewelersBench.java104
-rw-r--r--src/main/java/lance5057/tDefense/baubles/models/Renderer_JewelersBench.java43
-rw-r--r--src/main/java/lance5057/tDefense/baubles/renderers/BaubleRenderer.java108
-rw-r--r--src/main/java/lance5057/tDefense/baubles/renderers/SheatheModel.java128
-rw-r--r--src/main/java/lance5057/tDefense/baubles/tools/BaubleTool.java152
-rw-r--r--src/main/java/lance5057/tDefense/baubles/tools/Sheathe.java48
-rw-r--r--src/main/java/lance5057/tDefense/baubles/tools/TDBaubles.java99
-rw-r--r--src/main/java/lance5057/tDefense/core/CoreBase.java38
-rw-r--r--src/main/java/lance5057/tDefense/core/CoreBlocks.java68
-rw-r--r--src/main/java/lance5057/tDefense/core/CoreClientProxy.java25
-rw-r--r--src/main/java/lance5057/tDefense/core/CoreCommonProxy.java5
-rw-r--r--src/main/java/lance5057/tDefense/core/CoreItems.java25
-rw-r--r--src/main/java/lance5057/tDefense/core/TD_Patterns.java60
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/AeonSteelBlock.java15
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/DogbeariumBlock.java15
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/GreenMintBlock.java15
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/QueensGoldBlock.java15
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/RedMintBlock.java15
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/crestMount/CrestMount.java287
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/crestMount/Gui_CrestMount.java7
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/crestMount/Handler_CrestMount.java (renamed from src/main/java/lance5057/tDefense/core/network/Handler_CrestMount.java)13
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/crestMount/Message_CrestMount.java (renamed from src/main/java/lance5057/tDefense/core/network/Message_CrestMount.java)26
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/crestMount/Renderer_CrestMount.java164
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/crestMount/TileEntity_CrestMount.java90
-rw-r--r--src/main/java/lance5057/tDefense/core/blocks/ore/TD_Ore.java41
-rw-r--r--src/main/java/lance5057/tDefense/core/entity/EntityHookshotHook.java162
-rw-r--r--src/main/java/lance5057/tDefense/core/events/TDEventHandler.java98
-rw-r--r--src/main/java/lance5057/tDefense/core/gui/GuiTDGuideBook.java590
-rw-r--r--src/main/java/lance5057/tDefense/core/items/GuideBook.java26
-rw-r--r--src/main/java/lance5057/tDefense/core/items/MetaModifierItem.java63
-rw-r--r--src/main/java/lance5057/tDefense/core/items/RawGem.java16
-rw-r--r--src/main/java/lance5057/tDefense/core/liquids/MoltenFluid.java57
-rw-r--r--src/main/java/lance5057/tDefense/core/materials/traits/TraitAxeLover.java2
-rw-r--r--src/main/java/lance5057/tDefense/core/materials/traits/TraitFirestarter.java2
-rw-r--r--src/main/java/lance5057/tDefense/core/network/Handler_FinishingAnvil.java22
-rw-r--r--src/main/java/lance5057/tDefense/core/network/Message_FinishingAnvil.java49
-rw-r--r--src/main/java/lance5057/tDefense/core/network/PacketHandler.java16
-rw-r--r--src/main/java/lance5057/tDefense/core/renderer/HookRenderer.java121
-rw-r--r--src/main/java/lance5057/tDefense/core/renderer/MoreFlexibleToolRenderer.java359
-rw-r--r--src/main/java/lance5057/tDefense/core/renderer/TestSkinChanger.java58
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/ModifierSoul.java31
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/Shears.java193
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/TDToolEvents.java3
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/TDTools.java4
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/TinkerWrench.java255
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/TinkerZweihander.java164
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/TinkersHookshot.java119
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/Zweihander.java90
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/ActiveToolMods/TDefenseActiveToolMod.java31
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/BloodMagic/BloodMagicMods.java133
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/Botania/BotaniaMods.java193
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierBoolExclusive.java83
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierIntExclusive.java91
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierSoulHandler.java393
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/Modifiers.java86
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/ModifiersBase.java42
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/TDefense/TDMods.java470
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/Thaumcraft/ThaumcraftMods.java110
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/Thaumcraft/modifierRepairVis.java69
-rw-r--r--src/main/java/lance5057/tDefense/core/tools/modifiers/modLapisShears.java85
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Container_FinishingAnvil.java41
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/FinishingAnvil.java159
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Gui_FinishingAnvil.java609
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/ModelFinishingAnvil.java65
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/RenderItem_FinishingAnvil.java48
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Renderer_FinishingAnvil.java45
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/TileEntity_FinishingAnvil.java195
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/utilities/FileGetter.java21
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/utilities/Injector.java722
-rw-r--r--src/main/java/lance5057/tDefense/finishingAnvil/utilities/ToolCoreTip.java59
-rw-r--r--src/main/java/lance5057/tDefense/holiday/HolidayBase.java32
-rw-r--r--src/main/java/lance5057/tDefense/holiday/xmas/XmasBase.java26
-rw-r--r--src/main/java/lance5057/tDefense/holiday/xmas/XmasItems.java33
-rw-r--r--src/main/java/lance5057/tDefense/holiday/xmas/gumdropslime/GumDropSlimeRenderer.java2
-rw-r--r--src/main/java/lance5057/tDefense/proxy/ClientProxy.java32
-rw-r--r--src/main/java/lance5057/tDefense/proxy/CommonProxy.java57
-rw-r--r--src/main/java/lance5057/tDefense/util/BlocksBase.java49
-rw-r--r--src/main/java/lance5057/tDefense/util/ItemsBase.java21
-rw-r--r--src/main/java/lance5057/tDefense/util/ModuleBase.java17
-rw-r--r--src/main/resources/assets/tinkersdefense/models/item/tools/zweihander.tcon.json36
-rw-r--r--src/main/resources/assets/tinkersdefense/models/sheathe_1.pngbin0 -> 598 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/beheading_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/beheading_zweihander_effect.png)bin261 -> 261 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/blade.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_blade.png)bin131 -> 131 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/blaze_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/blaze_zweihander_effect.png)bin223 -> 223 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/bloodoath_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/bloodoath_zweihander_effect.png)bin638 -> 638 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/bloodoath_zweihander_effect.png.mcmeta (renamed from src/main/resources/assets/tinker/textures/items/zweihander/bloodoath_zweihander_effect.png.mcmeta)0
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/broken.pngbin0 -> 213 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/core.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_core.png)bin177 -> 177 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/corpseivy_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/corpseivy_zweihander_effect.png)bin472 -> 472 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/diamond_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/diamond_zweihander_effect.png)bin146 -> 146 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/emerald_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/emerald_zweihander_effect.png)bin116 -> 116 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/flux_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/flux_zweihander_effect.png)bin216 -> 216 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_blade.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_blade.png)bin259 -> 259 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_core.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_core.png)bin264 -> 264 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_guard.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_guard.png)bin272 -> 272 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_handle.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_handle.png)bin280 -> 280 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/guard.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_guard.png)bin199 -> 199 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/handle.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_handle.png)bin186 -> 186 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/lapis_zweihander_effect (1).png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/lapis_zweihander_effect (1).png)bin146 -> 146 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/lapis_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/lapis_zweihander_effect.png)bin146 -> 146 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/lava_zweihander_effect (1).png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/lava_zweihander_effect (1).png)bin141 -> 141 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/lava_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/lava_zweihander_effect.png)bin141 -> 141 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/manacore_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/manacore_zweihander_effect.png)bin174 -> 174 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/moss_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/moss_zweihander_effect.png)bin163 -> 163 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/necrotic_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/necrotic_zweihander_effect.png)bin175 -> 175 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/piston_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/piston_zweihander_effect.png)bin195 -> 195 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/quartz_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/quartz_zweihander_effect.png)bin173 -> 173 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_blade.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_blade.png)bin224 -> 224 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_core.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_core.png)bin254 -> 254 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_guard.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_guard.png)bin261 -> 261 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_handle.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_handle.png)bin263 -> 263 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/redstone_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/redstone_zweihander_effect.png)bin137 -> 137 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/reinforced_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/reinforced_zweihander_effect.png)bin191 -> 191 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/scabbing_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/scabbing_zweihander_effect.png)bin255 -> 255 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/silk_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/silk_zweihander_effect.png)bin187 -> 187 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/smite_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/smite_zweihander_effect.png)bin307 -> 307 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/spider_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/spider_zweihander_effect.png)bin162 -> 162 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/terracore_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/terracore_zweihander_effect.png)bin175 -> 175 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/items/zweihander/textbook_zweihander_effect.png (renamed from src/main/resources/assets/tinker/textures/items/zweihander/textbook_zweihander_effect.png)bin143 -> 143 bytes
-rw-r--r--src/main/resources/assets/tinkersdefense/textures/model/sheathe.pngbin0 -> 598 bytes
-rw-r--r--src/main/resources/mcmod.info4
442 files changed, 7129 insertions, 34943 deletions
diff --git a/src/api/java/buildcraft/api/tools/IToolWrench.java b/src/api/java/buildcraft/api/tools/IToolWrench.java
deleted file mode 100644
index e48ae06..0000000
--- a/src/api/java/buildcraft/api/tools/IToolWrench.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/**
- * Copyright (c) 2011-2015, SpaceToad and the BuildCraft Team
- * http://www.mod-buildcraft.com
- *
- * The BuildCraft API is distributed under the terms of the MIT License.
- * Please check the contents of the license, which should be located
- * as "LICENSE.API" in the BuildCraft source code distribution.
- */
-package buildcraft.api.tools;
-
-import net.minecraft.entity.player.EntityPlayer;
-
-/***
- * Implement this interface on subclasses of Item to have that item work as a wrench for buildcraft
- */
-public interface IToolWrench
-{
-
- /***
- * Called to ensure that the wrench can be used. To get the ItemStack that is used, check player.inventory.getCurrentItem()
- *
- * @param player
- * - The player doing the wrenching
- * @param x
- * ,y,z - The coordinates for the block being wrenched
- *
- * @return true if wrenching is allowed, false if not
- */
- boolean canWrench(EntityPlayer player, int x, int y, int z);
-
- /***
- * Callback after the wrench has been used. This can be used to decrease durability or for other purposes. To get the ItemStack that was used, check
- * player.inventory.getCurrentItem()
- *
- * @param player
- * - The player doing the wrenching
- * @param x
- * ,y,z - The coordinates of the block being wrenched
- */
- void wrenchUsed(EntityPlayer player, int x, int y, int z);
-}
diff --git a/src/api/java/cofh/api/block/IDismantleable.java b/src/api/java/cofh/api/block/IDismantleable.java
deleted file mode 100644
index 9a9c19a..0000000
--- a/src/api/java/cofh/api/block/IDismantleable.java
+++ /dev/null
@@ -1,28 +0,0 @@
-package cofh.api.block;
-
-import java.util.ArrayList;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-
-/**
- * Implemented on Blocks which have some method of being instantly dismantled.
- *
- * @author King Lemming
- *
- */
-public interface IDismantleable
-{
-
- /**
- * Dismantles the block. If returnDrops is true, the drop(s) should be placed into the player's inventory.
- */
- ArrayList<ItemStack> dismantleBlock(EntityPlayer player, World world, int x, int y, int z, boolean returnDrops);
-
- /**
- * Return true if the block can be dismantled. The criteria for this is entirely up to the block.
- */
- boolean canDismantle(EntityPlayer player, World world, int x, int y, int z);
-
-}
diff --git a/src/api/java/cofh/api/energy/EnergyStorage.java b/src/api/java/cofh/api/energy/EnergyStorage.java
deleted file mode 100644
index 01ec59b..0000000
--- a/src/api/java/cofh/api/energy/EnergyStorage.java
+++ /dev/null
@@ -1,187 +0,0 @@
-package cofh.api.energy;
-
-import net.minecraft.nbt.NBTTagCompound;
-
-/**
- * Reference implementation of {@link IEnergyStorage}. Use/extend this or implement your own.
- *
- * @author King Lemming
- *
- */
-public class EnergyStorage implements IEnergyStorage
-{
-
- protected int energy;
- protected int capacity;
- protected int maxReceive;
- protected int maxExtract;
-
- public EnergyStorage(int capacity)
- {
-
- this(capacity, capacity, capacity);
- }
-
- public EnergyStorage(int capacity, int maxTransfer)
- {
-
- this(capacity, maxTransfer, maxTransfer);
- }
-
- public EnergyStorage(int capacity, int maxReceive, int maxExtract)
- {
-
- this.capacity = capacity;
- this.maxReceive = maxReceive;
- this.maxExtract = maxExtract;
- }
-
- public EnergyStorage readFromNBT(NBTTagCompound nbt)
- {
-
- energy = nbt.getInteger("Energy");
-
- if(energy > capacity)
- {
- energy = capacity;
- }
- return this;
- }
-
- public NBTTagCompound writeToNBT(NBTTagCompound nbt)
- {
-
- if(energy < 0)
- {
- energy = 0;
- }
- nbt.setInteger("Energy", energy);
- return nbt;
- }
-
- public void setCapacity(int capacity)
- {
-
- this.capacity = capacity;
-
- if(energy > capacity)
- {
- energy = capacity;
- }
- }
-
- public void setMaxTransfer(int maxTransfer)
- {
-
- setMaxReceive(maxTransfer);
- setMaxExtract(maxTransfer);
- }
-
- public void setMaxReceive(int maxReceive)
- {
-
- this.maxReceive = maxReceive;
- }
-
- public void setMaxExtract(int maxExtract)
- {
-
- this.maxExtract = maxExtract;
- }
-
- public int getMaxReceive()
- {
-
- return maxReceive;
- }
-
- public int getMaxExtract()
- {
-
- return maxExtract;
- }
-
- /**
- * This function is included to allow for server -&gt; client sync. Do not call this externally to the containing Tile Entity, as not all IEnergyHandlers
- * are guaranteed to have it.
- *
- * @param energy
- */
- public void setEnergyStored(int energy)
- {
-
- this.energy = energy;
-
- if(this.energy > capacity)
- {
- this.energy = capacity;
- }
- else if(this.energy < 0)
- {
- this.energy = 0;
- }
- }
-
- /**
- * This function is included to allow the containing tile to directly and efficiently modify the energy contained in the EnergyStorage. Do not rely on this
- * externally, as not all IEnergyHandlers are guaranteed to have it.
- *
- * @param energy
- */
- public void modifyEnergyStored(int energy)
- {
-
- this.energy += energy;
-
- if(this.energy > capacity)
- {
- this.energy = capacity;
- }
- else if(this.energy < 0)
- {
- this.energy = 0;
- }
- }
-
- /* IEnergyStorage */
- @Override
- public int receiveEnergy(int maxReceive, boolean simulate)
- {
-
- final int energyReceived = Math.min(capacity - energy, Math.min(this.maxReceive, maxReceive));
-
- if(!simulate)
- {
- energy += energyReceived;
- }
- return energyReceived;
- }
-
- @Override
- public int extractEnergy(int maxExtract, boolean simulate)
- {
-
- final int energyExtracted = Math.min(energy, Math.min(this.maxExtract, maxExtract));
-
- if(!simulate)
- {
- energy -= energyExtracted;
- }
- return energyExtracted;
- }
-
- @Override
- public int getEnergyStored()
- {
-
- return energy;
- }
-
- @Override
- public int getMaxEnergyStored()
- {
-
- return capacity;
- }
-
-}
diff --git a/src/api/java/cofh/api/energy/IEnergyConnection.java b/src/api/java/cofh/api/energy/IEnergyConnection.java
deleted file mode 100644
index a1fad46..0000000
--- a/src/api/java/cofh/api/energy/IEnergyConnection.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package cofh.api.energy;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Implement this interface on TileEntities which should connect to energy transportation blocks. This is intended for blocks which generate energy but do not
- * accept it; otherwise just use IEnergyHandler.
- * <p>
- * Note that {@link IEnergyHandler} is an extension of this.
- *
- * @author King Lemming
- *
- */
-public interface IEnergyConnection
-{
-
- /**
- * Returns TRUE if the TileEntity can connect on a given side.
- */
- boolean canConnectEnergy(ForgeDirection from);
-
-}
diff --git a/src/api/java/cofh/api/energy/IEnergyContainerItem.java b/src/api/java/cofh/api/energy/IEnergyContainerItem.java
deleted file mode 100644
index 43a570b..0000000
--- a/src/api/java/cofh/api/energy/IEnergyContainerItem.java
+++ /dev/null
@@ -1,53 +0,0 @@
-package cofh.api.energy;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Implement this interface on Item classes that support external manipulation of their internal energy storages.
- * <p>
- * A reference implementation is provided {@link ItemEnergyContainer}.
- *
- * @author King Lemming
- *
- */
-public interface IEnergyContainerItem
-{
-
- /**
- * Adds energy to a container item. Returns the quantity of energy that was accepted. This should always return 0 if the item cannot be externally charged.
- *
- * @param container
- * ItemStack to be charged.
- * @param maxReceive
- * Maximum amount of energy to be sent into the item.
- * @param simulate
- * If TRUE, the charge will only be simulated.
- * @return Amount of energy that was (or would have been, if simulated) received by the item.
- */
- int receiveEnergy(ItemStack container, int maxReceive, boolean simulate);
-
- /**
- * Removes energy from a container item. Returns the quantity of energy that was removed. This should always return 0 if the item cannot be externally
- * discharged.
- *
- * @param container
- * ItemStack to be discharged.
- * @param maxExtract
- * Maximum amount of energy to be extracted from the item.
- * @param simulate
- * If TRUE, the discharge will only be simulated.
- * @return Amount of energy that was (or would have been, if simulated) extracted from the item.
- */
- int extractEnergy(ItemStack container, int maxExtract, boolean simulate);
-
- /**
- * Get the amount of energy currently stored in the container item.
- */
- int getEnergyStored(ItemStack container);
-
- /**
- * Get the max amount of energy that can be stored in the container item.
- */
- int getMaxEnergyStored(ItemStack container);
-
-}
diff --git a/src/api/java/cofh/api/energy/IEnergyHandler.java b/src/api/java/cofh/api/energy/IEnergyHandler.java
deleted file mode 100644
index ea6d8fa..0000000
--- a/src/api/java/cofh/api/energy/IEnergyHandler.java
+++ /dev/null
@@ -1,58 +0,0 @@
-package cofh.api.energy;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Implement this interface on Tile Entities which should handle energy, generally storing it in one or more internal {@link IEnergyStorage} objects.
- * <p>
- * A reference implementation is provided {@link TileEnergyHandler}.
- *
- * @author King Lemming
- *
- */
-public interface IEnergyHandler extends IEnergyProvider, IEnergyReceiver
-{
-
- // merely a convenience interface (remove these methods in 1.8; provided here for back-compat via compiler doing things)
-
- /**
- * Add energy to an IEnergyReceiver, internal distribution is left entirely to the IEnergyReceiver.
- *
- * @param from
- * Orientation the energy is received from.
- * @param maxReceive
- * Maximum amount of energy to receive.
- * @param simulate
- * If TRUE, the charge will only be simulated.
- * @return Amount of energy that was (or would have been, if simulated) received.
- */
- @Override
- int receiveEnergy(ForgeDirection from, int maxReceive, boolean simulate);
-
- /**
- * Remove energy from an IEnergyProvider, internal distribution is left entirely to the IEnergyProvider.
- *
- * @param from
- * Orientation the energy is extracted from.
- * @param maxExtract
- * Maximum amount of energy to extract.
- * @param simulate
- * If TRUE, the extraction will only be simulated.
- * @return Amount of energy that was (or would have been, if simulated) extracted.
- */
- @Override
- int extractEnergy(ForgeDirection from, int maxExtract, boolean simulate);
-
- /**
- * Returns the amount of energy currently stored.
- */
- @Override
- int getEnergyStored(ForgeDirection from);
-
- /**
- * Returns the maximum amount of energy that can be stored.
- */
- @Override
- int getMaxEnergyStored(ForgeDirection from);
-
-}
diff --git a/src/api/java/cofh/api/energy/IEnergyProvider.java b/src/api/java/cofh/api/energy/IEnergyProvider.java
deleted file mode 100644
index 0437e11..0000000
--- a/src/api/java/cofh/api/energy/IEnergyProvider.java
+++ /dev/null
@@ -1,39 +0,0 @@
-package cofh.api.energy;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Implement this interface on Tile Entities which should provide energy, generally storing it in one or more internal {@link IEnergyStorage} objects.
- * <p>
- * A reference implementation is provided {@link TileEnergyHandler}.
- *
- * @author King Lemming
- *
- */
-public interface IEnergyProvider extends IEnergyConnection
-{
-
- /**
- * Remove energy from an IEnergyProvider, internal distribution is left entirely to the IEnergyProvider.
- *
- * @param from
- * Orientation the energy is extracted from.
- * @param maxExtract
- * Maximum amount of energy to extract.
- * @param simulate
- * If TRUE, the extraction will only be simulated.
- * @return Amount of energy that was (or would have been, if simulated) extracted.
- */
- int extractEnergy(ForgeDirection from, int maxExtract, boolean simulate);
-
- /**
- * Returns the amount of energy currently stored.
- */
- int getEnergyStored(ForgeDirection from);
-
- /**
- * Returns the maximum amount of energy that can be stored.
- */
- int getMaxEnergyStored(ForgeDirection from);
-
-}
diff --git a/src/api/java/cofh/api/energy/IEnergyReceiver.java b/src/api/java/cofh/api/energy/IEnergyReceiver.java
deleted file mode 100644
index 226e61d..0000000
--- a/src/api/java/cofh/api/energy/IEnergyReceiver.java
+++ /dev/null
@@ -1,39 +0,0 @@
-package cofh.api.energy;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Implement this interface on Tile Entities which should receive energy, generally storing it in one or more internal {@link IEnergyStorage} objects.
- * <p>
- * A reference implementation is provided {@link TileEnergyHandler}.
- *
- * @author King Lemming
- *
- */
-public interface IEnergyReceiver extends IEnergyConnection
-{
-
- /**
- * Add energy to an IEnergyReceiver, internal distribution is left entirely to the IEnergyReceiver.
- *
- * @param from
- * Orientation the energy is received from.
- * @param maxReceive
- * Maximum amount of energy to receive.
- * @param simulate
- * If TRUE, the charge will only be simulated.
- * @return Amount of energy that was (or would have been, if simulated) received.
- */
- int receiveEnergy(ForgeDirection from, int maxReceive, boolean simulate);
-
- /**
- * Returns the amount of energy currently stored.
- */
- int getEnergyStored(ForgeDirection from);
-
- /**
- * Returns the maximum amount of energy that can be stored.
- */
- int getMaxEnergyStored(ForgeDirection from);
-
-}
diff --git a/src/api/java/cofh/api/energy/IEnergyStorage.java b/src/api/java/cofh/api/energy/IEnergyStorage.java
deleted file mode 100644
index 4ea5935..0000000
--- a/src/api/java/cofh/api/energy/IEnergyStorage.java
+++ /dev/null
@@ -1,47 +0,0 @@
-package cofh.api.energy;
-
-/**
- * An energy storage is the unit of interaction with Energy inventories.<br>
- * This is not to be implemented on TileEntities. This is for internal use only.
- * <p>
- * A reference implementation can be found at {@link EnergyStorage}.
- *
- * @author King Lemming
- *
- */
-public interface IEnergyStorage
-{
-
- /**
- * Adds energy to the storage. Returns quantity of energy that was accepted.
- *
- * @param maxReceive
- * Maximum amount of energy to be inserted.
- * @param simulate
- * If TRUE, the insertion will only be simulated.
- * @return Amount of energy that was (or would have been, if simulated) accepted by the storage.
- */
- int receiveEnergy(int maxReceive, boolean simulate);
-
- /**
- * Removes energy from the storage. Returns quantity of energy that was removed.
- *
- * @param maxExtract
- * Maximum amount of energy to be extracted.
- * @param simulate
- * If TRUE, the extraction will only be simulated.
- * @return Amount of energy that was (or would have been, if simulated) extracted from the storage.
- */
- int extractEnergy(int maxExtract, boolean simulate);
-
- /**
- * Returns the amount of energy currently stored.
- */
- int getEnergyStored();
-
- /**
- * Returns the maximum amount of energy that can be stored.
- */
- int getMaxEnergyStored();
-
-}
diff --git a/src/api/java/cofh/api/energy/ItemEnergyContainer.java b/src/api/java/cofh/api/energy/ItemEnergyContainer.java
deleted file mode 100644
index 3e8e4fb..0000000
--- a/src/api/java/cofh/api/energy/ItemEnergyContainer.java
+++ /dev/null
@@ -1,128 +0,0 @@
-package cofh.api.energy;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-
-/**
- * Reference implementation of {@link IEnergyContainerItem}. Use/extend this or implement your own.
- *
- * @author King Lemming
- *
- */
-public class ItemEnergyContainer extends Item implements IEnergyContainerItem
-{
-
- protected int capacity;
- protected int maxReceive;
- protected int maxExtract;
-
- public ItemEnergyContainer()
- {
-
- }
-
- public ItemEnergyContainer(int capacity)
- {
-
- this(capacity, capacity, capacity);
- }
-
- public ItemEnergyContainer(int capacity, int maxTransfer)
- {
-
- this(capacity, maxTransfer, maxTransfer);
- }
-
- public ItemEnergyContainer(int capacity, int maxReceive, int maxExtract)
- {
-
- this.capacity = capacity;
- this.maxReceive = maxReceive;
- this.maxExtract = maxExtract;
- }
-
- public ItemEnergyContainer setCapacity(int capacity)
- {
-
- this.capacity = capacity;
- return this;
- }
-
- public void setMaxTransfer(int maxTransfer)
- {
-
- setMaxReceive(maxTransfer);
- setMaxExtract(maxTransfer);
- }
-
- public void setMaxReceive(int maxReceive)
- {
-
- this.maxReceive = maxReceive;
- }
-
- public void setMaxExtract(int maxExtract)
- {
-
- this.maxExtract = maxExtract;
- }
-
- /* IEnergyContainerItem */
- @Override
- public int receiveEnergy(ItemStack container, int maxReceive, boolean simulate)
- {
-
- if(container.stackTagCompound == null)
- {
- container.stackTagCompound = new NBTTagCompound();
- }
- int energy = container.stackTagCompound.getInteger("Energy");
- final int energyReceived = Math.min(capacity - energy, Math.min(this.maxReceive, maxReceive));
-
- if(!simulate)
- {
- energy += energyReceived;
- container.stackTagCompound.setInteger("Energy", energy);
- }
- return energyReceived;
- }
-
- @Override
- public int extractEnergy(ItemStack container, int maxExtract, boolean simulate)
- {
-
- if(container.stackTagCompound == null || !container.stackTagCompound.hasKey("Energy"))
- {
- return 0;
- }
- int energy = container.stackTagCompound.getInteger("Energy");
- final int energyExtracted = Math.min(energy, Math.min(this.maxExtract, maxExtract));
-
- if(!simulate)
- {
- energy -= energyExtracted;
- container.stackTagCompound.setInteger("Energy", energy);
- }
- return energyExtracted;
- }
-
- @Override
- public int getEnergyStored(ItemStack container)
- {
-
- if(container.stackTagCompound == null || !container.stackTagCompound.hasKey("Energy"))
- {
- return 0;
- }
- return container.stackTagCompound.getInteger("Energy");
- }
-
- @Override
- public int getMaxEnergyStored(ItemStack container)
- {
-
- return capacity;
- }
-
-}
diff --git a/src/api/java/cofh/api/energy/TileEnergyHandler.java b/src/api/java/cofh/api/energy/TileEnergyHandler.java
deleted file mode 100644
index b50940b..0000000
--- a/src/api/java/cofh/api/energy/TileEnergyHandler.java
+++ /dev/null
@@ -1,73 +0,0 @@
-package cofh.api.energy;
-
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Reference implementation of {@link IEnergyHandler}. Use/extend this or implement your own.
- *
- * @author King Lemming
- *
- */
-public class TileEnergyHandler extends TileEntity implements IEnergyHandler
-{
-
- protected EnergyStorage storage = new EnergyStorage(32000);
-
- @Override
- public void readFromNBT(NBTTagCompound nbt)
- {
-
- super.readFromNBT(nbt);
- storage.readFromNBT(nbt);
- }
-
- @Override
- public void writeToNBT(NBTTagCompound nbt)
- {
-
- super.writeToNBT(nbt);
- storage.writeToNBT(nbt);
- }
-
- /* IEnergyConnection */
- @Override
- public boolean canConnectEnergy(ForgeDirection from)
- {
-
- return true;
- }
-
- /* IEnergyReceiver */
- @Override
- public int receiveEnergy(ForgeDirection from, int maxReceive, boolean simulate)
- {
-
- return storage.receiveEnergy(maxReceive, simulate);
- }
-
- /* IEnergyProvider */
- @Override
- public int extractEnergy(ForgeDirection from, int maxExtract, boolean simulate)
- {
-
- return storage.extractEnergy(maxExtract, simulate);
- }
-
- /* IEnergyReceiver and IEnergyProvider */
- @Override
- public int getEnergyStored(ForgeDirection from)
- {
-
- return storage.getEnergyStored();
- }
-
- @Override
- public int getMaxEnergyStored(ForgeDirection from)
- {
-
- return storage.getMaxEnergyStored();
- }
-
-}
diff --git a/src/api/java/cofh/api/item/IToolHammer.java b/src/api/java/cofh/api/item/IToolHammer.java
deleted file mode 100644
index efa5d07..0000000
--- a/src/api/java/cofh/api/item/IToolHammer.java
+++ /dev/null
@@ -1,45 +0,0 @@
-package cofh.api.item;
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.item.ItemStack;
-
-/**
- * Implement this interface on subclasses of Item to have that item work as a tool for CoFH mods.
- */
-public interface IToolHammer
-{
-
- /**
- * Called to ensure that the tool can be used.
- *
- * @param item
- * The itemstack for the tool. Not required to match equipped item (e.g., multi-tools that contain other tools)
- * @param user
- * The entity using the tool
- * @param x
- * X location of the block/tile
- * @param y
- * Y location of the block/tile
- * @param z
- * Z location of the block/tile
- * @return True if this tool can be used
- */
- boolean isUsable(ItemStack item, EntityLivingBase user, int x, int y, int z);
-
- /**
- * Callback for when the tool has been used reactively.
- *
- * @param item
- * The ItemStack for the tool. Not required to match equipped item (e.g., multi-tools that contain other tools)
- * @param user
- * The entity using the tool
- * @param x
- * X location of the block/tile
- * @param y
- * Y location of the block/tile
- * @param z
- * Z location of the block/tile
- */
- void toolUsed(ItemStack item, EntityLivingBase user, int x, int y, int z);
-
-}
diff --git a/src/api/java/cofh/core/item/IEqualityOverrideItem.java b/src/api/java/cofh/core/item/IEqualityOverrideItem.java
deleted file mode 100644
index e09423e..0000000
--- a/src/api/java/cofh/core/item/IEqualityOverrideItem.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package cofh.core.item;
-
-import net.minecraft.item.ItemStack;
-
-public interface IEqualityOverrideItem
-{
-
- public boolean isLastHeldItemEqual(ItemStack current, ItemStack previous);
-
-}
diff --git a/src/api/java/cofh/lib/util/helpers/BlockHelper.java b/src/api/java/cofh/lib/util/helpers/BlockHelper.java
deleted file mode 100644
index 3b06035..0000000
--- a/src/api/java/cofh/lib/util/helpers/BlockHelper.java
+++ /dev/null
@@ -1,650 +0,0 @@
-package cofh.lib.util.helpers;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.Vec3;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Contains various helper functions to assist with {@link Block} and Block-related manipulation and interaction.
- *
- * @author King Lemming
- *
- */
-public final class BlockHelper
-{
-
- private BlockHelper()
- {
-
- }
-
- public static int MAX_ID = 1024;
- public static byte[] rotateType = new byte[MAX_ID];
- public static final int[][] SIDE_COORD_MOD = { {0, -1, 0}, {0, 1, 0}, {0, 0, -1}, {0, 0, 1}, {-1, 0, 0}, {1, 0, 0}};
- public static float[][] SIDE_COORD_AABB = { {1, -2, 1}, {1, 2, 1}, {1, 1, 1}, {1, 1, 2}, {1, 1, 1}, {2, 1, 1}};
- public static final byte[] SIDE_LEFT = {4, 5, 5, 4, 2, 3};
- public static final byte[] SIDE_RIGHT = {5, 4, 4, 5, 3, 2};
- public static final byte[] SIDE_OPPOSITE = {1, 0, 3, 2, 5, 4};
- public static final byte[] SIDE_ABOVE = {3, 2, 1, 1, 1, 1};
- public static final byte[] SIDE_BELOW = {2, 3, 0, 0, 0, 0};
-
- // These assume facing is towards negative - looking AT side 1, 3, or 5.
- public static final byte[] ROTATE_CLOCK_Y = {0, 1, 4, 5, 3, 2};
- public static final byte[] ROTATE_CLOCK_Z = {5, 4, 2, 3, 0, 1};
- public static final byte[] ROTATE_CLOCK_X = {2, 3, 1, 0, 4, 5};
-
- public static final byte[] ROTATE_COUNTER_Y = {0, 1, 5, 4, 2, 3};
- public static final byte[] ROTATE_COUNTER_Z = {4, 5, 2, 3, 1, 0};
- public static final byte[] ROTATE_COUNTER_X = {3, 2, 0, 1, 4, 5};
-
- public static final byte[] INVERT_AROUND_Y = {0, 1, 3, 2, 5, 4};
- public static final byte[] INVERT_AROUND_Z = {1, 0, 2, 3, 5, 4};
- public static final byte[] INVERT_AROUND_X = {1, 0, 3, 2, 4, 5};
-
- // Map which gives relative Icon to use on a block which can be placed on any side.
- public static final byte[][] ICON_ROTATION_MAP = new byte[6][];
-
- static
- {
- ICON_ROTATION_MAP[0] = new byte[] {0, 1, 2, 3, 4, 5};
- ICON_ROTATION_MAP[1] = new byte[] {1, 0, 2, 3, 4, 5};
- ICON_ROTATION_MAP[2] = new byte[] {3, 2, 0, 1, 4, 5};
- ICON_ROTATION_MAP[3] = new byte[] {3, 2, 1, 0, 5, 4};
- ICON_ROTATION_MAP[4] = new byte[] {3, 2, 5, 4, 0, 1};
- ICON_ROTATION_MAP[5] = new byte[] {3, 2, 4, 5, 1, 0};
- }
-
- public static final class RotationType
- {
-
- public static final int PREVENT = -1;
- public static final int FOUR_WAY = 1;
- public static final int SIX_WAY = 2;
- public static final int RAIL = 3;
- public static final int PUMPKIN = 4;
- public static final int STAIRS = 5;
- public static final int REDSTONE = 6;
- public static final int LOG = 7;
- public static final int SLAB = 8;
- public static final int CHEST = 9;
- public static final int LEVER = 10;
- public static final int SIGN = 11;
- }
-
- static
- { // TODO: review which of these can be removed in favor of the vanilla handler
- rotateType[Block.getIdFromBlock(Blocks.bed)] = RotationType.PREVENT;
-
- rotateType[Block.getIdFromBlock(Blocks.stone_slab)] = RotationType.SLAB;
- rotateType[Block.getIdFromBlock(Blocks.wooden_slab)] = RotationType.SLAB;
-
- rotateType[Block.getIdFromBlock(Blocks.rail)] = RotationType.RAIL;
- rotateType[Block.getIdFromBlock(Blocks.golden_rail)] = RotationType.RAIL;
- rotateType[Block.getIdFromBlock(Blocks.detector_rail)] = RotationType.RAIL;
- rotateType[Block.getIdFromBlock(Blocks.activator_rail)] = RotationType.RAIL;
-
- rotateType[Block.getIdFromBlock(Blocks.pumpkin)] = RotationType.PUMPKIN;
- rotateType[Block.getIdFromBlock(Blocks.lit_pumpkin)] = RotationType.PUMPKIN;
-
- rotateType[Block.getIdFromBlock(Blocks.furnace)] = RotationType.FOUR_WAY;
- rotateType[Block.getIdFromBlock(Blocks.lit_furnace)] = RotationType.FOUR_WAY;
- rotateType[Block.getIdFromBlock(Blocks.ender_chest)] = RotationType.FOUR_WAY;
-
- rotateType[Block.getIdFromBlock(Blocks.trapped_chest)] = RotationType.CHEST;
- rotateType[Block.getIdFromBlock(Blocks.chest)] = RotationType.CHEST;
-
- rotateType[Block.getIdFromBlock(Blocks.dispenser)] = RotationType.SIX_WAY;
- rotateType[Block.getIdFromBlock(Blocks.sticky_piston)] = RotationType.SIX_WAY;
- rotateType[Block.getIdFromBlock(Blocks.piston)] = RotationType.SIX_WAY;
- rotateType[Block.getIdFromBlock(Blocks.hopper)] = RotationType.SIX_WAY;
- rotateType[Block.getIdFromBlock(Blocks.dropper)] = RotationType.SIX_WAY;
-
- rotateType[Block.getIdFromBlock(Blocks.unpowered_repeater)] = RotationType.REDSTONE;
- rotateType[Block.getIdFromBlock(Blocks.unpowered_comparator)] = RotationType.REDSTONE;
- rotateType[Block.getIdFromBlock(Blocks.powered_repeater)] = RotationType.REDSTONE;
- rotateType[Block.getIdFromBlock(Blocks.powered_comparator)] = RotationType.REDSTONE;
-
- rotateType[Block.getIdFromBlock(Blocks.lever)] = RotationType.LEVER;
-
- rotateType[Block.getIdFromBlock(Blocks.standing_sign)] = RotationType.SIGN;
-
- rotateType[Block.getIdFromBlock(Blocks.oak_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.stone_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.brick_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.stone_brick_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.nether_brick_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.sandstone_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.spruce_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.birch_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.jungle_stairs)] = RotationType.STAIRS;
- rotateType[Block.getIdFromBlock(Blocks.quartz_stairs)] = RotationType.STAIRS;
- }
-
- public static int getMicroBlockAngle(int side, float hitX, float hitY, float hitZ)
- {
-
- int direction = side ^ 1;
- final float degreeCenter = 0.32f / 2;
-
- float x = 0, y = 0;
- switch(side >> 1)
- {
- case 0:
- x = hitX;
- y = hitZ;
- break;
- case 1:
- x = hitX;
- y = hitY;
- break;
- case 2:
- x = hitY;
- y = hitZ;
- break;
- }
- x -= .5f;
- y -= .5f;
-
- if(x * x + y * y > degreeCenter * degreeCenter)
- {
-
- int a = (int) ((Math.atan2(x, y) + Math.PI) * 4 / Math.PI);
- a = ++a & 7;
- switch(a >> 1)
- {
- case 0:
- case 4:
- direction = 2;
- break;
- case 1:
- direction = 4;
- break;
- case 2:
- direction = 3;
- break;
- case 3:
- direction = 5;
- break;
- }
- }
- return direction;
- }
-
- public static ForgeDirection getMicroBlockAngle(ForgeDirection side, float hitX, float hitY, float hitZ)
- {
-
- return ForgeDirection.VALID_DIRECTIONS[getMicroBlockAngle(side.ordinal(), hitX, hitY, hitZ)];
- }
-
- public static int getHighestY(World world, int x, int z)
- {
-
- return world.getChunkFromBlockCoords(x, z).getTopFilledSegment() + 16;
- }
-
- public static int getSurfaceBlockY(World world, int x, int z)
- {
-
- int y = world.getChunkFromBlockCoords(x, z).getTopFilledSegment() + 16;
-
- Block block;
- do
- {
- if(--y < 0)
- {
- break;
- }
- block = world.getBlock(x, y, z);
- }
- while(block.isAir(world, x, y, z) || block.isReplaceable(world, x, y, z) || block.isLeaves(world, x, y, z) || block.isFoliage(world, x, y, z) || block.canBeReplacedByLeaves(world, x, y, z));
- return y;
- }
-
- public static int getTopBlockY(World world, int x, int z)
- {
-
- int y = world.getChunkFromBlockCoords(x, z).getTopFilledSegment() + 16;
-
- Block block;
- do
- {
- if(--y < 0)
- {
- break;
- }
- block = world.getBlock(x, y, z);
- }
- while(block.isAir(world, x, y, z));
- return y;
- }
-
- public static MovingObjectPosition getCurrentMovingObjectPosition(EntityPlayer player, double distance, boolean fluid)
- {
-
- final Vec3 posVec = Vec3.createVectorHelper(player.posX, player.posY, player.posZ);
- Vec3 lookVec = player.getLook(1);
- posVec.yCoord += player.getEyeHeight();
- lookVec = posVec.addVector(lookVec.xCoord * distance, lookVec.yCoord * distance, lookVec.zCoord * distance);
- return player.worldObj.rayTraceBlocks(posVec, lookVec, fluid);
- }
-
- public static MovingObjectPosition getCurrentMovingObjectPosition(EntityPlayer player, double distance)
- {
-
- return getCurrentMovingObjectPosition(player, distance, false);
- }
-
- public static MovingObjectPosition getCurrentMovingObjectPosition(EntityPlayer player, boolean fluid)
- {
-
- return getCurrentMovingObjectPosition(player, player.capabilities.isCreativeMode ? 5.0F : 4.5F, fluid);
- }
-
- public static MovingObjectPosition getCurrentMovingObjectPosition(EntityPlayer player)
- {
-
- return getCurrentMovingObjectPosition(player, player.capabilities.isCreativeMode ? 5.0F : 4.5F, false);
- }
-
- public static int getCurrentMousedOverSide(EntityPlayer player)
- {
-
- final MovingObjectPosition mouseOver = getCurrentMovingObjectPosition(player);
- return mouseOver == null ? 0 : mouseOver.sideHit;
- }
-
- public static int determineXZPlaceFacing(EntityLivingBase living)
- {
-
- final int quadrant = MathHelper.floor_double(living.rotationYaw * 4.0F / 360.0F + 0.5D) & 3;
-
- switch(quadrant)
- {
- case 0:
- return 2;
- case 1:
- return 5;
- case 2:
- return 3;
- case 3:
- return 4;
- }
- return 3;
- }
-
- public static boolean isEqual(Block blockA, Block blockB)
- {
-
- if(blockA == blockB)
- {
- return true;
- }
- if(blockA == null | blockB == null)
- {
- return false;
- }
- return blockA.equals(blockB) || blockA.isAssociatedBlock(blockB);
- }
-
- /* UNSAFE Tile Entity Retrieval */
- // public static TileEntity getAdjacentTileEntityUnsafe(World world, int x, int y, int z, ForgeDirection dir) {
- //
- // if (world == null) {
- // return null;
- // }
- // Chunk chunk = world.getChunkFromBlockCoords(x + dir.offsetX, z + dir.offsetZ);
- // return chunk == null ? null : chunk.getChunkBlockTileEntityUnsafe((x + dir.offsetX) & 0xF, y + dir.offsetY, (z + dir.offsetZ) & 0xF);
- // }
- //
- // public static TileEntity getAdjacentTileEntityUnsafe(World world, int x, int y, int z, int side) {
- //
- // return world == null ? null : getAdjacentTileEntityUnsafe(world, x, y, z, ForgeDirection.values()[side]);
- // }
- //
- // public static TileEntity getAdjacentTileEntityUnsafe(TileEntity refTile, ForgeDirection dir) {
- //
- // return refTile == null ? null : getAdjacentTileEntityUnsafe(refTile.worldObj, refTile.xCoord, refTile.yCoord, refTile.zCoord, dir);
- // }
- //
- // public static TileEntity getAdjacentTileEntityUnsafe(TileEntity refTile, int side) {
- //
- // return refTile == null ? null : getAdjacentTileEntityUnsafe(refTile.worldObj, refTile.xCoord, refTile.yCoord, refTile.zCoord,
- // ForgeDirection.values()[side]);
- // }
-
- public static Block getAdjacentBlock(World world, int x, int y, int z, ForgeDirection dir)
- {
-
- x += dir.offsetX;
- y += dir.offsetY;
- z += dir.offsetZ;
- return world == null || !world.blockExists(x, y, z) ? Blocks.air : world.getBlock(x, y, z);
- }
-
- public static Block getAdjacentBlock(World world, int x, int y, int z, int side)
- {
-
- return world == null ? Blocks.air : getAdjacentBlock(world, x, y, z, ForgeDirection.getOrientation(side));
- }
-
- /* Safe Tile Entity Retrieval */
- public static TileEntity getAdjacentTileEntity(World world, int x, int y, int z, ForgeDirection dir)
- {
-
- x += dir.offsetX;
- y += dir.offsetY;
- z += dir.offsetZ;
- return world == null || !world.blockExists(x, y, z) ? null : world.getTileEntity(x, y, z);
- }
-
- public static TileEntity getAdjacentTileEntity(World world, int x, int y, int z, int side)
- {
-
- return world == null ? null : getAdjacentTileEntity(world, x, y, z, ForgeDirection.getOrientation(side));
- }
-
- public static TileEntity getAdjacentTileEntity(TileEntity refTile, ForgeDirection dir)
- {
-
- return refTile == null ? null : getAdjacentTileEntity(refTile.getWorldObj(), refTile.xCoord, refTile.yCoord, refTile.zCoord, dir);
- }
-
- public static TileEntity getAdjacentTileEntity(TileEntity refTile, int side)
- {
-
- return refTile == null ? null : getAdjacentTileEntity(refTile.getWorldObj(), refTile.xCoord, refTile.yCoord, refTile.zCoord, ForgeDirection.values()[side]);
- }
-
- public static int determineAdjacentSide(TileEntity refTile, int x, int y, int z)
- {
-
- return y > refTile.yCoord ? 1 : y < refTile.yCoord ? 0 : z > refTile.zCoord ? 3 : z < refTile.zCoord ? 2 : x > refTile.xCoord ? 5 : 4;
- }
-
- /* COORDINATE TRANSFORM */
- public static int[] getAdjacentCoordinatesForSide(MovingObjectPosition pos)
- {
-
- return getAdjacentCoordinatesForSide(pos.blockX, pos.blockY, pos.blockZ, pos.sideHit);
- }
-
- public static int[] getAdjacentCoordinatesForSide(int x, int y, int z, int side)
- {
-
- return new int[] {x + SIDE_COORD_MOD[side][0], y + SIDE_COORD_MOD[side][1], z + SIDE_COORD_MOD[side][2]};
- }
-
- public static AxisAlignedBB getAdjacentAABBForSide(MovingObjectPosition pos)
- {
-
- return getAdjacentAABBForSide(pos.blockX, pos.blockY, pos.blockZ, pos.sideHit);
- }
-
- public static AxisAlignedBB getAdjacentAABBForSide(int x, int y, int z, int side)
- {
-
- return AxisAlignedBB.getBoundingBox(x + SIDE_COORD_MOD[side][0], y + SIDE_COORD_MOD[side][1], z + SIDE_COORD_MOD[side][2], x + SIDE_COORD_AABB[side][0], y + SIDE_COORD_AABB[side][1], z + SIDE_COORD_AABB[side][2]);
- }
-
- public static int getLeftSide(int side)
- {
-
- return SIDE_LEFT[side];
- }
-
- public static int getRightSide(int side)
- {
-
- return SIDE_RIGHT[side];
- }
-
- public static int getOppositeSide(int side)
- {
-
- return SIDE_OPPOSITE[side];
- }
-
- public static int getAboveSide(int side)
- {
-
- return SIDE_ABOVE[side];
- }
-
- public static int getBelowSide(int side)
- {
-
- return SIDE_BELOW[side];
- }
-
- /* BLOCK ROTATION */
- public static boolean canRotate(Block block)
- {
-
- final int bId = Block.getIdFromBlock(block);
- return bId < MAX_ID ? rotateType[Block.getIdFromBlock(block)] != 0 : false;
- }
-
- public static int rotateVanillaBlock(World world, Block block, int x, int y, int z)
- {
-
- final int bId = Block.getIdFromBlock(block);
- int bMeta = world.getBlockMetadata(x, y, z);
- switch(rotateType[bId])
- {
- case RotationType.FOUR_WAY:
- return SIDE_LEFT[bMeta];
- case RotationType.SIX_WAY:
- if(bMeta < 6)
- {
- return ++bMeta % 6;
- }
- return bMeta;
- case RotationType.RAIL:
- if(bMeta < 2)
- {
- return ++bMeta % 2;
- }
- return bMeta;
- case RotationType.PUMPKIN:
- return ++bMeta % 4;
- case RotationType.STAIRS:
- return ++bMeta % 8;
- case RotationType.REDSTONE:
- final int upper = bMeta & 0xC;
- int lower = bMeta & 0x3;
- return upper + ++lower % 4;
- case RotationType.LOG:
- return (bMeta + 4) % 12;
- case RotationType.SLAB:
- return (bMeta + 8) % 16;
- case RotationType.CHEST:
- int coords[] = new int[3];
- for(int i = 2; i < 6; i++)
- {
- coords = getAdjacentCoordinatesForSide(x, y, z, i);
- if(isEqual(world.getBlock(coords[0], coords[1], coords[2]), block))
- {
- world.setBlockMetadataWithNotify(coords[0], coords[1], coords[2], SIDE_OPPOSITE[bMeta], 1);
- return SIDE_OPPOSITE[bMeta];
- }
- }
- return SIDE_LEFT[bMeta];
- case RotationType.LEVER:
- int shift = 0;
- if(bMeta > 7)
- {
- bMeta -= 8;
- shift = 8;
- }
- if(bMeta == 5)
- {
- return 6 + shift;
- }
- else if(bMeta == 6)
- {
- return 5 + shift;
- }
- else if(bMeta == 7)
- {
- return 0 + shift;
- }
- else if(bMeta == 0)
- {
- return 7 + shift;
- }
- return bMeta + shift;
- case RotationType.SIGN:
- return ++bMeta % 16;
- case RotationType.PREVENT:
- default:
- return bMeta;
- }
- }
-
- public static int rotateVanillaBlockAlt(World world, Block block, int x, int y, int z)
- {
-
- final int bId = Block.getIdFromBlock(block);
- int bMeta = world.getBlockMetadata(x, y, z);
- switch(rotateType[bId])
- {
- case RotationType.FOUR_WAY:
- return SIDE_RIGHT[bMeta];
- case RotationType.SIX_WAY:
- if(bMeta < 6)
- {
- return (bMeta + 5) % 6;
- }
- return bMeta;
- case RotationType.RAIL:
- if(bMeta < 2)
- {
- return ++bMeta % 2;
- }
- return bMeta;
- case RotationType.PUMPKIN:
- return (bMeta + 3) % 4;
- case RotationType.STAIRS:
- return (bMeta + 7) % 8;
- case RotationType.REDSTONE:
- final int upper = bMeta & 0xC;
- final int lower = bMeta & 0x3;
- return upper + (lower + 3) % 4;
- case RotationType.LOG:
- return (bMeta + 8) % 12;
- case RotationType.SLAB:
- return (bMeta + 8) % 16;
- case RotationType.CHEST:
- int coords[] = new int[3];
- for(int i = 2; i < 6; i++)
- {
- coords = getAdjacentCoordinatesForSide(x, y, z, i);
- if(isEqual(world.getBlock(coords[0], coords[1], coords[2]), block))
- {
- world.setBlockMetadataWithNotify(coords[0], coords[1], coords[2], SIDE_OPPOSITE[bMeta], 1);
- return SIDE_OPPOSITE[bMeta];
- }
- }
- return SIDE_RIGHT[bMeta];
- case RotationType.LEVER:
- int shift = 0;
- if(bMeta > 7)
- {
- bMeta -= 8;
- shift = 8;
- }
- if(bMeta == 5)
- {
- return 6 + shift;
- }
- else if(bMeta == 6)
- {
- return 5 + shift;
- }
- else if(bMeta == 7)
- {
- return 0 + shift;
- }
- else if(bMeta == 0)
- {
- return 7 + shift;
- }
- case RotationType.SIGN:
- return ++bMeta % 16;
- case RotationType.PREVENT:
- default:
- return bMeta;
- }
- }
-
- public static List<ItemStack> breakBlock(World worldObj, int x, int y, int z, Block block, int fortune, boolean doBreak, boolean silkTouch)
- {
-
- return breakBlock(worldObj, null, x, y, z, block, fortune, doBreak, silkTouch);
- }
-
- public static List<ItemStack> breakBlock(World worldObj, EntityPlayer player, int x, int y, int z, Block block, int fortune, boolean doBreak, boolean silkTouch)
- {
-
- if(block.getBlockHardness(worldObj, x, y, z) == -1)
- {
- return new LinkedList<ItemStack>();
- }
- final int meta = worldObj.getBlockMetadata(x, y, z);
- List<ItemStack> stacks = null;
- if(silkTouch && block.canSilkHarvest(worldObj, player, x, y, z, meta))
- {
- stacks = new LinkedList<ItemStack>();
- stacks.add(createStackedBlock(block, meta));
- }
- else
- {
- stacks = block.getDrops(worldObj, x, y, z, meta, fortune);
- }
- if(!doBreak)
- {
- return stacks;
- }
- worldObj.playAuxSFXAtEntity(player, 2001, x, y, z, Block.getIdFromBlock(block) + (meta << 12));
- worldObj.setBlockToAir(x, y, z);
-
- final List<EntityItem> result = worldObj.getEntitiesWithinAABB(EntityItem.class, AxisAlignedBB.getBoundingBox(x - 2, y - 2, z - 2, x + 3, y + 3, z + 3));
- for(int i = 0; i < result.size(); i++)
- {
- final EntityItem entity = result.get(i);
- if(entity.isDead || entity.getEntityItem().stackSize <= 0)
- {
- continue;
- }
- stacks.add(entity.getEntityItem());
- entity.worldObj.removeEntity(entity);
- }
- return stacks;
- }
-
- public static ItemStack createStackedBlock(Block block, int bMeta)
- {
-
- final Item item = Item.getItemFromBlock(block);
- if(item.getHasSubtypes())
- {
- return new ItemStack(item, 1, bMeta);
- }
- return new ItemStack(item, 1, 0);
- }
-
-}
diff --git a/src/api/java/dynamicswordskills/api/ISword.java b/src/api/java/dynamicswordskills/api/ISword.java
deleted file mode 100644
index 9d81357..0000000
--- a/src/api/java/dynamicswordskills/api/ISword.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/**
- Copyright (C) <2015> <coolAlias>
- This file is part of coolAlias' Dynamic Sword Skills Minecraft Mod; as such,
- you can redistribute it and/or modify it under the terms of the GNU
- General Public License as published by the Free Software Foundation,
- either version 3 of the License, or (at your option) any later version.
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-
-package dynamicswordskills.api;
-
-/**
- *
- * For the purpose of using certain skills, this item will be considered a sword.
- *
- * Skills which require a sword are:
- * {@link LeapingBlow}, {@link MortalDraw}, and {@link RisingCut}
- *
- */
-public interface ISword
-{
-
-}
diff --git a/src/api/java/exterminatorJeff/undergroundBiomes/api/UBAPIHook.java b/src/api/java/exterminatorJeff/undergroundBiomes/api/UBAPIHook.java
deleted file mode 100644
index b917269..0000000
--- a/src/api/java/exterminatorJeff/undergroundBiomes/api/UBAPIHook.java
+++ /dev/null
@@ -1,12 +0,0 @@
-package exterminatorJeff.undergroundBiomes.api;
-
-/**
- * Striped down version, get the full API from here: https://github.com/Zeno410/UndergroundBiomes1.7API
- * @author Zeno410
- */
-public class UBAPIHook
-{
- public static final UBAPIHook ubAPIHook = new UBAPIHook();
- //public UBDimensionalStrataColumnProvider dimensionalStrataColumnProvider; // set in the main Underground Biomes
- public UBOreTexturizer ubOreTexturizer;
-}
diff --git a/src/api/java/exterminatorJeff/undergroundBiomes/api/UBOreTexturizer.java b/src/api/java/exterminatorJeff/undergroundBiomes/api/UBOreTexturizer.java
deleted file mode 100644
index 2b9b6de..0000000
--- a/src/api/java/exterminatorJeff/undergroundBiomes/api/UBOreTexturizer.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * To change this template, choose Tools | Templates
- * and open the template in the editor.
- */
-
-package exterminatorJeff.undergroundBiomes.api;
-
-import net.minecraft.block.Block;
-import net.minecraft.world.World;
-import cpw.mods.fml.common.event.FMLPreInitializationEvent;
-
-/**
- * Striped down version, get the full API from here: https://github.com/Zeno410/UndergroundBiomes1.7API
- * This is an interface for the class that can create Underground Biomes versions of arbitary ores
- * It creates three new blocks for each texturized ore.
- * @author Zeno410
- */
-public interface UBOreTexturizer
-{
- // usage: Block is the ore block.
- // Overlay name is the fully qualified name, e.g. modname:overlayName
- // that static vars are fully qualified names for all the textures in the UB pack, just pass as is
- // the event isn't needed per se, but if this is called anytime else, the blocks will not "stick"
- public void setupUBOre(Block oreBlock, String overlayName, FMLPreInitializationEvent event);
-
- public void setupUBOre(Block oreBlock, int metadata, String overlayName, FMLPreInitializationEvent event);
-
- public void setupUBOre(Block oreBlock, int metadata, String overlayName, String blockName, FMLPreInitializationEvent event);
-
- public void requestUBOreSetup(Block oreBlock, String overlayName) throws BlocksAreAlreadySet;
-
- public void requestUBOreSetup(Block oreBlock, int metadata, String overlayName) throws BlocksAreAlreadySet;
-
- public void requestUBOreSetup(Block oreBlock, int metadata, String overlayName, String blockName) throws BlocksAreAlreadySet;
-
- public void redoOres(int xInBlockCoordinates, int zInBlockCoordinates, World serverSideWorld);
-
- public static String amber_overlay = "undergroundbiomes:amber_overlay";
- public static String cinnabar_overlay = "undergroundbiomes:cinnabar_overlay";
- public static String coal_overlay = "undergroundbiomes:coal_overlay";
- public static String copper_overlay = "undergroundbiomes:copper_overlay";
- public static String diamond_overlay = "undergroundbiomes:diamond_overlay";
- public static String emerald_overlay = "undergroundbiomes:emerald_overlay";
- public static String gold_overlay = "undergroundbiomes:gold_overlay";
- public static String iron_overlay = "undergroundbiomes:iron_overlay";
- public static String lapis_overlay = "undergroundbiomes:lapis_overlay";
- public static String lead_overlay = "undergroundbiomes:lead_overlay";
- public static String olivine_peridot_overlay = "undergroundbiomes:olivine-peridot_overlay";
- public static String redstone_overlay = "undergroundbiomes:redstone_overlay";
- public static String ruby_overlay = "undergroundbiomes:ruby_overlay";
- public static String sapphire_overlay = "undergroundbiomes:sapphire_overlay";
- public static String tin_overlay = "undergroundbiomes:tin_overlay";
- public static String uranium_overlay = "undergroundbiomes:uranium_overlay";
-
- public class BlocksAreAlreadySet extends RuntimeException
- {
- // this is thrown if UB has already run its pre-initialization step and can no longer register blocks
- public final Block oreBlock;
- public final String overlayName;
-
- public BlocksAreAlreadySet(Block oreBlock, String overlayName)
- {
- this.oreBlock = oreBlock;
- this.overlayName = overlayName;
- }
-
- @Override
- public String toString()
- {
- String blockDescription = "undefined block";
- String overlayDescription = "undefined overlay";
- if(oreBlock != null)
- {
- blockDescription = oreBlock.getUnlocalizedName();
- }
- if(overlayName != null)
- {
- overlayDescription = overlayName;
- }
- return "Attempt to create Underground Biomes ore for " + blockDescription + " with " + overlayDescription + " after blocks have already been defined";
- }
-
- }
-}
diff --git a/src/api/java/ic2/api/Direction.java b/src/api/java/ic2/api/Direction.java
deleted file mode 100644
index ce0f077..0000000
--- a/src/api/java/ic2/api/Direction.java
+++ /dev/null
@@ -1,151 +0,0 @@
-package ic2.api;
-
-import java.util.EnumSet;
-import java.util.Set;
-
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Represents the 6 possible directions along the axis of a block.
- */
-public enum Direction
-{
- /**
- * -X
- */
- XN,
- /**
- * +X
- */
- XP,
-
- /**
- * -Y
- */
- YN, //MC-Code starts with 0 here
- /**
- * +Y
- */
- YP, // 1...
-
- /**
- * -Z
- */
- ZN,
- /**
- * +Z
- */
- ZP;
-
- private Direction()
- {
- final int side = ordinal() / 2;
- final int sign = getSign();
-
- xOffset = side == 0 ? sign : 0;
- yOffset = side == 1 ? sign : 0;
- zOffset = side == 2 ? sign : 0;
- }
-
- public static Direction fromSideValue(int side)
- {
- return directions[(side + 2) % 6];
- }
-
- public static Direction fromForgeDirection(ForgeDirection dir)
- {
- if(dir == ForgeDirection.UNKNOWN)
- {
- return null;
- }
-
- return fromSideValue(dir.ordinal());
- }
-
- /**
- * Get the tile entity next to a tile entity following this direction.
- *
- * @param tileEntity tile entity to check
- * @return Adjacent tile entity or null if none exists
- */
- public TileEntity applyToTileEntity(TileEntity te)
- {
- return applyTo(te.getWorldObj(), te.xCoord, te.yCoord, te.zCoord);
- }
-
- /**
- * Get the tile entity next to a position following this direction.
- *
- * @param world World to check
- * @param x X coordinate to check from
- * @param y Y coordinate to check from
- * @param z Z coordinate to check from
- * @return Adjacent tile entity or null if none exists
- */
- public TileEntity applyTo(World world, int x, int y, int z)
- {
- final int coords[] = {x, y, z};
-
- coords[ordinal() / 2] += getSign();
-
- if(world != null && world.blockExists(coords[0], coords[1], coords[2]))
- {
- try
- {
- return world.getTileEntity(coords[0], coords[1], coords[2]);
- }
- catch(final Exception e)
- {
- throw new RuntimeException(
- "error getting TileEntity at dim " + world.provider.dimensionId + " " + coords[0] + "/" + coords[1] + "/" + coords[2]);
- }
- }
-
- return null;
- }
-
- /**
- * Get the inverse of this direction (XN -> XP, XP -> XN, etc.)
- *
- * @return Inverse direction
- */
- public Direction getInverse()
- {
- return directions[ordinal() ^ 1];
- }
-
- /**
- * Convert this direction to a Minecraft side value.
- *
- * @return Minecraft side value
- */
- public int toSideValue()
- {
- return (ordinal() + 4) % 6;
- }
-
- /**
- * Determine direction sign (N for negative or P for positive).
- *
- * @return -1 if the direction is negative, +1 if the direction is positive
- */
- private int getSign()
- {
- return (ordinal() % 2) * 2 - 1;
- }
-
- public ForgeDirection toForgeDirection()
- {
- return ForgeDirection.getOrientation(toSideValue());
- }
-
- public final int xOffset;
- public final int yOffset;
- public final int zOffset;
-
- public static final Direction[] directions = Direction.values();
- public static final Set<Direction> noDirections = EnumSet.noneOf(Direction.class);
- public static final Set<Direction> allDirections = EnumSet.allOf(Direction.class);
-}
diff --git a/src/api/java/ic2/api/crops/BaseSeed.java b/src/api/java/ic2/api/crops/BaseSeed.java
deleted file mode 100644
index a7b55f6..0000000
--- a/src/api/java/ic2/api/crops/BaseSeed.java
+++ /dev/null
@@ -1,88 +0,0 @@
-package ic2.api.crops;
-
-/**
- * Base agriculture seed. Used to determine the state of a plant once it is planted from an item.
- */
-public class BaseSeed
-{
- /**
- * Create a BaseSeed object.
- *
- * @param crop plant
- * @param size plant size
- * @param statGrowth1 plant growth stat
- * @param statGain1 plant gain stat
- * @param statResistance1 plant resistance stat
- * @param stackSize1 for internal usage only
- */
- @SuppressWarnings("deprecation")
- public BaseSeed(CropCard crop, int size, int statGrowth, int statGain, int statResistance, int stackSize)
- {
- super();
- this.crop = crop;
- id = Crops.instance.getIdFor(crop);
- this.size = size;
- this.statGrowth = statGrowth;
- this.statGain = statGain;
- this.statResistance = statResistance;
- this.stackSize = stackSize;
- }
-
- /**
- * @deprecated Use the CropCard version.
- */
- @Deprecated
- public BaseSeed(int id, int size, int statGrowth, int statGain, int statResistance, int stackSize)
- {
- this(getCropFromId(id), size, statGrowth, statGain, statResistance, stackSize);
- }
-
- @SuppressWarnings("deprecation")
- private static CropCard getCropFromId(int id)
- {
- final CropCard[] crops = Crops.instance.getCropList();
-
- if(id < 0 || id >= crops.length)
- {
- return null;
- }
-
- return crops[id];
- }
-
- /**
- * Plant.
- */
- public final CropCard crop;
-
- /**
- * @deprecated IDs aren't used anymore.
- */
- @Deprecated
- public int id;
-
- /**
- * Plant size.
- */
- public int size;
-
- /**
- * Plant growth stat.
- */
- public int statGrowth;
-
- /**
- * Plant gain stat.
- */
- public int statGain;
-
- /**
- * Plant resistance stat.
- */
- public int statResistance;
-
- /**
- * For internal usage only.
- */
- public int stackSize;
-}
diff --git a/src/api/java/ic2/api/crops/CropCard.java b/src/api/java/ic2/api/crops/CropCard.java
deleted file mode 100644
index e2a16d8..0000000
--- a/src/api/java/ic2/api/crops/CropCard.java
+++ /dev/null
@@ -1,491 +0,0 @@
-package ic2.api.crops;
-
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import cpw.mods.fml.common.Loader;
-import cpw.mods.fml.common.ModContainer;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-/**
- * Base agriculture crop.
- *
- * Any crop extending this can be registered using registerCrop to be added into the game.
- */
-public abstract class CropCard
-{
- public CropCard()
- {
- modId = getModId(); // initialize mod id while we should be in the real owner's init event
- }
-
- /**
- * Plant name for identifying this crop within your mod.
- *
- * The name has to be unique within the mod and is used for saving.
- * By default this name will be also used to determine displayKey() and registerSprites().
- *
- * @note changing name or owner will cause existing crops in users' worlds to disappear.
- *
- * @return Plant name
- */
- public abstract String name();
-
- /**
- * Determine the mod id owning this crop.
- *
- * The owner serves as a name space. With every mod using a different owner, a mod only has to
- * make sure it doesn't have conflicts with name() in itself.
- * It's recommended to hard code this to your mod id as specified in the @Mod annotation.
- * Do not use IC2's mod id here.
- *
- * @note changing name or owner will cause existing crops in users' worlds to disappear.
- *
- * @return Mod id.
- */
- public String owner()
- { // TODO: make abstract
- return modId;
- }
-
- /**
- * Translation key for display to the player.
- *
- * It's highly recommended to specify a valid key from your language file here, e.g. add
- * "yourmod.crop.yourCropName = Your crop's name" to the language file, override name() to
- * return "yourCropName" and override displayName() to return "yourmod.crop."+name().
- *
- * @return Unlocalized name.
- */
- public String displayName()
- {
- return name(); // return the raw name for backwards compatibility
- }
-
- /**
- * Your name here, will be shown in "Discovered by:" when analyzing seeds.
- *
- * @return Your name
- */
- public String discoveredBy()
- {
- return "unknown";
- }
-
- /**
- * Description of your plant. Keep it short, a few characters per line for up to two lines.
- * Default is showing attributes of your plant, 2 per line.
- *
- * @param i line to get, starting from 0
- * @return The line
- */
- public String desc(int i)
- {
- final String[] att = attributes();
-
- if(att == null || att.length == 0)
- {
- return "";
- }
-
- if(i == 0)
- {
- String s = att[0];
- if(att.length >= 2)
- {
- s += ", " + att[1];
- if(att.length >= 3)
- {
- s += ",";
- }
- }
- return s;
- }
- if(att.length < 3)
- {
- return "";
- }
- String s = att[2];
- if(att.length >= 4)
- {
- s += ", " + att[3];
- }
- return s;
- }
-
- /**
- * *
- * @param crop reference to ICropTile
- * @return roots lengt use in isBlockBelow
- */
- public int getrootslength(ICropTile crop)
- { // TODO: camel case
- return 1;
- }
-
- /**
- * Tier of the plant. Ranges from 1 to 16, 0 is Weed.
- * Valuable and powerful crops have higher tiers, useless and weak ones have lower tiers.
- *
- * @return Tier
- */
- public abstract int tier();
-
- /**
- * Describe the plant through a set of stats, influencing breeding.
- * Plants sharing stats and attributes will tend to cross-breed more often.
- *
- * Stats:
- * - 0: Chemistry (Industrial uses based on chemical plant components)
- * - 1: Consumable (Food, potion ingredients, stuff meant to be eaten or similarly used)
- * - 2: Defensive (Plants with defense capabilities (damaging, explosive, chemical) or special abilities in general)
- * - 3: Colorful (How colorful/aesthetically/beautiful is the plant, like dye-plants or plants without actual effects)
- * - 4: Weed (Is this plant weed-like and rather unwanted/quick-spreading? Rare super-breed plants should have low values here)
- *
- * @param n index of the requested stat
- * @return The requested value of the stats
- */
- public abstract int stat(int n); // TODO: change to fixed property object or builder with other attributes like tier
-
- /**
- * Additional attributes of the plant, also influencing breeding.
- * Plants sharing stats and attributes will tend to cross-breed more often.
- *
- * @return Attributes as an array of strings
- */
- public abstract String[] attributes(); // TODO: default to none
-
- /**
- * Determine the max crop size.
- *
- * Currently only used for texture allocation.
- */
- public abstract int maxSize();
-
- /**
- * Instantiate your Icons here.
- *
- * This method will get called by IC2, don't call it yourself.
- *
- * It's highly recommended to use your own assert domain here, e.g. yourmod:crop/* instead of
- * ic2:crop/*, which will then read assets/yourmod/textures/blocks/crop/*.png.
- */
- @SideOnly(Side.CLIENT)
- public void registerSprites(IIconRegister iconRegister)
- {
- textures = new IIcon[maxSize()];
-
- for(int i = 1; i <= textures.length; i++)
- {
- // ic2:crop/blockCrop.NAME.n is the legacy name for backwards compatiblity
- textures[i - 1] = iconRegister.registerIcon("ic2:crop/blockCrop." + name() + "." + i);
- }
- }
-
- /**
- * Sprite the crop is meant to be rendered with.
- *
- * @param crop reference to ICropTile
- * @return 0-255, representing the sprite index on the crop's spritesheet.
- */
- @SideOnly(Side.CLIENT)
- public IIcon getSprite(ICropTile crop)
- {
- if(crop.getSize() <= 0 || crop.getSize() > textures.length)
- {
- return null;
- }
-
- return textures[crop.getSize() - 1];
- }
-
- /**
- * Amount of growth points needed to increase the plant's size.
- * Default is 200 * tier.
- */
- public int growthDuration(ICropTile crop)
- {
- return tier() * 200;
- }
-
- /**
- * Check whether the plant can grow further.
- *
- * Consider:
- * - Humidity, nutrients and air quality
- * - Current size
- * - Light level
- * - Special biomes or conditions, accessible through crop.worldObj
- *
- * This method will be called upon empty upgraded crops to check whether a neighboring plant can cross onto it! Don't check if the size is greater than 0 and if the ID is real.
- *
- * @param crop reference to ICropTile
- * @return Whether the crop can grow
- */
- public abstract boolean canGrow(ICropTile crop);
-
- /**
- * Calculate the influence for the plant to grow based on humidity, nutrients and air.
- * Normal behavior is rating the three stats "normal", with each of them ranging from 0-30.
- * Basic rule: Assume everything returns 10. All together must equal 30. Add the factors to your likings, for example (humidity*0.7)+(nutrients*0.9)+(air*1.4)
- *
- * Default is humidity + nutrients + air (no factors).
- *
- * @param crop reference to ICropTile
- * @param humidity ground humidity, influenced by hydration
- * @param nutrients nutrient quality in ground, based on fertilizers
- * @param air air quality, influences by open gardens and less crops surrounding this one
- * @return 0-30
- */
- public int weightInfluences(ICropTile crop, float humidity, float nutrients, float air)
- {
- return (int) (humidity + nutrients + air);
- }
-
- /**
- * Used to determine whether the plant can crossbreed with another crop.
- * Default is allow crossbreeding if the size is greater or equal than 3.
- *
- * @param crop crop to crossbreed with
- */
- public boolean canCross(ICropTile crop)
- {
- return crop.getSize() >= 3;
- }
-
- /**
- * Called when the plant is rightclicked by a player.
- * Default action is harvesting.
- *
- * Only called Serverside.
- *
- * @param crop reference to ICropTile
- * @param player player rightclicking the crop
- * @return Whether the plant has changed
- */
- public boolean rightclick(ICropTile crop, EntityPlayer player)
- {
- return crop.harvest(true);
- }
-
- /**
- * Use in Crop Havester with insert Cropnalyzer to get best Output.
- *
- * @param crop reference to ICropTile
- * @return need crop size for best output.
- */
-
- public abstract int getOptimalHavestSize(ICropTile crop); // TODO: default to maxSize
-
- /**
- * Check whether the crop can be harvested.
- *
- * @param crop reference to ICropTile
- * @return Whether the crop can be harvested in its current state.
- */
- public abstract boolean canBeHarvested(ICropTile crop); // TODO: default to maxSize check
-
- /**
- * Base chance for dropping the plant's gains, specify values greater than 1 for multiple drops.
- * Default is 0.95^tier.
- *
- * @return Chance to drop the gains
- */
- public float dropGainChance()
- { // TODO: change to double
- return (float) Math.pow(0.95, tier());
- }
-
- /**
- * Item obtained from harvesting the plant.
- *
- * @param crop reference to ICropTile
- * @return Item obtained
- */
- public abstract ItemStack getGain(ICropTile crop);
-
- /**
- * Get the size of the plant after harvesting.
- * Default is 1.
- *
- * @param crop reference to ICropTile
- * @return Plant size after harvesting
- */
- public byte getSizeAfterHarvest(ICropTile crop)
- {
- return 1;
- } // TODO: change to int
-
- /**
- * Called when the plant is left clicked by a player.
- * Default action is picking the plant.
- *
- * Only called server side.
- *
- * @param crop reference to ICropTile
- * @param player player left clicked the crop
- * @return Whether the plant has changed
- */
- public boolean leftclick(ICropTile crop, EntityPlayer player)
- { // TODO: camel case
- return crop.pick(true);
- }
-
- /**
- * Base chance for dropping seeds when the plant is picked.
- * Default is 0.5*0.8^tier with a bigger chance for sizes greater than 2 and absolutely no chance for size 0.
- *
- * @param crop reference to ICropTile
- * @return Chance to drop the seeds
- */
- public float dropSeedChance(ICropTile crop)
- {
- if(crop.getSize() == 1)
- {
- return 0;
- }
- float base = 0.5F;
- if(crop.getSize() == 2)
- {
- base /= 2F;
- }
- for(int i = 0; i < tier(); i++)
- {
- base *= 0.8;
- }
- return base;
- }
-
- /**
- * Obtain seeds dropped when the plant is picked.
- * Multiple drops of the returned ItemStack can occur.
- * Default action is generating a seed from this crop.
- *
- * @param crop reference to ICropTile
- * @return Seeds
- */
- public ItemStack getSeeds(ICropTile crop)
- {
- return crop.generateSeeds(crop.getCrop(), crop.getGrowth(), crop.getGain(), crop.getResistance(), crop.getScanLevel());
- }
-
- /**
- * Called when a neighbor block to the crop has changed.
- *
- * @param crop reference to ICropTile
- */
- public void onNeighbourChange(ICropTile crop)
- {
- //
- }
-
- /**
- * Check if the crop should emit redstone.
- *
- * @return Whether the crop should emit redstone
- */
- public int emitRedstone(ICropTile crop)
- {
- return 0;
- }
-
- /**
- * Called when the crop is destroyed.
- *
- * @param crop reference to ICropTile
- */
- public void onBlockDestroyed(ICropTile crop)
- {
- //
- }
-
- /**
- * Get the light value emitted by the plant.
- *
- * @param crop reference to ICropTile
- * @return Light value emitted
- */
- public int getEmittedLight(ICropTile crop)
- {
- return 0;
- }
-
- /**
- * Default is true if the entity is an EntityLiving in jumping or sprinting state.
- *
- * @param crop reference to ICropTile
- * @param entity entity colliding
- * @return Whether trampling calculation should happen, return false if the plant is no longer valid.
- */
- public boolean onEntityCollision(ICropTile crop, Entity entity)
- {
- if(entity instanceof EntityLivingBase)
- {
- return ((EntityLivingBase) entity).isSprinting();
- }
-
- return false;
- }
-
- /**
- * Called every time the crop ticks.
- * Should be called every 256 ticks or around 13 seconds.
- *
- * @param crop reference to ICropTile
- */
- public void tick(ICropTile crop)
- {
- // nothing by default
- }
-
- /**
- * Check whether this plant spreads weed to surrounding tiles.
- * Default is true if the plant has a high growth stat (or is weeds) and size greater or equal than 2.
- *
- * @param crop reference to ICropTile
- * @return Whether the plant spreads weed
- */
- public boolean isWeed(ICropTile crop)
- {
- return crop.getSize() >= 2 && (crop.getCrop() == Crops.weed || crop.getGrowth() >= 24);
- }
-
- /**
- * Get this plant's ID.
- *
- * @return ID of this CropCard or -1 if it's not registered
- * @deprecated IDs aren't used anymore.
- */
- @Deprecated
- public final int getId()
- {
- return Crops.instance.getIdFor(this);
- }
-
- private static String getModId()
- {
- final ModContainer modContainer = Loader.instance().activeModContainer();
-
- if(modContainer != null)
- {
- return modContainer.getModId();
- }
- else
- {
- // this is bad if you are not actually IC2
- assert false;
-
- return "unknown";
- }
- }
-
- @SideOnly(Side.CLIENT)
- protected IIcon textures[];
-
- private final String modId; // TODO: make owner abstract, remove modId auto detection
- // TODO: add a clean way to obtain world reference and position
-}
diff --git a/src/api/java/ic2/api/crops/Crops.java b/src/api/java/ic2/api/crops/Crops.java
deleted file mode 100644
index c6f0745..0000000
--- a/src/api/java/ic2/api/crops/Crops.java
+++ /dev/null
@@ -1,149 +0,0 @@
-package ic2.api.crops;
-
-import java.util.Collection;
-
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.biome.BiomeGenBase;
-import net.minecraftforge.common.BiomeDictionary.Type;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-/**
- * General management of the crop system.
- */
-public abstract class Crops
-{
- public static Crops instance;
-
- public static CropCard weed; // weed has special properties, thus it's exposed here
-
- /**
- * Adds a crop nutrient biome bonus.
- *
- * +10/-10 0 indicates no bonus and negative values indicate a penalty.
- *
- * @param type Forge biome type to apply the bonus in
- * @param nutrientsBonus Nutrient stat bonus
- */
- public abstract void addBiomenutrientsBonus(Type type, int nutrientsBonus);
-
- /**
- * Adds a crop humidity biome bonus.
- *
- * +10/-10 0 indicates no bonus and negative values indicate a penalty.
- *
- * @param type Forge biome type to apply the bonus in
- * @param humidityBonus Humidity stat bonus
- */
- public abstract void addBiomehumidityBonus(Type type, int humidityBonus);
-
- /**
- * Gets the humidity bonus for a biome.
- *
- * @param biome Biome to check
- * @return Humidity bonus or 0 if none
- */
- public abstract int getHumidityBiomeBonus(BiomeGenBase biome);
-
- /**
- * Gets the nutrient bonus for a biome.
- *
- * @param biome Biome to check
- * @return Nutrient bonus or 0 if none
- */
- public abstract int getNutrientBiomeBonus(BiomeGenBase biome);
-
- /**
- * Get the crop card for the specified owner and name.
- *
- * @param owner CropCard owner mod id.
- * @param name CropCard name.
- * @return Matching CropCard.
- */
- public abstract CropCard getCropCard(String owner, String name);
-
- /**
- * Get the crop card for the specified seed item stack.
- *
- * @param stack ItemStack containing seeds for the crop.
- * @return Matching CropCard.
- */
- public abstract CropCard getCropCard(ItemStack stack);
-
- /**
- * Returns a list of all crops.
- *
- * @return All registered crops.
- */
- public abstract Collection<CropCard> getCrops();
-
- /**
- * Returns the list of registered crops.
- *
- * @return Registered crops by ID
- */
- @Deprecated
- public abstract CropCard[] getCropList();
-
- /**
- * Register a plant.
- *
- * @param crop Plant to register.
- * @return Autoassigned id for legacy compatibility, TODO: change to void.
- */
- public abstract short registerCrop(CropCard crop);
-
- /**
- * Register a plant and provide a legacy id for migration.
- *
- * @param crop Plant to register.
- * @param legacyId ID previously used for this crop.
- * @return true, TODO: change to void.
- */
- public abstract boolean registerCrop(CropCard crop, int legacyId);
-
- /**
- * @deprecated use the CropCard version.
- */
- @Deprecated
- public abstract boolean registerBaseSeed(ItemStack stack, int id, int size, int growth, int gain, int resistance);
-
- /**
- * Registers a base seed, an item used to plant a crop.
- *
- * @param stack item
- * @param id plant ID
- * @param size initial size
- * @param growth initial growth stat
- * @param gain initial gain stat
- * @param resistance initial resistance stat
- * @return True if successful
- */
- public abstract boolean registerBaseSeed(ItemStack stack, CropCard crop, int size, int growth, int gain, int resistance);
-
- /**
- * Finds a base seed from the given item.
- *
- * @return Base seed or null if none found
- */
- public abstract BaseSeed getBaseSeed(ItemStack stack);
-
- /**
- * Execute registerSprites for all registered crop cards.
- *
- * This method will get called by IC2, don't call it yourself.
- */
- @SideOnly(Side.CLIENT)
- public abstract void startSpriteRegistration(IIconRegister iconRegister);
-
- /**
- * Returns the ID for the given crop.
- *
- * @param crop Crop to look up
- * @return ID, or -1 if not found
- * @deprecated IDs aren't used anymore.
- */
- @Deprecated
- public abstract int getIdFor(CropCard crop);
-}
diff --git a/src/api/java/ic2/api/crops/ICropTile.java b/src/api/java/ic2/api/crops/ICropTile.java
deleted file mode 100644
index 5ad2f6f..0000000
--- a/src/api/java/ic2/api/crops/ICropTile.java
+++ /dev/null
@@ -1,290 +0,0 @@
-package ic2.api.crops;
-
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.ChunkCoordinates;
-import net.minecraft.world.World;
-
-/**
- * Interface implemented by the crop tile entity.
- */
-public interface ICropTile
-{
- /**
- * Get the crop.
- *
- * @return CropCard, or null if there is no plant currently on the crop
- */
- public CropCard getCrop();
-
- /**
- * Set the crop.
- *
- * @param cropCard CropCard or null for no plant
- */
- public void setCrop(CropCard cropCard);
-
- /**
- * @deprecated IDs have been removed.
- */
- @Deprecated
- public short getID();
-
- /**
- * @deprecated IDs have been removed.
- */
- @Deprecated
- public void setID(short id);
-
- /**
- * Get the crop's plant size.
- *
- * @return Plant size, starting with 1 and maximum varies depending on plant
- */
- public byte getSize();
-
- /**
- * Set the crop's plant size.
- *
- * @param size Plant size
- */
- public void setSize(byte size);
-
- /**
- * Get the crop's plant growth stat.
- * Higher values indicate faster growth.
- *
- * @return Plant growth stat
- */
- public byte getGrowth();
-
- /**
- * Set the crop's plant growth stat.
- *
- * @param growth Plant growth stat
- */
- public void setGrowth(byte growth);
-
- /**
- * Get the crop's plant gain stat.
- * Higher values indicate more drops.
- *
- * @return Plant gain stat
- */
- public byte getGain();
-
- /**
- * Set the crop's plant gain stat.
- *
- * @param gain Plant gain stat
- */
- public void setGain(byte gain);
-
- /**
- * Get the crop's plant resistance stat.
- * Higher values indicate more resistance against trampling.
- *
- * @return Plant resistance stat
- */
- public byte getResistance();
-
- /**
- * Set the crop's plant resistance stat.
- *
- * @param resistance Plant resistance stat
- */
- public void setResistance(byte resistance);
-
- /**
- * Get the crop's plant scan level.
- * Increases every time the seed is analyzed.
- *
- * @return Plant scan level
- */
- public byte getScanLevel();
-
- /**
- * Set the crop's plant scan level.
- *
- * @param scanLevel Plant scan level
- */
- public void setScanLevel(byte scanLevel);
-
- /**
- * Get the crop's plant custom data, stored alongside the crop.
- * Can be modified in place.
- *
- * @return Plant custom data
- */
- public NBTTagCompound getCustomData();
-
- /**
- * Get the crop's nutrient storage.
- * Ranges from 0 to 100.
- *
- * @return Crop nutrient storage
- */
- public int getNutrientStorage();
-
- /**
- * Set the crop's nutrient storage.
- *
- * @param nutrientStorage Crop nutrient storage
- */
- public void setNutrientStorage(int nutrientStorage);
-
- /**
- * Get the crop's hydration storage.
- * 0 indicates nothing, 1-10 indicate water hydration and 11-100 for hydration cells.
- *
- * @return Crop hydration storage
- */
- public int getHydrationStorage();
-
- /**
- * Set the crop's hydration storage.
- *
- * @param hydrationStorage Crop hydration storage
- */
- public void setHydrationStorage(int hydrationStorage);
-
- /**
- * Get the crop's Weed-Ex storage.
- *
- * @return Crop Weed-Ex storage
- */
- public int getWeedExStorage();
-
- /**
- * Set the crop's Weed-Ex storage.
- *
- * @param weedExStorage Crop Weed-Ex storage
- */
- public void setWeedExStorage(int weedExStorage);
-
- /**
- * Get the crop's humidity.
- * Ranges from 0 (dry) to 10 (humid).
- * Updates every couple of seconds or when an update is requested.
- *
- * @see #updateState()
- *
- * @return Crop humidity level
- */
- public byte getHumidity();
-
- /**
- * Get the crop's nutrient level.
- * Ranges from 0 (empty) to 10 (full).
- * Updates every couple of seconds or when an update is requested.
- *
- * @see #updateState()
- *
- * @return Crop nutrient level
- */
- public byte getNutrients();
-
- /**
- * Get the crop's air quality.
- * Ranges from 0 (cluttered) to 10 (fresh).
- * Updates every couple of seconds or when an update is requested.
- *
- * @see #updateState()
- *
- * @return Crop air quality
- */
- public byte getAirQuality();
-
- /**
- * Get the crop's world.
- *
- * @return Crop world
- */
- public World getWorld();
-
- /**
- * Get the crop's location.
- *
- * @return Crop location
- */
- public ChunkCoordinates getLocation();
-
- /**
- * Get the crop's light level.
- *
- * @return Crop light level
- */
- public int getLightLevel();
-
- /**
- * Pick the crop, removing and giving seeds for the plant.
- *
- * @param manual whether it was done by hand (not automated)
- * @return true if successfully picked
- */
- public boolean pick(boolean manual);
-
- /**
- * Harvest the crop, turning it into gain and resetting its size.
- * drop output on ground
- * @param manual
- * @return true if successfully harvested
- */
- public boolean harvest(boolean manual);
-
- /**
- * Harvest the crop, turning it into gain and resetting its size.
- * drop output on ground
- * @param Optimal force check getOptimalHavestSize() for harvest
- * @return ItemStack[] of harvest output
- */
-
- ItemStack[] harvest_automated(boolean Optimal);
-
- /**
- * Fully clears the crop without dropping anything.
- */
- public void reset();
-
- /**
- * Request a texture and lighting update.
- */
- public void updateState();
-
- /**
- * Check if a block is under the farmland containing the crop.
- * Searches up to 2 blocks below the farmland or an air space, whichever appears first.
- *
- * @param block block to search
- * @return Whether the block was found
- */
- public boolean isBlockBelow(Block block);
-
- /**
- * Check if a block is under the farmland containing the crop.
- * Searches up to 2 blocks below the farmland or an air space, whichever appears first.
- *
- * @param oreDictionaryName blocks to search
- * @return Whether the blocks were found
- */
- public boolean isBlockBelow(String oreDictionaryName);
-
- /**
- * Generate plant seeds with the given parameters.
- *
- * @param crop plant
- * @param growth plant growth stat
- * @param gain plant gain stat
- * @param resis plant resistance stat
- * @param scan plant scan level
- * @return Plant seed item
- */
- public ItemStack generateSeeds(CropCard crop, byte growth, byte gain, byte resis, byte scan);
-
- /**
- * @deprecated Use the CropCard version instead.
- */
- @Deprecated
- public ItemStack generateSeeds(short plant, byte growth, byte gain, byte resis, byte scan);
-}
diff --git a/src/api/java/ic2/api/crops/package-info.java b/src/api/java/ic2/api/crops/package-info.java
deleted file mode 100644
index 018003a..0000000
--- a/src/api/java/ic2/api/crops/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.crops;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/energy/EnergyNet.java b/src/api/java/ic2/api/energy/EnergyNet.java
deleted file mode 100644
index 05a2b59..0000000
--- a/src/api/java/ic2/api/energy/EnergyNet.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ic2.api.energy;
-
-/**
- * Provides access to the energy network.
- *
- * The old EnergyNet methods missing in IEnergyNet have been migrated to events (load, unload) or
- * removed (tiles no longer emit energy actively, the energy net implementation requests it).
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public final class EnergyNet
-{
- /**
- * Instance of the global EnergyNet class.
- */
- public static IEnergyNet instance;
-}
diff --git a/src/api/java/ic2/api/energy/IEnergyNet.java b/src/api/java/ic2/api/energy/IEnergyNet.java
deleted file mode 100644
index e3058ea..0000000
--- a/src/api/java/ic2/api/energy/IEnergyNet.java
+++ /dev/null
@@ -1,86 +0,0 @@
-package ic2.api.energy;
-
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Interface representing the methods provided by the global EnergyNet class.
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public interface IEnergyNet
-{
- /**
- * Get the EnergyNet-registered tile entity at the specified position.
- *
- * This is not the same as World.getTileEntity(), it's possible to register delegate tile
- * entities with the energy net which are different from what's actually in the world. Those
- * delegates allow to use separate TileEntity objects just for the EnergyNet interfaces,
- * simplifying cross-mod dependencies and multi-blocks.
- *
- * @param world World containing the tile entity
- * @param x x-coordinate
- * @param y y-coordinate
- * @param z z-coordinate
- * @return tile entity registered to the energy net or null if none is registered
- */
- TileEntity getTileEntity(World world, int x, int y, int z);
-
- /**
- * Get the EnergyNet-registered neighbor tile entity at the specified position.
- *
- * @param te TileEntity indicating the world and position to search from
- * @param dir direction the neighbor is to be found
- * @return neighbor tile entity registered to the energy net or null if none is registered
- */
- TileEntity getNeighbor(TileEntity te, ForgeDirection dir);
-
- /**
- * determine how much energy has been emitted by the EnergyEmitter specified
- *
- * @note call this twice with x ticks delay to get the avg. emitted power p = (call2 - call1) / x EU/tick
- *
- * @param tileEntity energy emitter
- * @deprecated Discontinued, use getNodeStats instead.
- */
- @Deprecated
- double getTotalEnergyEmitted(TileEntity tileEntity);
-
- /**
- * determine how much energy has been sunken by the EnergySink specified
- *
- * @note call this twice with x ticks delay to get the avg. sunken power p = (call2 - call1) / x EU/tick
- *
- * @param tileEntity energy emitter
- * @deprecated Discontinued, use getNodeStats instead.
- */
- @Deprecated
- double getTotalEnergySunken(TileEntity tileEntity);
-
- /**
- * Retrieve statistics for the tile entity specified.
- *
- * The statistics apply to the last simulated tick.
- *
- * @param te Tile entity to check.
- * @return Statistics for the tile entity.
- */
- NodeStats getNodeStats(TileEntity te);
-
- /**
- * Determine the typical power used by the specific tier, e.g. 128 eu/t for tier 2.
- *
- * @param tier tier
- * @return power in eu/t
- */
- double getPowerFromTier(int tier);
-
- /**
- * Determine minimum tier required to handle the specified power, e.g. tier 2 for 128 eu/t.
- *
- * @param power in eu/t
- * @return tier
- */
- int getTierFromPower(double power);
-}
diff --git a/src/api/java/ic2/api/energy/NodeStats.java b/src/api/java/ic2/api/energy/NodeStats.java
deleted file mode 100644
index e38b5e2..0000000
--- a/src/api/java/ic2/api/energy/NodeStats.java
+++ /dev/null
@@ -1,30 +0,0 @@
-package ic2.api.energy;
-
-public class NodeStats
-{
- public NodeStats(double energyIn, double energyOut, double voltage)
- {
- this.energyIn = energyIn;
- this.energyOut = energyOut;
- this.voltage = voltage;
- }
-
- public double getEnergyIn()
- {
- return energyIn;
- }
-
- public double getEnergyOut()
- {
- return energyOut;
- }
-
- public double getVoltage()
- {
- return voltage;
- }
-
- protected double energyIn;
- protected double energyOut;
- protected double voltage;
-}
diff --git a/src/api/java/ic2/api/energy/event/EnergyTileEvent.java b/src/api/java/ic2/api/energy/event/EnergyTileEvent.java
deleted file mode 100644
index 1fc04d3..0000000
--- a/src/api/java/ic2/api/energy/event/EnergyTileEvent.java
+++ /dev/null
@@ -1,27 +0,0 @@
-package ic2.api.energy.event;
-
-import ic2.api.energy.tile.IEnergyTile;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.event.world.WorldEvent;
-
-/**
- * Base class for energy net events, don't use it directly.
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public class EnergyTileEvent extends WorldEvent
-{
- public final IEnergyTile energyTile;
-
- public EnergyTileEvent(IEnergyTile energyTile1)
- {
- super(((TileEntity) energyTile1).getWorldObj());
-
- if(world == null)
- {
- throw new NullPointerException("world is null");
- }
-
- energyTile = energyTile1;
- }
-}
diff --git a/src/api/java/ic2/api/energy/event/EnergyTileLoadEvent.java b/src/api/java/ic2/api/energy/event/EnergyTileLoadEvent.java
deleted file mode 100644
index 62192f7..0000000
--- a/src/api/java/ic2/api/energy/event/EnergyTileLoadEvent.java
+++ /dev/null
@@ -1,27 +0,0 @@
-package ic2.api.energy.event;
-
-import ic2.api.energy.tile.IEnergyTile;
-
-/**
- * Event announcing new energy tiles.
- *
- * This event notifies subscribers of loaded energy tiles, e.g. after getting
- * loaded through the chunk they are in or after being placed down by the
- * player or another deployer mechanism.
- *
- * Every energy tile which wants to get connected to the IC2 Energy Network has
- * to either post this event or alternatively call EnergyNet.addTileEntity().
- *
- * You may use this event to build a static representation of energy tiles for
- * your own energy grid implementation if you need to. It's not required if you
- * always lookup energy paths on demand.
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public class EnergyTileLoadEvent extends EnergyTileEvent
-{
- public EnergyTileLoadEvent(IEnergyTile energyTile1)
- {
- super(energyTile1);
- }
-}
diff --git a/src/api/java/ic2/api/energy/event/EnergyTileUnloadEvent.java b/src/api/java/ic2/api/energy/event/EnergyTileUnloadEvent.java
deleted file mode 100644
index cf44877..0000000
--- a/src/api/java/ic2/api/energy/event/EnergyTileUnloadEvent.java
+++ /dev/null
@@ -1,28 +0,0 @@
-package ic2.api.energy.event;
-
-import ic2.api.energy.tile.IEnergyTile;
-
-/**
- * Event announcing terminated energy tiles.
- *
- * This event notifies subscribers of unloaded energy tiles, e.g. after getting
- * unloaded through the chunk they are in or after being destroyed by the
- * player or another block pick/destruction mechanism.
- *
- * Every energy tile which wants to get disconnected from the IC2 Energy
- * Network has to either post this event or alternatively call
- * EnergyNet.removeTileEntity().
- *
- * You may use this event to build a static representation of energy tiles for
- * your own energy grid implementation if you need to. It's not required if you
- * always lookup energy paths on demand.
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public class EnergyTileUnloadEvent extends EnergyTileEvent
-{
- public EnergyTileUnloadEvent(IEnergyTile energyTile1)
- {
- super(energyTile1);
- }
-}
diff --git a/src/api/java/ic2/api/energy/event/package-info.java b/src/api/java/ic2/api/energy/event/package-info.java
deleted file mode 100644
index de3bb9e..0000000
--- a/src/api/java/ic2/api/energy/event/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.energy.event;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/energy/package-info.java b/src/api/java/ic2/api/energy/package-info.java
deleted file mode 100644
index 0efa97f..0000000
--- a/src/api/java/ic2/api/energy/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.energy;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/energy/prefab/BasicSink.java b/src/api/java/ic2/api/energy/prefab/BasicSink.java
deleted file mode 100644
index 4b93858..0000000
--- a/src/api/java/ic2/api/energy/prefab/BasicSink.java
+++ /dev/null
@@ -1,410 +0,0 @@
-package ic2.api.energy.prefab;
-
-import ic2.api.energy.event.EnergyTileLoadEvent;
-import ic2.api.energy.event.EnergyTileUnloadEvent;
-import ic2.api.energy.tile.IEnergySink;
-import ic2.api.info.Info;
-import ic2.api.item.ElectricItem;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.common.util.ForgeDirection;
-import cpw.mods.fml.common.FMLCommonHandler;
-
-/**
- * BasicSink is a simple adapter to provide an ic2 energy sink.
- *
- * It's designed to be attached to a tile entity as a delegate. Functionally BasicSink acts as a
- * one-time configurable input energy buffer, thus providing a common use case for machines.
- *
- * Sub-classing BasicSink instead of using it as a delegate works as well, but isn't recommended.
- * The delegate can be extended with additional functionality through a sub class though.
- *
- * The constraints set by BasicSink like the strict tank-like energy buffering should provide a
- * more easy to use and stable interface than using IEnergySink directly while aiming for
- * optimal performance.
- *
- * Using BasicSink involves the following steps:
- * - create a BasicSink instance in your TileEntity, typically in a field
- * - forward invalidate, onChunkUnload, readFromNBT, writeToNBT and updateEntity to the BasicSink
- * instance.
- * If you have other means of determining when the tile entity is fully loaded, notify onLoaded
- * that way instead of forwarding updateEntity.
- * - call useEnergy whenever appropriate. canUseEnergy determines if enough energy is available
- * without consuming the energy.
- * - optionally use getEnergyStored to display the output buffer charge level
- * - optionally use setEnergyStored to sync the stored energy to the client (e.g. in the Container)
- *
- * Example implementation code:
- * @code{.java}
- * public class SomeTileEntity extends TileEntity {
- * // new basic energy sink, 1000 EU buffer, tier 1 (32 EU/t, LV)
- * private BasicSink ic2EnergySink = new BasicSink(this, 1000, 1);
- *
- * @Override
- * public void invalidate() {
- * ic2EnergySink.invalidate(); // notify the energy sink
- * ...
- * super.invalidate(); // this is important for mc!
- * }
- *
- * @Override
- * public void onChunkUnload() {
- * ic2EnergySink.onChunkUnload(); // notify the energy sink
- * ...
- * }
- *
- * @Override
- * public void readFromNBT(NBTTagCompound tag) {
- * super.readFromNBT(tag);
- *
- * ic2EnergySink.readFromNBT(tag);
- * ...
- * }
- *
- * @Override
- * public void writeToNBT(NBTTagCompound tag) {
- * super.writeToNBT(tag);
- *
- * ic2EnergySink.writeToNBT(tag);
- * ...
- * }
- *
- * @Override
- * public void updateEntity() {
- * ic2EnergySink.updateEntity(); // notify the energy sink
- * ...
- * if (ic2EnergySink.useEnergy(5)) { // use 5 eu from the sink's buffer this tick
- * ... // do something with the energy
- * }
- * ...
- * }
- *
- * ...
- * }
- * @endcode
- */
-public class BasicSink extends TileEntity implements IEnergySink
-{
- // **********************************
- // *** Methods for use by the mod ***
- // **********************************
-
- /**
- * Constructor for a new BasicSink delegate.
- *
- * @param parent1 TileEntity represented by this energy sink.
- * @param capacity1 Maximum amount of eu to store.
- * @param tier1 IC2 tier, 1 = LV, 2 = MV, ...
- */
- public BasicSink(TileEntity parent1, int capacity1, int tier1)
- {
- parent = parent1;
- capacity = capacity1;
- tier = tier1;
- }
-
- // in-world te forwards >>
-
- /**
- * Forward for the base TileEntity's updateEntity(), used for creating the energy net link.
- * Either updateEntity or onLoaded have to be used.
- */
- @Override
- public void updateEntity()
- {
- if(!addedToEnet)
- {
- onLoaded();
- }
- }
-
- /**
- * Notification that the base TileEntity finished loaded, for advanced uses.
- * Either updateEntity or onLoaded have to be used.
- */
- public void onLoaded()
- {
- if(!addedToEnet && !FMLCommonHandler.instance().getEffectiveSide().isClient() && Info.isIc2Available())
- {
- worldObj = parent.getWorldObj();
- xCoord = parent.xCoord;
- yCoord = parent.yCoord;
- zCoord = parent.zCoord;
-
- MinecraftForge.EVENT_BUS.post(new EnergyTileLoadEvent(this));
-
- addedToEnet = true;
- }
- }
-
- /**
- * Forward for the base TileEntity's invalidate(), used for destroying the energy net link.
- * Both invalidate and onChunkUnload have to be used.
- */
- @Override
- public void invalidate()
- {
- super.invalidate();
-
- onChunkUnload();
- }
-
- /**
- * Forward for the base TileEntity's onChunkUnload(), used for destroying the energy net link.
- * Both invalidate and onChunkUnload have to be used.
- */
- @Override
- public void onChunkUnload()
- {
- if(addedToEnet && Info.isIc2Available())
- {
- MinecraftForge.EVENT_BUS.post(new EnergyTileUnloadEvent(this));
-
- addedToEnet = false;
- }
- }
-
- /**
- * Forward for the base TileEntity's readFromNBT(), used for loading the state.
- *
- * @param tag Compound tag as supplied by TileEntity.readFromNBT()
- */
- @Override
- public void readFromNBT(NBTTagCompound tag)
- {
- super.readFromNBT(tag);
-
- final NBTTagCompound data = tag.getCompoundTag("IC2BasicSink");
-
- energyStored = data.getDouble("energy");
- }
-
- /**
- * Forward for the base TileEntity's writeToNBT(), used for saving the state.
- *
- * @param tag Compound tag as supplied by TileEntity.writeToNBT()
- */
- @Override
- public void writeToNBT(NBTTagCompound tag)
- {
- try
- {
- super.writeToNBT(tag);
- }
- catch(final RuntimeException e)
- {
- // happens if this is a delegate, ignore
- }
-
- final NBTTagCompound data = new NBTTagCompound();
-
- data.setDouble("energy", energyStored);
-
- tag.setTag("IC2BasicSink", data);
- }
-
- // << in-world te forwards
- // methods for using this adapter >>
-
- /**
- * Get the maximum amount of energy this sink can hold in its buffer.
- *
- * @return Capacity in EU.
- */
- public int getCapacity()
- {
- return capacity;
- }
-
- /**
- * Set the maximum amount of energy this sink can hold in its buffer.
- *
- * @param capacity1 Capacity in EU.
- */
- public void setCapacity(int capacity1)
- {
- capacity = capacity1;
- }
-
- /**
- * Get the IC2 energy tier for this sink.
- *
- * @return IC2 Tier.
- */
- public int getTier()
- {
- return tier;
- }
-
- /**
- * Set the IC2 energy tier for this sink.
- *
- * @param tier1 IC2 Tier.
- */
- public void setTier(int tier1)
- {
- tier = tier1;
- }
-
- /**
- * Determine the energy stored in the sink's input buffer.
- *
- * @return amount in EU, may be above capacity
- */
- public double getEnergyStored()
- {
- return energyStored;
- }
-
- /**
- * Set the stored energy to the specified amount.
- *
- * This is intended for server -> client synchronization, e.g. to display the stored energy in
- * a GUI through getEnergyStored().
- *
- * @param amount
- */
- public void setEnergyStored(double amount)
- {
- energyStored = amount;
- }
-
- /**
- * Determine if the specified amount of energy is available.
- *
- * @param amount in EU
- * @return true if the amount is available
- */
- public boolean canUseEnergy(double amount)
- {
- return energyStored >= amount;
- }
-
- /**
- * Use the specified amount of energy, if available.
- *
- * @param amount amount to use
- * @return true if the amount was available
- */
- public boolean useEnergy(double amount)
- {
- if(canUseEnergy(amount) && !FMLCommonHandler.instance().getEffectiveSide().isClient())
- {
- energyStored -= amount;
-
- return true;
- }
- return false;
- }
-
- /**
- * Discharge the supplied ItemStack into this sink's energy buffer.
- *
- * @param stack ItemStack to discharge (null is ignored)
- * @param limit Transfer limit, values <= 0 will use the battery's limit
- * @return true if energy was transferred
- */
- public boolean discharge(ItemStack stack, int limit)
- {
- if(stack == null || !Info.isIc2Available())
- {
- return false;
- }
-
- double amount = capacity - energyStored;
- if(amount <= 0)
- {
- return false;
- }
-
- if(limit > 0 && limit < amount)
- {
- amount = limit;
- }
-
- amount = ElectricItem.manager.discharge(stack, amount, tier, limit > 0, true, false);
-
- energyStored += amount;
-
- return amount > 0;
- }
-
- // << methods for using this adapter
-
- // backwards compatibility (ignore these) >>
-
- @Deprecated
- public void onUpdateEntity()
- {
- updateEntity();
- }
-
- @Deprecated
- public void onInvalidate()
- {
- invalidate();
- }
-
- @Deprecated
- public void onOnChunkUnload()
- {
- onChunkUnload();
- }
-
- @Deprecated
- public void onReadFromNbt(NBTTagCompound tag)
- {
- readFromNBT(tag);
- }
-
- @Deprecated
- public void onWriteToNbt(NBTTagCompound tag)
- {
- writeToNBT(tag);
- }
-
- // << backwards compatibility
-
- // ******************************
- // *** Methods for use by ic2 ***
- // ******************************
-
- // energy net interface >>
-
- @Override
- public boolean acceptsEnergyFrom(TileEntity emitter, ForgeDirection direction)
- {
- return true;
- }
-
- @Override
- public double getDemandedEnergy()
- {
- return Math.max(0, capacity - energyStored);
- }
-
- @Override
- public double injectEnergy(ForgeDirection directionFrom, double amount, double voltage)
- {
- energyStored += amount;
-
- return 0;
- }
-
- @Override
- public int getSinkTier()
- {
- return tier;
- }
-
- // << energy net interface
-
- public final TileEntity parent;
-
- protected int capacity;
- protected int tier;
- protected double energyStored;
- protected boolean addedToEnet;
-}
diff --git a/src/api/java/ic2/api/energy/prefab/BasicSource.java b/src/api/java/ic2/api/energy/prefab/BasicSource.java
deleted file mode 100644
index 5be7e1c..0000000
--- a/src/api/java/ic2/api/energy/prefab/BasicSource.java
+++ /dev/null
@@ -1,416 +0,0 @@
-package ic2.api.energy.prefab;
-
-import ic2.api.energy.EnergyNet;
-import ic2.api.energy.event.EnergyTileLoadEvent;
-import ic2.api.energy.event.EnergyTileUnloadEvent;
-import ic2.api.energy.tile.IEnergySource;
-import ic2.api.info.Info;
-import ic2.api.item.ElectricItem;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.common.util.ForgeDirection;
-import cpw.mods.fml.common.FMLCommonHandler;
-
-/**
- * BasicSource is a simple adapter to provide an ic2 energy source.
- *
- * It's designed to be attached to a tile entity as a delegate. Functionally BasicSource acts as a
- * one-time configurable output energy buffer, thus providing a common use case for generators.
- *
- * Sub-classing BasicSource instead of using it as a delegate works as well, but isn't recommended.
- * The delegate can be extended with additional functionality through a sub class though.
- *
- * The constraints set by BasicSource like the strict tank-like energy buffering should provide a
- * more easy to use and stable interface than using IEnergySource directly while aiming for
- * optimal performance.
- *
- * Using BasicSource involves the following steps:
- * - create a BasicSource instance in your TileEntity, typically in a field
- * - forward invalidate, onChunkUnload, readFromNBT, writeToNBT and updateEntity to the BasicSource
- * instance.
- * If you have other means of determining when the tile entity is fully loaded, notify onLoaded
- * that way instead of forwarding updateEntity.
- * - call addEnergy whenever appropriate, using getFreeCapacity may determine if e.g. the generator
- * should run
- * - optionally use getEnergyStored to display the output buffer charge level
- * - optionally use setEnergyStored to sync the stored energy to the client (e.g. in the Container)
- *
- * Example implementation code:
- * @code{.java}
- * public class SomeTileEntity extends TileEntity {
- * // new basic energy source, 1000 EU buffer, tier 1 (32 EU/t, LV)
- * private BasicSource ic2EnergySource = new BasicSource(this, 1000, 1);
- *
- * @Override
- * public void invalidate() {
- * ic2EnergySource.invalidate(); // notify the energy source
- * ...
- * super.invalidate(); // this is important for mc!
- * }
- *
- * @Override
- * public void onChunkUnload() {
- * ic2EnergySource.onChunkUnload(); // notify the energy source
- * ...
- * }
- *
- * @Override
- * public void readFromNBT(NBTTagCompound tag) {
- * super.readFromNBT(tag);
- *
- * ic2EnergySource.readFromNBT(tag);
- * ...
- * }
- *
- * @Override
- * public void writeToNBT(NBTTagCompound tag) {
- * super.writeToNBT(tag);
- *
- * ic2EnergySource.writeToNBT(tag);
- * ...
- * }
- *
- * @Override
- * public void updateEntity() {
- * ic2EnergySource.updateEntity(); // notify the energy source
- * ...
- * ic2EnergySource.addEnergy(5); // add 5 eu to the source's buffer this tick
- * ...
- * }
- *
- * ...
- * }
- * @endcode
- */
-public class BasicSource extends TileEntity implements IEnergySource
-{
- // **********************************
- // *** Methods for use by the mod ***
- // **********************************
-
- /**
- * Constructor for a new BasicSource delegate.
- *
- * @param parent1 Base TileEntity represented by this energy source.
- * @param capacity1 Maximum amount of eu to store.
- * @param tier1 IC2 tier, 1 = LV, 2 = MV, ...
- */
- public BasicSource(TileEntity parent1, double capacity1, int tier1)
- {
- final double power = EnergyNet.instance.getPowerFromTier(tier1);
-
- parent = parent1;
- capacity = capacity1 < power ? power : capacity1;
- tier = tier1;
- this.power = power;
- }
-
- // in-world te forwards >>
-
- /**
- * Forward for the base TileEntity's updateEntity(), used for creating the energy net link.
- * Either updateEntity or onLoaded have to be used.
- */
- @Override
- public void updateEntity()
- {
- if(!addedToEnet)
- {
- onLoaded();
- }
- }
-
- /**
- * Notification that the base TileEntity finished loading, for advanced uses.
- * Either updateEntity or onLoaded have to be used.
- */
- public void onLoaded()
- {
- if(!addedToEnet && !FMLCommonHandler.instance().getEffectiveSide().isClient() && Info.isIc2Available())
- {
- worldObj = parent.getWorldObj();
- xCoord = parent.xCoord;
- yCoord = parent.yCoord;
- zCoord = parent.zCoord;
-
- MinecraftForge.EVENT_BUS.post(new EnergyTileLoadEvent(this));
-
- addedToEnet = true;
- }
- }
-
- /**
- * Forward for the base TileEntity's invalidate(), used for destroying the energy net link.
- * Both invalidate and onChunkUnload have to be used.
- */
- @Override
- public void invalidate()
- {
- super.invalidate();
-
- onChunkUnload();
- }
-
- /**
- * Forward for the base TileEntity's onChunkUnload(), used for destroying the energy net link.
- * Both invalidate and onChunkUnload have to be used.
- */
- @Override
- public void onChunkUnload()
- {
- if(addedToEnet && Info.isIc2Available())
- {
- MinecraftForge.EVENT_BUS.post(new EnergyTileUnloadEvent(this));
-
- addedToEnet = false;
- }
- }
-
- /**
- * Forward for the base TileEntity's readFromNBT(), used for loading the state.
- *
- * @param tag Compound tag as supplied by TileEntity.readFromNBT()
- */
- @Override
- public void readFromNBT(NBTTagCompound tag)
- {
- super.readFromNBT(tag);
-
- final NBTTagCompound data = tag.getCompoundTag("IC2BasicSource");
-
- energyStored = data.getDouble("energy");
- }
-
- /**
- * Forward for the base TileEntity's writeToNBT(), used for saving the state.
- *
- * @param tag Compound tag as supplied by TileEntity.writeToNBT()
- */
- @Override
- public void writeToNBT(NBTTagCompound tag)
- {
- try
- {
- super.writeToNBT(tag);
- }
- catch(final RuntimeException e)
- {
- // happens if this is a delegate, ignore
- }
-
- final NBTTagCompound data = new NBTTagCompound();
-
- data.setDouble("energy", energyStored);
-
- tag.setTag("IC2BasicSource", data);
- }
-
- // << in-world te forwards
- // methods for using this adapter >>
-
- /**
- * Get the maximum amount of energy this source can hold in its buffer.
- *
- * @return Capacity in EU.
- */
- public double getCapacity()
- {
- return capacity;
- }
-
- /**
- * Set the maximum amount of energy this source can hold in its buffer.
- *
- * @param capacity1 Capacity in EU.
- */
- public void setCapacity(double capacity1)
- {
- if(capacity1 < power)
- {
- capacity1 = power;
- }
-
- capacity = capacity1;
- }
-
- /**
- * Get the IC2 energy tier for this source.
- *
- * @return IC2 Tier.
- */
- public int getTier()
- {
- return tier;
- }
-
- /**
- * Set the IC2 energy tier for this source.
- *
- * @param tier1 IC2 Tier.
- */
- public void setTier(int tier1)
- {
- final double power = EnergyNet.instance.getPowerFromTier(tier1);
-
- if(capacity < power)
- {
- capacity = power;
- }
-
- tier = tier1;
- this.power = power;
- }
-
- /**
- * Determine the energy stored in the source's output buffer.
- *
- * @return amount in EU
- */
- public double getEnergyStored()
- {
- return energyStored;
- }
-
- /**
- * Set the stored energy to the specified amount.
- *
- * This is intended for server -> client synchronization, e.g. to display the stored energy in
- * a GUI through getEnergyStored().
- *
- * @param amount
- */
- public void setEnergyStored(double amount)
- {
- energyStored = amount;
- }
-
- /**
- * Determine the free capacity in the source's output buffer.
- *
- * @return amount in EU
- */
- public double getFreeCapacity()
- {
- return capacity - energyStored;
- }
-
- /**
- * Add some energy to the output buffer.
- *
- * @param amount maximum amount of energy to add
- * @return amount added/used, NOT remaining
- */
- public double addEnergy(double amount)
- {
- if(FMLCommonHandler.instance().getEffectiveSide().isClient())
- {
- return 0;
- }
- if(amount > capacity - energyStored)
- {
- amount = capacity - energyStored;
- }
-
- energyStored += amount;
-
- return amount;
- }
-
- /**
- * Charge the supplied ItemStack from this source's energy buffer.
- *
- * @param stack ItemStack to charge (null is ignored)
- * @return true if energy was transferred
- */
- public boolean charge(ItemStack stack)
- {
- if(stack == null || !Info.isIc2Available())
- {
- return false;
- }
-
- final double amount = ElectricItem.manager.charge(stack, energyStored, tier, false, false);
-
- energyStored -= amount;
-
- return amount > 0;
- }
-
- // << methods for using this adapter
-
- // backwards compatibility (ignore these) >>
-
- @Deprecated
- public void onUpdateEntity()
- {
- updateEntity();
- }
-
- @Deprecated
- public void onInvalidate()
- {
- invalidate();
- }
-
- @Deprecated
- public void onOnChunkUnload()
- {
- onChunkUnload();
- }
-
- @Deprecated
- public void onReadFromNbt(NBTTagCompound tag)
- {
- readFromNBT(tag);
- }
-
- @Deprecated
- public void onWriteToNbt(NBTTagCompound tag)
- {
- writeToNBT(tag);
- }
-
- // << backwards compatibility
-
- // ******************************
- // *** Methods for use by ic2 ***
- // ******************************
-
- // energy net interface >>
-
- @Override
- public boolean emitsEnergyTo(TileEntity receiver, ForgeDirection direction)
- {
- return true;
- }
-
- @Override
- public double getOfferedEnergy()
- {
- return Math.min(energyStored, power);
- }
-
- @Override
- public void drawEnergy(double amount)
- {
- energyStored -= amount;
- }
-
- @Override
- public int getSourceTier()
- {
- return tier;
- }
-
- // << energy net interface
-
- public final TileEntity parent;
-
- protected double capacity;
- protected int tier;
- protected double power;
- protected double energyStored;
- protected boolean addedToEnet;
-}
diff --git a/src/api/java/ic2/api/energy/prefab/package-info.java b/src/api/java/ic2/api/energy/prefab/package-info.java
deleted file mode 100644
index a1ba4ee..0000000
--- a/src/api/java/ic2/api/energy/prefab/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.energy.prefab;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/energy/tile/IEnergyAcceptor.java b/src/api/java/ic2/api/energy/tile/IEnergyAcceptor.java
deleted file mode 100644
index 55f3e97..0000000
--- a/src/api/java/ic2/api/energy/tile/IEnergyAcceptor.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package ic2.api.energy.tile;
-
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * For internal/multi-block usage only.
- *
- * @see IEnergySink
- * @see IEnergyConductor
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public interface IEnergyAcceptor extends IEnergyTile
-{
- /**
- * Determine if this acceptor can accept current from an adjacent emitter in a direction.
- *
- * The TileEntity in the emitter parameter is what was originally added to the energy net,
- * which may be normal in-world TileEntity, a delegate or an IMetaDelegate.
- *
- * @param emitter energy emitter, may also be null or an IMetaDelegate
- * @param direction direction the energy is being received from
- */
- boolean acceptsEnergyFrom(TileEntity emitter, ForgeDirection direction);
-}
diff --git a/src/api/java/ic2/api/energy/tile/IEnergyConductor.java b/src/api/java/ic2/api/energy/tile/IEnergyConductor.java
deleted file mode 100644
index e10430d..0000000
--- a/src/api/java/ic2/api/energy/tile/IEnergyConductor.java
+++ /dev/null
@@ -1,53 +0,0 @@
-package ic2.api.energy.tile;
-
-/**
- * Tile entities which conduct energy pulses without buffering (mostly cables) have to implement this
- * interface.
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public interface IEnergyConductor extends IEnergyAcceptor, IEnergyEmitter
-{
- /**
- * Energy loss for the conductor in EU per block.
- *
- * @return Energy loss
- */
- double getConductionLoss();
-
- /**
- * Amount of energy the insulation will handle before shocking nearby players and mobs.
- *
- * @return Insulation energy absorption in EU
- */
- double getInsulationEnergyAbsorption();
-
- /**
- * Amount of energy the insulation will handle before it is destroyed.
- * Ensure that this value is greater than the insulation energy absorption + 64.
- *
- * @return Insulation-destroying energy in EU
- */
- double getInsulationBreakdownEnergy();
-
- /**
- * Amount of energy the conductor will handle before it melts.
- *
- * @return Conductor-destroying energy in EU
- */
- double getConductorBreakdownEnergy();
-
- /**
- * Remove the conductor's insulation if the insulation breakdown energy was exceeded.
- *
- * @see #getInsulationBreakdownEnergy()
- */
- void removeInsulation();
-
- /**
- * Remove the conductor if the conductor breakdown energy was exceeded.
- *
- * @see #getConductorBreakdownEnergy()
- */
- void removeConductor();
-}
diff --git a/src/api/java/ic2/api/energy/tile/IEnergyEmitter.java b/src/api/java/ic2/api/energy/tile/IEnergyEmitter.java
deleted file mode 100644
index d09e849..0000000
--- a/src/api/java/ic2/api/energy/tile/IEnergyEmitter.java
+++ /dev/null
@@ -1,27 +0,0 @@
-package ic2.api.energy.tile;
-
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * For internal/multi-block usage only.
- *
- * @see IEnergySource
- * @see IEnergyConductor
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public interface IEnergyEmitter extends IEnergyTile
-{
- /**
- * Determine if this emitter can emit energy to an adjacent receiver.
- *
- * The TileEntity in the receiver parameter is what was originally added to the energy net,
- * which may be normal in-world TileEntity, a delegate or an IMetaDelegate.
- *
- * @param receiver receiver, may also be null or an IMetaDelegate
- * @param direction direction the receiver is from the emitter
- * @return Whether energy should be emitted
- */
- boolean emitsEnergyTo(TileEntity receiver, ForgeDirection direction);
-}
diff --git a/src/api/java/ic2/api/energy/tile/IEnergySink.java b/src/api/java/ic2/api/energy/tile/IEnergySink.java
deleted file mode 100644
index 1c834b7..0000000
--- a/src/api/java/ic2/api/energy/tile/IEnergySink.java
+++ /dev/null
@@ -1,45 +0,0 @@
-package ic2.api.energy.tile;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Allows a tile entity (mostly a machine) to receive energy.
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public interface IEnergySink extends IEnergyAcceptor
-{
- /**
- * Determine how much energy the sink accepts.
- *
- * Make sure that injectEnergy() does accepts energy if demandsEnergy() returns anything > 0.
- *
- * @note Modifying the energy net from this method is disallowed.
- *
- * @return max accepted input in eu
- */
- double getDemandedEnergy();
-
- /**
- * Determine the tier of this energy sink.
- * 1 = LV, 2 = MV, 3 = HV, 4 = EV etc.
- *
- * @note Modifying the energy net from this method is disallowed.
- * @note Return Integer.MAX_VALUE to allow any voltage.
- *
- * @return tier of this energy sink
- */
- int getSinkTier();
-
- /**
- * Transfer energy to the sink.
- *
- * It's highly recommended to accept all energy by letting the internal buffer overflow to
- * increase the performance and accuracy of the distribution simulation.
- *
- * @param directionFrom direction from which the energy comes from
- * @param amount energy to be transferred
- * @return Energy not consumed (leftover)
- */
- double injectEnergy(ForgeDirection directionFrom, double amount, double voltage);
-}
diff --git a/src/api/java/ic2/api/energy/tile/IEnergySource.java b/src/api/java/ic2/api/energy/tile/IEnergySource.java
deleted file mode 100644
index 1d70eaa..0000000
--- a/src/api/java/ic2/api/energy/tile/IEnergySource.java
+++ /dev/null
@@ -1,38 +0,0 @@
-package ic2.api.energy.tile;
-
-/**
- * Allows a tile entity (mostly a generator) to emit energy.
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public interface IEnergySource extends IEnergyEmitter
-{
- /**
- * Energy output provided by the source this tick.
- * This is typically Math.min(stored energy, max output/tick).
- *
- * @note Modifying the energy net from this method is disallowed.
- *
- * @return Energy offered this tick
- */
- double getOfferedEnergy();
-
- /**
- * Draw energy from this source's buffer.
- *
- * If the source doesn't have a buffer, this is a no-op.
- *
- * @param amount amount of EU to draw, may be negative
- */
- void drawEnergy(double amount);
-
- /**
- * Determine the tier of this energy source.
- * 1 = LV, 2 = MV, 3 = HV, 4 = EV etc.
- *
- * @note Modifying the energy net from this method is disallowed.
- *
- * @return tier of this energy source
- */
- int getSourceTier();
-}
diff --git a/src/api/java/ic2/api/energy/tile/IEnergyTile.java b/src/api/java/ic2/api/energy/tile/IEnergyTile.java
deleted file mode 100644
index e619e29..0000000
--- a/src/api/java/ic2/api/energy/tile/IEnergyTile.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package ic2.api.energy.tile;
-
-/**
- * For internal usage only, base class for all energy tiles.
- *
- * @see IEnergySink
- * @see IEnergySource
- * @see IEnergyConductor
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public interface IEnergyTile
-{
- //
-}
diff --git a/src/api/java/ic2/api/energy/tile/IHeatSource.java b/src/api/java/ic2/api/energy/tile/IHeatSource.java
deleted file mode 100644
index ceebc41..0000000
--- a/src/api/java/ic2/api/energy/tile/IHeatSource.java
+++ /dev/null
@@ -1,24 +0,0 @@
-package ic2.api.energy.tile;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-public interface IHeatSource
-{
-
- /*
- * Return max heat transmission peer Tick (only theoretical bandwidth not available amount)
- */
- int maxrequestHeatTick(ForgeDirection directionFrom);
-
- /*
- * @param requested amount of heat to transfer
- *
- * @return transmitted amount of heat
- *
- * example: You Request 100 units of heat but the Source have only 50 units left
- *
- * requestHeat(100) : return 50 : so 50 units of heat remove from HeatSource
- */
-
- int requestHeat(ForgeDirection directionFrom, int requestheat);
-}
diff --git a/src/api/java/ic2/api/energy/tile/IKineticSource.java b/src/api/java/ic2/api/energy/tile/IKineticSource.java
deleted file mode 100644
index 4271a67..0000000
--- a/src/api/java/ic2/api/energy/tile/IKineticSource.java
+++ /dev/null
@@ -1,23 +0,0 @@
-package ic2.api.energy.tile;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-public interface IKineticSource
-{
- /*
- * Return max kinetic energy transmission peer Tick (only theoretical bandwidth not available amount)
- */
- int maxrequestkineticenergyTick(ForgeDirection directionFrom);
-
- /*
- * @param requested amount of kinetic energy to transfer
- *
- * @return transmitted amount of kineticenergy
- *
- * example: You Request 100 units of kinetic energy but the Source have only 50 units left
- *
- * requestkineticenergy(100) : return 50 : so 50 units of kinetic energy remove from KineticSource
- */
-
- int requestkineticenergy(ForgeDirection directionFrom, int requestkineticenergy);
-}
diff --git a/src/api/java/ic2/api/energy/tile/IMetaDelegate.java b/src/api/java/ic2/api/energy/tile/IMetaDelegate.java
deleted file mode 100644
index c8ecc4c..0000000
--- a/src/api/java/ic2/api/energy/tile/IMetaDelegate.java
+++ /dev/null
@@ -1,37 +0,0 @@
-package ic2.api.energy.tile;
-
-import java.util.List;
-
-import net.minecraft.tileentity.TileEntity;
-
-/**
- * Interface for grouping multi-block structures to a single energy net delegate.
- *
- * The energy net uses TileEntity to refer to a specific xyz+world position. If multiple of those
- * positions should belong to the same functional structure, i.e. they consume or produce energy
- * only once for the whole multi-block instead of once per every single block, this interface
- * allows to do so.
- *
- * The tile entity implementing IMetaDelegate has to be added/removed to/from the energy net
- * instead of every single sub-TileEntity. The energy net interaction will be handled by the
- * IMetaDelegate TileEntity as well.
- *
- * The sub tile array TileEntity[] just provides optional connectivity (IEnergyAcceptor,
- * IEnergyEmitter) and mandatory position (x, y, z, World) data.
- * If the connectivity data on the sub tile is missing, the meta delegate is queried instead.
- *
- * See ic2/api/energy/usage.txt for an overall description of the energy net api.
- */
-public interface IMetaDelegate extends IEnergyTile
-{
- /**
- * Get the sub-TileEntities belonging to this Meta TileEntity.
- *
- * @note The list has to be consistent between the EnergyNet Load and Unload events.
- * @note The list must have at least 1 element.
- * @note The parent te implementing IMetaDelegate isn't automatically included.
- *
- * @return sub-TileEntity array
- */
- List<TileEntity> getSubTiles();
-}
diff --git a/src/api/java/ic2/api/energy/tile/package-info.java b/src/api/java/ic2/api/energy/tile/package-info.java
deleted file mode 100644
index 944249a..0000000
--- a/src/api/java/ic2/api/energy/tile/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.energy.tile;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/energy/usage.txt b/src/api/java/ic2/api/energy/usage.txt
deleted file mode 100644
index 49bd995..0000000
--- a/src/api/java/ic2/api/energy/usage.txt
+++ /dev/null
@@ -1,144 +0,0 @@
---------------------------------
--- Energy Network Description --
---------------------------------
-
-There are currently three different types of energy network blocks:
-- energy sources, e.g. generators or the output side of a storage block/transformer
-- energy sinks, e.g. machines or the input side of a storage block/transformer
-- conductors, e.g. cables
-
-Note that storage blocks or transformers are both sources and sinks.
-
-All those blocks have to have a tile entity which has to implement the interface corresponding to
-its function and also post events to the Forge event bus.
-
-The energy generation, distribution and consumption is strictly limited to the simulating (server)
-side, use the proper side checks before posting the related events. One possibility is to check for
-FMLCommonHandler.instance().getEffectiveSide().isClient() being false.
-
-The energy network works by calculating the energy flow between the sources which offer energy
-through getOfferedEnergy() and the sinks which request energy through demandedEnergyUnits().
-Conductors will carry the energy over a distance. Once the energy distribution is calculated, the
-energy net will update the sources and sinks through drawEnergy() and injectEnergyUnits() respectively.
-
-
----------------------------
--- Energy Network Events --
----------------------------
-
-The energy network currently requires 2 events to manage its internal representation of the grids:
-
--- EnergyTileLoadEvent --
-
-For all energy network tiles (sources, sinks, conductors) you have to post an EnergyTileLoadEvent.
-
-The event has to be posted as soon as the implementing tile entity is fully loaded, usually after
-loading the chunk which contains it or after the user placing the block.
-
-The energy net implementation will use the event to add it to its energy grid map, taking it into
-account for further energy transfers.
-
-You can detect the loading by either using the 1st iteration of updateEntity() or by waiting for
-the next world tick after TileEntity.validate(). The 2nd approach is obviously more sophisticated
-and requires to use some tick queuing mechanism.
-
-The event can by posted as following:
- MinecraftForge.EVENT_BUS.post(new EnergyTileLoadEvent(this));
-
--- EnergyTileUnloadEvent --
-
-Another event every energy tile has to post is the EnergyTileUnloadEvent.
-
-The event has to be posted as soon as the implementing tile entity is being unloaded, either by
-unloading the containing chunk or by destroying the block containing it.
-
-It's possible to detect the unloading by triggering on both the beginning of
-TileEntity.invalidate() and the beginning of TileEntity.onChunkUnload().
-
-It is important that the tile entity is still properly linked to the world while posting the unload
-event, otherwise the energy net can't find all affected connections.
-
-
---------------------------------------
--- Participating Block Requirements --
---------------------------------------
-
-The energy net blocks have to do the following to work properly:
-
--- energy source --
-
-An energy source has to post the following events:
- - EnergyTileLoadEvent on load
- - EnergyTileUnloadEvent on unload
-
-Additionally the interface IEnergySource has to be implemented.
-
--- energy sink --
-
-An energy sink has to post the following events:
- - EnergyTileLoadEvent on load
- - EnergyTileUnloadEvent on unload
-
-Additionally the interface IEnergySink has to be implemented.
-
--- energy conductor --
-
-An energy conductor has to post the following events:
- - EnergyTileLoadEvent on load
- - EnergyTileUnloadEvent on unload
-
-Additionally the interface IEnergyConductor has to be implemented.
-
-
-------------------------------
--- Energy Network Delegates --
-------------------------------
-
-A delegate is a separate object which performs tasks for the original object, in this case handling
-the energy net interaction.
-
-The TileEntity instances used by the events don't have to be the same as the in-world TileEntity
-instance for the corresponding position, it can be delegated to a separate TileEntity instance.
-This separate instance (delegate) needs to have its world and xyz coordinate fields set to match
-the in-world instance. The delegate implements the energy net interfaces and is added and removed
-to/from the energy net through EnergyTileLoadEvent and EnergyTileUnloadEvent.
-
-Separating the interfaces through a delegate allows to isolate the IC2 API usage into separate
-classes an potentially share common code like an input buffer with battery discharging outside the
-class hierarchy.
-It's even possible to use an ic2 energy net delegate alongside an in-world TileEntity which isn't
-designed to work with ic2 energy at all, like making a furnace electric by receiving energy through
-a delegate and adding the corresponding fuel amount to the in-world furnace TileEntity.
-
-Getting the in-world TileEntity for a delegate involves calling World.getBlockTileEntity() with the
-delegate's world and xyz coordinate information.
-
-
-------------------
--- Multi Blocks --
-------------------
-
-Multi blocks are a group of blocks which act as one functional entity.
-
-The IMetaDelegate interface groups multiple TileEntity instances (=sub tiles) representing the
-individual blocks to a single Energy Net relevant node. The sub tiles may be normal in-world or
-delegate TileEntity instances.
-
-The meta delegate is added to energy net once for the whole multi block structure and implements
-the energy net interfaces as well. The sub tiles may optionally implement IEnergyEmitter and/or
-IEnergyAcceptor to specify their connectivity rules independently, otherwise the meta delegate will
-be queried.
-
-
---------------------------------------------------
--- How to implement/add your own energy network --
---------------------------------------------------
-
-If you want to create an alternative way of distributing energy, e.g. to have different
-distribution rules or to use energy networks provided by other mods, you can register to the energy
-tile events and use the interfaces to handle the energy distribution yourself. It's no longer
-required to use conversion blocks.
-
-IC2's EnergyNet itself is built on top of the api events and interfaces, providing their default
-use case.
-
diff --git a/src/api/java/ic2/api/event/ExplosionEvent.java b/src/api/java/ic2/api/event/ExplosionEvent.java
deleted file mode 100644
index f46cb71..0000000
--- a/src/api/java/ic2/api/event/ExplosionEvent.java
+++ /dev/null
@@ -1,40 +0,0 @@
-package ic2.api.event;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.world.World;
-import net.minecraftforge.event.world.WorldEvent;
-import cpw.mods.fml.common.eventhandler.Cancelable;
-
-@Cancelable
-public class ExplosionEvent extends WorldEvent
-{
- public ExplosionEvent(World world, Entity entity, double x, double y, double z, double power, EntityLivingBase igniter, int radiationRange, double rangeLimit)
- {
- super(world);
-
- this.entity = entity;
- this.x = x;
- this.y = y;
- this.z = z;
- this.power = power;
- this.igniter = igniter;
- this.radiationRange = radiationRange;
- this.rangeLimit = rangeLimit;
- }
-
- /**
- * Entity representing the explosive, may be null.
- */
- public final Entity entity;
- public double x;
- public double y;
- public double z;
- public double power;
- /**
- * Entity causing the explosion, may be null.
- */
- public final EntityLivingBase igniter;
- public final int radiationRange;
- public final double rangeLimit;
-}
diff --git a/src/api/java/ic2/api/event/LaserEvent.java b/src/api/java/ic2/api/event/LaserEvent.java
deleted file mode 100644
index 226a818..0000000
--- a/src/api/java/ic2/api/event/LaserEvent.java
+++ /dev/null
@@ -1,123 +0,0 @@
-package ic2.api.event;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import net.minecraftforge.event.world.WorldEvent;
-import cpw.mods.fml.common.eventhandler.Cancelable;
-
-/**
- * A bunch of Events to handle the power of the Mining Laser.
- */
-@Cancelable
-public class LaserEvent extends WorldEvent
-{
- // the Laser Entity
- public final Entity lasershot;
-
- // the following variables can be changed and the Laser will adjust to them
-
- // the Player firing the Laser. If the Laser gets "reflected" the Player could change.
- public EntityLivingBase owner;
- // Range of the Laser Shot. Determine the amount of broken blocks, as well, as each broken block will subtract ~1F from range.
- public float range, power;
- public int blockBreaks;
- // Determines whether the laser will explode upon hitting something
- public boolean explosive, smelt;
-
- public LaserEvent(World world1, Entity lasershot1, EntityLivingBase owner1, float range1, float power1, int blockBreaks1, boolean explosive1, boolean smelt1)
- {
- super(world1);
- lasershot = lasershot1;
- owner = owner1;
- range = range1;
- power = power1;
- blockBreaks = blockBreaks1;
- explosive = explosive1;
- smelt = smelt1;
- }
-
- /**
- * Event when the Laser is getting shot by a Player.
- *
- * The Item is the Laser Gun which the "Player" has shot
- */
- public static class LaserShootEvent extends LaserEvent
- {
- ItemStack laseritem;
-
- public LaserShootEvent(World world1, Entity lasershot1, EntityLivingBase owner1, float range1, float power1, int blockBreaks1, boolean explosive1, boolean smelt1, ItemStack laseritem1)
- {
- super(world1, lasershot1, owner1, range1, power1, blockBreaks1, explosive1, smelt1);
- laseritem = laseritem1;
- }
- }
-
- /**
- * Event when the Laser is exploding for some Reason.
- *
- * The Laser will no longer exist after this Event is posted as it either Explodes or despawns after the Event is fired.
- */
- public static class LaserExplodesEvent extends LaserEvent
- {
- // explosion strength, even that can be changed!
- public float explosionpower, explosiondroprate,
- explosionentitydamage;
-
- public LaserExplodesEvent(World world1, Entity lasershot1, EntityLivingBase owner1, float range1, float power1, int blockBreaks1, boolean explosive1, boolean smelt1, float explosionpower1, float explosiondroprate1, float explosionentitydamage1)
- {
- super(world1, lasershot1, owner1, range1, power1, blockBreaks1, explosive1, smelt1);
- explosionpower = explosionpower1;
- explosiondroprate = explosiondroprate1;
- explosionentitydamage = explosionentitydamage1;
- }
- }
-
- /**
- * Event when the Laser is hitting a Block
- * x, y and z are the Coords of the Block.
- *
- * Canceling this Event stops the Laser from attempting to break the Block, what is very useful for Glass.
- * Use lasershot.setDead() to remove the Shot entirely.
- */
- public static class LaserHitsBlockEvent extends LaserEvent
- {
- // targeted block, even that can be changed!
- public int x, y, z;
- public int side;
- // removeBlock determines if the Block will be removed. dropBlock determines if the Block should drop something.
- public boolean removeBlock, dropBlock;
- public float dropChance;
-
- public LaserHitsBlockEvent(World world1, Entity lasershot1, EntityLivingBase owner1, float range1, float power1, int blockBreaks1, boolean explosive1, boolean smelt1, int x1, int y1, int z1, int side1, float dropChance1, boolean removeBlock1, boolean dropBlock1)
- {
- super(world1, lasershot1, owner1, range1, power1, blockBreaks1, explosive1, smelt1);
- x = x1;
- y = y1;
- z = z1;
- side = side1;
- removeBlock = removeBlock1;
- dropBlock = dropBlock1;
- dropChance = dropChance1;
- }
- }
-
- /**
- * Event when the Laser is getting at a Living Entity
- *
- * Canceling this Event ignores the Entity
- * Use lasershot.setDead() to remove the Shot entirely.
- */
- public static class LaserHitsEntityEvent extends LaserEvent
- {
- // the Entity which the Laser has shot at, even the target can be changed!
- public Entity hitentity;
-
- public LaserHitsEntityEvent(World world1, Entity lasershot1, EntityLivingBase owner1, float range1, float power1, int blockBreaks1, boolean explosive1, boolean smelt1, Entity hitentity1)
- {
- super(world1, lasershot1, owner1, range1, power1, blockBreaks1, explosive1, smelt1);
- hitentity = hitentity1;
- }
- }
-}
diff --git a/src/api/java/ic2/api/event/PaintEvent.java b/src/api/java/ic2/api/event/PaintEvent.java
deleted file mode 100644
index 4f7e743..0000000
--- a/src/api/java/ic2/api/event/PaintEvent.java
+++ /dev/null
@@ -1,32 +0,0 @@
-package ic2.api.event;
-
-import net.minecraft.world.World;
-import net.minecraftforge.event.world.WorldEvent;
-import cpw.mods.fml.common.eventhandler.Cancelable;
-
-@Cancelable
-public class PaintEvent extends WorldEvent
-{
- // target block
- public final int x;
- public final int y;
- public final int z;
- public final int side;
-
- // color to paint the block
- public final int color;
-
- // set to true to confirm the operation
- public boolean painted = false;
-
- public PaintEvent(World world1, int x1, int y1, int z1, int side1, int color1)
- {
- super(world1);
-
- x = x1;
- y = y1;
- z = z1;
- side = side1;
- color = color1;
- }
-}
diff --git a/src/api/java/ic2/api/event/RetextureEvent.java b/src/api/java/ic2/api/event/RetextureEvent.java
deleted file mode 100644
index 0dda540..0000000
--- a/src/api/java/ic2/api/event/RetextureEvent.java
+++ /dev/null
@@ -1,37 +0,0 @@
-package ic2.api.event;
-
-import net.minecraft.block.Block;
-import net.minecraft.world.World;
-import net.minecraftforge.event.world.WorldEvent;
-import cpw.mods.fml.common.eventhandler.Cancelable;
-
-@Cancelable
-public class RetextureEvent extends WorldEvent
-{
- // target block
- public final int x;
- public final int y;
- public final int z;
- public final int side;
-
- // referenced block (to grab the texture from)
- public final Block referencedBlock;
- public final int referencedMeta;
- public final int referencedSide;
-
- // set to true to confirm the operation
- public boolean applied = false;
-
- public RetextureEvent(World world1, int x1, int y1, int z1, int side1, Block referencedBlock, int referencedMeta1, int referencedSide1)
- {
- super(world1);
-
- x = x1;
- y = y1;
- z = z1;
- side = side1;
- this.referencedBlock = referencedBlock;
- referencedMeta = referencedMeta1;
- referencedSide = referencedSide1;
- }
-}
diff --git a/src/api/java/ic2/api/event/package-info.java b/src/api/java/ic2/api/event/package-info.java
deleted file mode 100644
index 45c1338..0000000
--- a/src/api/java/ic2/api/event/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.event;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/info/IEnergyValueProvider.java b/src/api/java/ic2/api/info/IEnergyValueProvider.java
deleted file mode 100644
index a66b35c..0000000
--- a/src/api/java/ic2/api/info/IEnergyValueProvider.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package ic2.api.info;
-
-import net.minecraft.item.ItemStack;
-
-public interface IEnergyValueProvider
-{
- /**
- * Determine the energy value for a single item in the supplied stack.
- * The value is used by most machines in the discharge slot.
- *
- * This only applies to basic single use items, others are to be queried
- * through e.g. ElectricItem.manager.getCharge().
- *
- * @param itemStack ItemStack containing the item to evaluate.
- * @return energy in EU
- */
- double getEnergyValue(ItemStack itemStack);
-}
diff --git a/src/api/java/ic2/api/info/IFuelValueProvider.java b/src/api/java/ic2/api/info/IFuelValueProvider.java
deleted file mode 100644
index 690a477..0000000
--- a/src/api/java/ic2/api/info/IFuelValueProvider.java
+++ /dev/null
@@ -1,16 +0,0 @@
-package ic2.api.info;
-
-import net.minecraft.item.ItemStack;
-
-public interface IFuelValueProvider
-{
- /**
- * Determine the fuel value for a single item in the supplied stack.
- * The information currently applies to Generators and the Iron Furnace.
- *
- * @param itemStack ItemStack containing the item to evaluate.
- * @param allowLava Determine if lava has a fuel value, currently only true for the Iron Furnace.
- * @return fuel value
- */
- int getFuelValue(ItemStack itemStack, boolean allowLava);
-}
diff --git a/src/api/java/ic2/api/info/Info.java b/src/api/java/ic2/api/info/Info.java
deleted file mode 100644
index 42f8235..0000000
--- a/src/api/java/ic2/api/info/Info.java
+++ /dev/null
@@ -1,45 +0,0 @@
-package ic2.api.info;
-
-import net.minecraft.potion.Potion;
-import net.minecraft.util.DamageSource;
-import cpw.mods.fml.common.Loader;
-import cpw.mods.fml.common.LoaderState;
-
-public class Info
-{
- public static IEnergyValueProvider itemEnergy;
- public static IFuelValueProvider itemFuel;
- public static Object ic2ModInstance;
-
- /**
- * Damage Sources used by IC2.
- * Getting assigned in preload.
- */
- public static DamageSource DMG_ELECTRIC, DMG_NUKE_EXPLOSION,
- DMG_RADIATION;
-
- /**
- * Potions used by IC2.
- * Getting assigned in preload.
- */
- public static Potion POTION_RADIATION;
-
- public static boolean isIc2Available()
- {
- if(ic2Available != null)
- {
- return ic2Available;
- }
-
- final boolean loaded = Loader.isModLoaded("IC2");
-
- if(Loader.instance().hasReachedState(LoaderState.CONSTRUCTING))
- {
- ic2Available = loaded;
- }
-
- return loaded;
- }
-
- private static Boolean ic2Available = null;
-}
diff --git a/src/api/java/ic2/api/info/package-info.java b/src/api/java/ic2/api/info/package-info.java
deleted file mode 100644
index 126f59e..0000000
--- a/src/api/java/ic2/api/info/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.info;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/item/ElectricItem.java b/src/api/java/ic2/api/item/ElectricItem.java
deleted file mode 100644
index f4037a9..0000000
--- a/src/api/java/ic2/api/item/ElectricItem.java
+++ /dev/null
@@ -1,64 +0,0 @@
-package ic2.api.item;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Allows for charging, discharging and using electric items (IElectricItem).
- */
-public final class ElectricItem
-{
- /**
- * IElectricItemManager to use for interacting with IElectricItem ItemStacks.
- *
- * This manager will act as a gateway and delegate the tasks to the final implementation
- * (rawManager or a custom one) as necessary.
- */
- public static IElectricItemManager manager;
-
- /**
- * Standard IElectricItemManager implementation, only call it directly from another
- * IElectricItemManager. Use manager instead.
- */
- public static IElectricItemManager rawManager;
-
- /**
- * Register an electric item manager for items not implementing IElectricItem.
- *
- * This method is only designed for special purposes, implementing IElectricItem or
- * ISpecialElectricItem instead of using this is faster.
- *
- * Managers used with ISpecialElectricItem shouldn't be registered.
- *
- * @param manager Manager to register.
- */
- public static void registerBackupManager(IBackupElectricItemManager manager)
- {
- backupManagers.add(manager);
- }
-
- /**
- * Get the electric item manager suitable for the supplied item stack.
- *
- * This method is for internal use only.
- *
- * @param stack ItemStack to be handled.
- * @return First suitable electric item manager.
- */
- public static IBackupElectricItemManager getBackupManager(ItemStack stack)
- {
- for(final IBackupElectricItemManager manager : backupManagers)
- {
- if(manager.handles(stack))
- {
- return manager;
- }
- }
-
- return null;
- }
-
- private static final List<IBackupElectricItemManager> backupManagers = new ArrayList<IBackupElectricItemManager>();
-}
diff --git a/src/api/java/ic2/api/item/IBackupElectricItemManager.java b/src/api/java/ic2/api/item/IBackupElectricItemManager.java
deleted file mode 100644
index d53b885..0000000
--- a/src/api/java/ic2/api/item/IBackupElectricItemManager.java
+++ /dev/null
@@ -1,13 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * This interface specifies a manager applicable to items not implementing IElectricItem.
- *
- * The manager implementing this has to be registered with ElectricItem.registerBackupManager().
- */
-public interface IBackupElectricItemManager extends IElectricItemManager
-{
- boolean handles(ItemStack stack);
-}
diff --git a/src/api/java/ic2/api/item/IBlockCuttingBlade.java b/src/api/java/ic2/api/item/IBlockCuttingBlade.java
deleted file mode 100644
index e153117..0000000
--- a/src/api/java/ic2/api/item/IBlockCuttingBlade.java
+++ /dev/null
@@ -1,6 +0,0 @@
-package ic2.api.item;
-
-public interface IBlockCuttingBlade
-{
- int gethardness();
-}
diff --git a/src/api/java/ic2/api/item/IBoxable.java b/src/api/java/ic2/api/item/IBoxable.java
deleted file mode 100644
index 1d86e2c..0000000
--- a/src/api/java/ic2/api/item/IBoxable.java
+++ /dev/null
@@ -1,14 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.item.ItemStack;
-
-public interface IBoxable
-{
- /**
- * Determine whether an item can be stored in a toolbox or not.
- *
- * @param itemstack item to be stored
- * @return Whether to store the item in the toolbox or not
- */
- public abstract boolean canBeStoredInToolbox(ItemStack itemstack);
-}
diff --git a/src/api/java/ic2/api/item/IC2Items.java b/src/api/java/ic2/api/item/IC2Items.java
deleted file mode 100644
index 78c680d..0000000
--- a/src/api/java/ic2/api/item/IC2Items.java
+++ /dev/null
@@ -1,608 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Provides access to IC2 blocks and items.
- *
- * Some items can be acquired through the ore dictionary which is the recommended way.
- * The items are initialized while IC2 is being loaded - try to use ModsLoaded() or load your mod after IC2.
- * Some blocks/items can be disabled by a config setting, so it's recommended to check if they're null first.
- *
- * Getting the associated Block/Item for an ItemStack x:
- * Blocks: Block.blocksList[x.itemID]
- * Items: x.getItem()
- */
-public final class IC2Items
-{
- /**
- * Get an ItemStack for a specific item name, example: Items.getItem("resin")
- * See the list below for item names.
- * Make sure to copy() the ItemStack if you want to modify it.
- *
- * @param name item name
- * @return The item or null if the item does not exist or an error occurred
- */
- public static ItemStack getItem(String name)
- {
- try
- {
- if(Ic2Items == null)
- {
- Ic2Items = Class.forName(getPackage() + ".core.Ic2Items");
- }
-
- final Object ret = Ic2Items.getField(name).get(null);
-
- if(ret instanceof ItemStack)
- {
- return (ItemStack) ret;
- }
- return null;
- }
- catch(final Exception e)
- {
- System.out.println("IC2 API: Call getItem failed for " + name);
-
- return null;
- }
- }
-
- /* Possible values:
-
- // ores
- copperOre; // Copper Ore block, currently not meta sensitive, meta in ItemStack set to 0, ore dictionary: oreCopper, null with enableWorldGenOreCopper = false
- tinOre; // Tin Ore block, currently not meta sensitive, meta in ItemStack set to 0, ore dictionary: oreTin, null with enableWorldGenOreTin = false
- uraniumOre; // Tin Ore block, currently not meta sensitive, meta in ItemStack set to 0, ore dictionary: oreUranium, null with enableWorldGenOreUranium = false
- leadOre; // Lead Ore Block, currently not meta sensitive, meta in ItemStack set to 0, ore dictionary: oreLead, null with enableWorldGenOreLead = false
-
- // rubber related
-
- Rubber wood block, meta reflects the state, meta in ItemStack set to 0, ore dictionary: woodRubber (with meta 0), null with enableWorldGenTreeRubber = false
- dropped (as an item) -> metadata 0
- block, no resin spot -> metadata 0 or 1
- block, wet resin spot -> metadata 2-5 (according to the side)
- block, dry resin spot -> metadata 8-11 (wet state + 6)
-
- rubberWood;
- rubberLeaves; // Rubber Leaves block, currently not meta sensitive, meta in ItemStack set to 0, null with enableWorldGenTreeRubber = false
- rubberSapling; // Rubber Sapling block, currently not meta sensitive, meta in ItemStack set to 0, null with enableWorldGenTreeRubber = false
- resinSheet; // Resin Sheet block, currently not meta sensitive
- rubberTrampoline; // Rubber Trampoline block, meta reflects internal state, meta in ItemStack set to 0
-
- // building/storage
- ironFence; // Iron Fence block, currently not meta sensitive
-
- reinforcedStone; // Reinforced Stone block, currently not meta sensitive
- reinforcedGlass; // Reinforced Glass block, currently not meta sensitive
- reinforcedDoorBlock; // Reinforced Door block, meta reflects the state (see vanilla doors), meta in ItemStack set to 0
-
- constructionreinforcedFoam; // Construction Reinforced Foam block, currently not meta sensitive
- constructionFoam; // Construction Foam block, currently not meta sensitive
- constructionFoamWall; // Construction Foam Wall block, meta = color, implements IPaintableBlock
- scaffold; // Scaffold block, meta reflects internal physical model data
- ironScaffold; // Scaffold block, meta reflects internal physical model data
-
- bronzeBlock; // Bronze block, meta sensitive
- copperBlock; // Copper block, meta sensitive
- tinBlock; // Tin block, meta sensitive
- uraniumBlock; // Uranium block, meta sensitive
- leadBlock; // Uranium block, meta sensitive
-
- // cables (when placed as a block, inventory items are different; TE implements IEnergyConductor)
-
- copperCableBlock; // Copper Cable block, meta sensitive
- insulatedCopperCableBlock; // Insulated Copper Cable block, meta sensitive
-
- goldCableBlock; // Gold Cable block, meta sensitive
- insulatedGoldCableBlock; // Insulated Gold Cable block, meta sensitive
- doubleInsulatedGoldCableBlock; // Double Insulated Gold Cable block, meta sensitive
-
- ironCableBlock; // Iron Cable block, meta sensitive
- insulatedIronCableBlock; // Insulated Iron Cable block, meta sensitive
- doubleInsulatedIronCableBlock; // Double Insulated Iron Cable block, meta sensitive
- trippleInsulatedIronCableBlock; // Tripple Insulated Iron Cable block, meta sensitive
-
- glassFiberCableBlock; // Glass Fiber Cable block, meta sensitive
-
- tinCableBlock; // Tin Cable block, meta sensitive
- insulatedtinCableBlock; // Insulated Tin Cable item, meta sensitive
- detectorCableBlock; // Detector Cable block, meta sensitive
- splitterCableBlock; // Splitter Cable block, meta sensitive
-
- // generators + related (TE implements IEnergySource ex. reactorChamber)
-
- generator; // Generator block, meta sensitive
- geothermalGenerator; // Geothermal Generator block, meta sensitive
- waterMill; // Water Mill block, meta sensitive
- solarPanel; // Solar Panel block, meta sensitive
- windMill; // Wind Mill block, meta sensitive
- nuclearReactor; // Nuclear Reactor block, meta sensitive
- reactorChamber; // Reactor Chamber block, currently not meta sensitive
- RTGenerator; // Radioisotope Thermoelectric Generator block, meta sensitive
- semifluidGenerator; // Semifluid Generator block, meta sensitive
-
-
- // energy storages (TE implements IEnergySource and IEnergyConductor)
-
- batBox; // BatBox block, meta sensitive
- cesuUnit; // CESU Unit block, meta sensitive
- mfeUnit; // MFE Unit block, meta sensitive
- mfsUnit; // MFS Unit block, meta sensitive
-
- // transformers (TE implements IEnergySource and IEnergyConductor)
-
- lvTransformer; // LV Transformer block, meta sensitive
- mvTransformer; // MV Transformer block, meta sensitive
- hvTransformer; // HV Transformer block, meta sensitive
- evTransformer; // EV Transformer block, meta sensitive
-
- // machines + related (TE implements IEnergySink ex. machine, miningPipe, miningPipeTip)
-
- machine; // Machine block, meta sensitive
- advancedMachine; // Advanced Machine block, meta sensitive
-
- ironFurnace; // Iron Furnace block, meta sensitive
- electroFurnace; // Electro Furnace block, meta sensitive
- macerator; // Macerator block, meta sensitive
- extractor; // Extractor block, meta sensitive
- compressor; // Compressor block, meta sensitive
- canner; // Canner block, meta sensitive
- miner; // Miner block, meta sensitive
- pump; // Pump block, meta sensitive
- magnetizer; // Magnetizer block, meta sensitive
- electrolyzer; // Electrolyzer block, meta sensitive
- recycler; // Recycler block, meta sensitive
- inductionFurnace; // Induction Furnace block, meta sensitive
- massFabricator; // Mass Fabricator block, meta sensitive
- terraformer; // Terraformer block, meta sensitive
- teleporter; // Teleporter block, meta sensitive
- teslaCoil; // Tesla Coil block, meta sensitive
- luminator; // Passive (dark) Luminator block, meta = facing
- activeLuminator; // Active (bright) Luminator block, meta = facing
- centrifuge; // Centrifuge block, meta sensitive
- metalformer; // MetalFormer block , meta sensitive
- orewashingplant; // Ore Wasching Plant, Meta sensitive
- patternstorage; // Pattern Storage, Meta sensitive
- scanner; // Scanner, Meta sensitive
- replicator; // Replicator, Meta sensitive
-
- miningPipe; // Mining Pipe block, currently not meta sensitive, meta in ItemStack set to 0
- miningPipeTip; // Mining Pipe Tip block, currently not meta sensitive, meta in ItemStack set to 0
-
-
- // personal blocks
-
- personalSafe; // Personal Safe block, meta sensitive
- tradeOMat; // Trade-O-Mat block, meta sensitive
- energyOMat; // Energy-O-Mat block, meta sensitive
-
- // explosives
-
- industrialTnt; // Industrial TNT block, currently not meta sensitive
- nuke; // Nuke block, currently not meta sensitive
- dynamiteStick; // Dynamite Stick block, meta = placement, meta in ItemStack set to 0
- dynamiteStickWithRemote; // Dynamite Stick with Remote block, meta = placement, meta in ItemStack set to 0
-
- // Agriculture Stuff
-
- crop; // Crop Block, empty, not meta sensitive
- cropmatron; // Cropmatron machien block, meta sensititve
-
- // ----- items -----
-
- // rubber + related
- resin; // Resin item, currently not meta sensitive
- rubber; // Rubber item, currently not meta sensitive, ore dictionary: itemRubber
-
- FluidCell;
-
- // Lithium -> Tritium
-
- reactorLithiumCell; // LithiumCell use in Reaktor, , meta = damage value
- TritiumCell; // Tritium, currently not meta sensitive
-
- // Nuclear Fuel
-
- UranFuel; // , currently not meta sensitive
- MOXFuel; // , currently not meta sensitive
- Plutonium; // , currently not meta sensitive
- smallPlutonium; // , currently not meta sensitive
- Uran235; // , currently not meta sensitive
- smallUran235; // , currently not meta sensitive
- Uran238; // , currently not meta sensitive
-
- reactorDepletedUraniumSimple; // Depleted Uranium Cell items, currently not meta sensitive
- reactorDepletedUraniumDual;
- reactorDepletedUraniumQuad;
- reactorDepletedMOXSimple; // Depleted MOX Cell items, currently not meta sensitive
- reactorDepletedMOXDual;
- reactorDepletedMOXQuad;
- reactorMOXSimple; // Depleted MOX Cell items, currently not meta sensitive
- reactorMOXDual;
- reactorMOXQuad;
- RTGPellets;
-
-
- // Recipe Parts
-
- coil; // Coil, meta sensitive
- elemotor; // electric motor, meta sensitive
- powerunit; // Item Power Unit, meta sensitive
- powerunitsmall; // Item Power Unit, meta sensitive
-
-
- // ItemCasing
-
- casingcopper; // Copper ItemCasing, meta sensitive
- casingtin; // Tin ItemCasing, meta sensitive
- casingbronze; // Bronze ItemCasing, meta sensitive
- casinggold; // Gold ItemCasing, meta sensitive
- casingiron; // Iron ItemCasing, meta sensitive
- @Deprecated
- casingadviron; // Refined Iron ItemCasing, meta sensitive
- casinglead; // Lead ItemCasing, meta sensitive
-
- // Crushed Ore
- crushedIronOre; // Crushed Iron Ore, meta sensitive
- crushedCopperOre; // Crushed Copper Ore, meta sensitive
- crushedGoldOre; // Crushed Gold Ore, meta sensitive
- crushedTinOre; // Crushed Tin Ore, meta sensitive
- crushedUraniumOre; // Crushed Uranium Ore, meta sensitive
- crushedSilverOre; // Crushed Silver Ore, meta sensitive
- crushedLeadOre; // Crushed Lead Ore, meta sensitive
-
-
- //Purify Crushed Ore
- purifiedCrushedIronOre; // Purify Crushed Iron Ore, meta sensitive
- purifiedCrushedCopperOre; // Purify Crushed Copper Ore, meta sensitive
- purifiedCrushedGoldOre; // Purify Crushed Gold Ore, meta sensitive
- purifiedCrushedTinOre; // Purify Crushed Tin Ore, meta sensitive
- purifiedCrushedUraniumOre; // Purify Crushed Uranium Ore, meta sensitive
- purifiedCrushedSilverOre; // Purify Crushed Silver Ore, meta sensitive
- purifiedCrushedLeadOre; // Purify Crushed Lead Ore, meta sensitive
-
- // dusts
- stoneDust;
- bronzeDust; // Bronze Dust item, meta sensitive, ore dictionary: dustBronze
- clayDust; // Clay Dust item, meta sensitive, ore dictionary: dustClay
- coalDust; // Coal Dust item, meta sensitive, ore dictionary: dustCoal
- copperDust; // Copper Dust item, meta sensitive, ore dictionary: dustCopper
- goldDust; // Gold Dust item, meta sensitive, ore dictionary: dustGold
- ironDust; // Iron Dust item, meta sensitive, ore dictionary: dustIron
- silverDust; // Silver Dust item, meta sensitive, ore dictionary: dustSilver
- tinDust; // Tin Dust item, meta sensitive, ore dictionary: dustTin
- hydratedCoalDust; // Hydrated Coal Dust item, meta sensitive
- leadDust; // Lead Dust item, meta sensitive, ore dictionary: dustLead
- obsidianDust; // Obsidian Dust item, meta sensitive, ore dictionary: dustObsidian
- lapiDust; // Lapi Dust item, meta sensitive, ore dictionary: dustLapi
- sulfurDust; // Sulfur Dust item, meta sensitive, ore dictionary: dustSulfur
- lithiumDust; // Lithium dust, meta sensitive, ore dictionary: dustLithium
-
- // small dusts
-
- smallIronDust; // Small Iron Dust item, meta sensitive
- smallCopperDust; // Small Copper Dust item, meta sensitive
- smallGoldDust; // Small Gold Dust item, meta sensitive
- smallTinDust; // Small Tin Dust item, meta sensitive
- smallSilverDust; // Small Silver Dust item, meta sensitive
- smallLeadDust; // Small Lead Dust item, meta sensitive
- smallSulfurDust; // Small Sulfur Dust item, meta sensitive
- smallLithiumDust; // Small Lithium Dust item, meta sensitive
-
-
- // ingots
- @Deprecated
- refinedIronIngot; // Refined Iron Ingot item, currently not meta sensitive, ore dictionary: ingotRefinedIron
- copperIngot; // Copper Ingot item, currently not meta sensitive, ore dictionary: ingotCopper
- tinIngot; // Tin Ingot item, currently not meta sensitive, ore dictionary: ingotTin
- bronzeIngot; // Bronze Ingot item, currently not meta sensitive, ore dictionary: ingotBronze
- mixedMetalIngot; // Mixed Metal Ingot item, currently not meta sensitive
- leadIngot; // Lead Ingot item, currently not meta sensitive
-
-
- // tools/weapons (without electric tools)
- treetap; // Treetap item, meta = damage value
- wrench; // Wrench item, meta = damage value
- cutter; // Insulation Cutter item, meta = damage value
- constructionFoamSprayer; // Construction Foam Sprayer item, meta = charges (as of v1.45)
-
- bronzePickaxe; // Bronze Pickaxe item, meta = damage value
- bronzeAxe; // Bronze Axe item, meta = damage value
- bronzeSword; // Bronze Sword item, meta = damage value
- bronzeShovel; // Bronze Shovel item, meta = damage value
- bronzeHoe; // Bronze Hoe item, meta = damage value
-
- ForgeHammer; // Refine Iron Hammer item, meta = damage value
-
- // el. tools/devices/weapons
- miningDrill; // Mining Drill item, meta = damage value for charge level
- diamondDrill; // Diamond Tipped Mining Drill item, meta = damage value for charge level
- iridiumDrill; // Iridium Tipped Mining Drill item, meta = damage value for charge level
- chainsaw; // Chainsaw item, meta = damage value for charge level
- electricWrench; // Electric Wrench item, meta = damage value for charge level
- electricTreetap; // Electric Treetap item, meta = damage value for charge level
- miningLaser; // Mining Laser item, meta = damage value for charge level
-
- ecMeter; // EC-Mater item, meta = itemdata db index (as of v1.45)
- odScanner; // Ore Density Scanner item, meta = damage value for charge level
- ovScanner; // Ore Value Scanner item, meta = damage value for charge level
- obscurator; // Obscurator item, meta = damage value for charge level
-
- frequencyTransmitter; // Frequency Transmitter item, meta = itemdata db index (as of v1.45)
-
- nanoSaber; // Idle Nano Saber item, meta = damage value for charge level
- enabledNanoSaber; // Enabled Nano Saber item, meta = damage value for charge level
-
- toolbox; // Open/Empty toolbox, meta = Open (0) / Closed (1)
-
- // armor/wearable
- hazmatHelmet; // Hazmat Helmet item, meta = damage value
- hazmatChestplate; // Hazmat Chestplate item, meta = damage value
- hazmatLeggings; // Hazmat Leggings item, meta = damage value
- hazmatBoots; // Hazmat Boots item, meta = damage value
-
- bronzeHelmet; // Bronze Helmet Armor item, meta = damage value
- bronzeChestplate; // Bronze Chestplate Armor item, meta = damage value
- bronzeLeggings; // Bronze Leggings Armor item, meta = damage value
- bronzeBoots; // Bronze Boots Armor item, meta = damage value
-
- compositeArmor; // Composite Armor item, meta = damage value for charge level
-
- nanoHelmet; // Nano Helmet Armor item, meta = damage value for charge level
- nanoBodyarmor; // Nano Bodyarmor item, meta = damage value for charge level
- nanoLeggings; // Nano Leggings Armor item, meta = damage value for charge level
- nanoBoots; // Nano Boots Armor item, meta = damage value for charge level
-
- quantumHelmet; // Quantum Helmet Armor item, meta = damage value for charge level
- quantumBodyarmor; // Quantum Bodyarmor item, meta = damage value for charge level
- quantumLeggings; // Quantum Leggings Armor item, meta = damage value for charge level
- quantumBoots; // Quantum Boots Armor item, meta = damage value for charge level
-
- jetpack; // Jetpack item, meta = damage value for fuel level
- electricJetpack; // Electric Jetpack item, meta = damage value for charge level
-
- batPack; // BatPack item, meta = damage value for charge level
- advbatPack; // Adv.BatPack item, meta = damage value for charge level
- lapPack; // LapPack item, meta = damage value for charge level
- energyPack; // EnergyPack item, meta = damage value for charge level
-
- cfPack; // CF Pack item, meta = charges (as of v1.45)
- solarHelmet; // Solar Helmet, currently not meta sensitive
- staticBoots; // Static Boots, currently not meta sensitive
- nightvisionGoggles; // Nightvision Goggles, meta = damage value for charge level
-
- // batteries
- reBattery; // Empty RE Battery item, currently not meta sensitive
- chargedReBattery; // RE Battery item, meta = damage value for charge level
- advBattery; // Adv Batteryitem, meta = damage value for charge level
- energyCrystal; // Energy Crystal item, meta = damage value for charge level
- lapotronCrystal; // Lapotron Crystal item, meta = damage value for charge level
- suBattery; // SU Battery item, meta = damage value for charge level
-
- // cables
- copperCableItem; // Copper Cable item, meta sensitive
- insulatedCopperCableItem; // Insulated Copper Cable item, meta sensitive
-
- goldCableItem; // Gold Cable item, meta sensitive
- insulatedGoldCableItem; // Insulated Gold Cable item, meta sensitive
-
- @Deprecated
- doubleInsulatedGoldCableItem; // Double Insulated Gold Cable item, meta sensitive
-
- ironCableItem; // Iron Cable item, meta sensitive
- insulatedIronCableItem; // Insulated Iron Cable item, meta sensitive
-
- @Deprecated
- doubleInsulatedIronCableItem; // Double Insulated Iron Cable item, meta sensitive
- @Deprecated
- trippleInsulatedIronCableItem; // Tripple Insulated Iron Cable item, meta sensitive
- insulatedTinCableItem;
- glassFiberCableItem; // Glass Fiber Cable item, meta sensitive
- tinCableItem; // Tin Cable item, meta sensitive
-
-
- detectorCableItem; // Detector Cable item, meta sensitive
- splitterCableItem; // Splitter Cable item, meta sensitive
-
- // cells/containers (without reactor components)
-
- cell; // Empty Cell item, meta sensitive
- lavaCell; // Lava Cell item, meta sensitive
- waterCell; // Water Cell item, meta sensitive
- UuMatterCell; // UUMatter Cell item, meta sensitive
- CFCell; // constructionFoam Cell item, meta sensitive
-
-
- fuelRod; // Empy Fuel Rod item, currently not meta sensitive
- hydratedCoalCell; // Hydrated Coal Cell item, currently not meta sensitive
- bioCell; // Bio Cell item, currently not meta sensitive
- coalfuelCell; // Coalfuel Cell item, currently not meta sensitive
- biofuelCell; // Biofuel Cell item, currently not meta sensitive
- electrolyzedWaterCell; // Electrolyzed Water Cell item, currently not meta sensitive
- airCell; // Compressed Air item, currently not meta sensitive
-
- fuelCan; // Empty Fuel Can item, currently not meta sensitive
- filledFuelCan; // Fuel Can item, meta = fuel value (as of v1.45)
-
- tinCan; // Empty Tin Can item, currently not meta sensitive
- filledTinCan; // Filled Tin Can item, currently not meta sensitive
-
- // reactor components
- reactorUraniumSimple; // Uranium Cell items, meta = consumed uranium ticks
- reactorUraniumDual;
- reactorUraniumQuad;
-
- reactorCoolantSimple;
- reactorCoolantTriple ; // Coolant Cell item, NBT for heat-storage, meta is 0-10000 for display
- reactorCoolantSix;
-
- reactorPlating; // Integrated Reactor Plating item, currently not meta sensitive
- reactorPlatingHeat;
- reactorPlatingExplosive;
-
- reactorHeatSwitch; // Integrated Heat Disperser item, NBT for heat-storage, meta is 0-10000 for display
- reactorHeatSwitchCore;
- reactorHeatSwitchSpread;
- reactorHeatSwitchDiamond;
-
- reactorVent; // Heat Venting component, NBT for heat-storage, meta is 0-10000 for display
- reactorVentCore;
- reactorVentGold;
- reactorVentSpread;// Special: Does not store heat
- reactorVentDiamond;
-
- reactorReflector; // Increase efficiency without additional ticks, NBT for heat-storage, meta is 0-10000 for display
- reactorReflectorThick; // Increase efficiency without additional ticks, NBT for heat-storage, meta is 0-10000 for display
- reactorCondensator; // Consumes redstone to absorb heat, NBT for storage, meta is 0-10000 for display
- reactorCondensatorLap; // Consumes redstone/lapis to absorb heat, mNBT for storage, meta is 0-10000 for display
-
- // terraformer blueprints
- terraformerBlueprint; // Empty Terraformer Blueprint item, currently not meta sensitive
- cultivationTerraformerBlueprint; // Cultivation Terraformer Blueprint item, currently not meta sensitive
- irrigationTerraformerBlueprint; // Irrigation Terraformer Blueprint item, currently not meta sensitive
- chillingTerraformerBlueprint; // Chilling Terraformer Blueprint item, currently not meta sensitive
- desertificationTerraformerBlueprint; // Desertification Terraformer Blueprint item, currently not meta sensitive
- flatificatorTerraformerBlueprint; // Flatificator Terraformer Blueprint item, currently not meta sensitive
- mushroomTerraformerBlueprint; // Mushroom Terraformer Blueprint item, currently not meta sensitive
-
- // diamond chain
- coalBall; // Coal Ball item, currently not meta sensitive
- compressedCoalBall; // Compressed Coal Ball item, currently not meta sensitive
- coalChunk; // Coal Chunk item, currently not meta sensitive
- industrialDiamond; // Industrial Diamond item, currently not meta sensitive, DEPRECATED
-
- // recycler chain
- scrap; // Scrap item, currently not meta sensitive
- scrapBox; // Scrap Box item, currently not meta sensitive
-
- // fuel production chain
- hydratedCoalClump; // Hydrated Coal Clump item, currently not meta sensitive
- plantBall; // Plant Ball item, currently not meta sensitive
- compressedPlantBall; // Compressed Plant Ball item, currently not meta sensitive
-
- // painting
- painter; // Painter item, currently not meta sensitive
-
- blackPainter; // Black Painter item, meta = damage value
- redPainter; // Red Painter item, meta = damage value
- greenPainter; // Green Painter item, meta = damage value
- brownPainter; // Brown Painter item, meta = damage value
- bluePainter; // Blue Painter item, meta = damage value
- purplePainter; // Purple Painter item, meta = damage value
- cyanPainter; // Cyan Painter item, meta = damage value
- lightGreyPainter; // Light Grey Painter item, meta = damage value
- darkGreyPainter; // Dark Grey Painter item, meta = damage value
- pinkPainter; // Pink Painter item, meta = damage value
- limePainter; // Lime Painter item, meta = damage value
- yellowPainter; // Yellow Painter item, meta = damage value
- cloudPainter; // Cloud Painter item, meta = damage value
- magentaPainter; // Magenta Painter item, meta = damage value
- orangePainter; // Orange Painter item, meta = damage value
- whitePainter; // White Painter item, meta = damage value
-
- // explosives + related
- dynamite; // Throwable Dynamite item, currently not meta sensitive
- stickyDynamite; // Throwable Sticky Dynamite item, currently not meta sensitive
-
- remote; // Dynamite Remote item, currently not meta sensitive
-
- // misc intermediate recipe ingredients
- electronicCircuit; // Electronic Circuit item, currently not meta sensitive
- advancedCircuit; // Advanced Circuit item, currently not meta sensitive
-
- advancedAlloy; // Advanced Alloy item, currently not meta sensitive
-
- carbonFiber; // Raw Carbon Fiber item, currently not meta sensitive
- carbonMesh; // Raw Carbon Mesh item, currently not meta sensitive
- carbonPlate; // Carbon Plate item, currently not meta sensitive
-
- matter; // UUA item, currently not meta sensitive
- iridiumOre; // Iridium Ore item, currently not meta sensitive
- iridiumPlate; // Iridium Plate item, currently not meta sensitive
-
-
- // Metal Plates
-
- platecopper; // Metal plate item, meta sensitive
- platetin; // Metal plate item, meta sensitive
- platebronze; // Metal plate item, meta sensitive
- plategold; // Metal plate item, meta sensitive
- plateiron; // Metal plate item, meta sensitive
- platelead; // Metal plate item, meta sensitive
- platelapi; // Metal plate item, meta sensitive
- plateobsidian; // Metal plate item, meta sensitive
- plateadviron; // Metal plate item, meta sensitive
-
- // Metal Dense Plates
- denseplatecopper; // Metal dense plate item, meta sensitive
- denseplatetin; // Metal dense plate item, meta sensitive
- denseplatebronze; // Metal dense plate item, meta sensitive
- denseplategold; // Metal dense plate item, meta sensitive
- denseplateiron; // Metal dense plate item, meta sensitive
- @Deprecated
- denseplateadviron; // Metal dense plate item, meta sensitive
- denseplatelead; // Metal dense plate item, meta sensitive
- denseplatelapi; // Metal dense plate item, meta sensitive
- denseplateobsidian; // Metal dense plate item, meta sensitive
-
-
- // upgrade modules
- overclockerUpgrade; // overclocker upgrade item, meta sensitive
- transformerUpgrade; // transformer upgrade item, meta sensitive
- energyStorageUpgrade; // energy storage upgrade item, meta sensitive
- ejectorUpgrade; // ejector upgrade item, meta sensitive
-
- // misc
- coin; // Coin item, currently not meta sensitive
- reinforcedDoor; // Reinforced Door item, currently not meta sensitive
- constructionFoamPowder; // Construction Foam Powder item, currently not meta sensitive
- grinPowder; // Poisonous ingrident, currently not meta sensitive
- debug; // Debug item, currently not meta sensitive
- boatCarbon; // Carbon Fiber Canoe item, meta sensitive
- boatRubber; // Rubber Dinghy item, meta sensitive
- boatRubberBroken; // Damaged Rubber Dinghy item, meta sensitive
- boatElectric; // Electric Boat item, meta sensitive
-
- //Agriculture
- cropSeed; // Crop seeds, stuff stored in NBT, don't use for crafting recipes!
- cropnalyzer; // Cropnalyzer handheld device
- fertilizer; // Basic IC2Item, used to provide nutrients toCropBlocks
- hydratingCell; // Cell used to hydrate Crops, meta = Content, 0= Full, 9999 = Near empty
- electricHoe; // Electric Hoe, Metadata indicates charge level
- terraWart; // Mystic opposite of NEtherWart, cures StatusEffects, simply consumeable
- weedEx; // Spraying can of WEED-EX, meta indicates usages left
-
- //Boozeception
- mugEmpty; // Simple stone mug
- coffeeBeans; // Harvested CoffeeBeans
- coffeePowder; // Processed Coffee Beans, used to craft drinkable Coffee
- mugCoffee; // Mug of Coffee, Meta indicates status 0 = cold, 1 = Normal, 2 = Sugar'd
- hops; // Hops, harvested freshly from crop
- barrel; // Carried Barrel, metadata encrypts the information about the liquid inside
- blockBarrel; // Unobtainable "placed barrel", TileEntity controlling the Fermentation process
- mugBooze; // Mug filled with booze, metadata encrypts the information about the liquid inside
-
- */
-
- /**
- * Get the base IC2 package name, used internally.
- *
- * @return IC2 package name, if unable to be determined defaults to ic2
- */
- private static String getPackage()
- {
- final Package pkg = IC2Items.class.getPackage();
-
- if(pkg != null)
- {
- final String packageName = pkg.getName();
-
- return packageName.substring(0, packageName.length() - ".api.item".length());
- }
-
- return "ic2";
- }
-
- private static Class<?> Ic2Items;
-}
diff --git a/src/api/java/ic2/api/item/ICustomDamageItem.java b/src/api/java/ic2/api/item/ICustomDamageItem.java
deleted file mode 100644
index 56590d1..0000000
--- a/src/api/java/ic2/api/item/ICustomDamageItem.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.item.ItemStack;
-
-/**
- * ICustomDamageItem allows items to have custom damage handling without the massive overhead of
- * Item.getDamage() / Item.setDamage(), which turn ItemStack.getItemDamage into virtual calls.
- *
- * The custom damage value is typically stored in the item stacks nbt data.
- *
- * If an Item implements ICusomDamageItem, the normal ItemStack damage won't be changed by IC2.
- * It's up to the implementer to potentially manipulate it for suitable visual effect on the
- * rendered damage bar or to provide a suitable item renderer.
- *
- * Item.isDamageable() still applies.
- *
- * @author Player
- */
-public interface ICustomDamageItem
-{
- /**
- * Retrieve the custom damage value for the supplied item stack.
- *
- * @param stack ItemStack to be queried.
- * @return Custom damage value.
- */
- int getCustomDamage(ItemStack stack);
-
- /**
- * Retrieve the maximum custom damage value for the supplied item stack.
- * @param stack ItemStack to be queried.
- * @return Custom damage value limit.
- */
- int getMaxCustomDamage(ItemStack stack);
-
- /**
- * Set the custom damage value for the supplied item stack.
- *
- * @param stack ItemStack to be manipulated.
- * @param damage New damage value.
- */
- void setCustomDamage(ItemStack stack, int damage);
-
- /**
- * Increase the custom damage value for the supplied item stack.
- *
- * It's up to the implementation to not apply any damage, e.g. based on some randomness or
- * properties of src.
- *
- * @param stack ItemStack to be manipulated.
- * @param damage Extra damage to be applied.
- * @param src Entity damaging the item, may be null.
- * @return true if damage was applied.
- */
- boolean applyCustomDamage(ItemStack stack, int damage, EntityLivingBase src);
-}
diff --git a/src/api/java/ic2/api/item/IDebuggable.java b/src/api/java/ic2/api/item/IDebuggable.java
deleted file mode 100644
index cd5159e..0000000
--- a/src/api/java/ic2/api/item/IDebuggable.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package ic2.api.item;
-
-/**
- * Allows a tile entity to output a debug message when the debugItem is used on it.
- * Suggestions by Myrathi
- */
-public abstract interface IDebuggable
-{
- /**
- * Checks if the tile entity is in a state that can be debugged.
- *
- * @return True if the tile entity can be debugged
- */
- public abstract boolean isDebuggable();
-
- /**
- * Gets the debug text for the tile entity.
- *
- * @return The text that the debugItem should show
- */
- public abstract String getDebugText();
-}
diff --git a/src/api/java/ic2/api/item/IElectricItem.java b/src/api/java/ic2/api/item/IElectricItem.java
deleted file mode 100644
index 14935a5..0000000
--- a/src/api/java/ic2/api/item/IElectricItem.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-
-/**
- * Provides the ability to store energy on the implementing item.
- *
- * The item should have a maximum damage of 13.
- */
-public interface IElectricItem
-{
- /**
- * Determine if the item can be used in a machine or as an armor part to supply energy.
- *
- * @return Whether the item can supply energy
- */
- boolean canProvideEnergy(ItemStack itemStack);
-
- /**
- * Get the item ID to use for a charge energy greater than 0.
- *
- * @return Item ID to use
- */
- Item getChargedItem(ItemStack itemStack);
-
- /**
- * Get the item ID to use for a charge energy of 0.
- *
- * @return Item ID to use
- */
- Item getEmptyItem(ItemStack itemStack);
-
- /**
- * Get the item's maximum charge energy in EU.
- *
- * @return Maximum charge energy
- */
- double getMaxCharge(ItemStack itemStack);
-
- /**
- * Get the item's tier, lower tiers can't send energy to higher ones.
- *
- * Batteries are Tier 1, Advanced Batteries are Tier 2, Energy Crystals are Tier 3, Lapotron
- * Crystals are Tier 4.
- *
- * @return Item's tier
- */
- int getTier(ItemStack itemStack);
-
- /**
- * Get the item's transfer limit in EU per transfer operation.
- *
- * @return Transfer limit
- */
- double getTransferLimit(ItemStack itemStack);
-}
diff --git a/src/api/java/ic2/api/item/IElectricItemManager.java b/src/api/java/ic2/api/item/IElectricItemManager.java
deleted file mode 100644
index 315ce90..0000000
--- a/src/api/java/ic2/api/item/IElectricItemManager.java
+++ /dev/null
@@ -1,96 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.item.ItemStack;
-
-/**
- * This interface specifies a manager to handle the various tasks for electric items.
- *
- * The default implementation does the following:
- * - store and retrieve the charge
- * - handle charging, taking amount, tier, transfer limit, canProvideEnergy and simulate into account
- * - replace item IDs if appropriate (getChargedItemId() and getEmptyItemId())
- * - update and manage the damage value for the visual charge indicator
- *
- * @note If you're implementing your own variant (ISpecialElectricItem), you can delegate to the
- * default implementations through ElectricItem.rawManager. The default implementation is designed
- * to minimize its dependency on its own constraints/structure and delegates most work back to the
- * more atomic features in the gateway manager.
- */
-public interface IElectricItemManager
-{
- /**
- * Charge an item with a specified amount of energy.
- *
- * @param itemStack electric item's stack
- * @param amount amount of energy to charge in EU
- * @param tier tier of the charging device, has to be at least as high as the item to charge
- * @param ignoreTransferLimit ignore the transfer limit specified by getTransferLimit()
- * @param simulate don't actually change the item, just determine the return value
- * @return Energy transferred into the electric item
- */
- double charge(ItemStack stack, double amount, int tier, boolean ignoreTransferLimit, boolean simulate);
-
- /**
- * Discharge an item by a specified amount of energy
- *
- * @param itemStack electric item's stack
- * @param amount amount of energy to discharge in EU
- * @param tier tier of the discharging device, has to be at least as high as the item to discharge
- * @param ignoreTransferLimit ignore the transfer limit specified by getTransferLimit()
- * @param externally use the supplied item externally, i.e. to power something else as if it was a battery
- * @param simulate don't actually discharge the item, just determine the return value
- * @return Energy retrieved from the electric item
- */
- double discharge(ItemStack stack, double amount, int tier, boolean ignoreTransferLimit, boolean externally, boolean simulate);
-
- /**
- * Determine the charge level for the specified item.
- *
- * @param itemStack ItemStack containing the electric item
- * @return charge level in EU
- */
- double getCharge(ItemStack stack);
-
- /**
- * Determine if the specified electric item has at least a specific amount of EU.
- * This is supposed to be used in the item code during operation, for example if you want to implement your own electric item.
- * BatPacks are not taken into account.
- *
- * @param itemStack electric item's stack
- * @param amount minimum amount of energy required
- * @return true if there's enough energy
- */
- boolean canUse(ItemStack stack, double amount);
-
- /**
- * Try to retrieve a specific amount of energy from an Item, and if applicable, a BatPack.
- * This is supposed to be used in the item code during operation, for example if you want to implement your own electric item.
- *
- * @param itemStack electric item's stack
- * @param amount amount of energy to discharge in EU
- * @param entity entity holding the item
- * @return true if the operation succeeded
- */
- boolean use(ItemStack stack, double amount, EntityLivingBase entity);
-
- /**
- * Charge an item from the BatPack a player is wearing.
- * This is supposed to be used in the item code during operation, for example if you want to implement your own electric item.
- * use() already contains this functionality.
- *
- * @param itemStack electric item's stack
- * @param entity entity holding the item
- */
- void chargeFromArmor(ItemStack stack, EntityLivingBase entity);
-
- /**
- * Get the tool tip to display for electric items.
- *
- * @param itemStack ItemStack to determine the tooltip for
- * @return tool tip string or null for none
- */
- String getToolTip(ItemStack stack);
-
- // TODO: add tier getter
-}
diff --git a/src/api/java/ic2/api/item/IItemHudInfo.java b/src/api/java/ic2/api/item/IItemHudInfo.java
deleted file mode 100644
index 77f0454..0000000
--- a/src/api/java/ic2/api/item/IItemHudInfo.java
+++ /dev/null
@@ -1,25 +0,0 @@
-package ic2.api.item;
-
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-
-public interface IItemHudInfo
-{
- /*
- Add Info to Nano- and Quantum-Suit Helm Hud
- for itemStack
-
- @Override
- public List<String> getHudInfo(ItemStack itemStack) {
- List<String> info = new LinkedList<String>();
- info.add("i am a Cool Item");
- info.add("and have Cool info");
- return info;
- }
-
-
- */
-
- public List<String> getHudInfo(ItemStack itemStack);
-}
diff --git a/src/api/java/ic2/api/item/IKineticRotor.java b/src/api/java/ic2/api/item/IKineticRotor.java
deleted file mode 100644
index a2547bc..0000000
--- a/src/api/java/ic2/api/item/IKineticRotor.java
+++ /dev/null
@@ -1,24 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ResourceLocation;
-
-public interface IKineticRotor
-{
- int getDiameter(ItemStack stack);
-
- ResourceLocation getRotorRenderTexture(ItemStack stack);
-
- float getEfficiency(ItemStack stack);
-
- int getMinWindStrength(ItemStack stack);
-
- int getMaxWindStrength(ItemStack stack);
-
- boolean isAcceptedType(ItemStack stack, GearboxType type);
-
- public static enum GearboxType
- {
- WATER, WIND,
- }
-}
diff --git a/src/api/java/ic2/api/item/ILatheItem.java b/src/api/java/ic2/api/item/ILatheItem.java
deleted file mode 100644
index b98760e..0000000
--- a/src/api/java/ic2/api/item/ILatheItem.java
+++ /dev/null
@@ -1,71 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ResourceLocation;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-/**
- * Interface used for Items that can be processed in the Turning Table
- */
-public interface ILatheItem
-{
-
- /**
- * Returns the radius of this Lathe Item
- * Should be no more than 15 to still be able to display it properly.
- */
- int getWidth(ItemStack stack);
-
- /**
- * Returns the current state of this Lathe Item
- * The length of the array should be 5
- * The value should be the current size of the item at this time.
- * It should also not be greater than getWidth()
- */
- int[] getCurrentState(ItemStack stack);
-
- /**
- * This will set the current state of the Item on that position to that value.
- */
- void setState(ItemStack stack, int position, int value);
-
- /**
- * Returns the output Item (normally dust) when you lathe on this position.
- */
- ItemStack getOutputItem(ItemStack stack, int position);
-
- /**
- * How common it is if the above item will be put into the output slot.
- * 1.0 means it will always be outputted, 0.0 means it will never be outputted.
- */
- float getOutputChance(ItemStack stack, int position);
-
- /**
- * Returns the ResourceLocation of the texture used to display the item inside of the Lathe GUI
- */
- @SideOnly(Side.CLIENT)
- ResourceLocation getTexture(ItemStack stack);
-
- /**
- * This is similar to the Block HarvestLevel. Requires a different tool for a different hardness
- * for ex. the Iron Turning Blank has a Hardness of 2 (Like Iron Ore (Harvest Level)).
- * In this case however it requires a Tool hardness of one above (3)
- */
- int getHardness(ItemStack stack);
-
- /**
- * Interface used for Tools that can be used to modify {@link ILatheItem}
- */
- public static interface ILatheTool extends ICustomDamageItem
- {
-
- /**
- * This is similar to the Tool HarvestLevel. Requires a different tool for a different hardness
- * for ex. the Iron Turning Blank has a Hardness of 2 (Like Iron Ore (Harvest Level)).
- * The tool requires a hardness of one level above (in this case 3)
- */
- int getHardness(ItemStack stack);
- }
-
-}
diff --git a/src/api/java/ic2/api/item/IMetalArmor.java b/src/api/java/ic2/api/item/IMetalArmor.java
deleted file mode 100644
index c067814..0000000
--- a/src/api/java/ic2/api/item/IMetalArmor.java
+++ /dev/null
@@ -1,21 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-
-/**
- * Armor items implementing this can be considered metal armor.
- *
- * Currently used for determining which boots can be used to slide up a magnetic pole.
- */
-public interface IMetalArmor
-{
- /**
- * Determine if the given armor piece is metal armor.
- *
- * @param itemstack Armor piece as worn by the player
- * @param player The player
- * @return Whether the armor piece is metal armor
- */
- public boolean isMetalArmor(ItemStack itemstack, EntityPlayer player);
-}
diff --git a/src/api/java/ic2/api/item/ISpecialElectricItem.java b/src/api/java/ic2/api/item/ISpecialElectricItem.java
deleted file mode 100644
index b73cf1d..0000000
--- a/src/api/java/ic2/api/item/ISpecialElectricItem.java
+++ /dev/null
@@ -1,14 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.item.ItemStack;
-
-public interface ISpecialElectricItem extends IElectricItem
-{
- /**
- * Supply a custom IElectricItemManager.
- *
- * @param itemStack ItemStack to get the manager for
- * @return IElectricItemManager instance
- */
- IElectricItemManager getManager(ItemStack itemStack);
-}
diff --git a/src/api/java/ic2/api/item/ITerraformingBP.java b/src/api/java/ic2/api/item/ITerraformingBP.java
deleted file mode 100644
index cbb1eba..0000000
--- a/src/api/java/ic2/api/item/ITerraformingBP.java
+++ /dev/null
@@ -1,35 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.world.World;
-
-/**
- * Allows an item to act as a terraformer blueprint.
- */
-public interface ITerraformingBP
-{
- /**
- * Get the energy consumption per operation of the blueprint.
- *
- * @return Energy consumption in EU
- */
- public abstract int getConsume();
-
- /**
- * Get the maximum range of the blueprint.
- * Should be a divisor of 5.
- *
- * @return Maximum range in blocks
- */
- public abstract int getRange();
-
- /**
- * Perform the terraforming operation.
- *
- * @param world world to terraform
- * @param x X position to terraform
- * @param z Z position to terraform
- * @param yCoord Y position of the terraformer
- * @return Whether the operation was successful and the terraformer should consume energy.
- */
- public abstract boolean terraform(World world, int x, int z, int yCoord);
-}
diff --git a/src/api/java/ic2/api/item/ItemWrapper.java b/src/api/java/ic2/api/item/ItemWrapper.java
deleted file mode 100644
index 9a4e4d8..0000000
--- a/src/api/java/ic2/api/item/ItemWrapper.java
+++ /dev/null
@@ -1,69 +0,0 @@
-package ic2.api.item;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-
-import com.google.common.collect.ArrayListMultimap;
-import com.google.common.collect.Multimap;
-
-/**
- * Wrapper for inserting interfaces into items you don't own.
- *
- * @author Richard
- */
-public class ItemWrapper
-{
- private static final Multimap<Item, IBoxable> boxableItems = ArrayListMultimap.create();
- private static final Multimap<Item, IMetalArmor> metalArmorItems = ArrayListMultimap.create();
-
- public static void registerBoxable(Item item, IBoxable boxable)
- {
- boxableItems.put(item, boxable);
- }
-
- public static boolean canBeStoredInToolbox(ItemStack stack)
- {
- final Item item = stack.getItem();
- // use customs first to allow for overriding behavior
- for(final IBoxable boxable : boxableItems.get(item))
- {
- if(boxable.canBeStoredInToolbox(stack))
- {
- return true;
- }
- }
-
- if(item instanceof IBoxable && ((IBoxable) item).canBeStoredInToolbox(stack))
- {
- return true;
- }
-
- return false;
- }
-
- public static void registerMetalArmor(Item item, IMetalArmor armor)
- {
- metalArmorItems.put(item, armor);
- }
-
- public static boolean isMetalArmor(ItemStack stack, EntityPlayer player)
- {
- final Item item = stack.getItem();
- // use customs first to allow for overriding behavior
- for(final IMetalArmor metalArmor : metalArmorItems.get(item))
- {
- if(metalArmor.isMetalArmor(stack, player))
- {
- return true;
- }
- }
-
- if(item instanceof IMetalArmor && ((IMetalArmor) item).isMetalArmor(stack, player))
- {
- return true;
- }
-
- return false;
- }
-}
diff --git a/src/api/java/ic2/api/item/package-info.java b/src/api/java/ic2/api/item/package-info.java
deleted file mode 100644
index f9d4d80..0000000
--- a/src/api/java/ic2/api/item/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.item;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/network/INetworkClientTileEntityEventListener.java b/src/api/java/ic2/api/network/INetworkClientTileEntityEventListener.java
deleted file mode 100644
index 000ce16..0000000
--- a/src/api/java/ic2/api/network/INetworkClientTileEntityEventListener.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ic2.api.network;
-
-import net.minecraft.entity.player.EntityPlayer;
-
-/**
- * Allows a tile entity to receive network events received from clients.
- */
-public interface INetworkClientTileEntityEventListener
-{
- /**
- * Called when a network event is received.
- *
- * @param player client which sent the event
- * @param event event ID
- */
- void onNetworkEvent(EntityPlayer player, int event);
-}
diff --git a/src/api/java/ic2/api/network/INetworkDataProvider.java b/src/api/java/ic2/api/network/INetworkDataProvider.java
deleted file mode 100644
index 86e58c7..0000000
--- a/src/api/java/ic2/api/network/INetworkDataProvider.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package ic2.api.network;
-
-import java.util.List;
-
-/**
- * Tile entities which want to synchronized specific fields between client and server have to implement this.
- *
- * The fields don't update themselves, a field update must be sent every time a synchronized field changes.
- */
-public interface INetworkDataProvider
-{
- /**
- * Get the list of synchronized fields.
- *
- * @return Names of the synchronized fields
- */
- List<String> getNetworkedFields();
-}
diff --git a/src/api/java/ic2/api/network/INetworkItemEventListener.java b/src/api/java/ic2/api/network/INetworkItemEventListener.java
deleted file mode 100644
index 6ddbb4b..0000000
--- a/src/api/java/ic2/api/network/INetworkItemEventListener.java
+++ /dev/null
@@ -1,19 +0,0 @@
-package ic2.api.network;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-
-/**
- * Allows an item to receive network events received from the server.
- */
-public interface INetworkItemEventListener
-{
- /**
- * Called when a network event is received.
- *
- * @param itemStack item stack
- * @param player player containing the item
- * @param event event ID
- */
- void onNetworkEvent(ItemStack stack, EntityPlayer player, int event);
-}
diff --git a/src/api/java/ic2/api/network/INetworkTileEntityEventListener.java b/src/api/java/ic2/api/network/INetworkTileEntityEventListener.java
deleted file mode 100644
index e3cd5c3..0000000
--- a/src/api/java/ic2/api/network/INetworkTileEntityEventListener.java
+++ /dev/null
@@ -1,14 +0,0 @@
-package ic2.api.network;
-
-/**
- * Allows a tile entity to receive network events received from the server.
- */
-public interface INetworkTileEntityEventListener
-{
- /**
- * Called when a network event is received.
- *
- * @param event Event ID
- */
- void onNetworkEvent(int event);
-}
diff --git a/src/api/java/ic2/api/network/INetworkUpdateListener.java b/src/api/java/ic2/api/network/INetworkUpdateListener.java
deleted file mode 100644
index a37fcaa..0000000
--- a/src/api/java/ic2/api/network/INetworkUpdateListener.java
+++ /dev/null
@@ -1,14 +0,0 @@
-package ic2.api.network;
-
-/**
- * Allows a tile entity to receive field sync updates received from the server.
- */
-public interface INetworkUpdateListener
-{
- /**
- * Called when a field is synchronized.
- *
- * @param field field synchronized
- */
- void onNetworkUpdate(String field);
-}
diff --git a/src/api/java/ic2/api/network/NetworkHelper.java b/src/api/java/ic2/api/network/NetworkHelper.java
deleted file mode 100644
index 0615e35..0000000
--- a/src/api/java/ic2/api/network/NetworkHelper.java
+++ /dev/null
@@ -1,248 +0,0 @@
-package ic2.api.network;
-
-import java.lang.reflect.Method;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-
-/**
- * Provides methods to initiate events and synchronize tile entity fields in SMP.
- *
- * The methods are transparent between singleplayer and multiplayer - if a method is called in
- * singleplayer, the associated callback will be locally executed. The implementation is different
- * between the client and server versions of IC2.
- *
- * You'll usually want to use the server->client methods defined here to synchronize information
- * which is needed by the clients outside the GUI, such as rendering the block, playing sounds or
- * producing effects. Anything which is only visible inside the GUI should be synchronized through
- * the Container class associated to the GUI in Container.updateProgressBar().
- */
-public final class NetworkHelper
-{
- // server -> client
-
- /**
- * Schedule a TileEntity's field to be updated to the clients in range.
- *
- * The updater will query the field's value during the next update, updates happen usually
- * every 2 ticks. If low latency is important use initiateTileEntityEvent instead.
- *
- * IC2's network updates have to get triggered every time, it doesn't continuously poll/send
- * the field value. Just call updateTileEntityField after every change to a field which needs
- * network synchronization.
- *
- * The following field data types are currently supported:
- * - int, int[], short, short[], byte, byte[], long, long[]
- * - float, float[], double, double[]
- * - boolean, boolean[]
- * - String, String[]
- * - ItemStack
- * - NBTBase (includes NBTTagCompound)
- * - Block, Item, Achievement, Potion, Enchantment
- * - ChunkCoordinates, ChunkCoordIntPair
- * - TileEntity (does not sync the actual tile entity, instead looks up the tile entity by its position in the client world)
- * - World (does not sync the actual world, instead looks up the world by its dimension ID)
- *
- * Once the update has been processed by the client, it'll call onNetworkUpdate on the client-
- * side TileEntity if it implements INetworkUpdateListener.
- *
- * If this method is being executed on the client (i.e. Singleplayer), it'll just call
- * INetworkUpdateListener.onNetworkUpdate (if implemented by the te).
- *
- * @param te TileEntity to update
- * @param field Name of the field to update
- */
- public static void updateTileEntityField(TileEntity te, String field)
- {
- try
- {
- if(NetworkManager_updateTileEntityField == null)
- {
- NetworkManager_updateTileEntityField = Class.forName(getPackage() + ".core.network.NetworkManager").getMethod("updateTileEntityField", TileEntity.class, String.class);
- }
- if(instance == null)
- {
- instance = getInstance();
- }
-
- NetworkManager_updateTileEntityField.invoke(instance, te, field);
- }
- catch(final Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Immediately send an event for the specified TileEntity to the clients in range.
- *
- * If this method is being executed on the client (i.e. Singleplayer), it'll just call
- * INetworkTileEntityEventListener.onNetworkEvent (if implemented by the te).
- *
- * @param te TileEntity to notify, should implement INetworkTileEntityEventListener
- * @param event Arbitrary integer to represent the event, choosing the values is up to you
- * @param limitRange Limit the notification range to (currently) 20 blocks instead of the
- * tracking distance if true
- */
- public static void initiateTileEntityEvent(TileEntity te, int event, boolean limitRange)
- {
- try
- {
- if(NetworkManager_initiateTileEntityEvent == null)
- {
- NetworkManager_initiateTileEntityEvent = Class.forName(getPackage() + ".core.network.NetworkManager").getMethod("initiateTileEntityEvent", TileEntity.class, Integer.TYPE, Boolean.TYPE);
- }
- if(instance == null)
- {
- instance = getInstance();
- }
-
- NetworkManager_initiateTileEntityEvent.invoke(instance, te, event, limitRange);
- }
- catch(final Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Immediately send an event for the specified Item to the clients in range.
- *
- * The item should implement INetworkItemEventListener to receive the event.
- *
- * If this method is being executed on the client (i.e. Singleplayer), it'll just call
- * INetworkItemEventListener.onNetworkEvent (if implemented by the item).
- *
- * @param player EntityPlayer holding the item
- * @param itemStack ItemStack containing the item
- * @param event Arbitrary integer to represent the event, choosing the values is up to you
- * @param limitRange Limit the notification range to (currently) 20 blocks instead of the
- * tracking distance if true
- */
- public static void initiateItemEvent(EntityPlayer player, ItemStack itemStack, int event, boolean limitRange)
- {
- try
- {
- if(NetworkManager_initiateItemEvent == null)
- {
- NetworkManager_initiateItemEvent = Class.forName(getPackage() + ".core.network.NetworkManager").getMethod("initiateItemEvent", EntityPlayer.class, ItemStack.class, Integer.TYPE, Boolean.TYPE);
- }
- if(instance == null)
- {
- instance = getInstance();
- }
-
- NetworkManager_initiateItemEvent.invoke(instance, player, itemStack, event, limitRange);
- }
- catch(final Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- // client -> server
-
- /**
- * Immediately send an event for the specified TileEntity to the server.
- *
- * This method doesn't do anything if executed on the server.
- *
- * @param te TileEntity to notify, should implement INetworkClientTileEntityEventListener
- * @param event Arbitrary integer to represent the event, choosing the values is up to you
- */
- public static void initiateClientTileEntityEvent(TileEntity te, int event)
- {
- try
- {
- if(NetworkManager_initiateClientTileEntityEvent == null)
- {
- NetworkManager_initiateClientTileEntityEvent = Class.forName(getPackage() + ".core.network.NetworkManager").getMethod("initiateClientTileEntityEvent", TileEntity.class, Integer.TYPE);
- }
- if(instance == null)
- {
- instance = getInstance();
- }
-
- NetworkManager_initiateClientTileEntityEvent.invoke(instance, te, event);
- }
- catch(final Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Immediately send an event for the specified Item to the clients in range.
- *
- * The item should implement INetworkItemEventListener to receive the event.
- *
- * This method doesn't do anything if executed on the server.
- *
- * @param itemStack ItemStack containing the item
- * @param event Arbitrary integer to represent the event, choosing the values is up to you
- */
- public static void initiateClientItemEvent(ItemStack itemStack, int event)
- {
- try
- {
- if(NetworkManager_initiateClientItemEvent == null)
- {
- NetworkManager_initiateClientItemEvent = Class.forName(getPackage() + ".core.network.NetworkManager").getMethod("initiateClientItemEvent", ItemStack.class, Integer.TYPE);
- }
- if(instance == null)
- {
- instance = getInstance();
- }
-
- NetworkManager_initiateClientItemEvent.invoke(instance, itemStack, event);
- }
- catch(final Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Get the base IC2 package name, used internally.
- *
- * @return IC2 package name, if unable to be determined defaults to ic2
- */
- private static String getPackage()
- {
- final Package pkg = NetworkHelper.class.getPackage();
-
- if(pkg != null)
- {
- final String packageName = pkg.getName();
-
- return packageName.substring(0, packageName.length() - ".api.network".length());
- }
-
- return "ic2";
- }
-
- /**
- * Get the NetworkManager instance, used internally.
- *
- * @return NetworkManager instance
- */
- private static Object getInstance()
- {
- try
- {
- return Class.forName(getPackage() + ".core.util.SideGateway").getMethod("get").invoke(Class.forName(getPackage() + ".core.IC2").getDeclaredField("network").get(null));
- }
- catch(final Throwable e)
- {
- throw new RuntimeException(e);
- }
- }
-
- private static Object instance;
- private static Method NetworkManager_updateTileEntityField;
- private static Method NetworkManager_initiateTileEntityEvent;
- private static Method NetworkManager_initiateItemEvent;
- private static Method NetworkManager_initiateClientTileEntityEvent;
- private static Method NetworkManager_initiateClientItemEvent;
-}
diff --git a/src/api/java/ic2/api/network/package-info.java b/src/api/java/ic2/api/network/package-info.java
deleted file mode 100644
index 1b69df8..0000000
--- a/src/api/java/ic2/api/network/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.network;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/package-info.java b/src/api/java/ic2/api/package-info.java
deleted file mode 100644
index 00ff182..0000000
--- a/src/api/java/ic2/api/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/reactor/IReactor.java b/src/api/java/ic2/api/reactor/IReactor.java
deleted file mode 100644
index 5009b32..0000000
--- a/src/api/java/ic2/api/reactor/IReactor.java
+++ /dev/null
@@ -1,158 +0,0 @@
-package ic2.api.reactor;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ChunkCoordinates;
-import net.minecraft.world.World;
-
-/**
- * Interface implemented by the tile entity of nuclear reactors.
- */
-public interface IReactor
-{
- /**
- * Get the reactor's position in the world.
- *
- * @return Position of the reactor
- */
- public ChunkCoordinates getPosition();
-
- /**
- * Get the reactor's corresponding world.
- *
- * @return The reactor's world
- */
- public World getWorld();
-
- /**
- * Get the reactor's heat.
- *
- * @return The reactor's heat
- */
- public int getHeat();
-
- /**
- * Set the reactor's heat.
- *
- * @param heat reactor heat
- */
- public void setHeat(int heat);
-
- /**
- * Increase the reactor's heat.
- *
- * Use negative values to decrease.
- *
- * @param amount amount of heat to add
- * @return The reactor's heat after adding the specified amount
- */
- public int addHeat(int amount);
-
- /**
- * Get the reactor's maximum heat before exploding.
- *
- * @return Maximum heat value
- */
- public int getMaxHeat();
-
- /**
- * Set the reactor's stored maxHeat variable.
- * Used by plating to increase the reactors MaxHeat capacity.
- * Needs to be called during each cycle process.
- */
- public void setMaxHeat(int newMaxHeat);
-
- /**
- * add Heat to a EmitHeat Buffer
- * for use in Reactor operation.. need to be use
- * for all Componetents with self-cooling
- * no more magic heat disappear
- */
-
- public void addEmitHeat(int heat);
-
- /**
- * Get's the reactor's HEM (Heat Effect Modifier)
- * Basic value is 1.0F.
- * Reducing the value causes a weakening/reduction of the heat-based sideeffects of reactors
- * (F.e. water evaporation, melting, damaging entitys, etc)
- *
- * @return HEM
- */
- public float getHeatEffectModifier();
-
- /**
- * Set's the reactor's HEM
- * Needs to be called during each cycle process.
- */
- public void setHeatEffectModifier(float newHEM);
-
- /**
- * Get the reactor's energy output.
- *
- * @return Energy output, not multiplied by the base EU/t value
- */
- public float getReactorEnergyOutput();
-
- /**
- * Get the reactor's energy output.
- *
- * @return Energy output, multiplied with base EU/t value and MainConfig.get().getFloat("balance/energy/generator/nuclear")
- */
- public double getReactorEUEnergyOutput();
-
- /**
- * Add's the given amount of energy to the Reactor's output.
- *
- * @return Energy output after adding the value, not multiplied by the base EU/t value
- */
- public float addOutput(float energy);
-
- /**
- * Get the item at the specified grid coordinates.
- *
- * @param x X position of the item, out of bounds returns null
- * @param y Y position of the item, out of bounds returns null
- * @return The item or null if there is no item
- */
- public ItemStack getItemAt(int x, int y);
-
- /**
- * Set the item at the specified grid coordinates.
- *
- * @param x X position of the item, out of bounds is a no-op
- * @param y Y position of the item, out of bounds is a no-op
- * @param item The item to set.
- */
- public void setItemAt(int x, int y, ItemStack item);
-
- /**
- * Explode the reactor.
- */
- public void explode();
-
- /**
- * Get the reactor's tick rate (game ticks per reactor tick).
- *
- * @return Tick rate
- */
- public int getTickRate();
-
- /**
- * Get whether the reactor is active and supposed to produce energy
- * @return Whether the reactor is active
- */
- public boolean produceEnergy();
-
- /**
- * Set Redstone Signal without direct contact
- *
- */
-
- public void setRedstoneSignal(boolean redstone);
-
- /**
- * @return true if the reactor is FluidCooled
- */
-
- public boolean isFluidCooled();
-}
diff --git a/src/api/java/ic2/api/reactor/IReactorChamber.java b/src/api/java/ic2/api/reactor/IReactorChamber.java
deleted file mode 100644
index 66463b3..0000000
--- a/src/api/java/ic2/api/reactor/IReactorChamber.java
+++ /dev/null
@@ -1,21 +0,0 @@
-package ic2.api.reactor;
-
-/**
- * Interface implemented by the reactor chamber tile entity.
- */
-public interface IReactorChamber
-{
- /**
- * Get the chamber's reactor.
- *
- * @return The reactor
- */
- public IReactor getReactor();
-
- /**
- * Set Redstone Signal without direct contact
- *
- */
-
- public void setRedstoneSignal(boolean redstone);
-}
diff --git a/src/api/java/ic2/api/reactor/IReactorComponent.java b/src/api/java/ic2/api/reactor/IReactorComponent.java
deleted file mode 100644
index 4b4d8ad..0000000
--- a/src/api/java/ic2/api/reactor/IReactorComponent.java
+++ /dev/null
@@ -1,99 +0,0 @@
-package ic2.api.reactor;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Design custom Reactor components by implementing this Interface
- * Items implementing the interface will not be ejected from Reactors in their clean-up
- * and can/will be interacted with by other elements, f.e. Uranium Cells.
- *
- * All IC2 ReactorComponents implement and use this Interface
- *
- */
-public interface IReactorComponent
-{
- /**
- * Called by reactor upon iterating through it's inventory (every cycle).
- * Perform all necessary calculation/interaction here
- *
- * @param reactor Reference to the Reactor
- * @param yourStack Reference to the specific instance of iterated ItemStack
- * @param x X-coordinate of the stack in the grid
- * @param y Y-coordinate of the stack in the grid
- * @param heatrun every Stack will cycle 2 time (true, false) first run for heat, sec for Eu calculation
- */
- public void processChamber(IReactor reactor, ItemStack yourStack, int x, int y, boolean heatrun);
-
- /**
- * Can be called by Uranium-Components who attempt to generate energy by pulsing to other components.
- * Uranium-Uranium interaction (f.e.) uses this method.
- * @param reactor Reference to the Reactor
- * @param yourStack Reference to the specific instance of called ItemStack
- * @param pulsingStack Reference to the specific instance of pulsing ItemStack
- * @param youX X-coordinate of your stack in the grid
- * @param youY Y-coordinate of your stack in the grid
- * @param pulseX X-coordinate of pulsing stack in the grid
- * @param pulseY Y-coordinate of pulsing stack in the grid
- * @param heatrun true for only create heat not EU, false for only EU not heat
- * @return true if this component reacts to the pulse (and pulse is therefore meant to produce heat)
- */
- public boolean acceptUraniumPulse(IReactor reactor, ItemStack yourStack, ItemStack pulsingStack, int youX, int youY, int pulseX, int pulseY, boolean heatrun);
-
- /**
- * Called by components to determine whether your component can be heated.
- * @param reactor Reference to the Reactor
- * @param yourStack Reference to the specific instance of iterated ItemStack
- * @param x X-coordinate of the stack in the grid
- * @param y Y-coordinate of the stack in the grid
- * @return true if your component can take heat
- */
- public boolean canStoreHeat(IReactor reactor, ItemStack yourStack, int x, int y);
-
- /**
- * Called by heat-switches to determine how much heat to distribute into which direction.
- * Please return the maximum capacity of your heat-containing component here.
- * @param reactor Reference to the Reactor
- * @param yourStack Reference to the specific instance of iterated ItemStack
- * @param x X-coordinate of the stack in the grid
- * @param y Y-coordinate of the stack in the grid
- * @return Maximum heat
- */
- public int getMaxHeat(IReactor reactor, ItemStack yourStack, int x, int y);
-
- /**
- * Called by heat-switches to determine how much heat to distribute into which direction.
- * Please return the current amount of heat stored in this component
- * @param reactor Reference to the Reactor
- * @param yourStack Reference to the specific instance of iterated ItemStack
- * @param x X-coordinate of the stack in the grid
- * @param y Y-coordinate of the stack in the grid
- * @return Current Heat
- */
- public int getCurrentHeat(IReactor reactor, ItemStack yourStack, int x, int y);
-
- /**
- * Called by components to distribute heat to your component.
- * Perform heating-calculations and increase your heat (dmg) level accordingly.
- * This method will as well be called to REDUCE heat, by providing a negative amount.
- *
- * @param reactor Reference to the Reactor
- * @param yourStack Reference to the specific instance of iterated ItemStack
- * @param x X-coordinate of the stack in the grid
- * @param y Y-coordinate of the stack in the grid
- * @param heat Amount of heat to be added (may be negative to subtract heat)
- * @return 0 if the 'order' was accepted, return >0 to indicate the 'remaining' heat which couldn't be absorbed (and vice versa for <0)
- */
- public int alterHeat(IReactor reactor, ItemStack yourStack, int x, int y, int heat);
-
- /**
- * Called upon reactor explosion
- * Alter the explosion size.
- * Returning a float 0 < f < 1 will be counted as multiplier.
- * Anything else will be counted as a flat addition (in case of <0 = reduction).
- *
- * @param reactor Reference to the Reactor
- * @param yourStack Reference to the specific instance of iterated ItemStack
- * @return your explosion modifier
- */
- public float influenceExplosion(IReactor reactor, ItemStack yourStack);
-}
diff --git a/src/api/java/ic2/api/reactor/package-info.java b/src/api/java/ic2/api/reactor/package-info.java
deleted file mode 100644
index 7b70911..0000000
--- a/src/api/java/ic2/api/reactor/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.reactor;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/recipe/ICannerBottleRecipeManager.java b/src/api/java/ic2/api/recipe/ICannerBottleRecipeManager.java
deleted file mode 100644
index 6f64585..0000000
--- a/src/api/java/ic2/api/recipe/ICannerBottleRecipeManager.java
+++ /dev/null
@@ -1,54 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Map;
-
-import net.minecraft.item.ItemStack;
-
-public interface ICannerBottleRecipeManager
-{
- /**
- * Adds a recipe to the machine.
- *
- * @param container Container to be filled
- * @param fill Item to fill into the container
- * @param output Filled container
- */
- public void addRecipe(IRecipeInput container, IRecipeInput fill, ItemStack output);
-
- /**
- * Gets the recipe output for the given input.
- *
- * @param container Container to be filled
- * @param fill Item to fill into the container
- * @param adjustInput modify the input according to the recipe's requirements
- * @param acceptTest allow either container or fill to be null to see if either of them is part of a recipe
- * @return Recipe output, or null if none
- */
- public RecipeOutput getOutputFor(ItemStack container, ItemStack fill, boolean adjustInput, boolean acceptTest);
-
- /**
- * Gets a list of recipes.
- *
- * You're a mad evil scientist if you ever modify this.
- *
- * @return List of recipes
- */
- public Map<Input, RecipeOutput> getRecipes();
-
- public static class Input
- {
- public Input(IRecipeInput container1, IRecipeInput fill1)
- {
- container = container1;
- fill = fill1;
- }
-
- public boolean matches(ItemStack container1, ItemStack fill1)
- {
- return container.matches(container1) && fill.matches(fill1);
- }
-
- public final IRecipeInput container;
- public final IRecipeInput fill;
- }
-}
diff --git a/src/api/java/ic2/api/recipe/ICannerEnrichRecipeManager.java b/src/api/java/ic2/api/recipe/ICannerEnrichRecipeManager.java
deleted file mode 100644
index c4141ab..0000000
--- a/src/api/java/ic2/api/recipe/ICannerEnrichRecipeManager.java
+++ /dev/null
@@ -1,55 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Map;
-
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidStack;
-
-public interface ICannerEnrichRecipeManager
-{
- /**
- * Adds a recipe to the machine.
- *
- * @param input Fluid input
- * @param additive Item to enrich the fluid with
- * @param output Output fluid
- */
- public void addRecipe(FluidStack input, IRecipeInput additive, FluidStack output);
-
- /**
- * Gets the recipe output for the given input.
- *
- * @param input Fluid input
- * @param additive Item to enrich the fluid with
- * @param adjustInput modify the input according to the recipe's requirements
- * @param acceptTest allow input or additive to be null to see if either of them is part of a recipe
- * @return Recipe output, or null if none, output fluid in nbt
- */
- public RecipeOutput getOutputFor(FluidStack input, ItemStack additive, boolean adjustInput, boolean acceptTest);
-
- /**
- * Gets a list of recipes.
- *
- * You're a mad evil scientist if you ever modify this.
- *
- * @return List of recipes
- */
- public Map<Input, FluidStack> getRecipes();
-
- public static class Input
- {
- public Input(FluidStack fluid1, IRecipeInput additive1)
- {
- fluid = fluid1;
- additive = additive1;
- }
-
- public boolean matches(FluidStack fluid1, ItemStack additive1)
- {
- return (fluid == null || fluid.isFluidEqual(fluid1)) && additive.matches(additive1);
- }
-
- public final FluidStack fluid;
- public final IRecipeInput additive;
- }
-}
diff --git a/src/api/java/ic2/api/recipe/ICraftingRecipeManager.java b/src/api/java/ic2/api/recipe/ICraftingRecipeManager.java
deleted file mode 100644
index 12583a9..0000000
--- a/src/api/java/ic2/api/recipe/ICraftingRecipeManager.java
+++ /dev/null
@@ -1,27 +0,0 @@
-package ic2.api.recipe;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Recipe manager interface for crafting recipes.
- *
- * @author Richard
- */
-public interface ICraftingRecipeManager
-{
- /**
- * Adds a shaped crafting recipe.
- *
- * @param output Recipe output
- * @param input Recipe input format
- */
- public void addRecipe(ItemStack output, Object... input);
-
- /**
- * Adds a shapeless crafting recipe.
- *
- * @param output Recipe output
- * @param input Recipe input
- */
- public void addShapelessRecipe(ItemStack output, Object... input);
-}
diff --git a/src/api/java/ic2/api/recipe/IFluidHeatManager.java b/src/api/java/ic2/api/recipe/IFluidHeatManager.java
deleted file mode 100644
index ee8be18..0000000
--- a/src/api/java/ic2/api/recipe/IFluidHeatManager.java
+++ /dev/null
@@ -1,33 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Map;
-
-import net.minecraftforge.fluids.Fluid;
-
-public interface IFluidHeatManager extends ILiquidAcceptManager
-{
- /**
- * Add a new fluid to the Fluid Heat Generator.
- *
- * @param fluidName the fluid to burn
- * @param amount amount of fluid to consume per tick
- * @param heat amount of heat generated per tick
- */
- void addFluid(String fluidName, int amount, int heat);
-
- BurnProperty getBurnProperty(Fluid fluid);
-
- Map<String, BurnProperty> getBurnProperties();
-
- public static class BurnProperty
- {
- public BurnProperty(int amount1, int heat1)
- {
- amount = amount1;
- heat = heat1;
- }
-
- public final int amount;
- public final int heat;
- }
-}
diff --git a/src/api/java/ic2/api/recipe/ILiquidAcceptManager.java b/src/api/java/ic2/api/recipe/ILiquidAcceptManager.java
deleted file mode 100644
index 6483c34..0000000
--- a/src/api/java/ic2/api/recipe/ILiquidAcceptManager.java
+++ /dev/null
@@ -1,12 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Set;
-
-import net.minecraftforge.fluids.Fluid;
-
-public interface ILiquidAcceptManager
-{
- boolean acceptsFluid(Fluid fluid);
-
- Set<Fluid> getAcceptedFluids();
-}
diff --git a/src/api/java/ic2/api/recipe/ILiquidHeatExchangerManager.java b/src/api/java/ic2/api/recipe/ILiquidHeatExchangerManager.java
deleted file mode 100644
index 1fc079c..0000000
--- a/src/api/java/ic2/api/recipe/ILiquidHeatExchangerManager.java
+++ /dev/null
@@ -1,42 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Map;
-
-import net.minecraftforge.fluids.Fluid;
-
-public interface ILiquidHeatExchangerManager extends ILiquidAcceptManager
-{
-
- /**
- * Add a new fluid heatup/cooldown recipe.
- *
- * @param fluidName the fluid to heat up/cool down
- * @param fluidOutput the fluid the above fluid turns into
- * @param huPerMB the Thermal Energy difference in hU for the conversion of one mB fluid
- */
- void addFluid(String fluidName, String fluidOutput, int huPerMB);
-
- HeatExchangeProperty getHeatExchangeProperty(Fluid fluid);
-
- Map<String, HeatExchangeProperty> getHeatExchangeProperties();
-
- /**
- * This returns an ILiquidAcceptManager that only accepts fluids, that can be heated up / cooled down, but not both.
- * You can basically use this to check if the liquid resulting from this conversion can be reprocessed into the first one.
- * @return Returns the SingleDirectionManager.
- */
- ILiquidAcceptManager getSingleDirectionLiquidManager();
-
- public static class HeatExchangeProperty
- {
- public HeatExchangeProperty(Fluid outputFluid, int huPerMB)
- {
- this.outputFluid = outputFluid;
- this.huPerMB = huPerMB;
- }
-
- public final Fluid outputFluid;
- public final int huPerMB;
- }
-
-}
diff --git a/src/api/java/ic2/api/recipe/IListRecipeManager.java b/src/api/java/ic2/api/recipe/IListRecipeManager.java
deleted file mode 100644
index d488335..0000000
--- a/src/api/java/ic2/api/recipe/IListRecipeManager.java
+++ /dev/null
@@ -1,42 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Recipe manager interface for basic lists.
- *
- * @author Richard
- */
-public interface IListRecipeManager extends Iterable<IRecipeInput>
-{
- /**
- * Adds a stack to the list.
- *
- * @param stack Stack to add
- */
- public void add(IRecipeInput input);
-
- /**
- * Checks whether the specified stack is in the list.
- *
- * @param stack Stack to check
- * @return Whether the stack is in the list
- */
- public boolean contains(ItemStack stack);
-
- /**
- * @return if the List is Empty
- */
- public boolean isEmpty();
-
- /**
- * Gets the list of stacks.
- *
- * You're a mad evil scientist if you ever modify this.
- *
- * @return List of stacks
- */
- public List<IRecipeInput> getInputs();
-}
diff --git a/src/api/java/ic2/api/recipe/IMachineRecipeManager.java b/src/api/java/ic2/api/recipe/IMachineRecipeManager.java
deleted file mode 100644
index ff391f8..0000000
--- a/src/api/java/ic2/api/recipe/IMachineRecipeManager.java
+++ /dev/null
@@ -1,45 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Map;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-
-/**
- * Recipe manager interface for basic machines.
- *
- * @author RichardG, Player
- */
-public interface IMachineRecipeManager
-{ // TODO: merge with IMachineRecipeManagerExt
- /**
- * Adds a recipe to the machine.
- *
- * @param input Recipe input
- * @param metadata meta data for additional recipe properties, may be null
- * @param outputs Recipe outputs, zero or more depending on the machine
- *
- * For the thermal centrifuge @param metadata meta data {"minHeat": 1-xxx}
- * For the ore washing plant @param metadata meta data {"amount": 1-8000}
- *
- */
- public void addRecipe(IRecipeInput input, NBTTagCompound metadata, ItemStack... outputs);
-
- /**
- * Gets the recipe output for the given input.
- *
- * @param input Recipe input
- * @param adjustInput modify the input according to the recipe's requirements
- * @return Recipe output, or null if none
- */
- public RecipeOutput getOutputFor(ItemStack input, boolean adjustInput);
-
- /**
- * Gets a list of recipes.
- *
- * You're a mad evil scientist if you ever modify this.
- *
- * @return List of recipes
- */
- public Map<IRecipeInput, RecipeOutput> getRecipes(); // TODO: Change to iterable/collection/list
-}
diff --git a/src/api/java/ic2/api/recipe/IMachineRecipeManagerExt.java b/src/api/java/ic2/api/recipe/IMachineRecipeManagerExt.java
deleted file mode 100644
index 6dc4715..0000000
--- a/src/api/java/ic2/api/recipe/IMachineRecipeManagerExt.java
+++ /dev/null
@@ -1,23 +0,0 @@
-package ic2.api.recipe;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-
-public interface IMachineRecipeManagerExt extends IMachineRecipeManager
-{
- /**
- * Adds a recipe to the machine.
- *
- * @note Overwrite is only as reliable as IRecipeInput.getInputs().
- *
- * @param input Recipe input
- * @param metadata Meta data for additional recipe properties, may be null.
- * @param overwrite Replace an existing recipe, not recommended, may be ignored.
- * @param outputs Recipe outputs, zero or more depending on the machine.
- * @return true on success, false otherwise, e.g. on conflicts.
- *
- * For the thermal centrifuge @param metadata meta data {"minHeat": 1-xxx}
- * For the ore washing plant @param metadata meta data {"amount": 1-8000}
- */
- public boolean addRecipe(IRecipeInput input, NBTTagCompound metadata, boolean overwrite, ItemStack... outputs);
-}
diff --git a/src/api/java/ic2/api/recipe/IPatternStorage.java b/src/api/java/ic2/api/recipe/IPatternStorage.java
deleted file mode 100644
index 2b646f3..0000000
--- a/src/api/java/ic2/api/recipe/IPatternStorage.java
+++ /dev/null
@@ -1,12 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-
-public interface IPatternStorage
-{
- boolean addPattern(ItemStack itemstack);
-
- List<ItemStack> getPatterns();
-}
diff --git a/src/api/java/ic2/api/recipe/IRecipeInput.java b/src/api/java/ic2/api/recipe/IRecipeInput.java
deleted file mode 100644
index 99249bb..0000000
--- a/src/api/java/ic2/api/recipe/IRecipeInput.java
+++ /dev/null
@@ -1,32 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-
-public interface IRecipeInput
-{
- /**
- * Check if subject matches this recipe input, ignoring the amount.
- *
- * @param subject ItemStack to check
- * @return true if it matches the requirement
- */
- boolean matches(ItemStack subject);
-
- /**
- * Determine the minimum input stack size.
- *
- * @return input amount required
- */
- int getAmount();
-
- /**
- * List all possible inputs (best effort).
- *
- * The stack size is undefined, use getAmount to get the correct one.
- *
- * @return list of inputs, may be incomplete
- */
- List<ItemStack> getInputs();
-}
diff --git a/src/api/java/ic2/api/recipe/IScrapboxManager.java b/src/api/java/ic2/api/recipe/IScrapboxManager.java
deleted file mode 100644
index 4828591..0000000
--- a/src/api/java/ic2/api/recipe/IScrapboxManager.java
+++ /dev/null
@@ -1,14 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Map;
-
-import net.minecraft.item.ItemStack;
-
-public interface IScrapboxManager
-{
- void addDrop(ItemStack drop, float rawChance);
-
- ItemStack getDrop(ItemStack input, boolean adjustInput);
-
- Map<ItemStack, Float> getDrops();
-}
diff --git a/src/api/java/ic2/api/recipe/ISemiFluidFuelManager.java b/src/api/java/ic2/api/recipe/ISemiFluidFuelManager.java
deleted file mode 100644
index 1503a18..0000000
--- a/src/api/java/ic2/api/recipe/ISemiFluidFuelManager.java
+++ /dev/null
@@ -1,33 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Map;
-
-import net.minecraftforge.fluids.Fluid;
-
-public interface ISemiFluidFuelManager extends ILiquidAcceptManager
-{
- /**
- * Add a new fluid to the semi fluid generator.
- *
- * @param fluidName the fluid to burn
- * @param amount amount of fluid to consume per tick
- * @param power amount of energy generated per tick
- */
- void addFluid(String fluidName, int amount, double power);
-
- BurnProperty getBurnProperty(Fluid fluid);
-
- Map<String, BurnProperty> getBurnProperties();
-
- public static class BurnProperty
- {
- public BurnProperty(int amount1, double power1)
- {
- amount = amount1;
- power = power1;
- }
-
- public final int amount;
- public final double power;
- }
-}
diff --git a/src/api/java/ic2/api/recipe/RecipeInputFluidContainer.java b/src/api/java/ic2/api/recipe/RecipeInputFluidContainer.java
deleted file mode 100644
index 7f9ba8c..0000000
--- a/src/api/java/ic2/api/recipe/RecipeInputFluidContainer.java
+++ /dev/null
@@ -1,67 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidContainerRegistry;
-import net.minecraftforge.fluids.FluidContainerRegistry.FluidContainerData;
-import net.minecraftforge.fluids.FluidStack;
-
-public class RecipeInputFluidContainer implements IRecipeInput
-{
- public RecipeInputFluidContainer(Fluid fluid)
- {
- this(fluid, FluidContainerRegistry.BUCKET_VOLUME);
- }
-
- public RecipeInputFluidContainer(Fluid fluid, int amount)
- {
- this.fluid = fluid;
- this.amount = amount;
- }
-
- @Override
- public boolean matches(ItemStack subject)
- {
- final FluidStack fs = FluidContainerRegistry.getFluidForFilledItem(subject);
- if(fs == null)
- {
- return false;
- }
-
- return fs.getFluid() == fluid;
- }
-
- @Override
- public int getAmount()
- {
- return amount;
- }
-
- @Override
- public List<ItemStack> getInputs()
- {
- final List<ItemStack> ret = new ArrayList<ItemStack>();
-
- for(final FluidContainerData data : FluidContainerRegistry.getRegisteredFluidContainerData())
- {
- if(data.fluid.getFluid() == fluid)
- {
- ret.add(data.filledContainer);
- }
- }
-
- return ret;
- }
-
- @Override
- public String toString()
- {
- return "RInputFluidContainer<" + amount + "x" + fluid.getName() + ">";
- }
-
- public final Fluid fluid;
- public final int amount;
-}
diff --git a/src/api/java/ic2/api/recipe/RecipeInputItemStack.java b/src/api/java/ic2/api/recipe/RecipeInputItemStack.java
deleted file mode 100644
index 41a6012..0000000
--- a/src/api/java/ic2/api/recipe/RecipeInputItemStack.java
+++ /dev/null
@@ -1,55 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Arrays;
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
-
-public class RecipeInputItemStack implements IRecipeInput
-{
- public RecipeInputItemStack(ItemStack aInput)
- {
- this(aInput, aInput.stackSize);
- }
-
- public RecipeInputItemStack(ItemStack aInput, int aAmount)
- {
- if(aInput.getItem() == null)
- {
- throw new IllegalArgumentException("Invalid item stack specfied");
- }
-
- input = aInput.copy(); // Never forget to copy.
- amount = aAmount;
- }
-
- @Override
- public boolean matches(ItemStack subject)
- {
- return subject.getItem() == input.getItem() && (subject.getItemDamage() == input.getItemDamage() || input.getItemDamage() == OreDictionary.WILDCARD_VALUE);
- }
-
- @Override
- public int getAmount()
- {
- return amount;
- }
-
- @Override
- public List<ItemStack> getInputs()
- {
- return Arrays.asList(input);
- }
-
- @Override
- public String toString()
- {
- final ItemStack stack = input.copy();
- input.stackSize = amount;
- return "RInputItemStack<" + stack + ">";
- }
-
- public final ItemStack input;
- public final int amount;
-}
diff --git a/src/api/java/ic2/api/recipe/RecipeInputOreDict.java b/src/api/java/ic2/api/recipe/RecipeInputOreDict.java
deleted file mode 100644
index 173e6b3..0000000
--- a/src/api/java/ic2/api/recipe/RecipeInputOreDict.java
+++ /dev/null
@@ -1,134 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
-
-public class RecipeInputOreDict implements IRecipeInput
-{
- public RecipeInputOreDict(String input1)
- {
- this(input1, 1);
- }
-
- public RecipeInputOreDict(String input1, int amount1)
- {
- this(input1, amount1, null);
- }
-
- public RecipeInputOreDict(String input1, int amount1, Integer meta)
- {
- input = input1;
- amount = amount1;
- this.meta = meta;
- }
-
- @Override
- public boolean matches(ItemStack subject)
- {
- final List<ItemStack> inputs = getOres();
- final boolean useOreStackMeta = (meta == null);
- final Item subjectItem = subject.getItem();
- final int subjectMeta = subject.getItemDamage();
-
- for(final ItemStack oreStack : inputs)
- {
- final Item oreItem = oreStack.getItem();
- if(oreItem == null)
- {
- continue; // ignore invalid
- }
-
- final int metaRequired = useOreStackMeta ? oreStack.getItemDamage() : meta;
-
- if(subjectItem == oreItem && (subjectMeta == metaRequired || metaRequired == OreDictionary.WILDCARD_VALUE))
- {
- return true;
- }
- }
-
- return false;
- }
-
- @Override
- public int getAmount()
- {
- return amount;
- }
-
- @Override
- public List<ItemStack> getInputs()
- {
- final List<ItemStack> ores = getOres();
-
- // check if we have to filter the list first
- boolean hasInvalidEntries = false;
-
- for(final ItemStack stack : ores)
- {
- if(stack.getItem() == null)
- {
- hasInvalidEntries = true;
- break;
- }
- }
-
- if(!hasInvalidEntries)
- {
- return ores;
- }
-
- final List<ItemStack> ret = new ArrayList<ItemStack>(ores.size());
-
- for(final ItemStack stack : ores)
- {
- if(stack.getItem() != null)
- {
- ret.add(stack); // ignore invalid
- }
- }
-
- return Collections.unmodifiableList(ret);
- }
-
- @Override
- public String toString()
- {
- if(meta == null)
- {
- return "RInputOreDict<" + amount + "x" + input + ">";
- }
- else
- {
- return "RInputOreDict<" + amount + "x" + input + "@" + meta + ">";
- }
- }
-
- private List<ItemStack> getOres()
- {
- if(ores != null)
- {
- return ores;
- }
-
- // cache the ore list by making use of the fact that forge always uses the same list,
- // unless it's EMPTY_LIST, which should never happen.
- final List<ItemStack> ret = OreDictionary.getOres(input);
-
- if(ret != OreDictionary.EMPTY_LIST)
- {
- ores = ret;
- }
-
- return ret;
- }
-
- public final String input;
- public final int amount;
- public final Integer meta;
- private List<ItemStack> ores;
-}
diff --git a/src/api/java/ic2/api/recipe/RecipeOutput.java b/src/api/java/ic2/api/recipe/RecipeOutput.java
deleted file mode 100644
index aa7839d..0000000
--- a/src/api/java/ic2/api/recipe/RecipeOutput.java
+++ /dev/null
@@ -1,63 +0,0 @@
-package ic2.api.recipe;
-
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-
-public final class RecipeOutput
-{
- public RecipeOutput(NBTTagCompound metadata1, List<ItemStack> items1)
- {
- assert !items1.contains(null);
-
- metadata = metadata1;
- items = items1;
- }
-
- public RecipeOutput(NBTTagCompound metadata1, ItemStack... items1)
- {
- this(metadata1, Arrays.asList(items1));
- }
-
- @Override
- public boolean equals(Object obj)
- {
- if(obj instanceof RecipeOutput)
- {
- final RecipeOutput ro = (RecipeOutput) obj;
-
- if(items.size() == ro.items.size() && (metadata == null && ro.metadata == null || metadata != null && ro.metadata != null && metadata.equals(ro.metadata)))
- {
- final Iterator<ItemStack> itA = items.iterator();
- final Iterator<ItemStack> itB = ro.items.iterator();
-
- while(itA.hasNext() && itB.hasNext())
- {
- final ItemStack stackA = itA.next();
- final ItemStack stackB = itB.next();
-
- if(ItemStack.areItemStacksEqual(stackA, stackB))
- {
- return false;
- }
- }
-
- return true;
- }
- }
-
- return false;
- }
-
- @Override
- public String toString()
- {
- return "ROutput<" + items + "," + metadata + ">";
- }
-
- public final List<ItemStack> items;
- public final NBTTagCompound metadata;
-}
diff --git a/src/api/java/ic2/api/recipe/Recipes.java b/src/api/java/ic2/api/recipe/Recipes.java
deleted file mode 100644
index 0bcc71b..0000000
--- a/src/api/java/ic2/api/recipe/Recipes.java
+++ /dev/null
@@ -1,68 +0,0 @@
-package ic2.api.recipe;
-
-/**
- * General recipe registry.
- *
- * @author Richard
- */
-public class Recipes
-{
- public static IMachineRecipeManager macerator;
- public static IMachineRecipeManager extractor;
- public static IMachineRecipeManager compressor;
- public static IMachineRecipeManager centrifuge;
- public static IMachineRecipeManager blockcutter;
- public static IMachineRecipeManager blastfurance;
- public static IMachineRecipeManager recycler;
- public static IMachineRecipeManager metalformerExtruding;
- public static IMachineRecipeManager metalformerCutting;
- public static IMachineRecipeManager metalformerRolling;
- public static IMachineRecipeManager oreWashing;
- public static ICannerBottleRecipeManager cannerBottle;
- public static ICannerEnrichRecipeManager cannerEnrich;
-
- /**
- * Reference amplifier values:
- *
- * 5000: Scrap
- * 45000: Scrapbox
- *
- * As Parameter for the Amplification Value you have to use the NBTTagCompound
- *
- * NBTTagCompound nbt = new NBTTagCompound();
- * nbt.setInteger("amplification", aValue);
- * matterAmplifier.addRecipe(yourStack, nbt);
- */
- public static IMachineRecipeManager matterAmplifier;
- /**
- * Reference scrap box chance values:
- *
- * 0.1: Diamond
- * 0.5: Cake, Gold Helmet, Iron Ore, Gold Ore
- * 1.0: Wooden tools, Soul Sand, Sign, Leather, Feather, Bone
- * 1.5: Apple, Bread
- * 2.0: Netherrack, Rotten Flesh
- * 3.0: Grass, Gravel
- * 4.0: Stick
- * 5.0: Dirt, Wooden Hoe
- */
- public static IScrapboxManager scrapboxDrops;
- public static IListRecipeManager recyclerBlacklist;
- /**
- * Do not add anything to this Whitelist. This is for Configuration only.
- * You may need this if you have an own Recycler in your Mod, just to check if something can be recycled. but don't add anything to this List
- */
- public static IListRecipeManager recyclerWhitelist;
- public static ICraftingRecipeManager advRecipes;
-
- public static ISemiFluidFuelManager semiFluidGenerator;
- public static IFluidHeatManager FluidHeatGenerator;
- /**
- * Used by the Liquid Heat Exchanger to cool down liquids and determine the amount of hu generated for every mb.
- */
- public static ILiquidHeatExchangerManager liquidCooldownManager;
- /**
- * Opposite of {@link #liquidCooldownManager}. This is for Liquids that can be heated up again.
- */
- public static ILiquidHeatExchangerManager liquidHeatupManager;
-}
diff --git a/src/api/java/ic2/api/recipe/package-info.java b/src/api/java/ic2/api/recipe/package-info.java
deleted file mode 100644
index 4974eb1..0000000
--- a/src/api/java/ic2/api/recipe/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.recipe;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/tile/ExplosionWhitelist.java b/src/api/java/ic2/api/tile/ExplosionWhitelist.java
deleted file mode 100644
index ea3217b..0000000
--- a/src/api/java/ic2/api/tile/ExplosionWhitelist.java
+++ /dev/null
@@ -1,50 +0,0 @@
-package ic2.api.tile;
-
-import java.util.HashSet;
-import java.util.Set;
-
-import net.minecraft.block.Block;
-
-/**
- * Blocks on this whitelist will not resist an explosion but won't be destroyed.
- *
- * The explosion code by default ignores blocks which absorb more than 1000 explosion power to
- * prevent abusing personal safes, Trade-O-Mats and other blocks to serve as a cheap and
- * invulnerable reactor chambers. Said blocks will not shield the explosion and won't get
- * destroyed.
- */
-public final class ExplosionWhitelist
-{
- /**
- * Add a block to the whitelist.
- *
- * @param block block to add
- */
- public static void addWhitelistedBlock(Block block)
- {
- whitelist.add(block);
- }
-
- /**
- * Remove a block from the whitelist.
- *
- * @param block block to remove
- */
- public static void removeWhitelistedBlock(Block block)
- {
- whitelist.remove(block);
- }
-
- /**
- * Check if a block is on the whitelist.
- *
- * @param block block to check if whitelisted
- * @return Whether the block is whitelisted
- */
- public static boolean isBlockWhitelisted(Block block)
- {
- return whitelist.contains(block);
- }
-
- private static Set<Block> whitelist = new HashSet<Block>();
-}
diff --git a/src/api/java/ic2/api/tile/IEnergyStorage.java b/src/api/java/ic2/api/tile/IEnergyStorage.java
deleted file mode 100644
index c2ee2e4..0000000
--- a/src/api/java/ic2/api/tile/IEnergyStorage.java
+++ /dev/null
@@ -1,62 +0,0 @@
-package ic2.api.tile;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Interface implemented by the tile entity of energy storage blocks.
- */
-public interface IEnergyStorage
-{
- /**
- * Get the amount of energy currently stored in the block.
- *
- * @return Energy stored in the block
- */
- public int getStored();
-
- /**
- * Set the amount of energy currently stored in the block.
- *
- * @param energy stored energy
- */
- public void setStored(int energy);
-
- /**
- * Add the specified amount of energy.
- *
- * Use negative values to decrease.
- *
- * @param amount of energy to add
- * @return Energy stored in the block after adding the specified amount
- */
- public int addEnergy(int amount);
-
- /**
- * Get the maximum amount of energy the block can store.
- *
- * @return Maximum energy stored
- */
- public int getCapacity();
-
- /**
- * Get the block's energy output.
- *
- * @return Energy output in EU/t
- */
- public int getOutput();
-
- /**
- * Get the block's energy output.
- *
- * @return Energy output in EU/t
- */
- public double getOutputEnergyUnitsPerTick();
-
- /**
- * Get whether this block can have its energy used by an adjacent teleporter.
- *
- * @param side side the teleporter is draining energy from
- * @return Whether the block is teleporter compatible
- */
- public boolean isTeleporterCompatible(ForgeDirection side);
-}
diff --git a/src/api/java/ic2/api/tile/IWrenchable.java b/src/api/java/ic2/api/tile/IWrenchable.java
deleted file mode 100644
index bd2f3f5..0000000
--- a/src/api/java/ic2/api/tile/IWrenchable.java
+++ /dev/null
@@ -1,61 +0,0 @@
-package ic2.api.tile;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-
-/**
- * Allows a tile entity to make use of the wrench's removal and rotation functions.
- */
-public interface IWrenchable
-{
- /**
- * Determine if the wrench can be used to set the block's facing.
- * Called before wrenchCanRemove().
- *
- * @param entityPlayer player using the wrench, may be null
- * @param side block's side the wrench was clicked on
- * @return Whether the wrenching was done and the wrench should be damaged
- */
- boolean wrenchCanSetFacing(EntityPlayer entityPlayer, int side);
-
- /**
- * Get the block's facing.
- *
- * @return Block facing
- */
- short getFacing();
-
- /**
- * Set the block's facing
- *
- * @param facing facing to set the block to
- */
- void setFacing(short facing);
-
- /**
- * Determine if the wrench can be used to remove the block.
- * Called if wrenchSetFacing fails.
- *
- * @param entityPlayer player using the wrench, may be null
- * @return Whether the wrenching was done and the wrench should be damaged
- */
- boolean wrenchCanRemove(EntityPlayer entityPlayer);
-
- /**
- * Determine the probability to drop the block as it is.
- * The first entry in getDrops will be replaced by blockid:meta if the drop is successful.
- *
- * @return Probability from 0 to 1
- */
- float getWrenchDropRate();
-
- /**
- * Determine the item the block will drop when the wrenching is successful.
- *
- * The ItemStack will be copied before creating the EntityItem.
- *
- * @param entityPlayer player using the wrench, may be null
- * @return ItemStack to drop, may be null
- */
- ItemStack getWrenchDrop(EntityPlayer entityPlayer);
-}
diff --git a/src/api/java/ic2/api/tile/package-info.java b/src/api/java/ic2/api/tile/package-info.java
deleted file mode 100644
index 26c013a..0000000
--- a/src/api/java/ic2/api/tile/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.tile;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/ic2/api/util/IKeyboard.java b/src/api/java/ic2/api/util/IKeyboard.java
deleted file mode 100644
index b71a5e4..0000000
--- a/src/api/java/ic2/api/util/IKeyboard.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package ic2.api.util;
-
-import net.minecraft.entity.player.EntityPlayer;
-
-public interface IKeyboard
-{
- boolean isAltKeyDown(EntityPlayer player);
-
- boolean isBoostKeyDown(EntityPlayer player);
-
- boolean isForwardKeyDown(EntityPlayer player);
-
- boolean isJumpKeyDown(EntityPlayer player);
-
- boolean isModeSwitchKeyDown(EntityPlayer player);
-
- boolean isSideinventoryKeyDown(EntityPlayer player);
-
- boolean isHudModeKeyDown(EntityPlayer player);
-
- boolean isSneakKeyDown(EntityPlayer player);
-}
diff --git a/src/api/java/ic2/api/util/Keys.java b/src/api/java/ic2/api/util/Keys.java
deleted file mode 100644
index 7493868..0000000
--- a/src/api/java/ic2/api/util/Keys.java
+++ /dev/null
@@ -1,6 +0,0 @@
-package ic2.api.util;
-
-public class Keys
-{
- public static IKeyboard instance;
-}
diff --git a/src/api/java/ic2/api/util/package-info.java b/src/api/java/ic2/api/util/package-info.java
deleted file mode 100644
index 3207c5b..0000000
--- a/src/api/java/ic2/api/util/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "IC2", provides = "IC2API")
-package ic2.api.util;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/invtweaks/api/container/ChestContainer.java b/src/api/java/invtweaks/api/container/ChestContainer.java
deleted file mode 100644
index 7a921fd..0000000
--- a/src/api/java/invtweaks/api/container/ChestContainer.java
+++ /dev/null
@@ -1,41 +0,0 @@
-package invtweaks.api.container;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-/**
- * A marker for containers that have a chest-like persistant storage component. Enables the Inventroy Tweaks sorting
- * buttons for this container.
- */
-@Retention(RetentionPolicy.RUNTIME)
-@Target(ElementType.TYPE)
-public @interface ChestContainer
-{
- // Set to true if the Inventory Tweaks sorting buttons should be shown for this container.
- boolean showButtons() default true;
-
- // Size of a chest row
- int rowSize() default 9;
-
- // Uses 'large chest' mode for sorting buttons
- // (Renders buttons vertically down the right side of the GUI)
- boolean isLargeChest() default false;
-
- // Annotation for method to get size of a chest row if it is not a fixed size for this container class
- // Signature int func()
- @Retention(RetentionPolicy.RUNTIME)
- @Target(ElementType.METHOD)
- public @interface RowSizeCallback
- {
- }
-
- // Annotation for method to get size of a chest row if it is not a fixed size for this container class
- // Signature int func()
- @Retention(RetentionPolicy.RUNTIME)
- @Target(ElementType.METHOD)
- public @interface IsLargeCallback
- {
- }
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaBlock.java b/src/api/java/mcp/mobius/waila/api/IWailaBlock.java
deleted file mode 100644
index 181f938..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaBlock.java
+++ /dev/null
@@ -1,37 +0,0 @@
-package mcp.mobius.waila.api;
-
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-
-@Deprecated
-public interface IWailaBlock
-{
- /*
- * Use this method to return an item stack in case the default lookup system fails.
- * Return null if you want to use the default lookup system.
- * You get the world, the player and the location of the block. With that, it is easy to gather information & tile entities
- */
- ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config);
-
- /* Waila HUD is divided into 3 zones. The head corresponds to the item name,
- * body to where you mostly want to put informations, and I reserve the tail for modname display
- */
-
- /* Those 2 methods works exactly the same way, except they are related to a different zone in Waila HUD.
- * You get in input world, player and the block location. You also get the itemstack as returned by the default lookup system or getWailaStack().
- * ConfigHandler provides the current Waila config state so you can show/hide elements depending on the configuration. Refer the ConfigHandler class for more info.
- * currenttip represents the current list of text lines in the tooltip zone.
- * For example, getWailaHead() will have the current item name as currenttip.
- * You can modify the tips, add more, remove some, etc.
- * When you are done, just returns the currenttip and it will display in Waila.
- *
- * Always return the currenttip is you don't want to modify the current zone.
- */
-
- List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config);
-
- List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config);
-
- List<String> getWailaTail(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config);
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaBlockDecorator.java b/src/api/java/mcp/mobius/waila/api/IWailaBlockDecorator.java
deleted file mode 100644
index 093d044..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaBlockDecorator.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package mcp.mobius.waila.api;
-
-import net.minecraft.item.ItemStack;
-
-public interface IWailaBlockDecorator
-{
-
- void decorateBlock(ItemStack itemStack, IWailaDataAccessor accessor, IWailaConfigHandler config);
-
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaConfigHandler.java b/src/api/java/mcp/mobius/waila/api/IWailaConfigHandler.java
deleted file mode 100644
index 94e08d6..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaConfigHandler.java
+++ /dev/null
@@ -1,29 +0,0 @@
-package mcp.mobius.waila.api;
-
-import java.util.HashMap;
-import java.util.Set;
-
-public interface IWailaConfigHandler
-{
- /* Returns a set of all the currently loaded modules in the config handler */
- public Set<String> getModuleNames();
-
- /* Returns all the currently available options for a given module */
- public HashMap<String, String> getConfigKeys(String modName);
-
- /* Add a new option to a given module
- *
- * modName is the name of the module to add the option to (ie : Buildcraft, IndustrialCraft2, etc)
- * key is the config key (ie : bc.tankcontent, ic2.inputvalue)
- * name is the human readable name of the option (ie : "Tank content", "Max EU Input")
- * */
- //public void addConfig(String modName, String key, String name);
-
- /* Returns the current value of an option (true/false) with a default value defvalue if not set*/
- public boolean getConfig(String key, boolean defvalue);
-
- /* Returns the current value of an option (true/false) with a default value true if not set*/
- public boolean getConfig(String key);
-
- //public void setConfig(String key, boolean value);
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaDataAccessor.java b/src/api/java/mcp/mobius/waila/api/IWailaDataAccessor.java
deleted file mode 100644
index 9d0a6fb..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaDataAccessor.java
+++ /dev/null
@@ -1,46 +0,0 @@
-package mcp.mobius.waila.api;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.Vec3;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/* The Accessor is used to get some basic data out of the game without having to request
- * direct access to the game engine.
- * It will also return things that are unmodified by the overriding systems (like getWailaStack).
- */
-
-public interface IWailaDataAccessor
-{
-
- World getWorld();
-
- EntityPlayer getPlayer();
-
- Block getBlock();
-
- int getBlockID();
-
- int getMetadata();
-
- TileEntity getTileEntity();
-
- MovingObjectPosition getPosition();
-
- Vec3 getRenderingPosition();
-
- NBTTagCompound getNBTData();
-
- int getNBTInteger(NBTTagCompound tag, String keyname);
-
- double getPartialFrame();
-
- ForgeDirection getSide();
-
- ItemStack getStack();
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaDataProvider.java b/src/api/java/mcp/mobius/waila/api/IWailaDataProvider.java
deleted file mode 100644
index f0c886b..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaDataProvider.java
+++ /dev/null
@@ -1,36 +0,0 @@
-package mcp.mobius.waila.api;
-
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-
-public interface IWailaDataProvider
-{
- /*
- * Use this method to return an item stack in case the default lookup system fails.
- * Return null if you want to use the default lookup system.
- * You get the world, the player and the location of the block. With that, it is easy to gather information & tile entities
- */
- ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config);
-
- /* Waila HUD is divided into 3 zones. The head corresponds to the item name,
- * body to where you mostly want to put informations, and I reserve the tail for modname display
- */
-
- /* Those 2 methods works exactly the same way, except they are related to a different zone in Waila HUD.
- * You get in input world, player and the block location. You also get the itemstack as returned by the default lookup system or getWailaStack().
- * ConfigHandler provides the current Waila config state so you can show/hide elements depending on the configuration. Refer the ConfigHandler class for more info.
- * currenttip represents the current list of text lines in the tooltip zone.
- * For example, getWailaHead() will have the current item name as currenttip.
- * You can modify the tips, add more, remove some, etc.
- * When you are done, just returns the currenttip and it will display in Waila.
- *
- * Always return the currenttip is you don't want to modify the current zone.
- */
-
- List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config);
-
- List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config);
-
- List<String> getWailaTail(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config);
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaEntityAccessor.java b/src/api/java/mcp/mobius/waila/api/IWailaEntityAccessor.java
deleted file mode 100644
index 62e3352..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaEntityAccessor.java
+++ /dev/null
@@ -1,32 +0,0 @@
-package mcp.mobius.waila.api;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.Vec3;
-import net.minecraft.world.World;
-
-/* The Accessor is used to get some basic data out of the game without having to request
- * direct access to the game engine.
- * It will also return things that are unmodified by the overriding systems (like getWailaStack).
- */
-
-public interface IWailaEntityAccessor
-{
- World getWorld();
-
- EntityPlayer getPlayer();
-
- Entity getEntity();
-
- MovingObjectPosition getPosition();
-
- Vec3 getRenderingPosition();
-
- NBTTagCompound getNBTData();
-
- int getNBTInteger(NBTTagCompound tag, String keyname);
-
- double getPartialFrame();
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaEntityProvider.java b/src/api/java/mcp/mobius/waila/api/IWailaEntityProvider.java
deleted file mode 100644
index a7fe7a2..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaEntityProvider.java
+++ /dev/null
@@ -1,19 +0,0 @@
-package mcp.mobius.waila.api;
-
-import java.util.List;
-
-import net.minecraft.entity.Entity;
-
-public interface IWailaEntityProvider
-{
-
- /* A way to get an override on the entity returned by the raytracing */
- Entity getWailaOverride(IWailaEntityAccessor accessor, IWailaConfigHandler config);
-
- /* The classical HEAD/BODY/TAIL text getters */
- List<String> getWailaHead(Entity entity, List<String> currenttip, IWailaEntityAccessor accessor, IWailaConfigHandler config);
-
- List<String> getWailaBody(Entity entity, List<String> currenttip, IWailaEntityAccessor accessor, IWailaConfigHandler config);
-
- List<String> getWailaTail(Entity entity, List<String> currenttip, IWailaEntityAccessor accessor, IWailaConfigHandler config);
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaFMPAccessor.java b/src/api/java/mcp/mobius/waila/api/IWailaFMPAccessor.java
deleted file mode 100644
index a885ea7..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaFMPAccessor.java
+++ /dev/null
@@ -1,36 +0,0 @@
-package mcp.mobius.waila.api;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.Vec3;
-import net.minecraft.world.World;
-
-/* The Accessor is used to get some basic data out of the game without having to request
- * direct access to the game engine.
- * It will also return things that are unmodified by the overriding systems (like getWailaStack).
- */
-
-public interface IWailaFMPAccessor
-{
- World getWorld();
-
- EntityPlayer getPlayer();
-
- TileEntity getTileEntity();
-
- MovingObjectPosition getPosition();
-
- NBTTagCompound getNBTData();
-
- NBTTagCompound getFullNBTData();
-
- int getNBTInteger(NBTTagCompound tag, String keyname);
-
- double getPartialFrame();
-
- Vec3 getRenderingPosition();
-
- String getID();
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaFMPDecorator.java b/src/api/java/mcp/mobius/waila/api/IWailaFMPDecorator.java
deleted file mode 100644
index 64d6e30..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaFMPDecorator.java
+++ /dev/null
@@ -1,8 +0,0 @@
-package mcp.mobius.waila.api;
-
-import net.minecraft.item.ItemStack;
-
-public interface IWailaFMPDecorator
-{
- void decorateBlock(ItemStack itemStack, IWailaFMPAccessor accessor, IWailaConfigHandler config);
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaFMPProvider.java b/src/api/java/mcp/mobius/waila/api/IWailaFMPProvider.java
deleted file mode 100644
index 08f0ca3..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaFMPProvider.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package mcp.mobius.waila.api;
-
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-
-public interface IWailaFMPProvider
-{
- /* The classical HEAD/BODY/TAIL text getters */
- List<String> getWailaHead(ItemStack itemStack, List<String> currenttip, IWailaFMPAccessor accessor, IWailaConfigHandler config);
-
- List<String> getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaFMPAccessor accessor, IWailaConfigHandler config);
-
- List<String> getWailaTail(ItemStack itemStack, List<String> currenttip, IWailaFMPAccessor accessor, IWailaConfigHandler config);
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaRegistrar.java b/src/api/java/mcp/mobius/waila/api/IWailaRegistrar.java
deleted file mode 100644
index 8414a81..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaRegistrar.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package mcp.mobius.waila.api;
-
-public interface IWailaRegistrar
-{
- /* Add a config option in the section modname with displayed text configtext and access key keyname */
- public void addConfig(String modname, String keyname, String configtext);
-
- public void addConfigRemote(String modname, String keyname, String configtext);
-
- public void addConfig(String modname, String keyname);
-
- public void addConfigRemote(String modname, String keyname);
-
- /* Register a stack overrider for the given blockID */
- public void registerStackProvider(IWailaDataProvider dataProvider, Class block);
-
- /* Same thing, but works on a class hierarchy instead */
- public void registerHeadProvider(IWailaDataProvider dataProvider, Class block);
-
- public void registerBodyProvider(IWailaDataProvider dataProvider, Class block);
-
- public void registerTailProvider(IWailaDataProvider dataProvider, Class block);
-
- /* Entity text registration methods */
- public void registerHeadProvider(IWailaEntityProvider dataProvider, Class entity);
-
- public void registerBodyProvider(IWailaEntityProvider dataProvider, Class entity);
-
- public void registerTailProvider(IWailaEntityProvider dataProvider, Class entity);
-
- public void registerOverrideEntityProvider(IWailaEntityProvider dataProvider, Class entity);
-
- /* FMP Providers */
- public void registerHeadProvider(IWailaFMPProvider dataProvider, String name);
-
- public void registerBodyProvider(IWailaFMPProvider dataProvider, String name);
-
- public void registerTailProvider(IWailaFMPProvider dataProvider, String name);
-
- /* The block decorators */
- public void registerDecorator(IWailaBlockDecorator decorator, Class block);
-
- public void registerDecorator(IWailaFMPDecorator decorator, String name);
-
- /* Selective NBT key syncing. Will register a key to sync over the network for the given class (block, te or ent).
- * Accept * as a ending wildcard
- * registerNBTKey("bob.*", MyBlock.class)
- * registerNBTKey("data.life", MyEntity.class)
- * registerNBTKey("*", MyTileEntity.class) will reproduce the full tag syncing from 1.4.5
- * */
- public void registerSyncedNBTKey(String key, Class target);
-
- /* UNUSED FOR NOW (Will be used for the ingame wiki */
- public void registerDocTextFile(String filename);
-
- public void registerShortDataProvider(IWailaSummaryProvider dataProvider, Class item);
-}
diff --git a/src/api/java/mcp/mobius/waila/api/IWailaSummaryProvider.java b/src/api/java/mcp/mobius/waila/api/IWailaSummaryProvider.java
deleted file mode 100644
index 3d7a349..0000000
--- a/src/api/java/mcp/mobius/waila/api/IWailaSummaryProvider.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package mcp.mobius.waila.api;
-
-import java.util.LinkedHashMap;
-
-import net.minecraft.item.ItemStack;
-
-public interface IWailaSummaryProvider
-{
- /* This interface is used to control the display data in the description screen */
-
- /* BASIC TOOLS & ITEMS DATA */
- //EnumToolMaterial getMaterial(ItemStack stack);
- //String getMaterialName(ItemStack stack);
- //String getEffectiveBlock(ItemStack stack);
- //int getHarvestLevel(ItemStack stack);
- //float getEfficiencyOnProperMaterial(ItemStack stack);
- //int getEnchantability(ItemStack stack);
- //int getDamageVsEntity(ItemStack stack);
- //int getDurability(ItemStack stack);
-
- LinkedHashMap<String, String> getSummary(ItemStack stack, LinkedHashMap<String, String> currentSummary, IWailaConfigHandler config);
-}
diff --git a/src/api/java/mcp/mobius/waila/api/SpecialChars.java b/src/api/java/mcp/mobius/waila/api/SpecialChars.java
deleted file mode 100644
index a987a15..0000000
--- a/src/api/java/mcp/mobius/waila/api/SpecialChars.java
+++ /dev/null
@@ -1,41 +0,0 @@
-package mcp.mobius.waila.api;
-
-public class SpecialChars
-{
-
- public static String MCStyle = "\u00A7";
-
- public static String BLACK = MCStyle + "0";
- public static String DBLUE = MCStyle + "1";
- public static String DGREEN = MCStyle + "2";
- public static String DAQUA = MCStyle + "3";
- public static String DRED = MCStyle + "4";
- public static String DPURPLE = MCStyle + "5";
- public static String GOLD = MCStyle + "6";
- public static String GRAY = MCStyle + "7";
- public static String DGRAY = MCStyle + "8";
- public static String BLUE = MCStyle + "9";
- public static String GREEN = MCStyle + "a";
- public static String AQUA = MCStyle + "b";
- public static String RED = MCStyle + "c";
- public static String LPURPLE = MCStyle + "d";
- public static String YELLOW = MCStyle + "e";
- public static String WHITE = MCStyle + "f";
-
- public static String OBF = MCStyle + "k";
- public static String BOLD = MCStyle + "l";
- public static String STRIKE = MCStyle + "m";
- public static String UNDER = MCStyle + "n";
- public static String ITALIC = MCStyle + "o";
- public static String RESET = MCStyle + "r";
-
- public static String WailaStyle = "\u00A4";
- public static String WailaIcon = "\u00A5";
- public static String TAB = WailaStyle + WailaStyle + "a";
- public static String ALIGNRIGHT = WailaStyle + WailaStyle + "b";
- public static String ALIGNCENTER = WailaStyle + WailaStyle + "c";
- public static String HEART = WailaStyle + WailaIcon + "a";
- public static String HHEART = WailaStyle + WailaIcon + "b";
- public static String EHEART = WailaStyle + WailaIcon + "c";
-
-}
diff --git a/src/api/java/mcp/mobius/waila/api/package-info.java b/src/api/java/mcp/mobius/waila/api/package-info.java
deleted file mode 100644
index 82cf044..0000000
--- a/src/api/java/mcp/mobius/waila/api/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "1.0", owner = "Waila", provides = "WailaAPI")
-package mcp.mobius.waila.api;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/Chunk3D.java b/src/api/java/mekanism/api/Chunk3D.java
deleted file mode 100644
index 11c758f..0000000
--- a/src/api/java/mekanism/api/Chunk3D.java
+++ /dev/null
@@ -1,115 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.world.ChunkCoordIntPair;
-import net.minecraft.world.World;
-import net.minecraft.world.chunk.Chunk;
-
-/**
- * Chunk3D - an integer-based way to keep track of and perform operations on chunks in a Minecraft-based environment. This also takes
- * in account the dimension the chunk is in.
- * @author aidancbrady
- *
- */
-public class Chunk3D
-{
- public int dimensionId;
-
- public int xCoord;
- public int zCoord;
-
- /**
- * Creates a Chunk3D object from the given x and z coordinates, as well as a dimension.
- * @param x - chunk x location
- * @param z - chunk z location
- * @param dimension - the dimension this Chunk3D is in
- */
- public Chunk3D(int x, int z, int dimension)
- {
- xCoord = x;
- zCoord = z;
-
- dimensionId = dimension;
- }
-
- /**
- * Creates a Chunk3D from an entity based on it's location and dimension.
- * @param entity - the entity to get the Chunk3D object from
- */
- public Chunk3D(Entity entity)
- {
- xCoord = ((int) entity.posX) >> 4;
- zCoord = ((int) entity.posZ) >> 4;
-
- dimensionId = entity.dimension;
- }
-
- /**
- * Creates a Chunk3D from a Coord4D based on it's coordinates and dimension.
- * @param coord - the Coord4D object to get this Chunk3D from
- */
- public Chunk3D(Coord4D coord)
- {
- xCoord = coord.xCoord >> 4;
- zCoord = coord.zCoord >> 4;
-
- dimensionId = coord.dimensionId;
- }
-
- /**
- * Whether or not this chunk exists in the given world.
- * @param world - the world to check in
- * @return if the chunk exists
- */
- public boolean exists(World world)
- {
- return world.getChunkProvider().chunkExists(xCoord, zCoord);
- }
-
- /**
- * Gets a Chunk object corresponding to this Chunk3D's coordinates.
- * @param world - the world to get the Chunk object from
- * @return the corresponding Chunk object
- */
- public Chunk getChunk(World world)
- {
- return world.getChunkFromChunkCoords(xCoord, zCoord);
- }
-
- /**
- * Returns this Chunk3D in the Minecraft-based ChunkCoordIntPair format.
- * @return this Chunk3D as a ChunkCoordIntPair
- */
- public ChunkCoordIntPair toPair()
- {
- return new ChunkCoordIntPair(xCoord, zCoord);
- }
-
- @Override
- public Coord4D clone()
- {
- return new Coord4D(xCoord, zCoord, dimensionId);
- }
-
- @Override
- public String toString()
- {
- return "[Chunk3D: " + xCoord + ", " + zCoord + ", dim=" + dimensionId + "]";
- }
-
- @Override
- public boolean equals(Object obj)
- {
- return obj instanceof Chunk3D && ((Chunk3D) obj).xCoord == xCoord && ((Chunk3D) obj).zCoord == zCoord && ((Chunk3D) obj).dimensionId == dimensionId;
- }
-
- @Override
- public int hashCode()
- {
- int code = 1;
- code = 31 * code + xCoord;
- code = 31 * code + zCoord;
- code = 31 * code + dimensionId;
- return code;
- }
-}
diff --git a/src/api/java/mekanism/api/Coord4D.java b/src/api/java/mekanism/api/Coord4D.java
deleted file mode 100644
index 57f82ca..0000000
--- a/src/api/java/mekanism/api/Coord4D.java
+++ /dev/null
@@ -1,425 +0,0 @@
-package mekanism.api;
-
-import io.netty.buffer.ByteBuf;
-
-import java.util.ArrayList;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.Entity;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import net.minecraft.world.chunk.Chunk;
-import net.minecraftforge.common.util.ForgeDirection;
-import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
-
-/**
- * Coord4D - an integer-based way to keep track of and perform operations on blocks in a Minecraft-based environment. This also takes
- * in account the dimension the coordinate is in.
- * @author aidancbrady
- *
- */
-public class Coord4D
-{
- public int xCoord;
- public int yCoord;
- public int zCoord;
-
- public int dimensionId;
-
- /**
- * Creates a Coord4D WITHOUT a dimensionId. Don't use unless absolutely necessary.
- * @param x - x coordinate
- * @param y - y coordinate
- * @param z - z coordinate
- */
- public Coord4D(int x, int y, int z)
- {
- xCoord = x;
- yCoord = y;
- zCoord = z;
-
- dimensionId = 0;
- }
-
- /**
- * Creates a Coord4D from an entity's position, rounded down.
- * @param entity - entity to create the Coord4D from
- */
- public Coord4D(Entity entity)
- {
- xCoord = (int) entity.posX;
- yCoord = (int) entity.posY;
- zCoord = (int) entity.posZ;
-
- dimensionId = entity.worldObj.provider.dimensionId;
- }
-
- /**
- * Creates a Coord4D from the defined x, y, z, and dimension values.
- * @param x - x coordinate
- * @param y - y coordinate
- * @param z - z coordinate
- * @param dimension - dimension ID
- */
- public Coord4D(int x, int y, int z, int dimension)
- {
- xCoord = x;
- yCoord = y;
- zCoord = z;
-
- dimensionId = dimension;
- }
-
- public Coord4D(MovingObjectPosition mop)
- {
- xCoord = mop.blockX;
- yCoord = mop.blockY;
- zCoord = mop.blockZ;
- }
-
- /**
- * Gets the metadata of the block representing this Coord4D.
- * @param world - world this Coord4D is in
- * @return the metadata of this Coord4D's block
- */
- public int getMetadata(IBlockAccess world)
- {
- return world.getBlockMetadata(xCoord, yCoord, zCoord);
- }
-
- /**
- * Gets the TileEntity of the block representing this Coord4D.
- * @param world - world this Coord4D is in
- * @return the TileEntity of this Coord4D's block
- */
- public TileEntity getTileEntity(IBlockAccess world)
- {
- if(world instanceof World && !exists((World) world))
- {
- return null;
- }
-
- return world.getTileEntity(xCoord, yCoord, zCoord);
- }
-
- /**
- * Gets the Block value of the block representing this Coord4D.
- * @param world - world this Coord4D is in
- * @return the Block value of this Coord4D's block
- */
- public Block getBlock(IBlockAccess world)
- {
- if(world instanceof World && !exists((World) world))
- {
- return null;
- }
-
- return world.getBlock(xCoord, yCoord, zCoord);
- }
-
- /**
- * Writes this Coord4D's data to an NBTTagCompound.
- * @param nbtTags - tag compound to write to
- * @return the tag compound with this Coord4D's data
- */
- public NBTTagCompound write(NBTTagCompound nbtTags)
- {
- nbtTags.setInteger("x", xCoord);
- nbtTags.setInteger("y", yCoord);
- nbtTags.setInteger("z", zCoord);
- nbtTags.setInteger("dimensionId", dimensionId);
-
- return nbtTags;
- }
-
- /**
- * Writes this Coord4D's data to an ArrayList for packet transfer.
- * @param data - the ArrayList to add the data to
- */
- public void write(ArrayList data)
- {
- data.add(xCoord);
- data.add(yCoord);
- data.add(zCoord);
- data.add(dimensionId);
- }
-
- /**
- * Writes this Coord4D's data to a ByteBuf for packet transfer.
- * @param dataStream - the ByteBuf to add the data to
- */
- public void write(ByteBuf dataStream)
- {
- dataStream.writeInt(xCoord);
- dataStream.writeInt(yCoord);
- dataStream.writeInt(zCoord);
- dataStream.writeInt(dimensionId);
- }
-
- /**
- * Translates this Coord4D by the defined x, y, and z values.
- * @param x - x value to translate
- * @param y - y value to translate
- * @param z - z value to translate
- * @return translated Coord4D
- */
- public Coord4D translate(int x, int y, int z)
- {
- xCoord += x;
- yCoord += y;
- zCoord += z;
-
- return this;
- }
-
- /**
- * Translates this Coord4D by the defined Coord4D's coordinates, regardless of dimension.
- * @param coord - coordinates to translate by
- * @return translated Coord4D
- */
- public Coord4D translate(Coord4D coord)
- {
- translate(coord.xCoord, coord.yCoord, coord.zCoord);
-
- return this;
- }
-
- /**
- * Creates and returns a new Coord4D translated to the defined offsets of the side.
- * @param side - side to translate this Coord4D to
- * @return translated Coord4D
- */
- public Coord4D getFromSide(ForgeDirection side)
- {
- return getFromSide(side, 1);
- }
-
- /**
- * Creates and returns a new Coord4D translated to the defined offsets of the side by the defined amount.
- * @param side - side to translate this Coord4D to
- * @param amount - how far to translate this Coord4D
- * @return translated Coord4D
- */
- public Coord4D getFromSide(ForgeDirection side, int amount)
- {
- return new Coord4D(xCoord + (side.offsetX * amount),
- yCoord + (side.offsetY * amount),
- zCoord + (side.offsetZ * amount), dimensionId);
- }
-
- public ItemStack getStack(IBlockAccess world)
- {
- final Block block = getBlock(world);
-
- if(block == null || block == Blocks.air)
- {
- return null;
- }
-
- return new ItemStack(block, 1, getMetadata(world));
- }
-
- /**
- * Returns a new Coord4D from a defined TileEntity's xCoord, yCoord and zCoord values.
- * @param tileEntity - TileEntity at the location that will represent this Coord4D
- * @return the Coord4D object from the TileEntity
- */
- public static Coord4D get(TileEntity tileEntity)
- {
- return new Coord4D(tileEntity.xCoord, tileEntity.yCoord,
- tileEntity.zCoord,
- tileEntity.getWorldObj().provider.dimensionId);
- }
-
- /**
- * Returns a new Coord4D from a tag compound.
- * @param tag - tag compound to read from
- * @return the Coord4D from the tag compound
- */
- public static Coord4D read(NBTTagCompound tag)
- {
- return new Coord4D(tag.getInteger("x"), tag.getInteger("y"),
- tag.getInteger("z"), tag.getInteger("id"));
- }
-
- /**
- * Returns a new Coord4D from a ByteBuf.
- * @param dataStream - data input to read from
- * @return the Coord4D from the data input
- */
- public static Coord4D read(ByteBuf dataStream)
- {
- return new Coord4D(dataStream.readInt(), dataStream.readInt(),
- dataStream.readInt(), dataStream.readInt());
- }
-
- /**
- * Creates and returns a new Coord4D with values representing the difference between the defined Coord4D
- * @param other - the Coord4D to subtract from this
- * @return a Coord4D representing the distance between the defined Coord4D
- */
- public Coord4D difference(Coord4D other)
- {
- return new Coord4D(xCoord - other.xCoord, yCoord - other.yCoord,
- zCoord - other.zCoord, dimensionId);
- }
-
- /**
- * A method used to find the ForgeDirection represented by the distance of the defined Coord4D. Most likely won't have many
- * applicable uses.
- * @param other - Coord4D to find the side difference of
- * @return ForgeDirection representing the side the defined relative Coord4D is on to this
- */
- public ForgeDirection sideDifference(Coord4D other)
- {
- final Coord4D diff = difference(other);
-
- for(final ForgeDirection side : ForgeDirection.VALID_DIRECTIONS)
- {
- if(side.offsetX == diff.xCoord && side.offsetY == diff.yCoord && side.offsetZ == diff.zCoord)
- {
- return side;
- }
- }
-
- return ForgeDirection.UNKNOWN;
- }
-
- /**
- * Gets the distance to a defined Coord4D.
- * @param obj - the Coord4D to find the distance to
- * @return the distance to the defined Coord4D
- */
- public int distanceTo(Coord4D obj)
- {
- final int subX = xCoord - obj.xCoord;
- final int subY = yCoord - obj.yCoord;
- final int subZ = zCoord - obj.zCoord;
- return (int) MathHelper.sqrt_double(subX * subX + subY * subY + subZ * subZ);
- }
-
- /**
- * Whether or not the defined side of this Coord4D is visible.
- * @param side - side to check
- * @param world - world this Coord4D is in
- * @return
- */
- public boolean sideVisible(ForgeDirection side, IBlockAccess world)
- {
- return world.isAirBlock(xCoord + side.offsetX, yCoord + side.offsetY, zCoord + side.offsetZ);
- }
-
- /**
- * Gets a TargetPoint with the defined range from this Coord4D with the appropriate coordinates and dimension ID.
- * @param range - the range the packet can be sent in of this Coord4D
- * @return TargetPoint relative to this Coord4D
- */
- public TargetPoint getTargetPoint(double range)
- {
- return new TargetPoint(dimensionId, xCoord, yCoord, zCoord, range);
- }
-
- /**
- * Steps this Coord4D in the defined side's offset without creating a new value.
- * @param side - side to step towards
- * @return this Coord4D
- */
- public Coord4D step(ForgeDirection side)
- {
- return translate(side.offsetX, side.offsetY, side.offsetZ);
- }
-
- /**
- * Whether or not the chunk this Coord4D is in exists and is loaded.
- * @param world - world this Coord4D is in
- * @return the chunk of this Coord4D
- */
- public boolean exists(World world)
- {
- return world.getChunkProvider() == null || world.getChunkProvider().chunkExists(xCoord >> 4, zCoord >> 4);
- }
-
- /**
- * Gets the chunk this Coord4D is in.
- * @param world - world this Coord4D is in
- * @return the chunk of this Coord4D
- */
- public Chunk getChunk(World world)
- {
- return world.getChunkFromBlockCoords(xCoord, zCoord);
- }
-
- /**
- * Gets the Chunk3D object with chunk coordinates correlating to this Coord4D's location
- * @return Chunk3D with correlating chunk coordinates.
- */
- public Chunk3D getChunk3D()
- {
- return new Chunk3D(this);
- }
-
- /**
- * Whether or not the block this Coord4D represents is an air block.
- * @param world - world this Coord4D is in
- * @return if this Coord4D is an air block
- */
- public boolean isAirBlock(IBlockAccess world)
- {
- return world.isAirBlock(xCoord, yCoord, zCoord);
- }
-
- /**
- * Whether or not this block this Coord4D represents is replaceable.
- * @param world - world this Coord4D is in
- * @return if this Coord4D is replaceable
- */
- public boolean isReplaceable(IBlockAccess world)
- {
- return getBlock(world).isReplaceable(world, xCoord, yCoord, zCoord);
- }
-
- /**
- * Gets a bounding box that contains the area this Coord4D would take up in a world.
- * @return this Coord4D's bounding box
- */
- public AxisAlignedBB getBoundingBox()
- {
- return AxisAlignedBB.getBoundingBox(xCoord, yCoord, zCoord, xCoord + 1, yCoord + 1, zCoord + 1);
- }
-
- @Override
- public Coord4D clone()
- {
- return new Coord4D(xCoord, yCoord, zCoord, dimensionId);
- }
-
- @Override
- public String toString()
- {
- return "[Coord4D: " + xCoord + ", " + yCoord + ", " + zCoord + ", dim=" + dimensionId + "]";
- }
-
- @Override
- public boolean equals(Object obj)
- {
- return obj instanceof Coord4D && ((Coord4D) obj).xCoord == xCoord && ((Coord4D) obj).yCoord == yCoord && ((Coord4D) obj).zCoord == zCoord && ((Coord4D) obj).dimensionId == dimensionId;
- }
-
- @Override
- public int hashCode()
- {
- int code = 1;
- code = 31 * code + xCoord;
- code = 31 * code + yCoord;
- code = 31 * code + zCoord;
- code = 31 * code + dimensionId;
- return code;
- }
-}
diff --git a/src/api/java/mekanism/api/EnumColor.java b/src/api/java/mekanism/api/EnumColor.java
deleted file mode 100644
index 73d8b61..0000000
--- a/src/api/java/mekanism/api/EnumColor.java
+++ /dev/null
@@ -1,96 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.util.StatCollector;
-
-/**
- * Simple color enum for adding colors to in-game GUI strings of text.
- * @author AidanBrady
- *
- */
-public enum EnumColor
-{
- BLACK("\u00a70", "black", "Black", new int[] {0, 0, 0}, 0), DARK_BLUE("\u00a71", "darkBlue", "Blue", new int[] {0, 0, 170}, 4), DARK_GREEN("\u00a72", "darkGreen", "Green", new int[] {0, 170, 0}, 2), DARK_AQUA("\u00a73", "darkAqua", "Cyan", new int[] {0, 255, 255}, 6), DARK_RED("\u00a74", "darkRed", null, new int[] {170, 0, 0}, -1), PURPLE("\u00a75", "purple", "Purple", new int[] {170, 0, 170}, 5), ORANGE("\u00a76", "orange", "Orange", new int[] {255, 170, 0}, 14), GREY("\u00a77", "grey", "LightGray", new int[] {170, 170, 170}, 7), DARK_GREY("\u00a78", "darkGrey", "Gray", new int[] {85, 85, 85}, 8), INDIGO("\u00a79", "indigo", "LightBlue", new int[] {85, 85, 255}, 12), BRIGHT_GREEN("\u00a7a", "brightGreen", "Lime", new int[] {85, 255, 85}, 10), AQUA("\u00a7b", "aqua", null, new int[] {85, 255, 255}, -1), RED("\u00a7c", "red", "Red", new int[] {255, 0, 0}, 1), PINK("\u00a7d", "pink", "Magenta", new int[] {255, 85, 255}, 13), YELLOW("\u00a7e", "yellow", "Yellow", new int[] {255, 255, 85}, 11), WHITE("\u00a7f", "white", "White", new int[] {255, 255, 255}, 15),
- //Extras for dye-completeness
- BROWN("\u00a76", "brown", "Brown", new int[] {150, 75, 0}, 3), BRIGHT_PINK("\u00a7d", "brightPink", "Pink", new int[] {255, 192, 203}, 9);
-
- public static EnumColor[] DYES = new EnumColor[] {BLACK, RED, DARK_GREEN, BROWN, DARK_BLUE, PURPLE, DARK_AQUA, GREY, DARK_GREY, BRIGHT_PINK, BRIGHT_GREEN, YELLOW, INDIGO, PINK, ORANGE, WHITE};
-
- /** The color code that will be displayed */
- public final String code;
-
- public final int[] rgbCode;
-
- public final int mcMeta;
-
- /** A friendly name of the color. */
- public String unlocalizedName;
-
- public String dyeName;
-
- private EnumColor(String s, String n, String dye, int[] rgb, int meta)
- {
- code = s;
- unlocalizedName = n;
- dyeName = dye;
- rgbCode = rgb;
- mcMeta = meta;
- }
-
- /**
- * Gets the localized name of this color by translating the unlocalized name.
- * @return localized name
- */
- public String getLocalizedName()
- {
- return StatCollector.translateToLocal("color." + unlocalizedName);
- }
-
- public String getDyeName()
- {
- return StatCollector.translateToLocal("dye." + unlocalizedName);
- }
-
- public String getOreDictName()
- {
- return dyeName;
- }
-
- /**
- * Gets the name of this color with it's color prefix code.
- * @return the color's name and color prefix
- */
- public String getName()
- {
- return code + getLocalizedName();
- }
-
- public String getDyedName()
- {
- return code + getDyeName();
- }
-
- /**
- * Gets the 0-1 of this color's RGB value by dividing by 255 (used for OpenGL coloring).
- * @param index - R:0, G:1, B:2
- * @return the color value
- */
- public float getColor(int index)
- {
- return rgbCode[index] / 255F;
- }
-
- /**
- * Gets the value of this color mapped to MC in-game item colors present in dyes and wool.
- * @return mc meta value
- */
- public int getMetaValue()
- {
- return mcMeta;
- }
-
- @Override
- public String toString()
- {
- return code;
- }
-}
diff --git a/src/api/java/mekanism/api/IClientTicker.java b/src/api/java/mekanism/api/IClientTicker.java
deleted file mode 100644
index 2288973..0000000
--- a/src/api/java/mekanism/api/IClientTicker.java
+++ /dev/null
@@ -1,8 +0,0 @@
-package mekanism.api;
-
-public interface IClientTicker
-{
- public void clientTick();
-
- public boolean needsTicks();
-}
diff --git a/src/api/java/mekanism/api/IConfigurable.java b/src/api/java/mekanism/api/IConfigurable.java
deleted file mode 100644
index 512fabf..0000000
--- a/src/api/java/mekanism/api/IConfigurable.java
+++ /dev/null
@@ -1,27 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.entity.player.EntityPlayer;
-
-/**
- * Implement this in your TileEntity class if your block can be modified by a Configurator.
- * @author aidancbrady
- *
- */
-public interface IConfigurable
-{
- /**
- * Called when a player shift-right clicks this block with a Configurator.
- * @param player - the player who clicked the block
- * @param side - the side the block was clicked on
- * @return whether or not an action was performed
- */
- public boolean onSneakRightClick(EntityPlayer player, int side);
-
- /**
- * Called when a player right clicks this block with a Configurator.
- * @param player - the player who clicked the block
- * @param side - the side the block was clicked on
- * @return whether or not an action was performed
- */
- public boolean onRightClick(EntityPlayer player, int side);
-}
diff --git a/src/api/java/mekanism/api/IFilterAccess.java b/src/api/java/mekanism/api/IFilterAccess.java
deleted file mode 100644
index 7bb2ee3..0000000
--- a/src/api/java/mekanism/api/IFilterAccess.java
+++ /dev/null
@@ -1,31 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.nbt.NBTTagCompound;
-
-/**
- * Implement this in your TileEntity class if you wish for Mekanism filters to be able to store any of their
- * information.
- * @author aidancbrady
- *
- */
-public interface IFilterAccess
-{
- /**
- * Collects the TileEntity's filter card data into the parameterized NBTTagCompound.
- * @param nbtTags - the NBTTagCompound of the filter card ItemStack
- * @return the NBTTagCompound that now contains the TileEntity's filter card data
- */
- public NBTTagCompound getFilterData(NBTTagCompound nbtTags);
-
- /**
- * Retrieves the TileEntity's data contained in the filter card based on the given NBTTagCompopund.
- * @param nbtTags - the NBTTagCompound of the filter card ItemStack
- */
- public void setFilterData(NBTTagCompound nbtTags);
-
- /**
- * A String name of this TileEntity that will be displayed as the type of data on the filter card.
- * @return the String name of this TileEntity
- */
- public String getDataType();
-}
diff --git a/src/api/java/mekanism/api/IHeatTransfer.java b/src/api/java/mekanism/api/IHeatTransfer.java
deleted file mode 100644
index 17393f7..0000000
--- a/src/api/java/mekanism/api/IHeatTransfer.java
+++ /dev/null
@@ -1,28 +0,0 @@
-package mekanism.api;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-public interface IHeatTransfer
-{
- /**The value of the zero point of our temperature scale in kelvin*/
- public static final double AMBIENT_TEMP = 300;
-
- /**The heat transfer coefficient for air*/
- public static final double AIR_INVERSE_COEFFICIENT = 10000;
-
- public double getTemp();
-
- public double getInverseConductionCoefficient();
-
- public double getInsulationCoefficient(ForgeDirection side);
-
- public void transferHeatTo(double heat);
-
- public double[] simulateHeat();
-
- public double applyTemperatureChange();
-
- public boolean canConnectHeat(ForgeDirection side);
-
- public IHeatTransfer getAdjacent(ForgeDirection side);
-}
diff --git a/src/api/java/mekanism/api/IMekWrench.java b/src/api/java/mekanism/api/IMekWrench.java
deleted file mode 100644
index 6ac4b05..0000000
--- a/src/api/java/mekanism/api/IMekWrench.java
+++ /dev/null
@@ -1,8 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.entity.player.EntityPlayer;
-
-public interface IMekWrench
-{
- public boolean canUseWrench(EntityPlayer player, int x, int y, int z);
-}
diff --git a/src/api/java/mekanism/api/ISalinationSolar.java b/src/api/java/mekanism/api/ISalinationSolar.java
deleted file mode 100644
index 20e3e1e..0000000
--- a/src/api/java/mekanism/api/ISalinationSolar.java
+++ /dev/null
@@ -1,11 +0,0 @@
-package mekanism.api;
-
-/**
- * Implement this class in a TileEntity if you wish for it to be able to heat up a Salination Plant.
- * @author aidancbrady
- *
- */
-public interface ISalinationSolar
-{
- public boolean seesSun();
-}
diff --git a/src/api/java/mekanism/api/ItemRetriever.java b/src/api/java/mekanism/api/ItemRetriever.java
deleted file mode 100644
index 1b6f4bd..0000000
--- a/src/api/java/mekanism/api/ItemRetriever.java
+++ /dev/null
@@ -1,120 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.block.Block;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-
-/**
- * Use this class's 'getItem()' method to retrieve ItemStacks from the 'Mekanism'
- * class.
- * @author AidanBrady
- *
- */
-public final class ItemRetriever
-{
- /** The 'MekanismItems' class that items are retrieved from. */
- private static Class MekanismItems;
-
- /** The 'MekanismBlocks' class that blocks are retrieved from. */
- private static Class MekanismBlocks;
-
- /**
- * Attempts to retrieve an ItemStack of an item with the declared identifier.
- *
- * Mekanism identifiers follow an easy-to-remember pattern. All identifiers
- * are identical to the String returned by 'getItemName().' None include spaces,
- * and all start with a capital letter. The name that shows up in-game can be
- * stripped down to identifier form by removing spaces and all non-alphabetic
- * characters (,./'=-_). Below is an example:
- *
- * ItemStack enrichedAlloy = ItemRetriever.getItem("EnrichedAlloy");
- *
- * Note that for items or blocks that have specific metadata you will need to create
- * a new ItemStack with that specified value, as this will only return an ItemStack
- * with the meta value '0.'
- *
- * Make sure you run this in or after FMLPostInitializationEvent runs, because most
- * items are registered when FMLInitializationEvent runs. However, some items ARE
- * registered later in order to hook into other mods. In a rare circumstance you may
- * have to add "after:Mekanism" in the @Mod 'dependencies' annotation.
- *
- * @param identifier - a String to be searched in the 'MekanismItems' class
- * @return an ItemStack of the declared identifier, otherwise null.
- */
- public static ItemStack getItem(String identifier)
- {
- try
- {
- if(MekanismItems == null)
- {
- MekanismItems = Class.forName("mekanism.common.MekanismItems");
- }
-
- final Object ret = MekanismItems.getField(identifier).get(null);
-
- if(ret instanceof Item)
- {
- return new ItemStack((Item) ret, 1);
- }
- else
- {
- return null;
- }
- }
- catch(final Exception e)
- {
- System.err.println("Error retrieving item with identifier '" + identifier + "': " + e.getMessage());
- return null;
- }
- }
-
- /**
- * Attempts to retrieve an ItemStack of a block with the declared identifier.
- *
- * Mekanism identifiers follow an easy-to-remember pattern. All identifiers
- * are identical to the String returned by 'getItemName().' None include spaces,
- * and all start with a capital letter. The name that shows up in-game can be
- * stripped down to identifier form by removing spaces and all non-alphabetic
- * characters (,./'=-_). Below is an example:
- *
- * ItemStack enrichedAlloy = ItemRetriever.getItem("EnrichedAlloy");
- *
- * Note that for items or blocks that have specific metadata you will need to create
- * a new ItemStack with that specified value, as this will only return an ItemStack
- * with the meta value '0.'
- *
- * Make sure you run this in or after FMLPostInitializationEvent runs, because most
- * items are registered when FMLInitializationEvent runs. However, some items ARE
- * registered later in order to hook into other mods. In a rare circumstance you may
- * have to add "after:Mekanism" in the @Mod 'dependencies' annotation.
- *
- * @param identifier - a String to be searched in the 'MekanismBlocks' class
- * @return an ItemStack of the declared identifier, otherwise null.
- */
- public static ItemStack getBlock(String identifier)
- {
- try
- {
- if(MekanismBlocks == null)
- {
- MekanismBlocks = Class.forName("mekanism.common.MekanismBlocks");
- }
-
- final Object ret = MekanismBlocks.getField(identifier).get(null);
-
- if(ret instanceof Block)
- {
- return new ItemStack((Block) ret, 1);
- }
- else
- {
- return null;
- }
- }
- catch(final Exception e)
- {
- System.err.println("Error retrieving block with identifier '" + identifier + "': " + e.getMessage());
- return null;
- }
- }
-}
diff --git a/src/api/java/mekanism/api/MekanismAPI.java b/src/api/java/mekanism/api/MekanismAPI.java
deleted file mode 100644
index cfbdb68..0000000
--- a/src/api/java/mekanism/api/MekanismAPI.java
+++ /dev/null
@@ -1,51 +0,0 @@
-package mekanism.api;
-
-import java.util.HashSet;
-import java.util.Set;
-
-import mekanism.api.util.BlockInfo;
-import net.minecraft.block.Block;
-import net.minecraft.item.Item;
-import net.minecraftforge.oredict.OreDictionary;
-import cpw.mods.fml.common.eventhandler.Event;
-
-public class MekanismAPI
-{
- //Add a BlockInfo value here if you don't want a certain block to be picked up by cardboard boxes
- private static Set<BlockInfo> cardboardBoxIgnore = new HashSet<BlockInfo>();
-
- /** Mekanism debug mode */
- public static boolean debug = false;
-
- public static boolean isBlockCompatible(Item item, int meta)
- {
- for(final BlockInfo i : cardboardBoxIgnore)
- {
- if(i.block == Block.getBlockFromItem(item) && (i.meta == OreDictionary.WILDCARD_VALUE || i.meta == meta))
- {
- return false;
- }
- }
-
- return true;
- }
-
- public static void addBoxBlacklist(Block block, int meta)
- {
- cardboardBoxIgnore.add(new BlockInfo(block, meta));
- }
-
- public static void removeBoxBlacklist(Block block, int meta)
- {
- cardboardBoxIgnore.remove(new BlockInfo(block, meta));
- }
-
- public static Set<BlockInfo> getBoxIgnore()
- {
- return cardboardBoxIgnore;
- }
-
- public static class BoxBlacklistEvent extends Event
- {
- }
-}
diff --git a/src/api/java/mekanism/api/MekanismConfig.java b/src/api/java/mekanism/api/MekanismConfig.java
deleted file mode 100644
index 81772b1..0000000
--- a/src/api/java/mekanism/api/MekanismConfig.java
+++ /dev/null
@@ -1,137 +0,0 @@
-package mekanism.api;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import mekanism.api.util.UnitDisplayUtils.EnergyType;
-import mekanism.api.util.UnitDisplayUtils.TempType;
-
-public class MekanismConfig
-{
- public static class general
- {
- public static boolean updateNotifications = true;
- public static boolean controlCircuitOreDict = true;
- public static boolean logPackets = false;
- public static boolean dynamicTankEasterEgg = false;
- public static boolean voiceServerEnabled = true;
- public static boolean cardboardSpawners = true;
- public static boolean enableWorldRegeneration = true;
- public static boolean creativeOverrideElectricChest = true;
- public static boolean spawnBabySkeletons = true;
- public static int obsidianTNTBlastRadius = 12;
- public static int osmiumPerChunk = 12;
- public static int copperPerChunk = 16;
- public static int tinPerChunk = 14;
- public static int saltPerChunk = 2;
- public static int obsidianTNTDelay = 100;
- public static int UPDATE_DELAY = 10;
- public static int VOICE_PORT = 36123;
- public static int maxUpgradeMultiplier = 10;
- public static int userWorldGenVersion = 0;
- public static double ENERGY_PER_REDSTONE = 10000;
- public static int ETHENE_BURN_TIME = 40;
- public static double DISASSEMBLER_USAGE = 10;
- public static EnergyType activeType = EnergyType.J;
- public static TempType tempUnit = TempType.K;
- public static double TO_IC2;
- public static double TO_TE;
- public static double FROM_H2;
- public static double FROM_IC2;
- public static double FROM_TE;
- public static int laserRange;
- public static double laserEnergyNeededPerHardness;
- public static double minerSilkMultiplier = 6;
- public static boolean blacklistIC2;
- public static boolean blacklistRF;
- public static boolean destroyDisabledBlocks;
- public static boolean enableAmbientLighting;
- public static int ambientLightingLevel;
- public static boolean prefilledPortableTanks;
- public static double armoredJetpackDamageRatio;
- public static int armoredJetpackDamageMax;
- public static boolean aestheticWorldDamage;
- public static boolean opsBypassRestrictions;
- public static double solarEvaporationSpeed;
- public static int maxJetpackGas;
- public static int maxScubaGas;
- public static int maxFlamethrowerGas;
- }
-
- public static class client
- {
- public static boolean enablePlayerSounds = true;
- public static boolean enableMachineSounds = true;
- public static boolean fancyUniversalCableRender = true;
- public static boolean holidays = true;
- public static float baseSoundVolume = 1F;
- public static boolean machineEffects = true;
- public static boolean oldTransmitterRender = false;
- public static boolean replaceSoundsWhenResuming = true;
- public static boolean renderCTM = true;
- }
-
- public static class machines
- {
- private static Map<String, Boolean> config = new HashMap<String, Boolean>();
-
- public static boolean isEnabled(String type)
- {
- return config.get(type) != null && config.get(type);
- }
-
- public static void setEntry(String type, boolean enabled)
- {
- config.put(type, enabled);
- }
- }
-
- public static class usage
- {
- public static double enrichmentChamberUsage;
- public static double osmiumCompressorUsage;
- public static double combinerUsage;
- public static double crusherUsage;
- public static double factoryUsage;
- public static double metallurgicInfuserUsage;
- public static double purificationChamberUsage;
- public static double energizedSmelterUsage;
- public static double digitalMinerUsage;
- public static double electricPumpUsage;
- public static double rotaryCondensentratorUsage;
- public static double oxidationChamberUsage;
- public static double chemicalInfuserUsage;
- public static double chemicalInjectionChamberUsage;
- public static double precisionSawmillUsage;
- public static double chemicalDissolutionChamberUsage;
- public static double chemicalWasherUsage;
- public static double chemicalCrystallizerUsage;
- public static double seismicVibratorUsage;
- public static double pressurizedReactionBaseUsage;
- public static double fluidicPlenisherUsage;
- public static double laserUsage;
- public static double gasCentrifugeUsage;
- public static double heavyWaterElectrolysisUsage;
- }
-
- public static class generators
- {
- public static double advancedSolarGeneration;
- public static double bioGeneration;
- public static double heatGeneration;
- public static double heatGenerationLava;
- public static double heatGenerationNether;
- public static double solarGeneration;
-
- public static double windGenerationMin;
- public static double windGenerationMax;
-
- public static int windGenerationMinY;
- public static int windGenerationMaxY;
- }
-
- public static class tools
- {
- public static double armorSpawnRate;
- }
-}
diff --git a/src/api/java/mekanism/api/Pos3D.java b/src/api/java/mekanism/api/Pos3D.java
deleted file mode 100644
index 03c5892..0000000
--- a/src/api/java/mekanism/api/Pos3D.java
+++ /dev/null
@@ -1,458 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.Vec3;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Pos3D - a way of performing operations on objects in a three dimensional environment.
- * @author aidancbrady
- *
- */
-public class Pos3D
-{
- public double xPos;
- public double yPos;
- public double zPos;
-
- public Pos3D()
- {
- this(0, 0, 0);
- }
-
- public Pos3D(Vec3 vec)
- {
- xPos = vec.xCoord;
- yPos = vec.yCoord;
- zPos = vec.zCoord;
- }
-
- public Pos3D(MovingObjectPosition mop)
- {
- xPos = mop.blockX;
- yPos = mop.blockY;
- zPos = mop.blockZ;
- }
-
- public Pos3D(double x, double y, double z)
- {
- xPos = x;
- yPos = y;
- zPos = z;
- }
-
- public Pos3D(Coord4D coord)
- {
- xPos = coord.xCoord;
- yPos = coord.yCoord;
- zPos = coord.zCoord;
- }
-
- /**
- * Creates a Pos3D with an entity's posX, posY, and posZ values.
- * @param entity - entity to create the Pos3D from
- */
- public Pos3D(Entity entity)
- {
- this(entity.posX, entity.posY, entity.posZ);
- }
-
- /**
- * Creates a Pos3D with a TileEntity's xCoord, yCoord and zCoord values.
- * @param tileEntity - TileEntity to create the Pos3D from
- */
- public Pos3D(TileEntity tileEntity)
- {
- this(tileEntity.xCoord, tileEntity.yCoord, tileEntity.zCoord);
- }
-
- /**
- * Returns a new Pos3D from a tag compound.
- * @param tag - tag compound to read from
- * @return the Pos3D from the tag compound
- */
- public static Pos3D read(NBTTagCompound tag)
- {
- return new Pos3D(tag.getDouble("x"), tag.getDouble("y"),
- tag.getDouble("z"));
- }
-
- /**
- * Writes this Pos3D's data to an NBTTagCompound.
- * @param nbtTags - tag compound to write to
- * @return the tag compound with this Pos3D's data
- */
- public NBTTagCompound write(NBTTagCompound nbtTags)
- {
- nbtTags.setDouble("x", xPos);
- nbtTags.setDouble("y", yPos);
- nbtTags.setDouble("z", zPos);
-
- return nbtTags;
- }
-
- /**
- * Creates and returns a Pos3D with values representing the difference between this and the Pos3D in the parameters.
- * @param pos - Pos3D to subtract
- * @return difference of the two Pos3Ds
- */
- public Pos3D diff(Pos3D pos)
- {
- return new Pos3D(xPos - pos.xPos, yPos - pos.yPos, zPos - pos.zPos);
- }
-
- /**
- * Creates a new Pos3D from the motion of an entity.
- * @param entity
- * @return Pos3D representing the motion of the given entity
- */
- public static Pos3D fromMotion(Entity entity)
- {
- return new Pos3D(entity.motionX, entity.motionY, entity.motionZ);
- }
-
- /**
- * Creates a new Coord4D representing this Pos3D in the provided dimension.
- * @param dimensionId - the dimension this Pos3D is in
- * @return Coord4D representing this Pos3D
- */
- public Coord4D getCoord(int dimensionId)
- {
- return new Coord4D((int) xPos, (int) yPos, (int) zPos, dimensionId);
- }
-
- /**
- * Centres a block-derived Pos3D
- */
- public Pos3D centre()
- {
- return translate(0.5, 0.5, 0.5);
- }
-
- /**
- * Translates this Pos3D by the defined values.
- * @param x - amount to translate on the x axis
- * @param y - amount to translate on the y axis
- * @param z - amount to translate on the z axis
- * @return the translated Pos3D
- */
- public Pos3D translate(double x, double y, double z)
- {
- xPos += x;
- yPos += y;
- zPos += z;
-
- return this;
- }
-
- /**
- * Performs the same operation as translate(x, y, z), but with a Pos3D value instead.
- * @param pos - Pos3D value to translate by
- * @return translated Pos3D
- */
- public Pos3D translate(Pos3D pos)
- {
- return translate(pos.xPos, pos.yPos, pos.zPos);
- }
-
- /**
- * Performs the same operation as translate(x, y, z), but by a set amount in a ForgeDirection
- */
- public Pos3D translate(ForgeDirection direction, double amount)
- {
- return translate(direction.offsetX * amount, direction.offsetY * amount, direction.offsetZ * amount);
- }
-
- /**
- * Performs the same operation as translate(x, y, z), but by a set amount in a ForgeDirection
- */
- public Pos3D translateExcludingSide(ForgeDirection direction, double amount)
- {
- if(direction.offsetX == 0)
- {
- xPos += amount;
- }
- if(direction.offsetY == 0)
- {
- yPos += amount;
- }
- if(direction.offsetZ == 0)
- {
- zPos += amount;
- }
-
- return this;
- }
-
- /**
- * Returns the distance between this and the defined Pos3D.
- * @param pos - the Pos3D to find the distance to
- * @return the distance between this and the defined Pos3D
- */
- public double distance(Pos3D pos)
- {
- final double subX = xPos - pos.xPos;
- final double subY = yPos - pos.yPos;
- final double subZ = zPos - pos.zPos;
- return MathHelper.sqrt_double(subX * subX + subY * subY + subZ * subZ);
- }
-
- /**
- * Rotates this Pos3D by the defined yaw value.
- * @param yaw - yaw to rotate by
- * @return rotated Pos3D
- */
- public Pos3D rotateYaw(double yaw)
- {
- final double yawRadians = Math.toRadians(yaw);
-
- final double x = xPos;
- final double z = zPos;
-
- if(yaw != 0)
- {
- xPos = x * Math.cos(yawRadians) - z * Math.sin(yawRadians);
- zPos = z * Math.cos(yawRadians) + x * Math.sin(yawRadians);
- }
-
- return this;
- }
-
- public Pos3D rotatePitch(double pitch)
- {
- final double pitchRadians = Math.toRadians(pitch);
-
- final double y = yPos;
- final double z = zPos;
-
- if(pitch != 0)
- {
- yPos = y * Math.cos(pitchRadians) - z * Math.sin(pitchRadians);
- zPos = z * Math.cos(pitchRadians) + y * Math.sin(pitchRadians);
- }
-
- return this;
- }
-
- public Pos3D rotate(double yaw, double pitch)
- {
- return rotate(yaw, pitch, 0);
- }
-
- public Pos3D rotate(double yaw, double pitch, double roll)
- {
- final double yawRadians = Math.toRadians(yaw);
- final double pitchRadians = Math.toRadians(pitch);
- final double rollRadians = Math.toRadians(roll);
-
- final double x = xPos;
- final double y = yPos;
- final double z = zPos;
-
- xPos = x * Math.cos(yawRadians) * Math.cos(pitchRadians) + z * (Math.cos(yawRadians) * Math.sin(pitchRadians) * Math.sin(rollRadians) - Math.sin(yawRadians) * Math.cos(rollRadians)) + y * (Math.cos(yawRadians) * Math.sin(pitchRadians) * Math.cos(rollRadians) + Math.sin(yawRadians) * Math.sin(rollRadians));
- zPos = x * Math.sin(yawRadians) * Math.cos(pitchRadians) + z * (Math.sin(yawRadians) * Math.sin(pitchRadians) * Math.sin(rollRadians) + Math.cos(yawRadians) * Math.cos(rollRadians)) + y * (Math.sin(yawRadians) * Math.sin(pitchRadians) * Math.cos(rollRadians) - Math.cos(yawRadians) * Math.sin(rollRadians));
- yPos = -x * Math.sin(pitchRadians) + z * Math.cos(pitchRadians) * Math.sin(rollRadians) + y * Math.cos(pitchRadians) * Math.cos(rollRadians);
-
- return this;
- }
-
- public Pos3D multiply(Pos3D pos)
- {
- xPos *= pos.xPos;
- yPos *= pos.yPos;
- zPos *= pos.zPos;
-
- return this;
- }
-
- /**
- * Scales this Pos3D by the defined x, y, an z values.
- * @param x - x value to scale by
- * @param y - y value to scale by
- * @param z - z value to scale by
- * @return scaled Pos3D
- */
- public Pos3D scale(double x, double y, double z)
- {
- xPos *= x;
- yPos *= y;
- zPos *= z;
-
- return this;
- }
-
- /**
- * Performs the same operation as scale(x, y, z), but with a value representing all three dimensions.
- * @param scale - value to scale by
- * @return scaled Pos3D
- */
- public Pos3D scale(double scale)
- {
- return scale(scale, scale, scale);
- }
-
- public Pos3D rotate(float angle, Pos3D axis)
- {
- return translateMatrix(getRotationMatrix(angle, axis), this);
- }
-
- public double[] getRotationMatrix(float angle)
- {
- final double[] matrix = new double[16];
- final Pos3D axis = clone().normalize();
-
- final double x = axis.xPos;
- final double y = axis.yPos;
- final double z = axis.zPos;
-
- angle *= 0.0174532925D;
-
- final float cos = (float) Math.cos(angle);
- final float ocos = 1.0F - cos;
- final float sin = (float) Math.sin(angle);
-
- matrix[0] = (x * x * ocos + cos);
- matrix[1] = (y * x * ocos + z * sin);
- matrix[2] = (x * z * ocos - y * sin);
- matrix[4] = (x * y * ocos - z * sin);
- matrix[5] = (y * y * ocos + cos);
- matrix[6] = (y * z * ocos + x * sin);
- matrix[8] = (x * z * ocos + y * sin);
- matrix[9] = (y * z * ocos - x * sin);
- matrix[10] = (z * z * ocos + cos);
- matrix[15] = 1.0F;
-
- return matrix;
- }
-
- public static Pos3D translateMatrix(double[] matrix, Pos3D translation)
- {
- final double x = translation.xPos * matrix[0] + translation.yPos * matrix[1] + translation.zPos * matrix[2] + matrix[3];
- final double y = translation.xPos * matrix[4] + translation.yPos * matrix[5] + translation.zPos * matrix[6] + matrix[7];
- final double z = translation.xPos * matrix[8] + translation.yPos * matrix[9] + translation.zPos * matrix[10] + matrix[11];
-
- translation.xPos = x;
- translation.yPos = y;
- translation.zPos = z;
-
- return translation;
- }
-
- public static double[] getRotationMatrix(float angle, Pos3D axis)
- {
- return axis.getRotationMatrix(angle);
- }
-
- public double anglePreNorm(Pos3D pos2)
- {
- return Math.acos(dotProduct(pos2));
- }
-
- public static double anglePreNorm(Pos3D pos1, Pos3D pos2)
- {
- return Math.acos(pos1.clone().dotProduct(pos2));
- }
-
- public double dotProduct(Pos3D pos)
- {
- return xPos * pos.xPos + yPos * pos.yPos + zPos * pos.zPos;
- }
-
- public Pos3D crossProduct(Pos3D compare)
- {
- return clone().toCrossProduct(compare);
- }
-
- public Pos3D toCrossProduct(Pos3D compare)
- {
- final double newX = yPos * compare.zPos - zPos * compare.yPos;
- final double newY = zPos * compare.xPos - xPos * compare.zPos;
- final double newZ = xPos * compare.yPos - yPos * compare.xPos;
-
- xPos = newX;
- yPos = newY;
- zPos = newZ;
-
- return this;
- }
-
- public Pos3D xCrossProduct()
- {
- return new Pos3D(0.0D, zPos, -yPos);
- }
-
- public Pos3D zCrossProduct()
- {
- return new Pos3D(-yPos, xPos, 0.0D);
- }
-
- public Pos3D getPerpendicular()
- {
- if(zPos == 0)
- {
- return zCrossProduct();
- }
-
- return xCrossProduct();
- }
-
- public Pos3D floor()
- {
- return new Pos3D(Math.floor(xPos), Math.floor(yPos), Math.floor(zPos));
- }
-
- public double getMagnitude()
- {
- return Math.sqrt(xPos * xPos + yPos * yPos + zPos * zPos);
- }
-
- public Pos3D normalize()
- {
- final double d = getMagnitude();
-
- if(d != 0)
- {
- this.scale(1 / d);
- }
-
- return this;
- }
-
- public static AxisAlignedBB getAABB(Pos3D pos1, Pos3D pos2)
- {
- return AxisAlignedBB.getBoundingBox(Math.min(pos1.xPos, pos2.xPos), Math.min(pos1.yPos, pos2.yPos), Math.min(pos1.zPos, pos2.zPos), Math.max(pos1.xPos, pos2.xPos), Math.max(pos1.yPos, pos2.yPos), Math.max(pos1.zPos, pos2.zPos));
- }
-
- @Override
- public Pos3D clone()
- {
- return new Pos3D(xPos, yPos, zPos);
- }
-
- @Override
- public String toString()
- {
- return "[Pos3D: " + xPos + ", " + yPos + ", " + zPos + "]";
- }
-
- @Override
- public boolean equals(Object obj)
- {
- return obj instanceof Pos3D && ((Pos3D) obj).xPos == xPos && ((Pos3D) obj).yPos == yPos && ((Pos3D) obj).zPos == zPos;
- }
-
- @Override
- public int hashCode()
- {
- int code = 1;
- code = 31 * code + new Double(xPos).hashCode();
- code = 31 * code + new Double(yPos).hashCode();
- code = 31 * code + new Double(zPos).hashCode();
- return code;
- }
-}
diff --git a/src/api/java/mekanism/api/Range4D.java b/src/api/java/mekanism/api/Range4D.java
deleted file mode 100644
index 7e4f6ae..0000000
--- a/src/api/java/mekanism/api/Range4D.java
+++ /dev/null
@@ -1,107 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.entity.player.EntityPlayer;
-import cpw.mods.fml.common.FMLCommonHandler;
-
-public class Range4D
-{
- public int dimensionId;
-
- public int xMin;
- public int yMin;
- public int zMin;
- public int xMax;
- public int yMax;
- public int zMax;
-
- public Range4D(int minX, int minY, int minZ, int maxX, int maxY, int maxZ, int dimension)
- {
- xMin = minX;
- yMin = minY;
- zMin = minZ;
- xMax = maxX;
- yMax = maxY;
- zMax = maxZ;
-
- dimensionId = dimension;
- }
-
- public Range4D(Chunk3D chunk)
- {
- xMin = chunk.xCoord * 16;
- yMin = 0;
- zMin = chunk.zCoord * 16;
- xMax = xMin + 16;
- yMax = 255;
- zMax = zMin + 16;
-
- dimensionId = chunk.dimensionId;
- }
-
- public Range4D(Coord4D coord)
- {
- xMin = coord.xCoord;
- yMin = coord.yCoord;
- zMin = coord.zCoord;
-
- xMax = coord.xCoord + 1;
- yMax = coord.yCoord + 1;
- zMax = coord.zCoord + 1;
-
- dimensionId = coord.dimensionId;
- }
-
- public static Range4D getChunkRange(EntityPlayer player)
- {
- final int radius = FMLCommonHandler.instance().getMinecraftServerInstance().getConfigurationManager().getViewDistance();
-
- return new Range4D(new Chunk3D(player)).expandChunks(radius);
- }
-
- public Range4D expandChunks(int chunks)
- {
- xMin -= chunks * 16;
- xMax += chunks * 16;
- zMin -= chunks * 16;
- zMax += chunks * 16;
-
- return this;
- }
-
- public boolean intersects(Range4D range)
- {
- return (xMax + 1 - 1.E-05D > range.xMin) && (range.xMax + 1 - 1.E-05D > xMin) && (yMax + 1 - 1.E-05D > range.yMin) && (range.yMax + 1 - 1.E-05D > yMin) && (zMax + 1 - 1.E-05D > range.zMin) && (range.zMax + 1 - 1.E-05D > zMin);
- }
-
- @Override
- public Range4D clone()
- {
- return new Range4D(xMin, yMin, zMin, xMax, yMax, zMax, dimensionId);
- }
-
- @Override
- public String toString()
- {
- return "[Range4D: " + xMin + ", " + yMin + ", " + zMin + ", " + xMax + ", " + yMax + ", " + zMax + ", dim=" + dimensionId + "]";
- }
-
- @Override
- public boolean equals(Object obj)
- {
- return obj instanceof Range4D && ((Range4D) obj).xMin == xMin && ((Range4D) obj).yMin == yMin && ((Range4D) obj).zMin == zMin && ((Range4D) obj).xMax == xMax && ((Range4D) obj).yMax == yMax && ((Range4D) obj).zMax == zMax && ((Range4D) obj).dimensionId == dimensionId;
- }
-
- @Override
- public int hashCode()
- {
- int code = 1;
- code = 31 * code + xMin;
- code = 31 * code + yMin;
- code = 31 * code + zMin;
- code = 31 * code + xMax;
- code = 31 * code + yMax;
- code = 31 * code + zMax;
- code = 31 * code + dimensionId;
- return code;
- }
-}
diff --git a/src/api/java/mekanism/api/TabProxy.java b/src/api/java/mekanism/api/TabProxy.java
deleted file mode 100644
index a96813c..0000000
--- a/src/api/java/mekanism/api/TabProxy.java
+++ /dev/null
@@ -1,45 +0,0 @@
-package mekanism.api;
-
-import net.minecraft.creativetab.CreativeTabs;
-
-/**
- * Class used to indirectly reference the Mekanism creative tab.
- * @author AidanBrady
- *
- */
-public final class TabProxy
-{
- /** The 'Mekanism' class where the tab instance is stored. */
- public static Class Mekanism;
-
- /**
- * Attempts to get the Mekanism creative tab instance from the 'Mekanism' class. Will return
- * the tab if the mod is loaded, but otherwise will return the defined 'preferred' creative tab. This way
- * you don't need to worry about NPEs!
- * @return Mekanism creative tab if can, otherwise preferred tab
- */
- public static CreativeTabs tabMekanism(CreativeTabs preferred)
- {
- try
- {
- if(Mekanism == null)
- {
- Mekanism = Class.forName("mekanism.common.Mekanism");
- }
-
- final Object ret = Mekanism.getField("tabMekanism").get(null);
-
- if(ret instanceof CreativeTabs)
- {
- return (CreativeTabs) ret;
- }
-
- return preferred;
- }
- catch(final Exception e)
- {
- System.err.println("Error retrieving Mekanism creative tab.");
- return preferred;
- }
- }
-}
diff --git a/src/api/java/mekanism/api/energy/EnergizedItemManager.java b/src/api/java/mekanism/api/energy/EnergizedItemManager.java
deleted file mode 100644
index 458c480..0000000
--- a/src/api/java/mekanism/api/energy/EnergizedItemManager.java
+++ /dev/null
@@ -1,60 +0,0 @@
-package mekanism.api.energy;
-
-import net.minecraft.item.ItemStack;
-
-public class EnergizedItemManager
-{
- /**
- * Discharges an IEnergizedItem with the defined amount of energy.
- * @param itemStack - ItemStack to discharge
- * @param amount - amount of energy to discharge from the item, usually the total amount of energy needed in a TileEntity
- * @return amount of energy discharged
- */
- public static double discharge(ItemStack itemStack, double amount)
- {
- if(itemStack != null)
- {
- if(itemStack.getItem() instanceof IEnergizedItem)
- {
- final IEnergizedItem energizedItem = (IEnergizedItem) itemStack.getItem();
-
- if(energizedItem.canSend(itemStack))
- {
- final double energyToUse = Math.min(energizedItem.getMaxTransfer(itemStack), Math.min(energizedItem.getEnergy(itemStack), amount));
- energizedItem.setEnergy(itemStack, energizedItem.getEnergy(itemStack) - energyToUse);
-
- return energyToUse;
- }
- }
- }
-
- return 0;
- }
-
- /**
- * Charges an IEnergizedItem with the defined amount of energy.
- * @param itemStack - ItemStack to charge
- * @param amount - amount of energy to charge the item with, usually the total amount of energy stored in a TileEntity
- * @return amount of energy charged
- */
- public static double charge(ItemStack itemStack, double amount)
- {
- if(itemStack != null)
- {
- if(itemStack.getItem() instanceof IEnergizedItem)
- {
- final IEnergizedItem energizedItem = (IEnergizedItem) itemStack.getItem();
-
- if(energizedItem.canReceive(itemStack))
- {
- final double energyToSend = Math.min(energizedItem.getMaxTransfer(itemStack), Math.min(energizedItem.getMaxEnergy(itemStack) - energizedItem.getEnergy(itemStack), amount));
- energizedItem.setEnergy(itemStack, energizedItem.getEnergy(itemStack) + energyToSend);
-
- return energyToSend;
- }
- }
- }
-
- return 0;
- }
-}
diff --git a/src/api/java/mekanism/api/energy/EnergyStack.java b/src/api/java/mekanism/api/energy/EnergyStack.java
deleted file mode 100644
index 807262d..0000000
--- a/src/api/java/mekanism/api/energy/EnergyStack.java
+++ /dev/null
@@ -1,14 +0,0 @@
-package mekanism.api.energy;
-
-/**
- * Created by ben on 27/03/15.
- */
-public class EnergyStack
-{
- public double amount;
-
- public EnergyStack(double newAmount)
- {
- amount = newAmount;
- }
-}
diff --git a/src/api/java/mekanism/api/energy/ICableOutputter.java b/src/api/java/mekanism/api/energy/ICableOutputter.java
deleted file mode 100644
index 015379c..0000000
--- a/src/api/java/mekanism/api/energy/ICableOutputter.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package mekanism.api.energy;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Implement this if your TileEntity is capable of outputting energy to cables, overriding Mekanism's default implementation.
- * @author AidanBrady
- *
- */
-public interface ICableOutputter
-{
- /**
- * Whether or not this block can output to a cable on a specific side.
- * @param side - side to check
- * @return if the block can output
- */
- public boolean canOutputTo(ForgeDirection side);
-}
diff --git a/src/api/java/mekanism/api/energy/IEnergizedItem.java b/src/api/java/mekanism/api/energy/IEnergizedItem.java
deleted file mode 100644
index b672545..0000000
--- a/src/api/java/mekanism/api/energy/IEnergizedItem.java
+++ /dev/null
@@ -1,59 +0,0 @@
-package mekanism.api.energy;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Implement this in an item's class if it should be able to store electricity.
- * @author aidancbrady
- *
- */
-public interface IEnergizedItem
-{
- /**
- * Gets and returns the amount of energy stored in this item.
- * @param itemStack - the ItemStack to check
- * @return energy stored
- */
- public double getEnergy(ItemStack itemStack);
-
- /**
- * Sets this item's stored energy value to a new amount.
- * @param itemStack - the ItemStack who's energy value is to be change
- * @param amount - new amount of energy
- */
- public void setEnergy(ItemStack itemStack, double amount);
-
- /**
- * Gets and returns this item's maximum amount of energy that can be stored.
- * @param itemStack - the ItemStack to check
- * @return maximum energy
- */
- public double getMaxEnergy(ItemStack itemStack);
-
- /**
- * Gets and returns how much energy this item can transfer to and from charging slots.
- * @param itemStack - the ItemStack to check
- * @return transfer amount
- */
- public double getMaxTransfer(ItemStack itemStack);
-
- /**
- * Gets and returns whether or not this item can receive energy from a charging slot.
- * @param itemStack - the ItemStack to check
- * @return if the item can receive energy
- */
- public boolean canReceive(ItemStack itemStack);
-
- /**
- * Gets and returns whether or not this item can send energy to a charging slot.
- * @param itemStack - the ItemStack to check
- * @return if the item can send energy
- */
- public boolean canSend(ItemStack itemStack);
-
- /**
- * Returns whether or not this item contains metadata-specific subtypes instead of using metadata for damage display.
- * @return if the item contains metadata-specific subtypes
- */
- public boolean isMetadataSpecific(ItemStack itemStack);
-}
diff --git a/src/api/java/mekanism/api/energy/IStrictEnergyAcceptor.java b/src/api/java/mekanism/api/energy/IStrictEnergyAcceptor.java
deleted file mode 100644
index 53edc68..0000000
--- a/src/api/java/mekanism/api/energy/IStrictEnergyAcceptor.java
+++ /dev/null
@@ -1,25 +0,0 @@
-package mekanism.api.energy;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Implement this if your TileEntity can accept energy at a floating-point double value from Universal Cables.
- * @author AidanBrady
- *
- */
-public interface IStrictEnergyAcceptor extends IStrictEnergyStorage
-{
- /**
- * Transfer a certain amount of energy to this acceptor.
- * @param amount - amount to transfer
- * @return energy used
- */
- public double transferEnergyToAcceptor(ForgeDirection side, double amount);
-
- /**
- * Whether or not this tile entity accepts energy from a certain side.
- * @param side - side to check
- * @return if tile entity accepts energy
- */
- public boolean canReceiveEnergy(ForgeDirection side);
-}
diff --git a/src/api/java/mekanism/api/energy/IStrictEnergyStorage.java b/src/api/java/mekanism/api/energy/IStrictEnergyStorage.java
deleted file mode 100644
index fd560fa..0000000
--- a/src/api/java/mekanism/api/energy/IStrictEnergyStorage.java
+++ /dev/null
@@ -1,27 +0,0 @@
-package mekanism.api.energy;
-
-/**
- * Mekanism-specific energy storage for TileEntities, already implemented in IStrictEnergyAcceptor.
- * @author aidancbrady
- *
- */
-public interface IStrictEnergyStorage
-{
- /**
- * Gets the amount of energy this TileEntity is currently storing.
- * @return stored energy
- */
- public double getEnergy();
-
- /**
- * Sets the amount of stored energy of this TileEntity to a new amount.
- * @param energy - new energy value
- */
- public void setEnergy(double energy);
-
- /**
- * Gets the maximum amount of energy this TileEntity can store.
- * @return maximum energy
- */
- public double getMaxEnergy();
-}
diff --git a/src/api/java/mekanism/api/energy/package-info.java b/src/api/java/mekanism/api/energy/package-info.java
deleted file mode 100644
index d16dddf..0000000
--- a/src/api/java/mekanism/api/energy/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|energy")
-package mekanism.api.energy;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/gas/Gas.java b/src/api/java/mekanism/api/gas/Gas.java
deleted file mode 100644
index b65353e..0000000
--- a/src/api/java/mekanism/api/gas/Gas.java
+++ /dev/null
@@ -1,222 +0,0 @@
-package mekanism.api.gas;
-
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidRegistry;
-
-/**
- * Gas - a class used to set specific properties of gasses when used or seen in-game.
- * @author aidancbrady
- *
- */
-public class Gas
-{
- private String name;
-
- private String unlocalizedName;
-
- private Fluid fluid;
-
- private IIcon icon;
-
- private boolean visible = true;
-
- private boolean from_fluid = false;
-
- /**
- * Creates a new Gas object with a defined name or key value.
- * @param s - name or key to associate this Gas with
- */
- public Gas(String s)
- {
- unlocalizedName = name = s;
- }
-
- /**
- * Creates a new Gas object that corresponds to the given Fluid
- */
- public Gas(Fluid f)
- {
- unlocalizedName = name = f.getName();
- icon = f.getStillIcon();
- fluid = f;
- from_fluid = true;
- }
-
- /**
- * Gets the name (key) of this Gas. This is NOT a translated or localized display name.
- * @return this Gas's name or key
- */
- public String getName()
- {
- return name;
- }
-
- /**
- * Whether or not this is a visible gas.
- * @return if this gas is visible
- */
- public boolean isVisible()
- {
- return visible;
- }
-
- /**
- * Sets this gas's "visible" state to a new value. Setting it to 'false' will treat this gas as an internal gas, and it will not be displayed or accessed by other mods.
- * @param v - new visible state
- * @return this Gas object
- */
- public Gas setVisible(boolean v)
- {
- visible = v;
-
- return this;
- }
-
- /**
- * Gets the unlocalized name of this Gas.
- * @return this Gas's unlocalized name
- */
- public String getUnlocalizedName()
- {
- return "gas." + unlocalizedName;
- }
-
- /**
- * Translates this Gas's unlocalized name and returns it as localized.
- * @return this Gas's localized name
- */
- public String getLocalizedName()
- {
- return StatCollector.translateToLocal(getUnlocalizedName());
- }
-
- /**
- * Sets the unlocalized name of this Gas.
- * @param s - unlocalized name to set
- * @return this Gas object
- */
- public Gas setUnlocalizedName(String s)
- {
- unlocalizedName = s;
-
- return this;
- }
-
- /**
- * Gets the IIcon associated with this Gas.
- * @return associated IIcon
- */
- public IIcon getIcon()
- {
- if(from_fluid)
- {
- return getFluid().getIcon();
- }
-
- return icon;
- }
-
- /**
- * Sets this gas's icon.
- * @param i - IIcon to associate with this Gas
- * @return this Gas object
- */
- public Gas setIcon(IIcon i)
- {
- icon = i;
-
- if(hasFluid())
- {
- fluid.setIcons(getIcon());
- }
-
- from_fluid = false;
-
- return this;
- }
-
- /**
- * Gets the ID associated with this gas.
- * @return the associated gas ID
- */
- public int getID()
- {
- return GasRegistry.getGasID(this);
- }
-
- /**
- * Writes this Gas to a defined tag compound.
- * @param nbtTags - tag compound to write this Gas to
- * @return the tag compound this gas was written to
- */
- public NBTTagCompound write(NBTTagCompound nbtTags)
- {
- nbtTags.setString("gasName", getName());
-
- return nbtTags;
- }
-
- /**
- * Returns the Gas stored in the defined tag compound.
- * @param nbtTags - tag compound to get the Gas from
- * @return Gas stored in the tag compound
- */
- public static Gas readFromNBT(NBTTagCompound nbtTags)
- {
- if(nbtTags == null || nbtTags.hasNoTags())
- {
- return null;
- }
-
- return GasRegistry.getGas(nbtTags.getString("gasName"));
- }
-
- /**
- * Whether or not this Gas has an associated fluid.
- * @return if this gas has a fluid
- */
- public boolean hasFluid()
- {
- return fluid != null;
- }
-
- /**
- * Gets the fluid associated with this Gas.
- * @return fluid associated with this gas
- */
- public Fluid getFluid()
- {
- return fluid;
- }
-
- /**
- * Registers a new fluid out of this Gas or gets one from the FluidRegistry.
- * @return this Gas object
- */
- public Gas registerFluid()
- {
- if(fluid == null)
- {
- if(FluidRegistry.getFluid(getName()) == null)
- {
- fluid = new Fluid(getName()).setGaseous(true);
- FluidRegistry.registerFluid(fluid);
- }
- else
- {
- fluid = FluidRegistry.getFluid(getName());
- }
- }
-
- return this;
- }
-
- @Override
- public String toString()
- {
- return name;
- }
-}
diff --git a/src/api/java/mekanism/api/gas/GasNetwork.java b/src/api/java/mekanism/api/gas/GasNetwork.java
deleted file mode 100644
index 05e18be..0000000
--- a/src/api/java/mekanism/api/gas/GasNetwork.java
+++ /dev/null
@@ -1,373 +0,0 @@
-package mekanism.api.gas;
-
-import java.util.Collection;
-import java.util.Collections;
-import java.util.EnumSet;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import mekanism.api.Coord4D;
-import mekanism.api.transmitters.DynamicNetwork;
-import mekanism.api.transmitters.IGridTransmitter;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.common.util.ForgeDirection;
-
-import com.google.common.collect.Lists;
-
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.common.eventhandler.Event;
-
-/**
- * A DynamicNetwork extension created specifically for the transfer of Gasses. By default this is server-only, but if ticked on
- * the client side and if it's posted events are handled properly, it has the capability to visually display gasses network-wide.
- * @author aidancbrady
- *
- */
-public class GasNetwork extends DynamicNetwork<IGasHandler, GasNetwork>
-{
- public int transferDelay = 0;
-
- public boolean didTransfer;
- public boolean prevTransfer;
-
- public float gasScale;
-
- public Gas refGas;
-
- public GasStack buffer;
- public int prevStored;
-
- public int prevTransferAmount = 0;
-
- public GasNetwork()
- {
- }
-
- public GasNetwork(Collection<GasNetwork> networks)
- {
- for(final GasNetwork net : networks)
- {
- if(net != null)
- {
- if(FMLCommonHandler.instance().getEffectiveSide().isClient())
- {
- if(net.refGas != null && net.gasScale > gasScale)
- {
- gasScale = net.gasScale;
- refGas = net.refGas;
- buffer = net.buffer;
-
- net.gasScale = 0;
- net.refGas = null;
- net.buffer = null;
- }
- }
- else
- {
- if(net.buffer != null)
- {
- if(buffer == null)
- {
- buffer = net.buffer.copy();
- }
- else
- {
- if(buffer.isGasEqual(net.buffer))
- {
- buffer.amount += net.buffer.amount;
- }
- else if(net.buffer.amount > buffer.amount)
- {
- buffer = net.buffer.copy();
- }
-
- }
-
- net.buffer = null;
- }
- }
-
- adoptTransmittersAndAcceptorsFrom(net);
- net.deregister();
- }
- }
-
- gasScale = getScale();
-
- register();
- }
-
- @Override
- public void absorbBuffer(IGridTransmitter<IGasHandler, GasNetwork> transmitter)
- {
- final Object b = transmitter.getBuffer();
-
- if(!(b instanceof GasStack) || ((GasStack) b).getGas() == null || ((GasStack) b).amount == 0)
- {
- return;
- }
-
- final GasStack gas = (GasStack) b;
-
- if(buffer == null || buffer.getGas() == null || buffer.amount == 0)
- {
- buffer = gas.copy();
- gas.amount = 0;
- return;
- }
-
- //TODO better multiple buffer impl
- if(buffer.isGasEqual(gas))
- {
- buffer.amount += gas.amount;
- }
-
- gas.amount = 0;
- }
-
- @Override
- public void clampBuffer()
- {
- if(buffer != null && buffer.amount > getCapacity())
- {
- buffer.amount = capacity;
- }
- }
-
- public int getGasNeeded()
- {
- return getCapacity() - (buffer != null ? buffer.amount : 0);
- }
-
- public int tickEmit(GasStack stack)
- {
- final List<IGasHandler> availableAcceptors = Lists.newArrayList();
-
- availableAcceptors.addAll(getAcceptors(stack.getGas()));
-
- Collections.shuffle(availableAcceptors);
-
- int toSend = stack.amount;
- final int prevSending = toSend;
-
- if(!availableAcceptors.isEmpty())
- {
- final int divider = availableAcceptors.size();
- int remaining = toSend % divider;
- final int sending = (toSend - remaining) / divider;
-
- for(final IGasHandler acceptor : availableAcceptors)
- {
- int currentSending = sending;
- final EnumSet<ForgeDirection> sides = acceptorDirections.get(Coord4D.get((TileEntity) acceptor));
-
- if(remaining > 0)
- {
- currentSending++;
- remaining--;
- }
-
- for(final ForgeDirection side : sides)
- {
- final int prev = toSend;
-
- toSend -= acceptor.receiveGas(side, new GasStack(
- stack.getGas(), currentSending), true);
-
- if(toSend < prev)
- {
- break;
- }
- }
- }
- }
-
- final int sent = prevSending - toSend;
-
- if(sent > 0 && FMLCommonHandler.instance().getEffectiveSide().isServer())
- {
- didTransfer = true;
- transferDelay = 2;
- }
-
- return sent;
- }
-
- public int emit(GasStack stack, boolean doTransfer)
- {
- if(buffer != null && buffer.getGas() != stack.getGas())
- {
- return 0;
- }
-
- final int toUse = Math.min(getGasNeeded(), stack.amount);
-
- if(doTransfer)
- {
- if(buffer == null)
- {
- buffer = stack.copy();
- buffer.amount = toUse;
- }
- else
- {
- buffer.amount += toUse;
- }
- }
-
- return toUse;
- }
-
- @Override
- public void onUpdate()
- {
- super.onUpdate();
-
- if(FMLCommonHandler.instance().getEffectiveSide().isServer())
- {
- prevTransferAmount = 0;
-
- if(transferDelay == 0)
- {
- didTransfer = false;
- }
- else
- {
- transferDelay--;
- }
-
- final int stored = buffer != null ? buffer.amount : 0;
-
- if(stored != prevStored)
- {
- needsUpdate = true;
- }
-
- prevStored = stored;
-
- if(didTransfer != prevTransfer || needsUpdate)
- {
- MinecraftForge.EVENT_BUS.post(new GasTransferEvent(this,
- buffer, didTransfer));
- needsUpdate = false;
- }
-
- prevTransfer = didTransfer;
-
- if(buffer != null)
- {
- prevTransferAmount = tickEmit(buffer);
- buffer.amount -= prevTransferAmount;
-
- if(buffer.amount <= 0)
- {
- buffer = null;
- }
- }
- }
- }
-
- @Override
- public void clientTick()
- {
- super.clientTick();
-
- gasScale = Math.max(gasScale, getScale());
-
- if(didTransfer && gasScale < 1)
- {
- gasScale = Math.max(getScale(), Math.min(1, gasScale + 0.02F));
- }
- else if(!didTransfer && gasScale > 0)
- {
- gasScale = Math.max(getScale(), Math.max(0, gasScale - 0.02F));
-
- if(gasScale == 0)
- {
- buffer = null;
- }
- }
- }
-
- @Override
- public Set<IGasHandler> getAcceptors(Object data)
- {
- final Gas type = (Gas) data;
- final Set<IGasHandler> toReturn = new HashSet<IGasHandler>();
-
- if(FMLCommonHandler.instance().getEffectiveSide().isClient())
- {
- return toReturn;
- }
-
- for(final Coord4D coord : possibleAcceptors.keySet())
- {
- final EnumSet<ForgeDirection> sides = acceptorDirections.get(coord);
- final TileEntity tile = coord.getTileEntity(getWorld());
-
- if(!(tile instanceof IGasHandler) || sides == null || sides.isEmpty())
- {
- continue;
- }
-
- final IGasHandler acceptor = (IGasHandler) tile;
-
- for(final ForgeDirection side : sides)
- {
- if(acceptor != null && acceptor.canReceiveGas(side, type))
- {
- toReturn.add(acceptor);
- break;
- }
- }
- }
-
- return toReturn;
- }
-
- public static class GasTransferEvent extends Event
- {
- public final GasNetwork gasNetwork;
-
- public final GasStack transferType;
- public final boolean didTransfer;
-
- public GasTransferEvent(GasNetwork network, GasStack type, boolean did)
- {
- gasNetwork = network;
- transferType = type;
- didTransfer = did;
- }
- }
-
- public float getScale()
- {
- return Math.min(1, (buffer == null || getCapacity() == 0 ? 0 : (float) buffer.amount / getCapacity()));
- }
-
- @Override
- public String toString()
- {
- return "[GasNetwork] " + transmitters.size() + " transmitters, " + possibleAcceptors.size() + " acceptors.";
- }
-
- @Override
- public String getNeededInfo()
- {
- return Integer.toString(getGasNeeded());
- }
-
- @Override
- public String getStoredInfo()
- {
- return buffer != null ? buffer.getGas().getLocalizedName() + " (" + buffer.amount + ")" : "None";
- }
-
- @Override
- public String getFlowInfo()
- {
- return Integer.toString(prevTransferAmount) + "/t";
- }
-}
diff --git a/src/api/java/mekanism/api/gas/GasRegistry.java b/src/api/java/mekanism/api/gas/GasRegistry.java
deleted file mode 100644
index 37a6363..0000000
--- a/src/api/java/mekanism/api/gas/GasRegistry.java
+++ /dev/null
@@ -1,113 +0,0 @@
-package mekanism.api.gas;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import net.minecraftforge.fluids.Fluid;
-
-public class GasRegistry
-{
- private static ArrayList<Gas> registeredGasses = new ArrayList<Gas>();
-
- /**
- * Register a new gas into GasRegistry.
- * @param gas - Gas to register
- * @return the gas that has been registered, pulled right out of GasRegistry
- */
- public static Gas register(Gas gas)
- {
- if(gas == null)
- {
- return null;
- }
-
- registeredGasses.add(gas);
-
- return getGas(gas.getName());
- }
-
- /**
- * Gets the gas associated with the defined ID.
- * @param id - ID to check
- * @return gas associated with defined ID
- */
- public static Gas getGas(int id)
- {
- if(id == -1)
- {
- return null;
- }
-
- return registeredGasses.get(id);
- }
-
- /**
- * Gets the gas associated with the defined fluid.
- * @param f - fluid to check
- * @return the gas associated with the fluid
- */
- public static Gas getGas(Fluid f)
- {
- for(final Gas gas : getRegisteredGasses())
- {
- if(gas.hasFluid() && gas.getFluid() == f)
- {
- return gas;
- }
- }
-
- return null;
- }
-
- /**
- * Whether or not GasRegistry contains a gas with the specified name
- * @param name - name to check
- * @return if GasRegistry contains a gas with the defined name
- */
- public static boolean containsGas(String name)
- {
- return getGas(name) != null;
- }
-
- /**
- * Gets the list of all gasses registered in GasRegistry.
- * @return a cloned list of all registered gasses
- */
- public static List<Gas> getRegisteredGasses()
- {
- return (List<Gas>) registeredGasses.clone();
- }
-
- /**
- * Gets the gas associated with the specified name.
- * @param name - name of the gas to get
- * @return gas associated with the name
- */
- public static Gas getGas(String name)
- {
- for(final Gas gas : registeredGasses)
- {
- if(gas.getName().toLowerCase().equals(name.toLowerCase()))
- {
- return gas;
- }
- }
-
- return null;
- }
-
- /**
- * Gets the gas ID of a specified gas.
- * @param gas - gas to get the ID from
- * @return gas ID
- */
- public static int getGasID(Gas gas)
- {
- if(gas == null || !containsGas(gas.getName()))
- {
- return -1;
- }
-
- return registeredGasses.indexOf(gas);
- }
-}
diff --git a/src/api/java/mekanism/api/gas/GasStack.java b/src/api/java/mekanism/api/gas/GasStack.java
deleted file mode 100644
index 6d04a53..0000000
--- a/src/api/java/mekanism/api/gas/GasStack.java
+++ /dev/null
@@ -1,134 +0,0 @@
-package mekanism.api.gas;
-
-import net.minecraft.nbt.NBTTagCompound;
-
-/**
- * GasStack - a specified amount of a defined Gas with certain properties.
- * @author aidancbrady
- *
- */
-public class GasStack
-{
- private Gas type;
-
- public int amount;
-
- /**
- * Creates a new GasStack with a defined gas ID and quantity.
- * @param id - gas ID to associate this GasStack to, will perform a GasRegistry lookup in the constructor
- * @param quantity - amount of gas to be referenced in this GasStack
- */
- public GasStack(int id, int quantity)
- {
- type = GasRegistry.getGas(id);
- amount = quantity;
- }
-
- /**
- * Creates a new GasStack with a defined Gas type and quantity.
- * @param gas - gas type of the stack
- * @param quantity - amount of gas to be referenced in this GasStack
- */
- public GasStack(Gas gas, int quantity)
- {
- type = gas;
- amount = quantity;
- }
-
- private GasStack()
- {
- }
-
- /**
- * Gets the Gas type of this GasStack.
- * @return this GasStack's Gas type
- */
- public Gas getGas()
- {
- return type;
- }
-
- public GasStack withAmount(int newAmount)
- {
- amount = newAmount;
-
- return this;
- }
-
- /**
- * Writes this GasStack to a defined tag compound.
- * @param nbtTags - tag compound to write to
- * @return tag compound with this GasStack's data
- */
- public NBTTagCompound write(NBTTagCompound nbtTags)
- {
- type.write(nbtTags);
- nbtTags.setInteger("amount", amount);
-
- return nbtTags;
- }
-
- /**
- * Reads this GasStack's data from a defined tag compound.
- * @param nbtTags - tag compound to read from
- */
- public void read(NBTTagCompound nbtTags)
- {
- type = Gas.readFromNBT(nbtTags);
- amount = nbtTags.getInteger("amount");
- }
-
- /**
- * Returns the GasStack stored in the defined tag compound, or null if it doesn't exist.
- * @param nbtTags - tag compound to read from
- * @return GasStack stored in the tag compound
- */
- public static GasStack readFromNBT(NBTTagCompound nbtTags)
- {
- if(nbtTags == null || nbtTags.hasNoTags())
- {
- return null;
- }
-
- final GasStack stack = new GasStack();
- stack.read(nbtTags);
-
- if(stack.getGas() == null || stack.amount <= 0)
- {
- return null;
- }
-
- return stack;
- }
-
- /**
- * Returns a copied form of this GasStack.
- * @return copied GasStack
- */
- public GasStack copy()
- {
- return new GasStack(type, amount);
- }
-
- /**
- * Whether or not this GasStack's gas type is equal to the other defined GasStack.
- * @param stack - GasStack to check
- * @return if the GasStacks contain the same gas type
- */
- public boolean isGasEqual(GasStack stack)
- {
- return stack != null && getGas() == stack.getGas();
- }
-
- @Override
- public String toString()
- {
- return "[" + type + ", " + amount + "]";
- }
-
- @Override
- public int hashCode()
- {
- return type == null ? 0 : type.getID();
- }
-}
diff --git a/src/api/java/mekanism/api/gas/GasTank.java b/src/api/java/mekanism/api/gas/GasTank.java
deleted file mode 100644
index 69b7a3c..0000000
--- a/src/api/java/mekanism/api/gas/GasTank.java
+++ /dev/null
@@ -1,256 +0,0 @@
-package mekanism.api.gas;
-
-import net.minecraft.nbt.NBTTagCompound;
-
-/**
- * An optional way of managing and/or storing gasses. Would be very useful in TileEntity and Entity gas storage.
- * @author aidancbrady
- *
- */
-public class GasTank
-{
- public GasStack stored;
-
- private int maxGas;
-
- private GasTank()
- {
- }
-
- /**
- * Creates a tank with a defined capacity.
- * @param max - the maximum amount of gas this GasTank can hold
- */
- public GasTank(int max)
- {
- maxGas = max;
- }
-
- /**
- * Sets this tank's GasStack value to a new value. Will cap the amount to this GasTank's capacity.
- * @param stack - value to set this tank's GasStack value to
- */
- public void setGas(GasStack stack)
- {
- stored = stack;
-
- if(stored != null)
- {
- stored.amount = Math.min(getMaxGas(), stored.amount);
- }
- }
-
- /**
- * Draws a specified amount of gas out of this tank.
- * @param amount - amount to draw
- * @param doDraw - if the gas should actually be removed from this tank
- * @return gas taken from this GasTank as a GasStack value
- */
- public GasStack draw(int amount, boolean doDraw)
- {
- if(stored == null || amount <= 0)
- {
- return null;
- }
-
- final GasStack ret = new GasStack(getGas().getGas(),
- Math.min(getStored(), amount));
-
- if(ret.amount > 0)
- {
- if(doDraw)
- {
- stored.amount -= ret.amount;
-
- if(stored.amount <= 0)
- {
- stored = null;
- }
- }
-
- return ret;
- }
-
- return null;
- }
-
- /**
- * Adds a specified amount of gas to this tank.
- * @param amount - the GasStack for this tank to receive
- * @param doReceive - if the gas should actually be added to this tank
- * @return the amount of gas accepted by this tank
- */
- public int receive(GasStack amount, boolean doReceive)
- {
- if(amount == null || (stored != null && !(stored.amount != getMaxGas() && stored.isGasEqual(amount))))
- {
- return 0;
- }
-
- final int toFill = Math.min(getMaxGas() - getStored(), amount.amount);
-
- if(doReceive)
- {
- if(stored == null)
- {
- stored = amount.copy().withAmount(getStored() + toFill);
- }
- else
- {
- stored.amount = Math.min(getMaxGas(), getStored() + amount.amount);
- }
- }
-
- return toFill;
- }
-
- /**
- * If this GasTank can receive the specified type of gas. Will return false if this tank does not need anymore gas.
- * @param gas - gas to check
- * @return if this GasTank can accept the defined gas
- */
- public boolean canReceive(Gas gas)
- {
- if(getNeeded() == 0 || stored != null && (gas != null && gas != stored.getGas()))
- {
- return false;
- }
-
- return true;
- }
-
- /**
- * If this GasTank can receive the specified type of gas. Will return TRUE if this tank does not need anymore gas.
- * @param gas - gas to check
- * @return if this GasTank can accept the defined gas
- */
- public boolean canReceiveType(Gas gas)
- {
- if(stored != null && (gas != null && gas != stored.getGas()))
- {
- return false;
- }
-
- return true;
- }
-
- /**
- * If this GasTank can be drawn of the specified type of gas. Will return false if this tank does not contain any gas.
- * @param gas - gas to check
- * @return if this GasTank can be drawn of the defined gas
- */
- public boolean canDraw(Gas gas)
- {
- if(stored == null || (gas != null && gas != stored.getGas()))
- {
- return false;
- }
-
- return true;
- }
-
- /**
- * Gets the amount of gas needed by this GasTank.
- * @return
- */
- public int getNeeded()
- {
- return getMaxGas() - getStored();
- }
-
- /**
- * Gets the maximum amount of gas this tank can hold.
- * @return - max gas
- */
- public int getMaxGas()
- {
- return maxGas;
- }
-
- /**
- * Sets the maximum amount of gas this tank can hold
- */
- public void setMaxGas(int capacity)
- {
- maxGas = capacity;
- }
-
- /**
- * Gets the GasStack held by this GasTank.
- * @return - GasStakc held by this tank
- */
- public GasStack getGas()
- {
- return stored;
- }
-
- /**
- * Gets the type of gas currently stored in this GasTank.
- * @return gas type contained
- */
- public Gas getGasType()
- {
- return stored != null ? stored.getGas() : null;
- }
-
- /**
- * Gets the amount of gas stored by this GasTank.
- * @return amount of gas stored
- */
- public int getStored()
- {
- return stored != null ? stored.amount : 0;
- }
-
- /**
- * Writes this tank to a defined tag compound.
- * @param nbtTags - tag compound to write to
- * @return tag compound with this tank's data
- */
- public NBTTagCompound write(NBTTagCompound nbtTags)
- {
- if(stored != null && stored.getGas() != null)
- {
- nbtTags.setTag("stored", stored.write(new NBTTagCompound()));
- }
-
- nbtTags.setInteger("maxGas", maxGas);
-
- return nbtTags;
- }
-
- /**
- * Reads this tank's data from a defined tag compound.
- * @param nbtTags - tag compound to read from
- */
- public void read(NBTTagCompound nbtTags)
- {
- if(nbtTags.hasKey("stored"))
- {
- stored = GasStack.readFromNBT(nbtTags.getCompoundTag("stored"));
- }
-
- if(nbtTags.hasKey("maxGas") && nbtTags.getInteger("maxGas") != 0)
- {
- maxGas = nbtTags.getInteger("maxGas");
- }
- }
-
- /**
- * Returns the tank stored in the defined tag compound, or null if it doesn't exist.
- * @param nbtTags - tag compound to read from
- * @return tank stored in the tag compound
- */
- public static GasTank readFromNBT(NBTTagCompound nbtTags)
- {
- if(nbtTags == null || nbtTags.hasNoTags())
- {
- return null;
- }
-
- final GasTank tank = new GasTank();
- tank.read(nbtTags);
-
- return tank;
- }
-}
diff --git a/src/api/java/mekanism/api/gas/GasTransmission.java b/src/api/java/mekanism/api/gas/GasTransmission.java
deleted file mode 100644
index a714af0..0000000
--- a/src/api/java/mekanism/api/gas/GasTransmission.java
+++ /dev/null
@@ -1,181 +0,0 @@
-package mekanism.api.gas;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.List;
-
-import mekanism.api.Coord4D;
-import mekanism.api.transmitters.ITransmitterTile;
-import mekanism.api.transmitters.TransmissionType;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * A handy class containing several utilities for efficient gas transfer.
- * @author AidanBrady
- *
- */
-public final class GasTransmission
-{
- /**
- * Gets all the acceptors around a tile entity.
- * @param tileEntity - center tile entity
- * @return array of IGasAcceptors
- */
- public static IGasHandler[] getConnectedAcceptors(TileEntity tileEntity)
- {
- final IGasHandler[] acceptors = new IGasHandler[] {null, null, null, null, null, null};
-
- for(final ForgeDirection orientation : ForgeDirection.VALID_DIRECTIONS)
- {
- final TileEntity acceptor = Coord4D.get(tileEntity).getFromSide(orientation).getTileEntity(tileEntity.getWorldObj());
-
- if(acceptor instanceof IGasHandler)
- {
- acceptors[orientation.ordinal()] = (IGasHandler) acceptor;
- }
- }
-
- return acceptors;
- }
-
- /**
- * Gets all the tube connections around a tile entity.
- * @param tileEntity - center tile entity
- * @return array of ITubeConnections
- */
- public static ITubeConnection[] getConnections(TileEntity tileEntity)
- {
- final ITubeConnection[] connections = new ITubeConnection[] {null, null, null, null, null, null};
-
- for(final ForgeDirection orientation : ForgeDirection.VALID_DIRECTIONS)
- {
- final TileEntity connection = Coord4D.get(tileEntity).getFromSide(orientation).getTileEntity(tileEntity.getWorldObj());
-
- if(canConnect(connection, orientation))
- {
- connections[orientation.ordinal()] = (ITubeConnection) connection;
- }
- }
-
- return connections;
- }
-
- /**
- * Whether or not a TileEntity can connect to a specified tile on a specified side.
- * @param tileEntity - TileEntity to attempt connection to
- * @param side - side to attempt connection on
- * @return if this tile and side are connectable
- */
- public static boolean canConnect(TileEntity tileEntity, ForgeDirection side)
- {
- if(tileEntity instanceof ITubeConnection && (!(tileEntity instanceof ITransmitterTile) || TransmissionType.checkTransmissionType(((ITransmitterTile) tileEntity).getTransmitter(), TransmissionType.GAS)))
- {
- if(((ITubeConnection) tileEntity).canTubeConnect(side.getOpposite()))
- {
- return true;
- }
- }
-
- return false;
- }
-
- /**
- * Removes a specified amount of gas from an IGasItem.
- * @param itemStack - ItemStack of the IGasItem
- * @param type - type of gas to remove from the IGasItem, null if it doesn't matter
- * @param amount - amount of gas to remove from the ItemStack
- * @return the GasStack removed by the IGasItem
- */
- public static GasStack removeGas(ItemStack itemStack, Gas type, int amount)
- {
- if(itemStack != null && itemStack.getItem() instanceof IGasItem)
- {
- final IGasItem item = (IGasItem) itemStack.getItem();
-
- if(type != null && item.getGas(itemStack) != null && item.getGas(itemStack).getGas() != type || !item.canProvideGas(itemStack, type))
- {
- return null;
- }
-
- return item.removeGas(itemStack, amount);
- }
-
- return null;
- }
-
- /**
- * Adds a specified amount of gas to an IGasItem.
- * @param itemStack - ItemStack of the IGasItem
- * @param stack - stack to add to the IGasItem
- * @return amount of gas accepted by the IGasItem
- */
- public static int addGas(ItemStack itemStack, GasStack stack)
- {
- if(itemStack != null && itemStack.getItem() instanceof IGasItem && ((IGasItem) itemStack.getItem()).canReceiveGas(itemStack, stack.getGas()))
- {
- return ((IGasItem) itemStack.getItem()).addGas(itemStack, stack.copy());
- }
-
- return 0;
- }
-
- /**
- * Emits gas from a central block by splitting the received stack among the sides given.
- * @param sides - the list of sides to output from
- * @param stack - the stack to output
- * @param from - the TileEntity to output from
- * @return the amount of gas emitted
- */
- public static int emit(List<ForgeDirection> sides, GasStack stack, TileEntity from)
- {
- if(stack == null)
- {
- return 0;
- }
-
- final List<IGasHandler> availableAcceptors = new ArrayList<IGasHandler>();
- final IGasHandler[] possibleAcceptors = getConnectedAcceptors(from);
-
- for(int i = 0; i < possibleAcceptors.length; i++)
- {
- final IGasHandler handler = possibleAcceptors[i];
-
- if(handler != null && handler.canReceiveGas(ForgeDirection.getOrientation(i).getOpposite(), stack.getGas()))
- {
- availableAcceptors.add(handler);
- }
- }
-
- Collections.shuffle(availableAcceptors);
-
- int toSend = stack.amount;
- final int prevSending = toSend;
-
- if(!availableAcceptors.isEmpty())
- {
- final int divider = availableAcceptors.size();
- int remaining = toSend % divider;
- final int sending = (toSend - remaining) / divider;
-
- for(final IGasHandler acceptor : availableAcceptors)
- {
- int currentSending = sending;
-
- if(remaining > 0)
- {
- currentSending++;
- remaining--;
- }
-
- final ForgeDirection dir = ForgeDirection.getOrientation(Arrays.asList(possibleAcceptors).indexOf(acceptor)).getOpposite();
- toSend -= acceptor.receiveGas(dir, new GasStack(stack.getGas(),
- currentSending), true);
- }
- }
-
- return prevSending - toSend;
- }
-}
diff --git a/src/api/java/mekanism/api/gas/IGasHandler.java b/src/api/java/mekanism/api/gas/IGasHandler.java
deleted file mode 100644
index e069523..0000000
--- a/src/api/java/mekanism/api/gas/IGasHandler.java
+++ /dev/null
@@ -1,47 +0,0 @@
-package mekanism.api.gas;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Implement this if your tile entity accepts gas from an external source.
- * @author AidanBrady
- *
- */
-public interface IGasHandler
-{
- /**
- * Transfer a certain amount of gas to this block.
- * @param stack - gas to add
- * @return gas added
- */
- public int receiveGas(ForgeDirection side, GasStack stack, boolean doTransfer);
-
- @Deprecated
- public int receiveGas(ForgeDirection side, GasStack stack);
-
- /**
- * Draws a certain amount of gas from this block.
- * @param amount - amount to draw
- * @return gas drawn
- */
- public GasStack drawGas(ForgeDirection side, int amount, boolean doTransfer);
-
- @Deprecated
- public GasStack drawGas(ForgeDirection side, int amount);
-
- /**
- * Whether or not this block can accept gas from a certain side.
- * @param side - side to check
- * @param type - type of gas to check
- * @return if block accepts gas
- */
- public boolean canReceiveGas(ForgeDirection side, Gas type);
-
- /**
- * Whether or not this block can be drawn of gas from a certain side.
- * @param side - side to check
- * @param type - type of gas to check
- * @return if block can be drawn of gas
- */
- public boolean canDrawGas(ForgeDirection side, Gas type);
-}
diff --git a/src/api/java/mekanism/api/gas/IGasItem.java b/src/api/java/mekanism/api/gas/IGasItem.java
deleted file mode 100644
index f95baa3..0000000
--- a/src/api/java/mekanism/api/gas/IGasItem.java
+++ /dev/null
@@ -1,81 +0,0 @@
-package mekanism.api.gas;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Implement this in your item class if it can store or transfer certain gasses.
- * @author AidanBrady
- *
- */
-public interface IGasItem
-{
- /**
- * Gets the rate of transfer this item can handle.
- * @return
- */
- public int getRate(ItemStack itemstack);
-
- /**
- * Adds a defined amount of a certain gas to an item.
- * @param itemstack - the itemstack to add gas to
- * @param type - the type of gas to add
- * @param amount - the amount of gas to add
- * @return the gas that was accepted by the item
- */
- public int addGas(ItemStack itemstack, GasStack stack);
-
- /**
- * Removes the defined amount of a certain gas from the item.
- * @param itemstack - the itemstack to remove gas from
- * @param type - the type of gas to remove
- * @param amount - the amount of gas to remove
- * @return the gas that was removed by the item
- */
- public GasStack removeGas(ItemStack itemstack, int amount);
-
- /**
- * Whether or not this storage tank be given a specific gas.
- * @param itemstack - the itemstack to check
- * @param type - the type of gas the tank can possibly receive
- * @return if the item be charged
- */
- public boolean canReceiveGas(ItemStack itemstack, Gas type);
-
- /**
- * Whether or not this item can give a gas receiver a certain type of gas.
- * @param itemstack - the itemstack to check
- * @param type - the type of gas the tank can provide
- * @return if the item can provide gas
- */
- public boolean canProvideGas(ItemStack itemstack, Gas type);
-
- /**
- * Get the gas of a declared type.
- * @param type - type of gas
- * @param data - ItemStack parameter if necessary
- * @return gas stored
- */
- public GasStack getGas(ItemStack itemstack);
-
- /**
- * Set the gas of a declared type to a new amount;
- * @param type - type of gas
- * @param data - ItemStack parameter if necessary
- * @param amount - amount to store
- */
- public void setGas(ItemStack itemstack, GasStack stack);
-
- /**
- * Gets the maximum amount of gas this tile entity can store.
- * @param type - type of gas
- * @param data - ItemStack parameter if necessary
- * @return maximum gas
- */
- public int getMaxGas(ItemStack itemstack);
-
- /**
- * Returns whether or not this item contains metadata-specific subtypes instead of using metadata for damage display.
- * @return if the item contains metadata-specific subtypes
- */
- public boolean isMetadataSpecific(ItemStack itemstack);
-}
diff --git a/src/api/java/mekanism/api/gas/IGasTransmitter.java b/src/api/java/mekanism/api/gas/IGasTransmitter.java
deleted file mode 100644
index 2785ac1..0000000
--- a/src/api/java/mekanism/api/gas/IGasTransmitter.java
+++ /dev/null
@@ -1,9 +0,0 @@
-package mekanism.api.gas;
-
-import mekanism.api.transmitters.IGridTransmitter;
-import net.minecraft.tileentity.TileEntity;
-
-public interface IGasTransmitter extends IGridTransmitter<IGasHandler, GasNetwork>
-{
- public boolean canTransferGasToTube(TileEntity tile);
-}
diff --git a/src/api/java/mekanism/api/gas/ITubeConnection.java b/src/api/java/mekanism/api/gas/ITubeConnection.java
deleted file mode 100644
index b669fed..0000000
--- a/src/api/java/mekanism/api/gas/ITubeConnection.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package mekanism.api.gas;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * Implement this if your block can connect to Pressurized Tubes.
- * @author AidanBrady
- *
- */
-public interface ITubeConnection
-{
- /**
- * Whether or not a tube can connect to a certain orientation.
- * @param side - orientation to check
- * @return if a tube can connect
- */
- public boolean canTubeConnect(ForgeDirection side);
-}
diff --git a/src/api/java/mekanism/api/gas/OreGas.java b/src/api/java/mekanism/api/gas/OreGas.java
deleted file mode 100644
index c9d7ad8..0000000
--- a/src/api/java/mekanism/api/gas/OreGas.java
+++ /dev/null
@@ -1,38 +0,0 @@
-package mekanism.api.gas;
-
-import net.minecraft.util.StatCollector;
-
-public class OreGas extends Gas
-{
- private final String oreName;
- private OreGas cleanGas;
-
- public OreGas(String s, String name)
- {
- super(s);
-
- oreName = name;
- }
-
- public boolean isClean()
- {
- return getCleanGas() == null;
- }
-
- public OreGas getCleanGas()
- {
- return cleanGas;
- }
-
- public OreGas setCleanGas(OreGas gas)
- {
- cleanGas = gas;
-
- return this;
- }
-
- public String getOreName()
- {
- return StatCollector.translateToLocal(oreName);
- }
-}
diff --git a/src/api/java/mekanism/api/gas/package-info.java b/src/api/java/mekanism/api/gas/package-info.java
deleted file mode 100644
index 2a6464c..0000000
--- a/src/api/java/mekanism/api/gas/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|gas")
-package mekanism.api.gas;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/infuse/InfuseObject.java b/src/api/java/mekanism/api/infuse/InfuseObject.java
deleted file mode 100644
index de9005e..0000000
--- a/src/api/java/mekanism/api/infuse/InfuseObject.java
+++ /dev/null
@@ -1,21 +0,0 @@
-package mekanism.api.infuse;
-
-/**
- * InfuseObject - an object associated with an ItemStack that can modify a Metallurgic Infuser's internal infuse.
- * @author AidanBrady
- *
- */
-public class InfuseObject
-{
- /** The type of infuse this item stores */
- public InfuseType type;
-
- /** How much infuse this item stores */
- public int stored;
-
- public InfuseObject(InfuseType infusion, int i)
- {
- type = infusion;
- stored = i;
- }
-}
diff --git a/src/api/java/mekanism/api/infuse/InfuseRegistry.java b/src/api/java/mekanism/api/infuse/InfuseRegistry.java
deleted file mode 100644
index 6916878..0000000
--- a/src/api/java/mekanism/api/infuse/InfuseRegistry.java
+++ /dev/null
@@ -1,113 +0,0 @@
-package mekanism.api.infuse;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * Use this class to add a new object that registers as an infuse object.
- * @author AidanBrady
- *
- */
-public class InfuseRegistry
-{
- /** The (private) map of ItemStacks and their related InfuseObjects. */
- private static Map<ItemStack, InfuseObject> infuseObjects = new HashMap<ItemStack, InfuseObject>();
-
- /** The (private) map of infuse names and their corresponding InfuseTypes. */
- private static Map<String, InfuseType> infuseTypes = new HashMap<String, InfuseType>();
-
- /**
- * Registers an InfuseType into the registry. Call this in PreInit!
- * @param infuse
- */
- public static void registerInfuseType(InfuseType infuse)
- {
- if(infuseTypes.containsKey(infuse.name))
- {
- return;
- }
-
- infuseTypes.put(infuse.name, infuse);
- }
-
- /**
- * Gets an InfuseType from it's name, or null if it doesn't exist.
- * @param name - the name of the InfuseType to get
- * @return the name's corresponding InfuseType
- */
- public static InfuseType get(String name)
- {
- if(name.equals("null"))
- {
- return null;
- }
-
- return infuseTypes.get(name);
- }
-
- /**
- * Whether or not the registry contains a correspondent InfuseType to a name.
- * @param name - the name to check
- * @return if the name has a coorespondent InfuseType
- */
- public static boolean contains(String name)
- {
- return get(name) != null;
- }
-
- /**
- * Registers a block or item that serves as an infuse object. An infuse object will store a certain type and amount of infuse,
- * and will deliver this amount to the Metallurgic Infuser's buffer of infuse. The item's stack size will be decremented when
- * it is placed in the Metallurgic Infuser's infuse slot, and the machine can accept the type and amount of infuse stored in the
- * object.
- * @param itemStack - stack the infuse object is linked to -- stack size is ignored
- * @param infuseObject - the infuse object with the type and amount data
- */
- public static void registerInfuseObject(ItemStack itemStack, InfuseObject infuseObject)
- {
- if(getObject(itemStack) != null)
- {
- return;
- }
-
- infuseObjects.put(itemStack, infuseObject);
- }
-
- /**
- * Gets the InfuseObject data from an ItemStack.
- * @param itemStack - the ItemStack to check
- * @return the ItemStack's InfuseObject
- */
- public static InfuseObject getObject(ItemStack itemStack)
- {
- for(final Map.Entry<ItemStack, InfuseObject> obj : infuseObjects.entrySet())
- {
- if(itemStack.isItemEqual(obj.getKey()))
- {
- return obj.getValue();
- }
- }
-
- return null;
- }
-
- /**
- * Gets the private map for InfuseObjects.
- * @return private InfuseObject map
- */
- public static final Map<ItemStack, InfuseObject> getObjectMap()
- {
- return infuseObjects;
- }
-
- /**
- * Gets the private map for InfuseTypes.
- * @return private InfuseType map
- */
- public static final Map<String, InfuseType> getInfuseMap()
- {
- return infuseTypes;
- }
-}
diff --git a/src/api/java/mekanism/api/infuse/InfuseType.java b/src/api/java/mekanism/api/infuse/InfuseType.java
deleted file mode 100644
index 76820a8..0000000
--- a/src/api/java/mekanism/api/infuse/InfuseType.java
+++ /dev/null
@@ -1,47 +0,0 @@
-package mekanism.api.infuse;
-
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-
-/**
- * The types of infuse currently available in Mekanism.
- * @author AidanBrady
- *
- */
-public final class InfuseType
-{
- /** The name of this infusion */
- public String name;
-
- /** The location of this infuse's GUI texture */
- public ResourceLocation texture;
-
- /** The infuse's GUI texture X offset. */
- public int texX;
-
- /** The infuse's GUI texture Y offset. */
- public int texY;
-
- /** The unlocalized name of this type. */
- public String unlocalizedName;
-
- public InfuseType(String s, ResourceLocation location, int x, int y)
- {
- name = s;
- texture = location;
- texX = x;
- texY = y;
- }
-
- public InfuseType setUnlocalizedName(String name)
- {
- unlocalizedName = name;
-
- return this;
- }
-
- public String getLocalizedName()
- {
- return StatCollector.translateToLocal(unlocalizedName);
- }
-}
diff --git a/src/api/java/mekanism/api/infuse/package-info.java b/src/api/java/mekanism/api/infuse/package-info.java
deleted file mode 100644
index a826ca2..0000000
--- a/src/api/java/mekanism/api/infuse/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|infuse")
-package mekanism.api.infuse;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/lasers/ILaserReceptor.java b/src/api/java/mekanism/api/lasers/ILaserReceptor.java
deleted file mode 100644
index 641f3ca..0000000
--- a/src/api/java/mekanism/api/lasers/ILaserReceptor.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package mekanism.api.lasers;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-public interface ILaserReceptor
-{
- public void receiveLaserEnergy(double energy, ForgeDirection side);
-
- public boolean canLasersDig();
-}
diff --git a/src/api/java/mekanism/api/lasers/package-info.java b/src/api/java/mekanism/api/lasers/package-info.java
deleted file mode 100644
index 957b64f..0000000
--- a/src/api/java/mekanism/api/lasers/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|laser")
-package mekanism.api.lasers;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/package-info.java b/src/api/java/mekanism/api/package-info.java
deleted file mode 100644
index f515694..0000000
--- a/src/api/java/mekanism/api/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|core")
-package mekanism.api;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/reactor/IFusionReactor.java b/src/api/java/mekanism/api/reactor/IFusionReactor.java
deleted file mode 100644
index 33d474c..0000000
--- a/src/api/java/mekanism/api/reactor/IFusionReactor.java
+++ /dev/null
@@ -1,65 +0,0 @@
-package mekanism.api.reactor;
-
-import mekanism.api.IHeatTransfer;
-import mekanism.api.gas.GasTank;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidTank;
-
-public interface IFusionReactor extends IHeatTransfer
-{
- public void addTemperatureFromEnergyInput(double energyAdded);
-
- public void simulate();
-
- public FluidTank getWaterTank();
-
- public FluidTank getSteamTank();
-
- public GasTank getDeuteriumTank();
-
- public GasTank getTritiumTank();
-
- public GasTank getFuelTank();
-
- public double getBufferedEnergy();
-
- public void setBufferedEnergy(double energy);
-
- public double getPlasmaTemp();
-
- public void setPlasmaTemp(double temp);
-
- public double getCaseTemp();
-
- public void setCaseTemp(double temp);
-
- public double getBufferSize();
-
- public void formMultiblock();
-
- public boolean isFormed();
-
- public void setInjectionRate(int rate);
-
- public int getInjectionRate();
-
- public boolean isBurning();
-
- public void setBurning(boolean burn);
-
- public int getMinInjectionRate(boolean active);
-
- public double getMaxPlasmaTemperature(boolean active);
-
- public double getMaxCasingTemperature(boolean active);
-
- public double getIgnitionTemperature(boolean active);
-
- public double getPassiveGeneration(boolean active, boolean current);
-
- public int getSteamPerTick(boolean current);
-
- public void updateTemperatures();
-
- public ItemStack[] getInventory();
-}
diff --git a/src/api/java/mekanism/api/reactor/INeutronCapture.java b/src/api/java/mekanism/api/reactor/INeutronCapture.java
deleted file mode 100644
index 6171a7f..0000000
--- a/src/api/java/mekanism/api/reactor/INeutronCapture.java
+++ /dev/null
@@ -1,6 +0,0 @@
-package mekanism.api.reactor;
-
-public interface INeutronCapture extends IReactorBlock
-{
- public int absorbNeutrons(int neutrons);
-}
diff --git a/src/api/java/mekanism/api/reactor/IReactorBlock.java b/src/api/java/mekanism/api/reactor/IReactorBlock.java
deleted file mode 100644
index 96d161b..0000000
--- a/src/api/java/mekanism/api/reactor/IReactorBlock.java
+++ /dev/null
@@ -1,11 +0,0 @@
-package mekanism.api.reactor;
-
-public interface IReactorBlock
-{
- public boolean isFrame();
-
- public void setReactor(IFusionReactor reactor);
-
- public IFusionReactor getReactor();
-
-}
diff --git a/src/api/java/mekanism/api/reactor/package-info.java b/src/api/java/mekanism/api/reactor/package-info.java
deleted file mode 100644
index 6f11811..0000000
--- a/src/api/java/mekanism/api/reactor/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|reactor")
-package mekanism.api.reactor;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/recipe/RecipeHelper.java b/src/api/java/mekanism/api/recipe/RecipeHelper.java
deleted file mode 100644
index 8884d44..0000000
--- a/src/api/java/mekanism/api/recipe/RecipeHelper.java
+++ /dev/null
@@ -1,372 +0,0 @@
-package mekanism.api.recipe;
-
-import java.lang.reflect.Method;
-
-import mekanism.api.gas.GasStack;
-import mekanism.api.infuse.InfuseType;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidStack;
-
-/**
- * SET TO BE REMOVED NEXT MINOR MEKANISM VERSION, PLEASE USE IMC INSTEAD.
- * Use this handy class to add recipes to Mekanism machinery.
- * @author AidanBrady
- *
- */
-@Deprecated
-public final class RecipeHelper
-{
- /**
- * Add an Enrichment Chamber recipe.
- * @param input - input ItemStack
- * @param output - output ItemStack
- */
- public static void addEnrichmentChamberRecipe(ItemStack input, ItemStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addEnrichmentChamberRecipe", ItemStack.class, ItemStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add an Osmium Compressor recipe.
- * @param input - input ItemStack
- * @param output - output ItemStack
- */
- public static void addOsmiumCompressorRecipe(ItemStack input, ItemStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addOsmiumCompressorRecipe", ItemStack.class, ItemStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Combiner recipe.
- * @param input - input ItemStack
- * @param output - output ItemStack
- */
- public static void addCombinerRecipe(ItemStack input, ItemStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addCombinerRecipe", ItemStack.class, ItemStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Crusher recipe.
- * @param input - input ItemStack
- * @param output - output ItemStack
- */
- public static void addCrusherRecipe(ItemStack input, ItemStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addCrusherRecipe", ItemStack.class, ItemStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Purification Chamber recipe.
- * @param input - input ItemStack
- * @param output - output ItemStack
- */
- public static void addPurificationChamberRecipe(ItemStack input, ItemStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addPurificationChamberRecipe", ItemStack.class, ItemStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Chemical Oxidizer recipe.
- * @param input - input ItemStack
- * @param output - output GasStack
- */
- public static void addChemicalOxidizerRecipe(ItemStack input, GasStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addChemicalOxidizerRecipe", ItemStack.class, GasStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Chemical Infuser recipe.
- * @param leftInput - left input GasStack
- * @param rightInput - right input GasStack
- * @param output - output GasStack
- */
- public static void addChemicalInfuserRecipe(GasStack leftInput, GasStack rightInput, GasStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addChemicalInfuserRecipe", GasStack.class, GasStack.class, GasStack.class);
- m.invoke(null, leftInput, rightInput, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Precision Sawmill recipe.
- * @param input - input ItemStack
- * @param primaryOutput - guaranteed output
- * @param secondaryOutput - possible extra output
- * @param chance - probability of obtaining extra output
- */
- public static void addPrecisionSawmillRecipe(ItemStack input, ItemStack primaryOutput, ItemStack secondaryOutput, double chance)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addPrecisionSawmillRecipe", ItemStack.class, ItemStack.class, ItemStack.class, Double.TYPE);
- m.invoke(null, input, primaryOutput, secondaryOutput, chance);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Precision Sawmill recipe with no chance output
- * @param input - input ItemStack
- * @param primaryOutput - guaranteed output
- */
- public static void addPrecisionSawmillRecipe(ItemStack input, ItemStack primaryOutput)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addPrecisionSawmillRecipe", ItemStack.class, ItemStack.class);
- m.invoke(null, input, primaryOutput);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Chemical Injection Chamber recipe.
- * @param input - input AdvancedInput
- * @param output - output ItemStack
- */
- public static void addChemicalInjectionChamberRecipe(ItemStack input, String gasName, ItemStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addChemicalInjectionChamberRecipe", ItemStack.class, String.class, ItemStack.class);
- m.invoke(null, input, gasName, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add an Electrolytic Separator recipe.
- * @param input - input FluidStack
- * @param energy - required energy
- * @param leftOutput - left output GasStack
- * @param rightOutput - right output GasStack
- */
- public static void addElectrolyticSeparatorRecipe(FluidStack input, double energy, GasStack leftOutput, GasStack rightOutput)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addElectrolyticSeparatorRecipe", FluidStack.class, Double.TYPE, GasStack.class, GasStack.class);
- m.invoke(null, input, energy, leftOutput, rightOutput);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Chemical Dissolution Chamber recipe.
- * @param input - input ItemStack
- * @param output - output GasStack
- */
- public static void addChemicalDissolutionChamberRecipe(ItemStack input, GasStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addChemicalDissolutionChamberRecipe", ItemStack.class, GasStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Chemical Washer recipe.
- * @param input - input GasStack
- * @param output - output GasStack
- */
- public static void addChemicalWasherRecipe(GasStack input, GasStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addChemicalWasherRecipe", GasStack.class, GasStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Chemical Crystallizer recipe.
- * @param input - input GasStack
- * @param output - output ItemStack
- */
- public static void addChemicalCrystallizerRecipe(GasStack input, ItemStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addChemicalCrystallizerRecipe", GasStack.class, ItemStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Metallurgic Infuser recipe.
- * @param infuse - which Infuse to use
- * @param amount - how much Infuse to use
- * @param input - input ItemStack
- * @param output - output ItemStack
- */
- public static void addMetallurgicInfuserRecipe(InfuseType infuse, int amount, ItemStack input, ItemStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addMetallurgicInfuserRecipe", InfuseType.class, Integer.TYPE, ItemStack.class, ItemStack.class);
- m.invoke(null, infuse, amount, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Pressurized Reaction Chamber recipe.
- * @param inputSolid - input ItemStack
- * @param inputFluid - input FluidStack
- * @param inputGas - input GasStack
- * @param outputSolid - output ItemStack
- * @param outputGas - output GasStack
- * @param extraEnergy - extra energy needed by the recipe
- * @param ticks - amount of ticks it takes for this recipe to complete
- */
- public static void addPRCRecipe(ItemStack inputSolid, FluidStack inputFluid, GasStack inputGas, ItemStack outputSolid, GasStack outputGas, double extraEnergy, int ticks)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addPRCRecipe", ItemStack.class, FluidStack.class, GasStack.class, ItemStack.class, GasStack.class, Double.TYPE, Integer.TYPE);
- m.invoke(null, inputSolid, inputFluid, inputGas, outputSolid, outputGas, extraEnergy, ticks);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Solar Evaporation Plant recipe.
- * @param input - input GasStack
- * @param output - output GasStack
- */
- public static void addSolarEvaporationRecipe(FluidStack input, FluidStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addSolarEvaporationRecipe", FluidStack.class, FluidStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-
- /**
- * Add a Solar Neutron Activator recipe.
- * @param input - input GasStack
- * @param output - output GasStack
- */
- public static void addSolarNeutronRecipe(GasStack input, GasStack output)
- {
- try
- {
- final Class recipeClass = Class.forName("mekanism.common.recipe.RecipeHandler");
- final Method m = recipeClass.getMethod("addSolarEvaporationRecipe", GasStack.class, GasStack.class);
- m.invoke(null, input, output);
- }
- catch(final Exception e)
- {
- System.err.println("Error while adding recipe: " + e.getMessage());
- }
- }
-}
diff --git a/src/api/java/mekanism/api/recipe/package-info.java b/src/api/java/mekanism/api/recipe/package-info.java
deleted file mode 100644
index 060e5ab..0000000
--- a/src/api/java/mekanism/api/recipe/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|recipe")
-package mekanism.api.recipe;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/transmitters/DynamicNetwork.java b/src/api/java/mekanism/api/transmitters/DynamicNetwork.java
deleted file mode 100644
index 39932c7..0000000
--- a/src/api/java/mekanism/api/transmitters/DynamicNetwork.java
+++ /dev/null
@@ -1,498 +0,0 @@
-package mekanism.api.transmitters;
-
-import java.util.Collection;
-import java.util.EnumSet;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.LinkedHashSet;
-import java.util.Map.Entry;
-import java.util.Set;
-
-import mekanism.api.Coord4D;
-import mekanism.api.IClientTicker;
-import mekanism.api.Range4D;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.common.util.ForgeDirection;
-
-import com.google.common.collect.Lists;
-import com.google.common.collect.Maps;
-import com.google.common.collect.Sets;
-
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.common.eventhandler.Event;
-
-public abstract class DynamicNetwork<A, N extends DynamicNetwork<A, N>> implements IClientTicker, INetworkDataHandler
-{
- public LinkedHashSet<IGridTransmitter<A, N>> transmitters = Sets.newLinkedHashSet();
- public LinkedHashSet<IGridTransmitter<A, N>> transmittersToAdd = Sets.newLinkedHashSet();
- public LinkedHashSet<IGridTransmitter<A, N>> transmittersAdded = Sets.newLinkedHashSet();
-
- public HashMap<Coord4D, A> possibleAcceptors = new HashMap<Coord4D, A>();
- public HashMap<Coord4D, EnumSet<ForgeDirection>> acceptorDirections = new HashMap<Coord4D, EnumSet<ForgeDirection>>();
- public HashMap<IGridTransmitter<A, N>, EnumSet<ForgeDirection>> changedAcceptors = Maps.newHashMap();
-
- private final Set<DelayQueue> updateQueue = new LinkedHashSet<DelayQueue>();
-
- protected Range4D packetRange = null;
-
- protected int capacity = 0;
- protected double meanCapacity = 0;
-
- protected boolean needsUpdate = false;
- protected int updateDelay = 0;
-
- protected boolean firstUpdate = true;
- protected World worldObj = null;
-
- public void addNewTransmitters(Collection<IGridTransmitter<A, N>> newTransmitters)
- {
- transmittersToAdd.addAll(newTransmitters);
- }
-
- public void commit()
- {
- if(!transmittersToAdd.isEmpty())
- {
- for(final IGridTransmitter<A, N> transmitter : transmittersToAdd)
- {
- if(transmitter.isValid())
- {
- if(worldObj == null)
- {
- worldObj = transmitter.world();
- }
-
- for(final ForgeDirection side : ForgeDirection.VALID_DIRECTIONS)
- {
- updateTransmitterOnSide(transmitter, side);
- }
-
- transmitter.setTransmitterNetwork((N) this);
- absorbBuffer(transmitter);
- transmitters.add(transmitter);
- }
- }
-
- updateCapacity();
- clampBuffer();
- queueClientUpdate(Lists.newArrayList(transmittersToAdd));
- transmittersToAdd.clear();
- }
-
- if(!changedAcceptors.isEmpty())
- {
- for(final Entry<IGridTransmitter<A, N>, EnumSet<ForgeDirection>> entry : changedAcceptors.entrySet())
- {
- final IGridTransmitter<A, N> transmitter = entry.getKey();
-
- if(transmitter.isValid())
- {
- final EnumSet<ForgeDirection> directionsChanged = entry.getValue();
-
- for(final ForgeDirection side : directionsChanged)
- {
- updateTransmitterOnSide(transmitter, side);
- }
- }
- }
-
- changedAcceptors.clear();
- }
- }
-
- public void updateTransmitterOnSide(IGridTransmitter<A, N> transmitter, ForgeDirection side)
- {
- final A acceptor = transmitter.getAcceptor(side);
- final Coord4D acceptorCoord = transmitter.coord().getFromSide(side);
- final EnumSet<ForgeDirection> directions = acceptorDirections.get(acceptorCoord);
-
- if(acceptor != null)
- {
- possibleAcceptors.put(acceptorCoord, acceptor);
-
- if(directions != null)
- {
- directions.add(side.getOpposite());
- }
- else
- {
- acceptorDirections.put(acceptorCoord, EnumSet.of(side.getOpposite()));
- }
- }
- else
- {
- if(directions != null)
- {
- directions.remove(side.getOpposite());
-
- if(directions.isEmpty())
- {
- possibleAcceptors.remove(acceptorCoord);
- acceptorDirections.remove(acceptorCoord);
- }
- }
- else
- {
- possibleAcceptors.remove(acceptorCoord);
- acceptorDirections.remove(acceptorCoord);
- }
- }
-
- }
-
- public abstract void absorbBuffer(IGridTransmitter<A, N> transmitter);
-
- public abstract void clampBuffer();
-
- public void invalidate()
- {
- //Remove invalid transmitters first for share calculations
- for(final Iterator<IGridTransmitter<A, N>> iter = transmitters.iterator(); iter.hasNext();)
- {
- final IGridTransmitter<A, N> transmitter = iter.next();
-
- if(!transmitter.isValid())
- {
- iter.remove();
- continue;
- }
- }
-
- //Clamp the new buffer
- clampBuffer();
-
- //Update all shares
- for(final IGridTransmitter<A, N> transmitter : transmitters)
- {
- transmitter.updateShare();
- }
-
- //Now invalidate the transmitters
- for(final IGridTransmitter<A, N> transmitter : transmitters)
- {
- invalidateTransmitter(transmitter);
- }
-
- transmitters.clear();
- deregister();
- }
-
- public void invalidateTransmitter(IGridTransmitter<A, N> transmitter)
- {
- if(!worldObj.isRemote && transmitter.isValid())
- {
- transmitter.takeShare();
- transmitter.setTransmitterNetwork(null);
- TransmitterNetworkRegistry.registerOrphanTransmitter(transmitter);
- }
- }
-
- public void acceptorChanged(IGridTransmitter<A, N> transmitter, ForgeDirection side)
- {
- final EnumSet<ForgeDirection> directions = changedAcceptors.get(transmitter);
-
- if(directions != null)
- {
- directions.add(side);
- }
- else
- {
- changedAcceptors.put(transmitter, EnumSet.of(side));
- }
-
- TransmitterNetworkRegistry.registerChangedNetwork(this);
- }
-
- public void adoptTransmittersAndAcceptorsFrom(N net)
- {
- for(final IGridTransmitter<A, N> transmitter : net.transmitters)
- {
- transmitter.setTransmitterNetwork((N) this);
- transmitters.add(transmitter);
- transmittersAdded.add(transmitter);
- }
-
- possibleAcceptors.putAll(net.possibleAcceptors);
-
- for(final Entry<Coord4D, EnumSet<ForgeDirection>> entry : net.acceptorDirections.entrySet())
- {
- final Coord4D coord = entry.getKey();
-
- if(acceptorDirections.containsKey(coord))
- {
- acceptorDirections.get(coord).addAll(entry.getValue());
- }
- else
- {
- acceptorDirections.put(coord, entry.getValue());
- }
- }
-
- }
-
- public Range4D getPacketRange()
- {
- if(packetRange == null)
- {
- return genPacketRange();
- }
-
- return packetRange;
- }
-
- protected Range4D genPacketRange()
- {
- if(getSize() == 0)
- {
- deregister();
- return null;
- }
-
- final IGridTransmitter<A, N> initTransmitter = transmitters.iterator().next();
- final Coord4D initCoord = initTransmitter.coord();
-
- int minX = initCoord.xCoord;
- int minY = initCoord.yCoord;
- int minZ = initCoord.zCoord;
- int maxX = initCoord.xCoord;
- int maxY = initCoord.yCoord;
- int maxZ = initCoord.zCoord;
-
- for(final IGridTransmitter transmitter : transmitters)
- {
- final Coord4D coord = transmitter.coord();
-
- if(coord.xCoord < minX)
- {
- minX = coord.xCoord;
- }
- if(coord.yCoord < minY)
- {
- minY = coord.yCoord;
- }
- if(coord.zCoord < minZ)
- {
- minZ = coord.zCoord;
- }
- if(coord.xCoord > maxX)
- {
- maxX = coord.xCoord;
- }
- if(coord.yCoord > maxY)
- {
- maxY = coord.yCoord;
- }
- if(coord.zCoord > maxZ)
- {
- maxZ = coord.zCoord;
- }
- }
-
- return new Range4D(minX, minY, minZ, maxX, maxY, maxZ,
- initTransmitter.world().provider.dimensionId);
- }
-
- public void register()
- {
- if(FMLCommonHandler.instance().getEffectiveSide().isServer())
- {
- TransmitterNetworkRegistry.getInstance().registerNetwork(this);
- }
- else
- {
- MinecraftForge.EVENT_BUS.post(new ClientTickUpdate(this, (byte) 1));
- }
- }
-
- public void deregister()
- {
- transmitters.clear();
-
- if(FMLCommonHandler.instance().getEffectiveSide().isServer())
- {
- TransmitterNetworkRegistry.getInstance().removeNetwork(this);
- }
- else
- {
- MinecraftForge.EVENT_BUS.post(new ClientTickUpdate(this, (byte) 0));
- }
- }
-
- public int getSize()
- {
- return transmitters.size();
- }
-
- public int getAcceptorSize()
- {
- return possibleAcceptors.size();
- }
-
- public synchronized void updateCapacity()
- {
- updateMeanCapacity();
- capacity = (int) meanCapacity * transmitters.size();
- }
-
- /**
- * Override this if things can have variable capacity along the network.
- * @return An 'average' value of capacity. Calculate it how you will.
- */
- protected synchronized void updateMeanCapacity()
- {
- if(transmitters.size() > 0)
- {
- meanCapacity = transmitters.iterator().next().getCapacity();
- }
- else
- {
- meanCapacity = 0;
- }
- }
-
- public int getCapacity()
- {
- return capacity;
- }
-
- public World getWorld()
- {
- return worldObj;
- }
-
- public abstract Set<A> getAcceptors(Object data);
-
- public void tick()
- {
- onUpdate();
- }
-
- public void onUpdate()
- {
- if(FMLCommonHandler.instance().getEffectiveSide().isServer())
- {
- final Iterator<DelayQueue> i = updateQueue.iterator();
-
- try
- {
- while(i.hasNext())
- {
- final DelayQueue q = i.next();
-
- if(q.delay > 0)
- {
- q.delay--;
- }
- else
- {
- transmittersAdded.addAll(transmitters);
- updateDelay = 1;
- i.remove();
- }
- }
- }
- catch(final Exception e)
- {
- }
-
- if(updateDelay > 0)
- {
- updateDelay--;
-
- if(updateDelay == 0)
- {
- MinecraftForge.EVENT_BUS.post(new TransmittersAddedEvent(
- this, firstUpdate, (Collection) transmittersAdded));
- firstUpdate = false;
- transmittersAdded.clear();
- needsUpdate = true;
- }
- }
- }
- }
-
- @Override
- public boolean needsTicks()
- {
- return getSize() > 0;
- }
-
- @Override
- public void clientTick()
- {
- }
-
- public void queueClientUpdate(Collection<IGridTransmitter<A, N>> newTransmitters)
- {
- transmittersAdded.addAll(newTransmitters);
- updateDelay = 3;
- }
-
- public static class TransmittersAddedEvent extends Event
- {
- public DynamicNetwork<?, ?> network;
- public boolean newNetwork;
- public Collection<IGridTransmitter> newTransmitters;
-
- public TransmittersAddedEvent(DynamicNetwork net, boolean newNet, Collection<IGridTransmitter> added)
- {
- network = net;
- newNetwork = newNet;
- newTransmitters = added;
- }
- }
-
- public static class ClientTickUpdate extends Event
- {
- public DynamicNetwork network;
- public byte operation; /*0 remove, 1 add*/
-
- public ClientTickUpdate(DynamicNetwork net, byte b)
- {
- network = net;
- operation = b;
- }
- }
-
- public static class NetworkClientRequest extends Event
- {
- public TileEntity tileEntity;
-
- public NetworkClientRequest(TileEntity tile)
- {
- tileEntity = tile;
- }
- }
-
- public void addUpdate(EntityPlayer player)
- {
- updateQueue.add(new DelayQueue(player));
- }
-
- public static class DelayQueue
- {
- public EntityPlayer player;
- public int delay;
-
- public DelayQueue(EntityPlayer p)
- {
- player = p;
- delay = 5;
- }
-
- @Override
- public int hashCode()
- {
- return player.hashCode();
- }
-
- @Override
- public boolean equals(Object o)
- {
- return o instanceof DelayQueue && ((DelayQueue) o).player.equals(this.player);
- }
- }
-}
diff --git a/src/api/java/mekanism/api/transmitters/IBlockableConnection.java b/src/api/java/mekanism/api/transmitters/IBlockableConnection.java
deleted file mode 100644
index 1183975..0000000
--- a/src/api/java/mekanism/api/transmitters/IBlockableConnection.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package mekanism.api.transmitters;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-public interface IBlockableConnection
-{
- public boolean canConnectMutual(ForgeDirection side);
-
- public boolean canConnect(ForgeDirection side);
-}
diff --git a/src/api/java/mekanism/api/transmitters/IGridTransmitter.java b/src/api/java/mekanism/api/transmitters/IGridTransmitter.java
deleted file mode 100644
index a184377..0000000
--- a/src/api/java/mekanism/api/transmitters/IGridTransmitter.java
+++ /dev/null
@@ -1,64 +0,0 @@
-package mekanism.api.transmitters;
-
-import java.util.Collection;
-
-import mekanism.api.Coord4D;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-
-public interface IGridTransmitter<A, N extends DynamicNetwork<A, N>> extends ITransmitter
-{
- public boolean hasTransmitterNetwork();
-
- /**
- * Gets the network currently in use by this transmitter segment.
- * @return network this transmitter is using
- */
- public N getTransmitterNetwork();
-
- /**
- * Sets this transmitter segment's network to a new value.
- * @param network - network to set to
- */
- public void setTransmitterNetwork(N network);
-
- public int getTransmitterNetworkSize();
-
- public int getTransmitterNetworkAcceptorSize();
-
- public String getTransmitterNetworkNeeded();
-
- public String getTransmitterNetworkFlow();
-
- public String getTransmitterNetworkBuffer();
-
- public double getTransmitterNetworkCapacity();
-
- public int getCapacity();
-
- public World world();
-
- public Coord4D coord();
-
- public Coord4D getAdjacentConnectableTransmitterCoord(ForgeDirection side);
-
- public A getAcceptor(ForgeDirection side);
-
- public boolean isValid();
-
- public boolean isOrphan();
-
- public void setOrphan(boolean orphaned);
-
- public N createEmptyNetwork();
-
- public N mergeNetworks(Collection<N> toMerge);
-
- public N getExternalNetwork(Coord4D from);
-
- public void takeShare();
-
- public void updateShare();
-
- public Object getBuffer();
-}
diff --git a/src/api/java/mekanism/api/transmitters/INetworkDataHandler.java b/src/api/java/mekanism/api/transmitters/INetworkDataHandler.java
deleted file mode 100644
index 38cd637..0000000
--- a/src/api/java/mekanism/api/transmitters/INetworkDataHandler.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package mekanism.api.transmitters;
-
-public interface INetworkDataHandler
-{
- public String getNeededInfo();
-
- public String getStoredInfo();
-
- public String getFlowInfo();
-}
diff --git a/src/api/java/mekanism/api/transmitters/ITransmitter.java b/src/api/java/mekanism/api/transmitters/ITransmitter.java
deleted file mode 100644
index cddc76a..0000000
--- a/src/api/java/mekanism/api/transmitters/ITransmitter.java
+++ /dev/null
@@ -1,11 +0,0 @@
-package mekanism.api.transmitters;
-
-public interface ITransmitter
-{
- /**
- * Get the transmitter's transmission type
- *
- * @return TransmissionType this transmitter uses
- */
- public TransmissionType getTransmissionType();
-}
diff --git a/src/api/java/mekanism/api/transmitters/ITransmitterTile.java b/src/api/java/mekanism/api/transmitters/ITransmitterTile.java
deleted file mode 100644
index 3940b71..0000000
--- a/src/api/java/mekanism/api/transmitters/ITransmitterTile.java
+++ /dev/null
@@ -1,6 +0,0 @@
-package mekanism.api.transmitters;
-
-public interface ITransmitterTile<A, N extends DynamicNetwork<A, N>>
-{
- public IGridTransmitter<A, N> getTransmitter();
-}
diff --git a/src/api/java/mekanism/api/transmitters/TransmissionType.java b/src/api/java/mekanism/api/transmitters/TransmissionType.java
deleted file mode 100644
index 34aed37..0000000
--- a/src/api/java/mekanism/api/transmitters/TransmissionType.java
+++ /dev/null
@@ -1,75 +0,0 @@
-package mekanism.api.transmitters;
-
-import mekanism.api.gas.IGasTransmitter;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.StatCollector;
-
-public enum TransmissionType
-{
- ENERGY("EnergyNetwork", "Energy"), FLUID("FluidNetwork", "Fluids"), GAS("GasNetwork", "Gases"), ITEM("InventoryNetwork", "Items"), HEAT("HeatNetwork", "Heat");
-
- private String name;
- private String transmission;
-
- private TransmissionType(String n, String t)
- {
- name = n;
- transmission = t;
- }
-
- public String getName()
- {
- return name;
- }
-
- public String getTransmission()
- {
- return transmission;
- }
-
- public String localize()
- {
- return StatCollector.translateToLocal("transmission." + getTransmission());
- }
-
- public static boolean checkTransmissionType(ITransmitter sideTile, TransmissionType type)
- {
- return type.checkTransmissionType(sideTile);
- }
-
- public static boolean checkTransmissionType(TileEntity tile1, TransmissionType type)
- {
- return checkTransmissionType(tile1, type, null);
- }
-
- public static boolean checkTransmissionType(TileEntity tile1, TransmissionType type, TileEntity tile2)
- {
- return type.checkTransmissionType(tile1, tile2);
- }
-
- public boolean checkTransmissionType(ITransmitter transmitter)
- {
- return transmitter.getTransmissionType() == this;
- }
-
- public boolean checkTransmissionType(TileEntity sideTile, TileEntity currentTile)
- {
- if(sideTile instanceof ITransmitter)
- {
- if(((ITransmitter) sideTile).getTransmissionType() == this)
- {
- return true;
- }
- }
-
- if(this == GAS && currentTile instanceof IGasTransmitter)
- {
- if(((IGasTransmitter) currentTile).canTransferGasToTube(sideTile))
- {
- return true;
- }
- }
-
- return false;
- }
-}
diff --git a/src/api/java/mekanism/api/transmitters/TransmitterNetworkRegistry.java b/src/api/java/mekanism/api/transmitters/TransmitterNetworkRegistry.java
deleted file mode 100644
index 4bf6a22..0000000
--- a/src/api/java/mekanism/api/transmitters/TransmitterNetworkRegistry.java
+++ /dev/null
@@ -1,294 +0,0 @@
-package mekanism.api.transmitters;
-
-import java.util.HashMap;
-import java.util.HashSet;
-
-import mekanism.api.Coord4D;
-import mekanism.api.MekanismAPI;
-import net.minecraftforge.common.util.ForgeDirection;
-
-import org.apache.logging.log4j.LogManager;
-import org.apache.logging.log4j.Logger;
-
-import com.google.common.collect.Maps;
-import com.google.common.collect.Sets;
-
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.common.gameevent.TickEvent.Phase;
-import cpw.mods.fml.common.gameevent.TickEvent.ServerTickEvent;
-import cpw.mods.fml.relauncher.Side;
-
-public class TransmitterNetworkRegistry
-{
- private static TransmitterNetworkRegistry INSTANCE = new TransmitterNetworkRegistry();
- private static boolean loaderRegistered = false;
-
- private final HashSet<DynamicNetwork> networks = Sets.newHashSet();
- private final HashSet<DynamicNetwork> networksToChange = Sets.newHashSet();
-
- private final HashSet<IGridTransmitter> invalidTransmitters = Sets.newHashSet();
- private final HashMap<Coord4D, IGridTransmitter> orphanTransmitters = Maps.newHashMap();
-
- private final Logger logger = LogManager.getLogger("MekanismTransmitters");
-
- public static void initiate()
- {
- if(!loaderRegistered)
- {
- loaderRegistered = true;
-
- FMLCommonHandler.instance().bus().register(INSTANCE);
- }
- }
-
- public static void reset()
- {
- getInstance().networks.clear();
- getInstance().networksToChange.clear();
- getInstance().invalidTransmitters.clear();
- getInstance().orphanTransmitters.clear();
- }
-
- public static void invalidateTransmitter(IGridTransmitter transmitter)
- {
- getInstance().invalidTransmitters.add(transmitter);
- }
-
- public static void registerOrphanTransmitter(IGridTransmitter transmitter)
- {
- getInstance().orphanTransmitters.put(transmitter.coord(), transmitter);
- }
-
- public static void registerChangedNetwork(DynamicNetwork network)
- {
- getInstance().networksToChange.add(network);
- }
-
- public static TransmitterNetworkRegistry getInstance()
- {
- return INSTANCE;
- }
-
- public void registerNetwork(DynamicNetwork network)
- {
- networks.add(network);
- }
-
- public void removeNetwork(DynamicNetwork network)
- {
- if(networks.contains(network))
- {
- networks.remove(network);
- }
- }
-
- @SubscribeEvent
- public void onTick(ServerTickEvent event)
- {
- if(event.phase == Phase.END && event.side == Side.SERVER)
- {
- tickEnd();
- }
- }
-
- public void tickEnd()
- {
- removeInvalidTransmitters();
-
- assignOrphans();
-
- commitChanges();
-
- for(final DynamicNetwork net : networks)
- {
- net.tick();
- }
- }
-
- public void removeInvalidTransmitters()
- {
- if(MekanismAPI.debug && !invalidTransmitters.isEmpty())
- {
- logger.info("Dealing with " + invalidTransmitters.size() + " invalid Transmitters");
- }
-
- for(final IGridTransmitter invalid : invalidTransmitters)
- {
- if(!(invalid.isOrphan() && invalid.isValid()))
- {
- final DynamicNetwork n = invalid.getTransmitterNetwork();
-
- if(n != null)
- {
- n.invalidate();
- }
- }
- }
-
- invalidTransmitters.clear();
- }
-
- public void assignOrphans()
- {
- if(MekanismAPI.debug && !orphanTransmitters.isEmpty())
- {
- logger.info("Dealing with " + orphanTransmitters.size() + " orphan Transmitters");
- }
-
- for(final IGridTransmitter orphanTransmitter : orphanTransmitters.values())
- {
- final DynamicNetwork network = getNetworkFromOrphan(orphanTransmitter);
-
- if(network != null)
- {
- networksToChange.add(network);
- network.register();
- }
- }
-
- orphanTransmitters.clear();
- }
-
- public <A, N extends DynamicNetwork<A, N>> DynamicNetwork<A, N> getNetworkFromOrphan(IGridTransmitter<A, N> startOrphan)
- {
- if(startOrphan.isValid() && startOrphan.isOrphan())
- {
- final OrphanPathFinder<A, N> finder = new OrphanPathFinder<A, N>(
- startOrphan);
- finder.start();
- N network;
-
- switch(finder.networksFound.size())
- {
- case 0:
- if(MekanismAPI.debug)
- {
- logger.info("No networks found. Creating new network for " + finder.connectedTransmitters.size() + " transmitters");
- }
-
- network = startOrphan.createEmptyNetwork();
-
- break;
- case 1:
- if(MekanismAPI.debug)
- {
- logger.info("Adding " + finder.connectedTransmitters.size() + " transmitters to single found network");
- }
-
- network = finder.networksFound.iterator().next();
-
- break;
- default:
- if(MekanismAPI.debug)
- {
- logger.info("Merging " + finder.networksFound.size() + " networks with " + finder.connectedTransmitters.size() + " new transmitters");
- }
-
- network = startOrphan.mergeNetworks(finder.networksFound);
- }
-
- network.addNewTransmitters(finder.connectedTransmitters);
-
- return network;
- }
-
- return null;
- }
-
- public void commitChanges()
- {
- for(final DynamicNetwork network : networksToChange)
- {
- network.commit();
- }
-
- networksToChange.clear();
- }
-
- @Override
- public String toString()
- {
- return "Network Registry:\n" + networks;
- }
-
- public String[] toStrings()
- {
- final String[] strings = new String[networks.size()];
- int i = 0;
-
- for(final DynamicNetwork network : networks)
- {
- strings[i++] = network.toString();
- }
-
- return strings;
- }
-
- public class OrphanPathFinder<A, N extends DynamicNetwork<A, N>>
- {
- public IGridTransmitter<A, N> startPoint;
-
- public HashSet<Coord4D> iterated = Sets.newHashSet();
-
- public HashSet<IGridTransmitter<A, N>> connectedTransmitters = Sets.newHashSet();
- public HashSet<N> networksFound = Sets.newHashSet();
-
- public OrphanPathFinder(IGridTransmitter<A, N> start)
- {
- startPoint = start;
- }
-
- public void start()
- {
- iterate(startPoint.coord(), ForgeDirection.UNKNOWN);
- }
-
- public void iterate(Coord4D from, ForgeDirection fromDirection)
- {
- if(iterated.contains(from))
- {
- return;
- }
-
- iterated.add(from);
-
- if(orphanTransmitters.containsKey(from))
- {
- final IGridTransmitter<A, N> transmitter = orphanTransmitters.get(from);
-
- if(transmitter.isValid() && transmitter.isOrphan())
- {
- connectedTransmitters.add(transmitter);
- transmitter.setOrphan(false);
-
- for(final ForgeDirection direction : ForgeDirection.VALID_DIRECTIONS)
- {
- if(direction != fromDirection)
- {
- final Coord4D directionCoord = transmitter.getAdjacentConnectableTransmitterCoord(direction);
-
- if(!(directionCoord == null || iterated.contains(directionCoord)))
- {
- iterate(directionCoord, direction.getOpposite());
- }
- }
- }
- }
- }
- else
- {
- addNetworkToIterated(from);
- }
- }
-
- public void addNetworkToIterated(Coord4D from)
- {
- final N net = startPoint.getExternalNetwork(from);
- if(net != null)
- {
- networksFound.add(net);
- }
- }
- }
-}
diff --git a/src/api/java/mekanism/api/transmitters/package-info.java b/src/api/java/mekanism/api/transmitters/package-info.java
deleted file mode 100644
index e959a85..0000000
--- a/src/api/java/mekanism/api/transmitters/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|transmitter")
-package mekanism.api.transmitters;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mekanism/api/util/BlockInfo.java b/src/api/java/mekanism/api/util/BlockInfo.java
deleted file mode 100644
index a0e349d..0000000
--- a/src/api/java/mekanism/api/util/BlockInfo.java
+++ /dev/null
@@ -1,37 +0,0 @@
-package mekanism.api.util;
-
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-
-public class BlockInfo
-{
- public Block block;
- public int meta;
-
- public BlockInfo(Block b, int j)
- {
- block = b;
- meta = j;
- }
-
- public static BlockInfo get(ItemStack stack)
- {
- return new BlockInfo(Block.getBlockFromItem(stack.getItem()),
- stack.getItemDamage());
- }
-
- @Override
- public boolean equals(Object obj)
- {
- return obj instanceof BlockInfo && ((BlockInfo) obj).block == block && ((BlockInfo) obj).meta == meta;
- }
-
- @Override
- public int hashCode()
- {
- int code = 1;
- code = 31 * code + block.getUnlocalizedName().hashCode();
- code = 31 * code + meta;
- return code;
- }
-}
diff --git a/src/api/java/mekanism/api/util/ItemInfo.java b/src/api/java/mekanism/api/util/ItemInfo.java
deleted file mode 100644
index 9a810b7..0000000
--- a/src/api/java/mekanism/api/util/ItemInfo.java
+++ /dev/null
@@ -1,36 +0,0 @@
-package mekanism.api.util;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-
-public class ItemInfo
-{
- public Item item;
- public int meta;
-
- public ItemInfo(Item i, int j)
- {
- item = i;
- meta = j;
- }
-
- public static ItemInfo get(ItemStack stack)
- {
- return new ItemInfo(stack.getItem(), stack.getItemDamage());
- }
-
- @Override
- public boolean equals(Object obj)
- {
- return obj instanceof ItemInfo && ((ItemInfo) obj).item == item && ((ItemInfo) obj).meta == meta;
- }
-
- @Override
- public int hashCode()
- {
- int code = 1;
- code = 31 * code + System.identityHashCode(item);
- code = 7 * code + meta;
- return code;
- }
-}
diff --git a/src/api/java/mekanism/api/util/ListUtils.java b/src/api/java/mekanism/api/util/ListUtils.java
deleted file mode 100644
index 4637ae3..0000000
--- a/src/api/java/mekanism/api/util/ListUtils.java
+++ /dev/null
@@ -1,293 +0,0 @@
-package mekanism.api.util;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-import java.util.Set;
-
-public class ListUtils
-{
- public static <V> List<V> inverse(List<V> list)
- {
- final List<V> toReturn = new ArrayList<V>();
-
- for(int i = list.size() - 1; i >= 0; i--)
- {
- toReturn.add(list.get(i));
- }
-
- return toReturn;
- }
-
- public static <V> List<V> cap(List<V> list, int cap)
- {
- List<V> toReturn = new ArrayList<V>();
-
- if(list.size() <= cap)
- {
- toReturn = copy(list);
- }
- else
- {
- int count = 0;
-
- for(final V obj : list)
- {
- count++;
-
- toReturn.add(obj);
-
- if(count == cap)
- {
- break;
- }
- }
- }
-
- return toReturn;
- }
-
- public static <V> List<V> copy(List<V> list)
- {
- final List<V> toReturn = new ArrayList<V>();
-
- for(final V obj : list)
- {
- toReturn.add(obj);
- }
-
- return toReturn;
- }
-
- public static <V> List<V> merge(List<V> listOne, List<V> listTwo)
- {
- final List<V> newList = new ArrayList<V>();
-
- for(final V obj : listOne)
- {
- newList.add(obj);
- }
-
- for(final V obj : listTwo)
- {
- newList.add(obj);
- }
-
- return newList;
- }
-
- public static <V> List<V> capRemains(List<V> list, int cap)
- {
- final List<V> toReturn = new ArrayList<V>();
-
- if(list.size() <= cap)
- {
- return toReturn;
- }
- else
- {
- inverse(list);
-
- final int iterNeeded = list.size() - cap;
- int count = 0;
-
- for(final V obj : list)
- {
- count++;
-
- toReturn.add(obj);
-
- if(count == iterNeeded)
- {
- break;
- }
- }
-
- return toReturn;
- }
- }
-
- public static <V> ArrayList<List<V>> split(List<V> list, int divide)
- {
- int remain = list.size() % divide;
- final int size = (list.size() - remain) / divide;
-
- final ArrayList<List<V>> toReturn = new ArrayList<List<V>>();
-
- for(int i = 0; i < divide; i++)
- {
- toReturn.add(i, new ArrayList<V>());
- }
-
- for(final List<V> iterSet : toReturn)
- {
- final List<V> removed = new ArrayList<V>();
-
- int toAdd = size;
-
- if(remain > 0)
- {
- remain--;
- toAdd++;
- }
-
- for(final V obj : list)
- {
- if(toAdd == 0)
- {
- break;
- }
-
- iterSet.add(obj);
- removed.add(obj);
- toAdd--;
- }
-
- for(final V obj : removed)
- {
- list.remove(obj);
- }
- }
-
- return toReturn;
- }
-
- public static <V> V getTop(List<V> list)
- {
- for(final V obj : list)
- {
- return obj;
- }
-
- return null;
- }
-
- public static <V> List<V> asList(Set<V> set)
- {
- return (List<V>) Arrays.asList(set.toArray());
- }
-
- public static <V> List<V> asList(V... values)
- {
- return Arrays.asList(values);
- }
-
- public static double[] splitDouble(int size, double num)
- {
- final double[] split = new double[size];
-
- for(int i = 0; i < size; i++)
- {
- final double remain = num % size;
- double ret = (num - remain) / size;
- ret += remain;
-
- split[i] = ret;
- num -= remain;
- }
-
- return split;
- }
-
- public static double[] percent(double[] values)
- {
- final double[] ret = new double[values.length];
- double total = 0;
-
- for(final double d : values)
- {
- total += d;
- }
-
- for(int i = 0; i < values.length; i++)
- {
- ret[i] = values[i] / total;
- }
-
- return ret;
- }
-
- public static int[] calcPercentInt(double[] percent, int val)
- {
- final int[] ret = new int[percent.length];
-
- for(int i = 0; i < percent.length; i++)
- {
- ret[i] = (int) Math.round(val * percent[i]);
- }
-
- int newTotal = 0;
- for(final int i : ret)
- {
- newTotal += i;
- }
-
- int diff = val - newTotal;
-
- if(diff != val)
- {
- for(int i = 0; i < ret.length; i++)
- {
- final int num = ret[i];
-
- if(diff < 0 && num == 0)
- {
- continue;
- }
-
- if(diff > 0)
- {
- ret[i]++;
- diff--;
- }
- else if(diff < 0)
- {
- ret[i]--;
- diff++;
- }
-
- if(diff == 0)
- {
- return ret;
- }
- }
- }
-
- return ret;
- }
-
- public static int[] splitInt(int size, int num)
- {
- final int[] split = new int[size];
-
- for(int i = 0; i < size; i++)
- {
- final int remain = num % size;
- int ret = (num - remain) / size;
- ret += remain;
-
- split[i] = ret;
- num -= remain;
- }
-
- return split;
- }
-
- public static double[] percent(int[] values)
- {
- final double[] ret = new double[values.length];
- double total = 0;
-
- for(final double d : values)
- {
- total += d;
- }
-
- for(int i = 0; i < values.length; i++)
- {
- ret[i] = values[i] / total;
- }
-
- return ret;
- }
-}
diff --git a/src/api/java/mekanism/api/util/StackUtils.java b/src/api/java/mekanism/api/util/StackUtils.java
deleted file mode 100644
index 17cfe3e..0000000
--- a/src/api/java/mekanism/api/util/StackUtils.java
+++ /dev/null
@@ -1,255 +0,0 @@
-package mekanism.api.util;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
-
-public final class StackUtils
-{
- public static List<ItemStack> split(ItemStack stack)
- {
- if(stack == null || stack.stackSize == 0)
- {
- return null;
- }
-
- final List<ItemStack> ret = new ArrayList<ItemStack>();
-
- if(stack.stackSize == 1)
- {
- ret.add(stack);
- return ret;
- }
-
- final int remain = stack.stackSize % 2;
- final int split = (int) ((stack.stackSize) / 2F);
-
- ret.add(size(stack, split + remain));
- ret.add(size(stack, split));
-
- return ret;
- }
-
- public static Item getItem(ItemStack stack)
- {
- if(stack == null)
- {
- return null;
- }
-
- return stack.getItem();
- }
-
- public static boolean diffIgnoreNull(ItemStack stack1, ItemStack stack2)
- {
- if(stack1 == null || stack2 == null)
- {
- return false;
- }
-
- return stack1.getItem() != stack2.getItem() || stack1.getItemDamage() != stack2.getItemDamage();
- }
-
- public static boolean equalsWildcard(ItemStack wild, ItemStack check)
- {
- if(wild == null || check == null)
- {
- return check == wild;
- }
-
- return wild.getItem() == check.getItem() && (wild.getItemDamage() == OreDictionary.WILDCARD_VALUE || wild.getItemDamage() == check.getItemDamage());
- }
-
- public static boolean equalsWildcardWithNBT(ItemStack wild, ItemStack check)
- {
- return equalsWildcard(wild, check) && (wild.stackTagCompound == null ? check.stackTagCompound == null : (wild.stackTagCompound == check.stackTagCompound || wild.stackTagCompound.equals(check.stackTagCompound)));
- }
-
- public static List<ItemStack> even(ItemStack stack1, ItemStack stack2)
- {
- final ArrayList<ItemStack> ret = new ArrayList<ItemStack>();
-
- if(getSize(stack1) == getSize(stack2) || Math.abs(getSize(stack1) - getSize(stack2)) == 1)
- {
- ret.add(stack1);
- ret.add(stack2);
-
- return ret;
- }
-
- if(getSize(stack1) > getSize(stack2))
- {
- final int diff = getSize(stack1) - getSize(stack2);
-
- final List<ItemStack> split = split(size(stack1, diff));
-
- ret.add(subtract(stack1, split.get(0)));
- ret.add(add(stack2, split.get(0)));
- }
- else if(getSize(stack2) > getSize(stack1))
- {
- final int diff = getSize(stack2) - getSize(stack1);
-
- final List<ItemStack> split = split(size(stack2, diff));
-
- ret.add(subtract(stack2, split.get(0)));
- ret.add(add(stack1, split.get(0)));
- }
-
- return ret;
- }
-
- public static ItemStack add(ItemStack stack1, ItemStack stack2)
- {
- if(stack1 == null)
- {
- return stack2;
- }
- else if(stack2 == null)
- {
- return stack1;
- }
-
- return size(stack1, getSize(stack1) + getSize(stack2));
- }
-
- public static ItemStack subtract(ItemStack stack1, ItemStack stack2)
- {
- if(stack1 == null)
- {
- return null;
- }
- else if(stack2 == null)
- {
- return stack1;
- }
-
- return size(stack1, getSize(stack1) - getSize(stack2));
- }
-
- public static ItemStack size(ItemStack stack, int size)
- {
- if(size <= 0 || stack == null)
- {
- return null;
- }
-
- final ItemStack ret = stack.copy();
- ret.stackSize = size;
- return ret;
- }
-
- public static ItemStack copy(ItemStack stack)
- {
- if(stack == null)
- {
- return null;
- }
-
- return stack.copy();
- }
-
- public static int getSize(ItemStack stack)
- {
- return stack != null ? stack.stackSize : 0;
- }
-
- public static List<ItemStack> getMergeRejects(ItemStack[] orig, ItemStack[] toAdd)
- {
- final List<ItemStack> ret = new ArrayList<ItemStack>();
-
- for(int i = 0; i < toAdd.length; i++)
- {
- if(toAdd[i] != null)
- {
- final ItemStack reject = getMergeReject(orig[i], toAdd[i]);
-
- if(reject != null)
- {
- ret.add(reject);
- }
- }
- }
-
- return ret;
- }
-
- public static void merge(ItemStack[] orig, ItemStack[] toAdd)
- {
- for(int i = 0; i < toAdd.length; i++)
- {
- if(toAdd[i] != null)
- {
- orig[i] = merge(orig[i], toAdd[i]);
- }
- }
- }
-
- public static ItemStack merge(ItemStack orig, ItemStack toAdd)
- {
- if(orig == null)
- {
- return toAdd;
- }
-
- if(toAdd == null)
- {
- return orig;
- }
-
- if(!orig.isItemEqual(toAdd) || !ItemStack.areItemStackTagsEqual(orig, toAdd))
- {
- return orig;
- }
-
- return StackUtils.size(orig, Math.min(orig.getMaxStackSize(), orig.stackSize + toAdd.stackSize));
- }
-
- public static ItemStack getMergeReject(ItemStack orig, ItemStack toAdd)
- {
- if(orig == null)
- {
- return null;
- }
-
- if(toAdd == null)
- {
- return orig;
- }
-
- if(!orig.isItemEqual(toAdd) || !ItemStack.areItemStackTagsEqual(orig, toAdd))
- {
- return orig;
- }
-
- final int newSize = orig.stackSize + toAdd.stackSize;
-
- if(newSize > orig.getMaxStackSize())
- {
- return StackUtils.size(orig, newSize - orig.getMaxStackSize());
- }
- else
- {
- return StackUtils.size(orig, newSize);
- }
- }
-
- public static boolean contains(ItemStack container, ItemStack contained)
- {
- return equalsWildcardWithNBT(contained, container) && container.stackSize >= contained.stackSize;
- }
-
- public static int hashItemStack(ItemStack stack)
- {
- if(stack == null || stack.getItem() == null)
- {
- return -1;
- }
-
- final String name = stack.getItemDamage() == OreDictionary.WILDCARD_VALUE ? stack.getItem().getUnlocalizedName() : stack.getItem().getUnlocalizedName(stack);
- return name.hashCode() << 8 | stack.getItemDamage();
- }
-}
diff --git a/src/api/java/mekanism/api/util/UnitDisplayUtils.java b/src/api/java/mekanism/api/util/UnitDisplayUtils.java
deleted file mode 100644
index 30eace1..0000000
--- a/src/api/java/mekanism/api/util/UnitDisplayUtils.java
+++ /dev/null
@@ -1,271 +0,0 @@
-package mekanism.api.util;
-
-/**
- * Code taken from UE and modified to fit Mekanism.
- */
-public class UnitDisplayUtils
-{
- public static enum ElectricUnit
- {
- JOULES("Joule", "J"), REDSTONE_FLUX("Redstone Flux", "RF"), MINECRAFT_JOULES("Minecraft Joule", "MJ"), ELECTRICAL_UNITS("Electrical Unit", "EU");
-
- public String name;
- public String symbol;
-
- private ElectricUnit(String s, String s1)
- {
- name = s;
- symbol = s1;
- }
-
- public String getPlural()
- {
- return this == REDSTONE_FLUX ? name : name + "s";
- }
- }
-
- public static enum TemperatureUnit
- {
- KELVIN("Kelvin", "K", 0, 1), CELSIUS("Celsius", "°C", 273.15, 1), RANKINE("Rankine", "R", 0, 9D / 5D), FAHRENHEIT("Fahrenheit", "°F", 459.67, 9D / 5D), AMBIENT("Ambient", "+STP", 300, 1);
-
- public String name;
- public String symbol;
- double zeroOffset;
- double intervalSize;
-
- private TemperatureUnit(String s, String s1, double offset, double size)
- {
- name = s;
- symbol = s1;
- zeroOffset = offset;
- intervalSize = size;
- }
-
- public double convertFromK(double T)
- {
- return (T * intervalSize) - zeroOffset;
- }
-
- public double convertToK(double T)
- {
- return (T + zeroOffset) / intervalSize;
- }
- }
-
- /** Metric system of measurement. */
- public static enum MeasurementUnit
- {
- FEMTO("Femto", "f", 0.000000000000001D), PICO("Pico", "p", 0.000000000001D), NANO("Nano", "n", 0.000000001D), MICRO("Micro", "u", 0.000001D), MILLI("Milli", "m", 0.001D), BASE("", "", 1), KILO("Kilo", "k", 1000D), MEGA("Mega", "M", 1000000D), GIGA("Giga", "G", 1000000000D), TERA("Tera", "T", 1000000000000D), PETA("Peta", "P", 1000000000000000D), EXA("Exa", "E", 1000000000000000000D), ZETTA("Zetta", "Z", 1000000000000000000000D), YOTTA("Yotta", "Y", 1000000000000000000000000D);
-
- /** long name for the unit */
- public String name;
-
- /** short unit version of the unit */
- public String symbol;
-
- /** Point by which a number is consider to be of this unit */
- public double value;
-
- private MeasurementUnit(String s, String s1, double v)
- {
- name = s;
- symbol = s1;
- value = v;
- }
-
- public String getName(boolean getShort)
- {
- if(getShort)
- {
- return symbol;
- }
- else
- {
- return name;
- }
- }
-
- public double process(double d)
- {
- return d / value;
- }
-
- public boolean above(double d)
- {
- return d > value;
- }
-
- public boolean below(double d)
- {
- return d < value;
- }
- }
-
- /**
- * Displays the unit as text. Does handle negative numbers, and will place a negative sign in
- * front of the output string showing this. Use string.replace to remove the negative sign if
- * unwanted
- */
- public static String getDisplay(double value, ElectricUnit unit, int decimalPlaces, boolean isShort)
- {
- String unitName = unit.name;
- String prefix = "";
-
- if(value < 0)
- {
- value = Math.abs(value);
- prefix = "-";
- }
-
- if(isShort)
- {
- unitName = unit.symbol;
- }
- else if(value > 1)
- {
- unitName = unit.getPlural();
- }
-
- if(value == 0)
- {
- return value + " " + unitName;
- }
- else
- {
- for(int i = 0; i < MeasurementUnit.values().length; i++)
- {
- final MeasurementUnit lowerMeasure = MeasurementUnit.values()[i];
-
- if(lowerMeasure.below(value) && lowerMeasure.ordinal() == 0)
- {
- return prefix + roundDecimals(lowerMeasure.process(value), decimalPlaces) + " " + lowerMeasure.getName(isShort) + unitName;
- }
-
- if(lowerMeasure.ordinal() + 1 >= MeasurementUnit.values().length)
- {
- return prefix + roundDecimals(lowerMeasure.process(value), decimalPlaces) + " " + lowerMeasure.getName(isShort) + unitName;
- }
-
- final MeasurementUnit upperMeasure = MeasurementUnit.values()[i + 1];
-
- if((lowerMeasure.above(value) && upperMeasure.below(value)) || lowerMeasure.value == value)
- {
- return prefix + roundDecimals(lowerMeasure.process(value), decimalPlaces) + " " + lowerMeasure.getName(isShort) + unitName;
- }
- }
- }
-
- return prefix + roundDecimals(value, decimalPlaces) + " " + unitName;
- }
-
- public static String getDisplayShort(double value, ElectricUnit unit)
- {
- return getDisplay(value, unit, 2, true);
- }
-
- public static String getDisplayShort(double value, ElectricUnit unit, int decimalPlaces)
- {
- return getDisplay(value, unit, decimalPlaces, true);
- }
-
- public static String getDisplaySimple(double value, ElectricUnit unit, int decimalPlaces)
- {
- if(value > 1)
- {
- if(decimalPlaces < 1)
- {
- return (int) value + " " + unit.getPlural();
- }
-
- return roundDecimals(value, decimalPlaces) + " " + unit.getPlural();
- }
-
- if(decimalPlaces < 1)
- {
- return (int) value + " " + unit.name;
- }
-
- return roundDecimals(value, decimalPlaces) + " " + unit.name;
- }
-
- public static String getDisplay(double T, TemperatureUnit unit, int decimalPlaces, boolean isShort)
- {
- String unitName = unit.name;
- String prefix = "";
-
- double value = unit.convertFromK(T);
-
- if(value < 0)
- {
- value = Math.abs(value);
- prefix = "-";
- }
-
- if(isShort)
- {
- unitName = unit.symbol;
- }
-
- if(value == 0)
- {
- return value + (isShort ? "" : " ") + unitName;
- }
- else
- {
- for(int i = 0; i < MeasurementUnit.values().length; i++)
- {
- final MeasurementUnit lowerMeasure = MeasurementUnit.values()[i];
-
- if(lowerMeasure.below(value) && lowerMeasure.ordinal() == 0)
- {
- return prefix + roundDecimals(lowerMeasure.process(value), decimalPlaces) + (isShort ? "" : " ") + lowerMeasure.getName(isShort) + unitName;
- }
-
- if(lowerMeasure.ordinal() + 1 >= MeasurementUnit.values().length)
- {
- return prefix + roundDecimals(lowerMeasure.process(value), decimalPlaces) + (isShort ? "" : " ") + lowerMeasure.getName(isShort) + unitName;
- }
-
- final MeasurementUnit upperMeasure = MeasurementUnit.values()[i + 1];
-
- if((lowerMeasure.above(value) && upperMeasure.below(value)) || lowerMeasure.value == value)
- {
- return prefix + roundDecimals(lowerMeasure.process(value), decimalPlaces) + (isShort ? "" : " ") + lowerMeasure.getName(isShort) + unitName;
- }
- }
- }
-
- return prefix + roundDecimals(value, decimalPlaces) + (isShort ? "" : " ") + unitName;
- }
-
- public static String getDisplayShort(double value, TemperatureUnit unit)
- {
- return getDisplay(value, unit, 2, true);
- }
-
- public static String getDisplayShort(double value, TemperatureUnit unit, int decimalPlaces)
- {
- return getDisplay(value, unit, decimalPlaces, true);
- }
-
- public static double roundDecimals(double d, int decimalPlaces)
- {
- final int j = (int) (d * Math.pow(10, decimalPlaces));
- return j / Math.pow(10, decimalPlaces);
- }
-
- public static double roundDecimals(double d)
- {
- return roundDecimals(d, 2);
- }
-
- public static enum EnergyType
- {
- J, RF, EU, MJ
- }
-
- public static enum TempType
- {
- K, C, R, F, STP
- }
-}
diff --git a/src/api/java/mekanism/api/util/package-info.java b/src/api/java/mekanism/api/util/package-info.java
deleted file mode 100644
index 78fd35b..0000000
--- a/src/api/java/mekanism/api/util/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(apiVersion = "8.0.0", owner = "Mekanism", provides = "MekanismAPI|util")
-package mekanism.api.util;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mods/battlegear2/api/IAllowItem.java b/src/api/java/mods/battlegear2/api/IAllowItem.java
deleted file mode 100644
index 2610f74..0000000
--- a/src/api/java/mods/battlegear2/api/IAllowItem.java
+++ /dev/null
@@ -1,12 +0,0 @@
-package mods.battlegear2.api;
-
-import net.minecraft.item.ItemStack;
-
-public interface IAllowItem
-{
-
- /**
- * Returns true if the mainhand {@link ItemStack} allows the offhand {@link ItemStack} to be placed in the partner offhand slot
- */
- public boolean allowOffhand(ItemStack mainhand, ItemStack offhand);
-}
diff --git a/src/api/java/mods/battlegear2/api/IOffhandDual.java b/src/api/java/mods/battlegear2/api/IOffhandDual.java
deleted file mode 100644
index 91f1293..0000000
--- a/src/api/java/mods/battlegear2/api/IOffhandDual.java
+++ /dev/null
@@ -1,63 +0,0 @@
-package mods.battlegear2.api;
-
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.event.entity.player.PlayerInteractEvent;
-import cpw.mods.fml.relauncher.Side;
-
-public interface IOffhandDual
-{
- /**
- * Returns true if this item can be dual wielded in the offhand slot
- * @param off The {@link ItemStack} holding this item
- */
- public boolean isOffhandHandDual(ItemStack off);
-
- /**
- * Perform any function when this item is held in the offhand and the user right clicks an entity.
- * This is generally used to attack an entity with the offhand item.
- * If this is the case the {@link PlayerEventChild.OffhandAttackEvent#parent} field should
- * be canceled (or {@link PlayerEventChild.OffhandAttackEvent#cancelParent} field left at true, to prevent any default right clicking events (Eg Villager Trading)
- *
- * @param event the OffhandAttackEvent that was generated
- * @param mainhandItem the {@link ItemStack} currently being held in the right hand
- * @param offhandItem the {@link ItemStack} currently being held in the left hand, holding this item
- * @return true if the off hand swing animation should be performed
- */
- public boolean offhandAttackEntity(PlayerEventChild.OffhandAttackEvent event, ItemStack mainhandItem, ItemStack offhandItem);
-
- /**
- * Perform any function when this item is held in the offhand and the user right clicks "Air".
- * Note: Called first on client-side, then on server side if {@link PlayerInteractEvent} is not cancelled and mainhandItem is not null,
- * following Forge rules for PlayerInteractEvent with Action==RIGHT_CLICK_AIR
- * Note: PlayerInteractEvent is already cancelled beforehand, and will be cancelled after if this method returns false
- * Note: Above issues will be fixed in next Minecraft versions by replacing first arg with a shallow copy
- * @param event the PlayerInteractEvent that was generated
- * @param mainhandItem the {@link ItemStack} currently being held in the right hand
- * @param offhandItem the {@link ItemStack} currently being held in the left hand, holding this item
- * @return true if the off hand swing animation should be performed
- */
- public boolean offhandClickAir(PlayerInteractEvent event, ItemStack mainhandItem, ItemStack offhandItem);
-
- /**
- * Perform any function when this item is held in the offhand and the user right clicks a block.
- * Note: this will happen prior to the activation of any activation functions of blocks
- * Note: Called first on client-side, then on server side if {@link PlayerInteractEvent} is not cancelled
- * Note: {@link PlayerInteractEvent#useItem} is already set on {@link Event.Result#DENY} before reaching this method, in order to avoid mainhandItem usage
- *
- * @param event the PlayerInteractEvent that was generated
- * @param mainhandItem the {@link ItemStack} currently being held in the right hand
- * @param offhandItem the {@link ItemStack} currently being held in the left hand, holding this item
- * @return true if the off hand swing animation should be performed
- */
- public boolean offhandClickBlock(PlayerInteractEvent event, ItemStack mainhandItem, ItemStack offhandItem);
-
- @SuppressWarnings("unused")
- /**
- * Perform any passive effects on each game tick when this item is held in the offhand
- * @deprecated See {@link Item#onUpdate(ItemStack, World, Entity, int, boolean)}
- * @param effectiveSide the effective side the method was called from
- * @param mainhandItem the {@link ItemStack} currently being held in the right hand
- * @param offhandItem the {@link ItemStack} currently being held in the left hand
- */
- public void performPassiveEffects(Side effectiveSide, ItemStack mainhandItem, ItemStack offhandItem);
-}
diff --git a/src/api/java/mods/battlegear2/api/ISheathed.java b/src/api/java/mods/battlegear2/api/ISheathed.java
deleted file mode 100644
index 5a96625..0000000
--- a/src/api/java/mods/battlegear2/api/ISheathed.java
+++ /dev/null
@@ -1,21 +0,0 @@
-package mods.battlegear2.api;
-
-import net.minecraft.item.ItemStack;
-
-/**
- * When a {@link net.minecraft.entity.player.EntityPlayer} is not in "battlemode", the {@link ItemStack}s stored in Battlegear additional slots
- * and previously selected are displayed, either on the back (slightly moved depending on armor) or on the hip (opposite side to the hand slot it is stored in)
- * Note:Default behavior is dependent on Battlegear configuration
- * This interface can be implemented in a {@link net.minecraft.item.Item} instance to decide where to actually render it
- * See {@link mods.battlegear2.api.RenderPlayerEventChild.PreRenderSheathed} and {@link mods.battlegear2.api.RenderPlayerEventChild.PostRenderSheathed}
- * for more flexibility over the rendering
- */
-public interface ISheathed
-{
-
- /**
- * Returns true if this item should always be sheathed on the back, false if it should be sheathed on the hip
- * @param item the {@link ItemStack} to be sheathed
- */
- public boolean sheatheOnBack(ItemStack item);
-}
diff --git a/src/api/java/mods/battlegear2/api/PlayerEventChild.java b/src/api/java/mods/battlegear2/api/PlayerEventChild.java
deleted file mode 100644
index d6a04f4..0000000
--- a/src/api/java/mods/battlegear2/api/PlayerEventChild.java
+++ /dev/null
@@ -1,306 +0,0 @@
-package mods.battlegear2.api;
-
-import mods.battlegear2.api.quiver.IArrowContainer2;
-import mods.battlegear2.api.shield.IShield;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.InventoryPlayer;
-import net.minecraft.entity.projectile.EntityArrow;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.DamageSource;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.event.entity.living.LivingHurtEvent;
-import net.minecraftforge.event.entity.player.ArrowLooseEvent;
-import net.minecraftforge.event.entity.player.AttackEntityEvent;
-import net.minecraftforge.event.entity.player.EntityInteractEvent;
-import net.minecraftforge.event.entity.player.PlayerEvent;
-import net.minecraftforge.event.entity.player.PlayerInteractEvent;
-import cpw.mods.fml.common.eventhandler.Cancelable;
-
-public abstract class PlayerEventChild extends PlayerEvent
-{
-
- /**
- * The event that this event is a child of
- */
- public final PlayerEvent parent;
-
- public PlayerEventChild(PlayerEvent parent)
- {
- super(parent.entityPlayer);
- this.parent = parent;
- }
-
- public void setCancelParentEvent(boolean cancel)
- {
- parent.setCanceled(cancel);
- }
-
- @Override
- public void setCanceled(boolean cancel)
- {
- super.setCanceled(cancel);
- parent.setCanceled(cancel);
- }
-
- @Override
- public void setResult(Result value)
- {
- super.setResult(value);
- parent.setResult(value);
- }
-
- public EntityPlayer getPlayer()
- {
- return parent.entityPlayer;
- }
-
- /**
- * Event fired when a shield successfully blocks an attack (in {@link LivingHurtEvent})
- */
- public static class ShieldBlockEvent extends PlayerEventChild
- {
- public final ItemStack shield;
- public final DamageSource source;
- public final float ammount; // use same name as other Forge events
- public float ammountRemaining = 0.0F; // damage remaining after shield block event, if any
- /**
- * If the {@link IShield#blockAnimation(EntityPlayer, float)} should be called
- */
- public boolean performAnimation = true;
- /**
- * If the shield should be damaged based on the ammount and the result of {@link IShield#getDamageReduction(ItemStack, DamageSource)}
- */
- public boolean damageShield = true;
-
- public ShieldBlockEvent(PlayerEvent parent, ItemStack shield, DamageSource source, float ammount)
- {
- super(parent);
- this.shield = shield;
- this.source = source;
- this.ammount = ammount;
- }
- }
-
- /**
- * Called when a player right clicks in battlemode
- * The parent event can be either {@link PlayerInteractEvent} or {@link EntityInteractEvent} if the OffhandAttackEvent allowed swinging
- * Both {@link ItemStack} can be null
- * If cancelled, no offhand swinging will be performed
- */
- @Cancelable
- public static class OffhandSwingEvent extends PlayerEventChild
- {
- public final ItemStack mainHand;
- public final ItemStack offHand;
-
- public OffhandSwingEvent(PlayerEvent parent, ItemStack mainHand, ItemStack offHand)
- {
- super(parent);
- this.mainHand = mainHand;
- this.offHand = offHand;
- }
- }
-
- /**
- * Called when a player right clicks an entity in battlemode
- * Both {@link ItemStack} can be null
- * Cancelling will prevent any further processing and prevails over the boolean fields
- */
- @Cancelable
- public static class OffhandAttackEvent extends PlayerEventChild
- {
-
- /**
- * If we should call the OffhandSwingEvent and perform swinging
- */
- public boolean swingOffhand = true;
- /**
- * If we should perform an attack on the entity with the offhand item
- * Note: Will post {@link AttackEntityEvent} and {@link Item#onLeftClickEntity(ItemStack, EntityPlayer, Entity)}
- * with {@link InventoryPlayer#currentItem} offset to the offhand
- */
- public boolean shouldAttack = true;
- /**
- * If we should cancel the base entity interaction event
- */
- public boolean cancelParent = true;
- /**
- * The base entity interaction event
- */
- public final EntityInteractEvent event;
- /**
- * Content of the main hand slot
- */
- public final ItemStack mainHand;
- /**
- * Content of the off hand slot
- */
- public final ItemStack offHand;
-
- public OffhandAttackEvent(EntityInteractEvent parent, ItemStack mainHand, ItemStack offHand)
- {
- super(parent);
- event = parent;
- this.mainHand = mainHand;
- this.offHand = offHand;
- }
-
- public Entity getTarget()
- {
- return ((EntityInteractEvent) parent).target;
- }
- }
-
- /**
- * This event replicates the event usage of {@link PlayerInteractEvent} for the item in left hand on right click,
- * allowing support for other mods that use such event to customize item usage
- * {@link Item#onItemUseFirst}, {@link Item#onItemRightClick} and {@link Item#onItemUse} will then get called the same way as with the item in the player right hand for PlayerInteractEvent
- */
- @Cancelable
- public static class UseOffhandItemEvent extends PlayerEventChild
- {
- /**
- * The {@link ItemStack} held in left hand
- */
- public final ItemStack offhand;
- /**
- * The equivalent {@link PlayerInteractEvent} that would have been triggered if the offhand item was held in right hand and right click was pressed
- */
- public final PlayerInteractEvent event;
-
- public UseOffhandItemEvent(PlayerInteractEvent event, ItemStack offhand)
- {
- super(event);
- this.event = event;
- this.offhand = offhand;
- }
- }
-
- public static class QuiverArrowEvent extends PlayerEventChild
- {
- /**
- * The event from which this occurred
- */
- protected final ArrowLooseEvent event;
-
- public QuiverArrowEvent(ArrowLooseEvent event)
- {
- super(event);
- this.event = event;
- }
-
- /**
- * @return the player using the bow
- */
- public EntityPlayer getArcher()
- {
- return getPlayer();
- }
-
- /**
- * @return the bow trying to fire
- */
- public ItemStack getBow()
- {
- return event.bow;
- }
-
- /**
- * @return the amount of charge in the bow
- */
- public float getCharge()
- {
- return event.charge;
- }
-
- /**
- * Event fired after an arrow has been selected and taken from a {@link IArrowContainer2}, before it is actually spawned
- */
- @Cancelable
- public static class Firing extends QuiverArrowEvent
- {
- /**
- * Damage done to the bow after arrow is fired
- */
- public int bowDamage = 1;
- /**
- * The volume of the sound emitted from the bow after arrow is fired
- */
- public float bowSoundVolume = 1.0F;
- /**
- * Decides if standard enchantments can be added to the arrow
- */
- public boolean addEnchantments = true;
- /**
- * Decides if critical state should be forced into the arrow
- */
- public boolean isCritical = false;
- /**
- * The quiver from which the arrow was pulled from
- */
- public final ItemStack quiver;
- /**
- * The arrow to be fired, can't be null
- */
- public final EntityArrow arrow;
-
- public Firing(ArrowLooseEvent parent, ItemStack quiver, EntityArrow arrow)
- {
- super(parent);
- this.quiver = quiver;
- this.arrow = arrow;
- }
-
- }
-
- /**
- * The DEFAULT result for this event is the vanilla charge calculated value
- * Use setNewCharge to override the value with the one provided
- * Change the event result to DENY to prevent further processing
- */
- @HasResult
- public static class ChargeCalculations extends QuiverArrowEvent
- {
- /**
- * Returned value if the result is set to allow
- */
- protected float charge;
-
- public ChargeCalculations(ArrowLooseEvent event)
- {
- super(event);
- }
-
- @Override
- public float getCharge()
- {
- MinecraftForge.EVENT_BUS.post(this);
- switch(getResult())
- {
- case ALLOW:
- return charge;
- case DENY:
- return 0;
- }
- float f = super.getCharge() / 20.0F;
- f = (f * f + f * 2.0F) / 3.0F;
- if(f < 0.1D)
- {
- return 0;
- }
- if(f > 1.0F)
- {
- f = 1.0F;
- }
- return f;
- }
-
- public void setNewCharge(float charge)
- {
- setResult(Result.ALLOW);
- this.charge = charge;
- }
- }
- }
-}
diff --git a/src/api/java/mods/battlegear2/api/package-info.java b/src/api/java/mods/battlegear2/api/package-info.java
deleted file mode 100644
index 81dbfe8..0000000
--- a/src/api/java/mods/battlegear2/api/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(owner = "battlegear2", provides = "DualWield", apiVersion = "0.1")
-package mods.battlegear2.api;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/mods/battlegear2/api/weapons/IBattlegearWeapon.java b/src/api/java/mods/battlegear2/api/weapons/IBattlegearWeapon.java
deleted file mode 100644
index 61ca8cc..0000000
--- a/src/api/java/mods/battlegear2/api/weapons/IBattlegearWeapon.java
+++ /dev/null
@@ -1,14 +0,0 @@
-package mods.battlegear2.api.weapons;
-
-import mods.battlegear2.api.IAllowItem;
-import mods.battlegear2.api.IOffhandDual;
-import mods.battlegear2.api.ISheathed;
-
-/**
- * A generic flag for weapon
- * <strong>Not</strong> necessary for an item to be wielded in battlegear slots
- */
-public interface IBattlegearWeapon extends ISheathed, IOffhandDual, IAllowItem
-{
-
-}
diff --git a/src/api/java/mods/battlegear2/api/weapons/package-info.java b/src/api/java/mods/battlegear2/api/weapons/package-info.java
deleted file mode 100644
index 152cc47..0000000
--- a/src/api/java/mods/battlegear2/api/weapons/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(owner = "battlegear2", provides = "Weapons", apiVersion = "0.1")
-package mods.battlegear2.api.weapons;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/modwarriors/notenoughkeys/api/Api.java b/src/api/java/modwarriors/notenoughkeys/api/Api.java
deleted file mode 100644
index 5da1ae8..0000000
--- a/src/api/java/modwarriors/notenoughkeys/api/Api.java
+++ /dev/null
@@ -1,44 +0,0 @@
-package modwarriors.notenoughkeys.api;
-
-import cpw.mods.fml.common.Loader;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-/**
- * Center of the API. Main api methods can be found in this class.
- *
- * @author TheTemportalist
- */
-@SideOnly(Side.CLIENT)
-public class Api
-{
-
- /**
- * Checks if NotEnoughKeys is loaded in the current environment
- *
- * @return 'true' if loaded
- */
- public static boolean isLoaded()
- {
- return Loader.isModLoaded("notenoughkeys");
- }
-
- /**
- * Registers a mod's keys with NEK
- *
- * @param modname The NAME of the mod registering the key
- * @param keyDecriptions A String[] (Array[String]) of the key descriptions. i.e. new String[]{"key.hotbar1"}
- */
- public static void registerMod(String modname, String[] keyDecriptions)
- {
- try
- {
- Class.forName("modwarriors.notenoughkeys.keys.KeyHelper").getMethod("registerMod", String.class, String[].class).invoke(null, modname, keyDecriptions);
- }
- catch(final Exception e)
- {
- e.printStackTrace();
- }
- }
-
-}
diff --git a/src/api/java/modwarriors/notenoughkeys/api/KeyBindingPressedEvent.java b/src/api/java/modwarriors/notenoughkeys/api/KeyBindingPressedEvent.java
deleted file mode 100644
index 850ec6a..0000000
--- a/src/api/java/modwarriors/notenoughkeys/api/KeyBindingPressedEvent.java
+++ /dev/null
@@ -1,46 +0,0 @@
-package modwarriors.notenoughkeys.api;
-
-import net.minecraft.client.settings.KeyBinding;
-import cpw.mods.fml.common.eventhandler.Cancelable;
-import cpw.mods.fml.common.eventhandler.Event;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-/**
- * Called when a keybinding is triggered with the passed with valid modifiers
- *
- * @author TheTemportalist
- */
-@SideOnly(Side.CLIENT)
-@Cancelable
-public class KeyBindingPressedEvent extends Event
-{
-
- /**
- * The KeyBinding being triggered
- */
- public KeyBinding keyBinding = null;
- /**
- * Tells whether a modifier was required AND was down when triggered
- */
- public boolean shiftRequired = false, ctrlRequired = false,
- altRequired = false;
-
- /**
- * Called with the passed keyBinding and modifiers.
- * Subscribe to this event so activate a keybinding when triggered.
- *
- * @param keyBinding The KeyBinding being triggered. Stores the key's description and keycode
- * @param modifiers The modifiers (SHIFT, CTRL, ALT) that determine when a compatible key is pressed
- */
- public KeyBindingPressedEvent(KeyBinding keyBinding, boolean[] modifiers)
- {
- super();
- this.keyBinding = keyBinding;
- shiftRequired = modifiers[0];
- ctrlRequired = modifiers[1];
- altRequired = modifiers[2];
-
- }
-
-}
diff --git a/src/api/java/modwarriors/notenoughkeys/api/package-info.java b/src/api/java/modwarriors/notenoughkeys/api/package-info.java
deleted file mode 100644
index 913ae44..0000000
--- a/src/api/java/modwarriors/notenoughkeys/api/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(owner = "Not Enough Keys", provides = "API_NEK", apiVersion = "1.0.0")
-package modwarriors.notenoughkeys.api;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/morph/api/Ability.java b/src/api/java/morph/api/Ability.java
deleted file mode 100644
index 266855b..0000000
--- a/src/api/java/morph/api/Ability.java
+++ /dev/null
@@ -1,227 +0,0 @@
-package morph.api;
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.ResourceLocation;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-/**
- *
- * Abstract ability class.
- * Think of it like the Entity class, extend it to make your own types.
- * Some abilities may seem more like traits, but let's just call it an ability for simplicity's sake.
- * Please take note that entities inherit their superclass' abilities.
- * @author iChun
- *
- */
-public abstract class Ability
-{
- /**
- * Ability parent field. Will be null for instances used in registration. Ability is then cloned and parent assigned later on.
- */
- private EntityLivingBase parent;
-
- /**
- * Flag for Ability activity. If true, tick/postRender/kill will notbe called.
- */
- public boolean inactive;
-
- /**
- * Basic constructor (but you didn't really need me to tell you that ;D )
- */
- public Ability()
- {
- parent = null;
- }
-
- /**
- * Function for mod mob support, with args.
- */
- public Ability parse(String[] args)
- {
- return this;
- }
-
- /**
- * Since parent is private it needs a setter.
- * @param newParent
- */
- public void setParent(EntityLivingBase ent)
- {
- parent = ent;
- }
-
- /**
- * Get's the parent entity for this ability
- * @return Entity the ability takes effect on
- */
- public EntityLivingBase getParent()
- {
- return parent;
- }
-
- /**
- * Each ability has to return a String type.
- * This is used for comparison, saving, as well as construction/loading of Ability.
- * Think of it like the way Minecraft registers entities.
- * @return Ability type
- */
- public abstract String getType();
-
- /**
- * Ticks every world tick, basically an ability onUpdate, similar to Entity's onUpdate.
- * Will only tick if getParent() is not null.
- * Please remember that getParent is not necessarily a player.
- */
- public abstract void tick();
-
- /**
- * Called when the ability is finally removed when the parent demorphs or morphs into a state that does not have this ability type.
- * This will NOT be called if the parent morphs into another morph that has this type of ability.
- */
- public abstract void kill();
-
- /**
- * Creates a copy of this ability for use with parents.
- * As previously stated before the ability instance used during registration is a base so it needs to be cloned for use with parents.
- */
- @Override
- public abstract Ability clone();
-
- /**
- * Return true for this if you need an inactive copy of this morph in-between morph states (abilities of the next morph are only swapped over when morph is complete)
- * Currently used for AbilitySwim to adjust the fog render.
- * @return requiresInactiveClone
- */
- public boolean requiresInactiveClone()
- {
- return false;
- }
-
- /**
- * Saving of ability to NBTTagCompound.
- * Mainly used for synching Abilities between the client-server for mod mobs which do not use the API to add abilities.
- * The ability type (getType()) is appended to nbt before function is called.
- * Not actually used.
- * @param NBTTagCompound saveData
- */
- public abstract void save(NBTTagCompound tag);
-
- /**
- * Loading of ability from NBTTagCompound.
- * Mainly used to load custom fields from NBT.
- * Not actually used.
- * @param NBTTagCompound saveData
- */
- public abstract void load(NBTTagCompound tag);
-
- /**
- * Rendering to be done post-render.
- * EG: Used by AbilitySwim to render air bubbles whilst on land.
- */
- @SideOnly(Side.CLIENT)
- public abstract void postRender();
-
- /**
- * Icon location for ability. Can be null.
- * Mod's default icons are 32x32. Can be any resolution though.
- * @return resourcelocation for icon
- */
- @SideOnly(Side.CLIENT)
- public abstract ResourceLocation getIcon();
-
- @SideOnly(Side.CLIENT)
- public boolean entityHasAbility(EntityLivingBase living)
- {
- return true;
- }
-
- /**
- * Registers the ability so the mod can look up the class when attempting to load Ability save data.
- * Call this no later than PostInit.
- * @param ability type
- * @param AbilityClass
- */
- public static void registerAbility(String name, Class<? extends Ability> clz)
- {
- try
- {
- Class.forName("morph.common.ability.AbilityHandler").getDeclaredMethod("registerAbility", String.class, Class.class).invoke(null, name, clz);
- }
- catch(final Exception e)
- {
- }
- }
-
- /**
- * Maps abilities to an Entity.
- * Adds on to the previous ability list, so this allows you to add abilities to Entity classes which already have abilities mapped.
- * However, only one ability of the same type is allowed for each entity. This method will overwrite abilities of the same type that were already mapped.
- * This will also register new abilities which were not registered before (just in case).
- * Call this no later than PostInit.
- * @param entClass
- * @param abilities
- */
- public static void mapAbilities(Class<? extends EntityLivingBase> entClass, Ability... abilities)
- {
- try
- {
- Class.forName("morph.common.ability.AbilityHandler").getDeclaredMethod("mapAbilities", Class.class, Ability[].class).invoke(null, entClass, abilities);
- }
- catch(final Exception e)
- {
- }
- }
-
- /**
- * Superman's kryptonite.
- * @param Entity class to remove ability from
- * @param Ability type
- */
- public static void removeAbility(Class<? extends EntityLivingBase> entClass, String type)
- {
- try
- {
- Class.forName("morph.common.ability.AbilityHandler").getDeclaredMethod("removeAbility", Class.class, String.class).invoke(null, entClass, type);
- }
- catch(final Exception e)
- {
- }
- }
-
- /**
- * Checks to see if the entity class has a mapped ability type.
- * @param entClass
- * @param Ability type
- * @return Entity class has ability type
- */
- public static boolean hasAbility(Class<? extends EntityLivingBase> entClass, String type)
- {
- try
- {
- return (Boolean) Class.forName("morph.common.ability.AbilityHandler").getDeclaredMethod("hasAbility", Class.class, String.class).invoke(null, entClass, type);
- }
- catch(final Exception e)
- {
- return false;
- }
- }
-
- /**
- * Creates an ability by type.
- * Check out AbilityHandler to see each Ability type and the parse function in their respective classes for the arguments.
- * @return
- */
- public static Ability createNewAbilityByType(String type, String[] arguments)
- {
- try
- {
- return (Ability) Class.forName("morph.common.ability.AbilityHandler").getDeclaredMethod("createNewAbilityByType", String.class, String[].class).invoke(null, type, arguments);
- }
- catch(final Exception e)
- {
- return null;
- }
- }
-}
diff --git a/src/api/java/morph/api/Api.java b/src/api/java/morph/api/Api.java
deleted file mode 100644
index a02c62f..0000000
--- a/src/api/java/morph/api/Api.java
+++ /dev/null
@@ -1,203 +0,0 @@
-package morph.api;
-
-import net.minecraft.client.entity.AbstractClientPlayer;
-import net.minecraft.client.model.ModelBase;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.util.ResourceLocation;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public final class Api
-{
- /**
- * Returns if a player is has a morph. If morph progress < 1.0F, player is mid-morphing.
- * Players demorphing are considered as a player with a morph until the demorph is complete.
- * @param Player Username
- * @param Clientside (false for Serverside)
- */
- public static boolean hasMorph(String playerName, boolean isClient)
- {
- try
- {
- return (Boolean) Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("hasMorph", String.class, boolean.class).invoke(null, playerName, isClient);
- }
- catch(final Exception e)
- {
- return false;
- }
- }
-
- /**
- * Returns morph progression of a player. Time per morph is 80 ticks.
- * If player does not have a morph, 1.0F will be returned.
- * @param Player Username
- * @param Clientside (false for Serverside)
- */
- public static float morphProgress(String playerName, boolean isClient)
- {
- try
- {
- return (Float) Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("morphProgress", String.class, boolean.class).invoke(null, playerName, isClient);
- }
- catch(final Exception e)
- {
- return 1.0F;
- }
- }
-
- /**
- * Returns previous entity instance used to render the morph.
- * If player does not have a previous morph state, null will be returned.
- * @param Player Username
- * @param Clientside (false for Serverside)
- */
- public static EntityLivingBase getPrevMorphEntity(String playerName, boolean isClient)
- {
- try
- {
- return (EntityLivingBase) Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("getPrevMorphEntity", String.class, boolean.class).invoke(null, playerName, isClient);
- }
- catch(final Exception e)
- {
- return null;
- }
- }
-
- /**
- * Returns entity instance used to render the morph.
- * If player does not have a morph, null will be returned.
- * @param Player Username
- * @param Clientside (false for Serverside)
- */
- public static EntityLivingBase getMorphEntity(String playerName, boolean isClient)
- {
- try
- {
- return (EntityLivingBase) Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("getMorphEntity", String.class, boolean.class).invoke(null, playerName, isClient);
- }
- catch(final Exception e)
- {
- return null;
- }
- }
-
- /**
- * Blacklists an entity from being morphed into.
- * Previously saved morphs of the classtype will not be removed.
- * @param Class (extends EntityLivingBase)
- */
- public static void blacklistEntity(Class<? extends EntityLivingBase> clz)
- {
- try
- {
- Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("blacklistEntity", Class.class).invoke(null, clz);
- }
- catch(final Exception e)
- {
- }
- }
-
- /**
- * Forces a player to morph into an EntityLivingBase, also adds said entity to the morph list.
- * Called Serverside only.
- * @param player
- * @param living
- * @return morphSuccessful
- */
- public static boolean forceMorph(EntityPlayerMP player, EntityLivingBase living)
- {
- try
- {
- return (Boolean) Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("forceMorph", EntityPlayerMP.class, EntityLivingBase.class).invoke(null, player, living);
- }
- catch(final Exception e)
- {
- return false;
- }
- }
-
- /**
- * Forces a player to demorph.
- * Called Serverside only.
- * @param player
- */
- public static void forceDemorph(EntityPlayerMP player)
- {
- try
- {
- Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("forceDemorph", EntityPlayerMP.class).invoke(null, player);
- }
- catch(final Exception e)
- {
- }
- }
-
- /**
- * Checks if the entity passed on is a Morph.
- * If it is, the player name will be passed, else null.
- * @param EntityLivingBase instance
- * @param Clientside (false for Serverside)
- */
- public static String isEntityAMorph(EntityLivingBase living, boolean isClient)
- {
- try
- {
- return (String) Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("isEntityAMorph", EntityLivingBase.class, boolean.class).invoke(null, living, isClient);
- }
- catch(final Exception e)
- {
- return null;
- }
- }
-
- /**
- * Allows the rendering of the next player rendered.
- * Prevents Morph from cancelling the player render event to render the morphed entity.
- */
- public static void allowNextPlayerRender()
- {
- try
- {
- Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("allowNextPlayerRender").invoke(null);
- }
- catch(final Exception e)
- {
- }
- }
-
- /**
- * Returns the black grainy morph skin that overlays the player when the player is morphing
- * @return Morph Skin Resource Location
- */
- @SideOnly(Side.CLIENT)
- public static ResourceLocation getMorphSkinTexture()
- {
- try
- {
- return (ResourceLocation) Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("getMorphSkinTexture").invoke(null);
- }
- catch(final Exception e)
- {
- return AbstractClientPlayer.locationStevePng;
- }
- }
-
- /**
- * Assign a specific arm to a model for rendering in First Person.
- * @param model Model which arm you are registering for
- * @param arm The arm in a ModelRenderer form.
- */
- @SideOnly(Side.CLIENT)
- public static void registerArmForModel(ModelBase model, ModelRenderer arm)
- {
- try
- {
- Class.forName("morph.common.core.ApiHandler").getDeclaredMethod("registerArmForModel", ModelBase.class, ModelRenderer.class).invoke(null, model, arm);
- }
- catch(final Exception e)
- {
- }
- }
-}
diff --git a/src/api/java/powercrystals/minefactoryreloaded/api/FactoryRegistry.java b/src/api/java/powercrystals/minefactoryreloaded/api/FactoryRegistry.java
deleted file mode 100644
index d83db32..0000000
--- a/src/api/java/powercrystals/minefactoryreloaded/api/FactoryRegistry.java
+++ /dev/null
@@ -1,114 +0,0 @@
-package powercrystals.minefactoryreloaded.api;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.Method;
-
-import cpw.mods.fml.common.Loader;
-import cpw.mods.fml.common.event.FMLInterModComms;
-import cpw.mods.fml.common.event.FMLInterModComms.IMCMessage;
-
-/**
- * @author PowerCrystals
- *
- * Class used to register plants and other farming-related things with MFR. Will do nothing if MFR does not exist.
- *
- */
-public class FactoryRegistry
-{
- /*
- * This may be called at any time during pre-init, init or post-init, assuming all blocks and items
- * that are being accessed from the registry have been appropriately registered.
- * Possible messages:
- *
- * // Registration:
- * addLaserPreferredOre | NBTTag with an ItemStack saved on it, with the color on the "value" attribute,
- * | A ValuedItem with item and value set.
- * registerAutoSpawnerBlacklist | The String identifier of an entity,
- * | A subclass of EntityLivingBase.
- * registerFertilizable | An instance of IFactoryFertilizable.
- * registerFertilizer | An instance of IFactoryFertilizer.
- * registerFruitLog | The String identifier of a block.
- * registerGrindable | An instance of IFactoryGrindable.
- * registerGrinderBlacklist | A subclass of EntityLivingBase.
- * registerHarvestable | An instance of IFactoryHarvestable.
- * registerLaserOre | NBTTag with an ItemStack saved on it, with the weight on the "value" attribute,
- * | A ValuedItem with item and value set.
- * registerLiquidDrinkHandler | A ValuedItem with key and object set; ILiquidDrinkHandler expected.
- * registerMobEggHandler | An instance of IMobEggHandler.
- * registerPickableFruit | An instance of IFactoryFruit.
- * registerPlantable | An instance of IFactoryPlantable.
- * registerRanchable | An instance of IFactoryRanchable.
- * registerRedNetLogicCircuit | An instance of IRedNetLogicCircuit.
- * registerRubberTreeBiome | The biomeName field of a biome to white list for rubber trees to spawn in.
- * registerSafariNetBlacklist | A subclass of EntityLivingBase.
- * registerSafariNetHandler | An instance of ISafariNetHandler.
- * registerSludgeDrop | NBTTag with an ItemStack saved on it, with the weight on the "value" attribute,
- * | A ValuedItem with item and value set.
- * registerSpawnHandler | An instance of IMobSpawnHandler.
- * registerVillagerTradeMob | An instance of IRandomMobProvider.
- *
- * // Simple implementations:
- * { Harvestables
- * registerHarvestable_Standard | The String identifier of a block.
- * registerHarvestable_Log | The String identifier of a block.
- * registerHarvestable_Leaves | The String identifier of a block.
- * registerHarvestable_Vine | The String identifier of a block.
- * registerHarvestable_Shrub | The String identifier of a block.
- * registerHarvestable_Mushroom | The String identifier of a block.
- * registerHarvestable_Crop | An ItemStack of a block, with a damage value indicating the meta value to harvest at.
- * | A ValuedItem with value and object set; Block expected.
- * registerHarvestable_Gourd | An NBTTag with the stem and fruit attributes, both String identifiers of blocks.
- * }
- * { Plantables
- * registerPlantable_Standard | An NBTTag with the seed (Item, String identifier), and
- * crop (Block, String identifier) attributes set, optionally
- * also having the meta (Integer, placed metadata value) attribute set.
- * No special checks for location, just sustainability.
- * registerPlantable_Crop | An NBTTag with the seed (Item, String identifier), and
- * crop (Block, String identifier) attributes set, optionally
- * also having the meta (Integer, placed metadata value) attribute set.
- * Will automatically hoe dirt and grass into farmland when planting.
- * registerPlantable_Sapling | An NBTTag with the sapling (Block, String identifier), and optionally
- * the seed (Item, String identifier) attributes set.
- * }
- * { Fertilizer
- * registerFertilizer | An NBTTag with the fert (Item, String identifier), meta (Integer), and
- * type (Integer, index into FertilizerType.values()) attributes set.
- * }
- * { Fertilizables
- * registerFertilizable_Grass | The String identifier of a block. Will bonemeal the block and expect
- * tall grass be planted above and around it, must be IGrowable. Works with
- * the GrowPlant and Grass type fertilizers, not recommended for crop plants.
- * registerFertilizable_Gourd | The String identifier of a block. Must be IGrowable, and expects identical
- * behavior to vanilla stems. Works with the GrowPlant fertilizers.
- * registerFertilizable_Crop | An NBTTag with the plant (Block, String identifier, IGrowable), and
- * meta (Integer, max growth phase) attributes set, optionally also having
- * the type (Integer, index into FertilizerType) attribute set.
- * registerFertilizable_Cocoa | An NBTTag with the plant (Block, String identifier), and optionally also
- * the type (Integer, index into FertilizerType) attributes set.
- * Expects metadata of the block to exactly match cocoa pods.
- * registerFertilizable_Standard | An NBTTag with the plant (Block, String identifier, IGrowable), and
- * optionally also the type (Integer, index into FertilizerType) attributes set.
- * Expects the block to change when successfully grown (e.g., saplings).
- * }
- */
- public static void sendMessage(String message, Object value)
- {
- if(!Loader.isModLoaded("MineFactoryReloaded") || Loader.instance().activeModContainer() == null)
- {
- return;
- }
- try
- {
- final Method m = FMLInterModComms.class.getDeclaredMethod("enqueueMessage", Object.class, String.class, IMCMessage.class);
- m.setAccessible(true);
- final Constructor<IMCMessage> c = IMCMessage.class.getDeclaredConstructor(String.class, Object.class);
- c.setAccessible(true);
- m.invoke(null, Loader.instance().activeModContainer(), "MineFactoryReloaded", c.newInstance(message, value));
- }
- catch(final Exception e)
- {
- e.printStackTrace();
- }
- }
-}
diff --git a/src/api/java/powercrystals/minefactoryreloaded/api/HarvestType.java b/src/api/java/powercrystals/minefactoryreloaded/api/HarvestType.java
deleted file mode 100644
index a56208e..0000000
--- a/src/api/java/powercrystals/minefactoryreloaded/api/HarvestType.java
+++ /dev/null
@@ -1,44 +0,0 @@
-package powercrystals.minefactoryreloaded.api;
-
-/**
- * @author PowerCrystals
- *
- * Determines what algorithm the Harvester uses when it encounters this IFactoryHarvestable in the world.
- */
-public enum HarvestType
-{
- /**
- * Just break the single block - no special action needed. e.g. Carrots, flowers, wheat.
- */
- Normal,
- /**
- * Search for harvestable blocks adjacent to this block but leave this block. e.g. Pumpkin, melon
- */
- Gourd,
- /**
- * Search for identical blocks above.
- */
- Column,
- /**
- * Search for identical blocks above but leave the bottom one for the future. e.g. Cactus, sugarcane.
- */
- LeaveBottom,
- /**
- * This block is the base of a tree and the harvester should enter tree-cutting mode.
- */
- Tree,
- /**
- * This block is the base of the tree and the harvester should enter tree-cutting mode.
- * The tree is searched for in the negative y axis instead.
- */
- TreeFlipped,
- /**
- * This block is part of a tree as above.
- */
- TreeLeaf,
- /**
- * This block is part of a tree as above, but fruits are cut before logs. e.g. cocoa
- * The tree is not searched for.
- */
- TreeFruit
-}
diff --git a/src/api/java/powercrystals/minefactoryreloaded/api/IFactoryGrindable.java b/src/api/java/powercrystals/minefactoryreloaded/api/IFactoryGrindable.java
deleted file mode 100644
index edfb8c9..0000000
--- a/src/api/java/powercrystals/minefactoryreloaded/api/IFactoryGrindable.java
+++ /dev/null
@@ -1,35 +0,0 @@
-package powercrystals.minefactoryreloaded.api;
-
-import java.util.List;
-import java.util.Random;
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.world.World;
-
-/**
- * @author PowerCrystals
- *
- * Defines a grindable entity for the Grinder.
- */
-public interface IFactoryGrindable
-{
- /**
- * @return The class that this grindable instance is handling. This must be a subtype of EntityLivingBase or the entity will never
- * be noticed by the Grinder.
- */
- public Class<? extends EntityLivingBase> getGrindableEntity();
-
- /**
- * @param world The world this entity is in.
- * @param entity The entity instance being ground.
- * @param random A Random instance.
- * @return The drops generated when this entity is killed.
- */
- public List<MobDrop> grind(World world, EntityLivingBase entity, Random random);
-
- /**
- * @param entity The entity instance being ground.
- * @return Whether this entity has been fully processed or not.
- */
- public boolean processEntity(EntityLivingBase entity);
-}
diff --git a/src/api/java/powercrystals/minefactoryreloaded/api/IFactoryHarvestable.java b/src/api/java/powercrystals/minefactoryreloaded/api/IFactoryHarvestable.java
deleted file mode 100644
index 1191149..0000000
--- a/src/api/java/powercrystals/minefactoryreloaded/api/IFactoryHarvestable.java
+++ /dev/null
@@ -1,71 +0,0 @@
-package powercrystals.minefactoryreloaded.api;
-
-import java.util.List;
-import java.util.Map;
-import java.util.Random;
-
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-
-/**
- * @author PowerCrystals
- *
- * Defines a harvestable block for the Harvester.
- */
-public interface IFactoryHarvestable
-{
- /**
- * @return The block this harvestable instance is managing.
- */
- public Block getPlant();
-
- /**
- * @return The type of harvest the Harvester should perform on this block.
- */
- public HarvestType getHarvestType();
-
- /**
- * @return Whether or not the Harvester should break the block when harvesting. If false, no changes will be performed by the Harvester itself.
- */
- public boolean breakBlock();
-
- /**
- * @param world The world this block is in.
- * @param harvesterSettings The harvester's current settings. Do not modify these.
- * @param x The X coordinate of the block being harvested.
- * @param y The Y coordinate of the block being harvested.
- * @param z The Z coordinate of the block being harvested.
- * @return True if this block can be harvested.
- */
- public boolean canBeHarvested(World world, Map<String, Boolean> harvesterSettings, int x, int y, int z);
-
- /**
- * @param world The world this block is in.
- * @param rand A Random instance to use when generating drops.
- * @param harvesterSettings The harvester's current settings. Do not modify these.
- * @param x The X coordinate of the block being harvested.
- * @param y The Y coordinate of the block being harvested.
- * @param z The Z coordinate of the block being harvested.
- * @return The drops generated by breaking this block. For a default implementation, calling Block.getBlockDropped() is usually sufficient.
- */
- public List<ItemStack> getDrops(World world, Random rand, Map<String, Boolean> harvesterSettings, int x, int y, int z);
-
- /**
- * Called before the block is going to be harvested. Usually empty.
- * @param world The world this block is in.
- * @param x The X coordinate of the block being harvested.
- * @param y The Y coordinate of the block being harvested.
- * @param z The Z coordinate of the block being harvested.
- */
- public void preHarvest(World world, int x, int y, int z);
-
- /**
- * Called after the block is going to be harvested. Used to re-till soil, for example.
- * @param world The world this block is in.
- * @param x The X coordinate of the block being harvested.
- * @param y The Y coordinate of the block being harvested.
- * @param z The Z coordinate of the block being harvested.
- */
- public void postHarvest(World world, int x, int y, int z);
-}
diff --git a/src/api/java/powercrystals/minefactoryreloaded/api/ILiquidDrinkHandler.java b/src/api/java/powercrystals/minefactoryreloaded/api/ILiquidDrinkHandler.java
deleted file mode 100644
index 31eba00..0000000
--- a/src/api/java/powercrystals/minefactoryreloaded/api/ILiquidDrinkHandler.java
+++ /dev/null
@@ -1,8 +0,0 @@
-package powercrystals.minefactoryreloaded.api;
-
-import net.minecraft.entity.EntityLivingBase;
-
-public interface ILiquidDrinkHandler
-{
- public void onDrink(EntityLivingBase player);
-}
diff --git a/src/api/java/powercrystals/minefactoryreloaded/api/MobDrop.java b/src/api/java/powercrystals/minefactoryreloaded/api/MobDrop.java
deleted file mode 100644
index 84a34a5..0000000
--- a/src/api/java/powercrystals/minefactoryreloaded/api/MobDrop.java
+++ /dev/null
@@ -1,24 +0,0 @@
-package powercrystals.minefactoryreloaded.api;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.WeightedRandom;
-
-public class MobDrop extends WeightedRandom.Item
-{
- private final ItemStack _stack;
-
- public MobDrop(int weight, ItemStack stack)
- {
- super(weight);
- _stack = stack;
- }
-
- public ItemStack getStack()
- {
- if(_stack == null)
- {
- return null;
- }
- return _stack.copy();
- }
-}
diff --git a/src/api/java/powercrystals/minefactoryreloaded/api/ValuedItem.java b/src/api/java/powercrystals/minefactoryreloaded/api/ValuedItem.java
deleted file mode 100644
index d9b1b55..0000000
--- a/src/api/java/powercrystals/minefactoryreloaded/api/ValuedItem.java
+++ /dev/null
@@ -1,72 +0,0 @@
-package powercrystals.minefactoryreloaded.api;
-
-import net.minecraft.item.ItemStack;
-
-public class ValuedItem
-{
- public final int value;
- public final ItemStack item;
- public final String key;
- public final Object object;
-
- public ValuedItem(int v, ItemStack i)
- {
- value = v;
- item = i;
- key = null;
- object = null;
- }
-
- public ValuedItem(String v, Object i)
- {
- value = -1;
- item = null;
- key = v;
- object = i;
- }
-
- /**
- * Presently unused but included so that if they do get used in the future,
- * people including this in their jar and loading before MFR don't destroy everyone
- */
-
- public ValuedItem(int v, Object i)
- {
- value = v;
- item = null;
- key = null;
- object = i;
- }
-
- public ValuedItem(String v, ItemStack i)
- {
- value = -1;
- item = i;
- key = v;
- object = null;
- }
-
- public ValuedItem(int v, String k, ItemStack i)
- {
- value = v;
- item = i;
- key = k;
- object = null;
- }
-
- public ValuedItem(int v, String k, Object i)
- {
- value = v;
- item = null;
- key = k;
- object = i;
- }
-
- public ValuedItem(int v, String k, ItemStack i, Object o)
- {
- value = v;
- item = i;
- key = k;
- object = o;
- }
-}
diff --git a/src/api/java/thaumcraft/api/BlockCoordinates.java b/src/api/java/thaumcraft/api/BlockCoordinates.java
deleted file mode 100644
index 9fb5dd8..0000000
--- a/src/api/java/thaumcraft/api/BlockCoordinates.java
+++ /dev/null
@@ -1,115 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-
-public class BlockCoordinates implements Comparable
-{
- public int x;
-
- /** the y coordinate */
- public int y;
-
- /** the z coordinate */
- public int z;
-
- public BlockCoordinates()
- {
- }
-
- public BlockCoordinates(int par1, int par2, int par3)
- {
- x = par1;
- y = par2;
- z = par3;
- }
-
- public BlockCoordinates(TileEntity tile)
- {
- x = tile.xCoord;
- y = tile.yCoord;
- z = tile.zCoord;
- }
-
- public BlockCoordinates(BlockCoordinates par1ChunkCoordinates)
- {
- x = par1ChunkCoordinates.x;
- y = par1ChunkCoordinates.y;
- z = par1ChunkCoordinates.z;
- }
-
- @Override
- public boolean equals(Object par1Obj)
- {
- if(!(par1Obj instanceof BlockCoordinates))
- {
- return false;
- }
- else
- {
- final BlockCoordinates coordinates = (BlockCoordinates) par1Obj;
- return x == coordinates.x && y == coordinates.y && z == coordinates.z;
- }
- }
-
- @Override
- public int hashCode()
- {
- return x + y << 8 + z << 16;
- }
-
- /**
- * Compare the coordinate with another coordinate
- */
- public int compareWorldCoordinate(BlockCoordinates par1)
- {
- return y == par1.y ? (z == par1.z ? x - par1.x : z - par1.z) : y - par1.y;
- }
-
- public void set(int par1, int par2, int par3, int d)
- {
- x = par1;
- y = par2;
- z = par3;
- }
-
- /**
- * Returns the squared distance between this coordinates and the coordinates given as argument.
- */
- public float getDistanceSquared(int par1, int par2, int par3)
- {
- final float f = x - par1;
- final float f1 = y - par2;
- final float f2 = z - par3;
- return f * f + f1 * f1 + f2 * f2;
- }
-
- /**
- * Return the squared distance between this coordinates and the ChunkCoordinates given as argument.
- */
- public float getDistanceSquaredToWorldCoordinates(BlockCoordinates par1ChunkCoordinates)
- {
- return getDistanceSquared(par1ChunkCoordinates.x, par1ChunkCoordinates.y, par1ChunkCoordinates.z);
- }
-
- @Override
- public int compareTo(Object par1Obj)
- {
- return compareWorldCoordinate((BlockCoordinates) par1Obj);
- }
-
- public void readNBT(NBTTagCompound nbt)
- {
- x = nbt.getInteger("b_x");
- y = nbt.getInteger("b_y");
- z = nbt.getInteger("b_z");
- }
-
- public void writeNBT(NBTTagCompound nbt)
- {
- nbt.setInteger("b_x", x);
- nbt.setInteger("b_y", y);
- nbt.setInteger("b_z", z);
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/IArchitect.java b/src/api/java/thaumcraft/api/IArchitect.java
deleted file mode 100644
index ba25d98..0000000
--- a/src/api/java/thaumcraft/api/IArchitect.java
+++ /dev/null
@@ -1,28 +0,0 @@
-package thaumcraft.api;
-
-import java.util.ArrayList;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-
-public interface IArchitect
-{
-
- /**
- * Returns a list of blocks that should be highlighted in world.
- */
- public ArrayList<BlockCoordinates> getArchitectBlocks(ItemStack stack, World world, int x, int y, int z, int side, EntityPlayer player);
-
- /**
- * which axis should be displayed.
- */
- public boolean showAxis(ItemStack stack, World world, EntityPlayer player, int side, EnumAxis axis);
-
- public enum EnumAxis
- {
- X, // east / west
- Y, // up / down
- Z; // north / south
- }
-}
diff --git a/src/api/java/thaumcraft/api/IGoggles.java b/src/api/java/thaumcraft/api/IGoggles.java
deleted file mode 100644
index 743e0e9..0000000
--- a/src/api/java/thaumcraft/api/IGoggles.java
+++ /dev/null
@@ -1,23 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.item.ItemStack;
-
-/**
- *
- * @author Azanor
- *
- * Equipped head slot items that extend this class will be able to perform most functions that
- * goggles of revealing can apart from view nodes which is handled by IRevealer.
- *
- */
-
-public interface IGoggles
-{
-
- /*
- * If this method returns true things like block essentia contents will be shown.
- */
- public boolean showIngamePopups(ItemStack itemstack, EntityLivingBase player);
-
-}
diff --git a/src/api/java/thaumcraft/api/IRepairable.java b/src/api/java/thaumcraft/api/IRepairable.java
deleted file mode 100644
index a742f2b..0000000
--- a/src/api/java/thaumcraft/api/IRepairable.java
+++ /dev/null
@@ -1,11 +0,0 @@
-package thaumcraft.api;
-
-/**
- * @author Azanor
- * Items, armor and tools with this interface can receive the Repair enchantment.
- * Repairs 1 point of durability every 10 seconds (2 for repair II)
- */
-public interface IRepairable
-{
-
-}
diff --git a/src/api/java/thaumcraft/api/IRepairableExtended.java b/src/api/java/thaumcraft/api/IRepairableExtended.java
deleted file mode 100644
index 87e4479..0000000
--- a/src/api/java/thaumcraft/api/IRepairableExtended.java
+++ /dev/null
@@ -1,16 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-
-/**
- * @author Azanor
- * Items, armor and tools with this interface can receive the Repair enchantment.
- * Repairs 1 point of durability every 10 seconds (2 for repair II)
- */
-public interface IRepairableExtended extends IRepairable
-{
-
- public boolean doRepair(ItemStack stack, EntityPlayer player, int enchantlevel);
-
-}
diff --git a/src/api/java/thaumcraft/api/IRunicArmor.java b/src/api/java/thaumcraft/api/IRunicArmor.java
deleted file mode 100644
index d9ed818..0000000
--- a/src/api/java/thaumcraft/api/IRunicArmor.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.item.ItemStack;
-
-/**
- *
- * @author Azanor
- *
- * Armor or bauble slot items that implement this interface can provide runic shielding.
- * Recharging, hardening, etc. is handled internally by thaumcraft.
- *
- */
-
-public interface IRunicArmor
-{
-
- /**
- * returns how much charge this item can provide. This is the base shielding value - any hardening is stored and calculated internally.
- */
- public int getRunicCharge(ItemStack itemstack);
-
-}
diff --git a/src/api/java/thaumcraft/api/IScribeTools.java b/src/api/java/thaumcraft/api/IScribeTools.java
deleted file mode 100644
index d6dbb8d..0000000
--- a/src/api/java/thaumcraft/api/IScribeTools.java
+++ /dev/null
@@ -1,14 +0,0 @@
-package thaumcraft.api;
-
-/**
- *
- * @author Azanor
- *
- * Interface used to identify scribing tool items used in research table
- *
- */
-
-public interface IScribeTools
-{
-
-}
diff --git a/src/api/java/thaumcraft/api/IVisDiscountGear.java b/src/api/java/thaumcraft/api/IVisDiscountGear.java
deleted file mode 100644
index 6032b07..0000000
--- a/src/api/java/thaumcraft/api/IVisDiscountGear.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import thaumcraft.api.aspects.Aspect;
-
-/**
- * @author Azanor
- * ItemArmor with this interface will grant a discount to the vis cost of actions the wearer performs with casting wands.
- * The amount returned is the percentage by which the cost is discounted. There is a built-int max discount of 50%, but
- * individual items really shouldn't have a discount more than 5%
- */
-public interface IVisDiscountGear
-{
-
- int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect);
-
-}
diff --git a/src/api/java/thaumcraft/api/IWarpingGear.java b/src/api/java/thaumcraft/api/IWarpingGear.java
deleted file mode 100644
index 674054f..0000000
--- a/src/api/java/thaumcraft/api/IWarpingGear.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-
-/**
- *
- * @author Azanor
- *
- * Armor, held items or bauble slot items that implement this interface add warp when equipped or held.
- *
- */
-
-public interface IWarpingGear
-{
-
- /**
- * returns how much warp this item adds while worn or held.
- */
- public int getWarp(ItemStack itemstack, EntityPlayer player);
-
-}
diff --git a/src/api/java/thaumcraft/api/ItemApi.java b/src/api/java/thaumcraft/api/ItemApi.java
deleted file mode 100644
index 3aea4f1..0000000
--- a/src/api/java/thaumcraft/api/ItemApi.java
+++ /dev/null
@@ -1,85 +0,0 @@
-package thaumcraft.api;
-
-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.
- *
- */
-public class ItemApi
-{
-
- public static ItemStack getItem(String itemString, int meta)
- {
- ItemStack item = null;
-
- try
- {
- final String itemClass = "thaumcraft.common.config.ConfigItems";
- final Object obj = Class.forName(itemClass).getField(itemString).get(null);
- if(obj instanceof Item)
- {
- item = new ItemStack((Item) obj, 1, meta);
- }
- else if(obj instanceof ItemStack)
- {
- item = (ItemStack) obj;
- }
- }
- catch(final Exception ex)
- {
- FMLLog.warning("[Thaumcraft] Could not retrieve item identified by: " + itemString);
- }
-
- return item;
- }
-
- public static ItemStack getBlock(String itemString, int meta)
- {
- ItemStack item = null;
-
- try
- {
- final String itemClass = "thaumcraft.common.config.ConfigBlocks";
- final Object obj = Class.forName(itemClass).getField(itemString).get(null);
- if(obj instanceof Block)
- {
- item = new ItemStack((Block) obj, 1, meta);
- }
- else if(obj instanceof ItemStack)
- {
- item = (ItemStack) obj;
- }
- }
- catch(final Exception ex)
- {
- FMLLog.warning("[Thaumcraft] Could not retrieve block identified by: " + itemString);
- }
-
- return item;
- }
-
- /**
- *
- * Some examples
- *
- * Casting Wands:
- * itemWandCasting
- *
- * Resources:
- * itemEssence, itemWispEssence, itemResource, itemShard, itemNugget,
- * itemNuggetChicken, itemNuggetBeef, itemNuggetPork, itemTripleMeatTreat
- *
- * Research:
- * itemResearchNotes, itemInkwell, itemThaumonomicon
- *
- */
-
-}
diff --git a/src/api/java/thaumcraft/api/ItemRunic.java b/src/api/java/thaumcraft/api/ItemRunic.java
deleted file mode 100644
index 3517558..0000000
--- a/src/api/java/thaumcraft/api/ItemRunic.java
+++ /dev/null
@@ -1,23 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-
-public class ItemRunic extends Item implements IRunicArmor
-{
-
- int charge;
-
- public ItemRunic(int charge)
- {
- super();
- this.charge = charge;
- }
-
- @Override
- public int getRunicCharge(ItemStack itemstack)
- {
- return charge;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/ThaumcraftApi.java b/src/api/java/thaumcraft/api/ThaumcraftApi.java
deleted file mode 100644
index c01d521..0000000
--- a/src/api/java/thaumcraft/api/ThaumcraftApi.java
+++ /dev/null
@@ -1,716 +0,0 @@
-package thaumcraft.api;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.HashMap;
-import java.util.List;
-import java.util.concurrent.ConcurrentHashMap;
-
-import net.minecraft.block.Block;
-import net.minecraft.enchantment.Enchantment;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.Item.ToolMaterial;
-import net.minecraft.item.ItemArmor.ArmorMaterial;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.common.util.EnumHelper;
-import net.minecraftforge.oredict.OreDictionary;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-import thaumcraft.api.crafting.CrucibleRecipe;
-import thaumcraft.api.crafting.InfusionEnchantmentRecipe;
-import thaumcraft.api.crafting.InfusionRecipe;
-import thaumcraft.api.crafting.ShapedArcaneRecipe;
-import thaumcraft.api.crafting.ShapelessArcaneRecipe;
-import thaumcraft.api.internal.DummyInternalMethodHandler;
-import thaumcraft.api.internal.IInternalMethodHandler;
-import thaumcraft.api.internal.WeightedRandomLoot;
-import thaumcraft.api.research.IScanEventHandler;
-import thaumcraft.api.research.ResearchCategories;
-import thaumcraft.api.research.ResearchCategoryList;
-import thaumcraft.api.research.ResearchItem;
-import thaumcraft.api.research.ResearchPage;
-
-/**
- * @author Azanor
- *
- *
- * IMPORTANT: If you are adding your own aspects to items it is a good idea to do it AFTER Thaumcraft adds its aspects, otherwise odd things may happen.
- *
- */
-public class ThaumcraftApi
-{
-
- //Materials
- public static ToolMaterial toolMatThaumium = EnumHelper.addToolMaterial("THAUMIUM", 3, 400, 7F, 2, 22);
- public static ToolMaterial toolMatVoid = EnumHelper.addToolMaterial("VOID", 4, 150, 8F, 3, 10);
- public static ToolMaterial toolMatElemental = EnumHelper.addToolMaterial("THAUMIUM_ELEMENTAL", 3, 1500, 10F, 3, 18);
- public static ArmorMaterial armorMatThaumium = EnumHelper.addArmorMaterial("THAUMIUM", 25, new int[] {2, 6, 5, 2}, 25);
- public static ArmorMaterial armorMatSpecial = EnumHelper.addArmorMaterial("SPECIAL", 25, new int[] {1, 3, 2, 1}, 25);
- public static ArmorMaterial armorMatThaumiumFortress = EnumHelper.addArmorMaterial("FORTRESS", 40, new int[] {3, 7, 6, 3}, 25);
- public static ArmorMaterial armorMatVoid = EnumHelper.addArmorMaterial("VOID", 10, new int[] {3, 7, 6, 3}, 10);
- public static ArmorMaterial armorMatVoidFortress = EnumHelper.addArmorMaterial("VOIDFORTRESS", 18, new int[] {4, 8, 7, 4}, 10);
-
- //Enchantment references
- public static int enchantFrugal;
- public static int enchantPotency;
- public static int enchantWandFortune;
- public static int enchantHaste;
- public static int enchantRepair;
-
- //Miscellaneous
- /**
- * Portable Hole Block-id Blacklist.
- * Simply add the block-id's of blocks you don't want the portable hole to go through.
- */
- public static ArrayList<Block> portableHoleBlackList = new ArrayList<Block>();
-
- //Internal (Do not alter this unless you like pretty explosions)
- //Calling methods from this will only work properly once Thaumcraft is past the FMLPreInitializationEvent phase.
- public static IInternalMethodHandler internalMethods = new DummyInternalMethodHandler();
-
- //RESEARCH/////////////////////////////////////////
- public static ArrayList<IScanEventHandler> scanEventhandlers = new ArrayList<IScanEventHandler>();
- public static ArrayList<EntityTags> scanEntities = new ArrayList<EntityTags>();
-
- public static class EntityTagsNBT
- {
- public EntityTagsNBT(String name, Object value)
- {
- this.name = name;
- this.value = value;
- }
-
- public String name;
- public Object value;
- }
-
- public static class EntityTags
- {
- public EntityTags(String entityName, AspectList aspects, EntityTagsNBT... nbts)
- {
- this.entityName = entityName;
- this.nbts = nbts;
- this.aspects = aspects;
- }
-
- public String entityName;
- public EntityTagsNBT[] nbts;
- public AspectList aspects;
- }
-
- /**
- * not really working atm, so ignore it for now
- * @param scanEventHandler
- */
- public static void registerScanEventhandler(IScanEventHandler scanEventHandler)
- {
- scanEventhandlers.add(scanEventHandler);
- }
-
- /**
- * This is used to add aspects to entities which you can then scan using a thaumometer.
- * Also used to calculate vis drops from mobs.
- * @param entityName
- * @param aspects
- * @param nbt you can specify certain nbt keys and their values
- * to differentiate between mobs. <br>For example the normal and wither skeleton:
- * <br>ThaumcraftApi.registerEntityTag("Skeleton", (new AspectList()).add(Aspect.DEATH, 5));
- * <br>ThaumcraftApi.registerEntityTag("Skeleton", (new AspectList()).add(Aspect.DEATH, 8), new NBTTagByte("SkeletonType",(byte) 1));
- */
- public static void registerEntityTag(String entityName, AspectList aspects, EntityTagsNBT... nbt)
- {
- scanEntities.add(new EntityTags(entityName, aspects, nbt));
- }
-
- //RECIPES/////////////////////////////////////////
- private static ArrayList craftingRecipes = new ArrayList();
- private static HashMap<Object, ItemStack> smeltingBonus = new HashMap<Object, ItemStack>();
-
- /**
- * This method is used to determine what bonus items are generated when the infernal furnace smelts items
- * @param in The input of the smelting operation. e.g. new ItemStack(Block.oreGold)
- * @param out The bonus item that can be produced from the smelting operation e.g. new ItemStack(nuggetGold,0,0).
- * Stacksize should be 0 unless you want to guarantee that at least 1 item is always produced.
- */
- public static void addSmeltingBonus(ItemStack in, ItemStack out)
- {
- smeltingBonus.put(Arrays.asList(in.getItem(), in.getItemDamage()), new ItemStack(
- out.getItem(), 0, out.getItemDamage()));
- }
-
- /**
- * This method is used to determine what bonus items are generated when the infernal furnace smelts items
- * @param in The ore dictionary input of the smelting operation. e.g. "oreGold"
- * @param out The bonus item that can be produced from the smelting operation e.g. new ItemStack(nuggetGold,0,0).
- * Stacksize should be 0 unless you want to guarantee that at least 1 item is always produced.
- */
- public static void addSmeltingBonus(String in, ItemStack out)
- {
- smeltingBonus.put(in, new ItemStack(out.getItem(), 0,
- out.getItemDamage()));
- }
-
- /**
- * Returns the bonus item produced from a smelting operation in the infernal furnace
- * @param in The input of the smelting operation. e.g. new ItemStack(oreGold)
- * @return the The bonus item that can be produced
- */
- public static ItemStack getSmeltingBonus(ItemStack in)
- {
- ItemStack out = smeltingBonus.get(Arrays.asList(in.getItem(), in.getItemDamage()));
- if(out == null)
- {
- out = smeltingBonus.get(Arrays.asList(in.getItem(), OreDictionary.WILDCARD_VALUE));
- }
- if(out == null)
- {
- final String od = OreDictionary.getOreName(OreDictionary.getOreID(in));
- out = smeltingBonus.get(od);
- }
- return out;
- }
-
- public static List getCraftingRecipes()
- {
- return craftingRecipes;
- }
-
- /**
- * @param research the research key required for this recipe to work. Leave blank if it will work without research
- * @param result the recipe output
- * @param aspects the vis cost per aspect.
- * @param recipe The recipe. Format is exactly the same as vanilla recipes. Input itemstacks are NBT sensitive.
- */
- public static ShapedArcaneRecipe addArcaneCraftingRecipe(String research, ItemStack result, AspectList aspects, Object... recipe)
- {
- final ShapedArcaneRecipe r = new ShapedArcaneRecipe(research, result,
- aspects, recipe);
- craftingRecipes.add(r);
- return r;
- }
-
- /**
- * @param research the research key required for this recipe to work. Leave blank if it will work without research
- * @param result the recipe output
- * @param aspects the vis cost per aspect
- * @param recipe The recipe. Format is exactly the same as vanilla shapeless recipes. Input itemstacks are NBT sensitive.
- */
- public static ShapelessArcaneRecipe addShapelessArcaneCraftingRecipe(String research, ItemStack result, AspectList aspects, Object... recipe)
- {
- final ShapelessArcaneRecipe r = new ShapelessArcaneRecipe(research, result,
- aspects, recipe);
- craftingRecipes.add(r);
- return r;
- }
-
- /**
- * @param research the research key required for this recipe to work. Leave blank if it will work without research
- * @param result the recipe output. It can either be an itemstack or an nbt compound tag that will be added to the central item
- * @param instability a number that represents the N in 1000 chance for the infusion altar to spawn an
- * instability effect each second while the crafting is in progress
- * @param aspects the essentia cost per aspect.
- * @param aspects input the central item to be infused
- * @param recipe An array of items required to craft this. Input itemstacks are NBT sensitive.
- * Infusion crafting components are automatically "fuzzy" and the oredict will be checked for possible matches.
- *
- */
- public static InfusionRecipe addInfusionCraftingRecipe(String research, Object result, int instability, AspectList aspects, ItemStack input, ItemStack[] recipe)
- {
- if(!(result instanceof ItemStack || result instanceof Object[]))
- {
- return null;
- }
- final InfusionRecipe r = new InfusionRecipe(research, result, instability,
- aspects, input, recipe);
- craftingRecipes.add(r);
- return r;
- }
-
- /**
- * @param research the research key required for this recipe to work. Leave blank if it will work without research
- * @param enchantment the enchantment that will be applied to the item
- * @param instability a number that represents the N in 1000 chance for the infusion altar to spawn an
- * instability effect each second while the crafting is in progress
- * @param aspects the essentia cost per aspect.
- * @param recipe An array of items required to craft this. Input itemstacks are NBT sensitive.
- * Infusion crafting components are automatically "fuzzy" and the oredict will be checked for possible matches.
- *
- */
- public static InfusionEnchantmentRecipe addInfusionEnchantmentRecipe(String research, Enchantment enchantment, int instability, AspectList aspects, ItemStack[] recipe)
- {
- final InfusionEnchantmentRecipe r = new InfusionEnchantmentRecipe(research,
- enchantment, instability, aspects, recipe);
- craftingRecipes.add(r);
- return r;
- }
-
- /**
- * @param stack the recipe result
- * @return the recipe
- */
- public static InfusionRecipe getInfusionRecipe(ItemStack res)
- {
- for(final Object r : getCraftingRecipes())
- {
- if(r instanceof InfusionRecipe)
- {
- if(((InfusionRecipe) r).getRecipeOutput() instanceof ItemStack)
- {
- if(((ItemStack) ((InfusionRecipe) r).getRecipeOutput()).isItemEqual(res))
- {
- return (InfusionRecipe) r;
- }
- }
- }
- }
- return null;
- }
-
- /**
- * @param key the research key required for this recipe to work.
- * @param result the output result
- * @param catalyst an itemstack of the catalyst or a string if it is an ore dictionary item
- * @param cost the vis cost
- * @param tags the aspects required to craft this
- */
- public static CrucibleRecipe addCrucibleRecipe(String key, ItemStack result, Object catalyst, AspectList tags)
- {
- final CrucibleRecipe rc = new CrucibleRecipe(key, result, catalyst, tags);
- getCraftingRecipes().add(rc);
- return rc;
- }
-
- /**
- * @param stack the recipe result
- * @return the recipe
- */
- public static CrucibleRecipe getCrucibleRecipe(ItemStack stack)
- {
- for(final Object r : getCraftingRecipes())
- {
- if(r instanceof CrucibleRecipe)
- {
- if(((CrucibleRecipe) r).getRecipeOutput().isItemEqual(stack))
- {
- return (CrucibleRecipe) r;
- }
- }
- }
- return null;
- }
-
- /**
- * @param hash the unique recipe code
- * @return the recipe
- */
- public static CrucibleRecipe getCrucibleRecipeFromHash(int hash)
- {
- for(final Object r : getCraftingRecipes())
- {
- if(r instanceof CrucibleRecipe)
- {
- if(((CrucibleRecipe) r).hash == hash)
- {
- return (CrucibleRecipe) r;
- }
- }
- }
- return null;
- }
-
- /**
- * Used by the thaumonomicon drilldown feature.
- * @param stack the item
- * @return the thaumcraft recipe key that produces that item.
- */
- private static HashMap<int[], Object[]> keyCache = new HashMap<int[], Object[]>();
-
- public static Object[] getCraftingRecipeKey(EntityPlayer player, ItemStack stack)
- {
- final int[] key = new int[] {Item.getIdFromItem(stack.getItem()), stack.getItemDamage()};
- if(keyCache.containsKey(key))
- {
- if(keyCache.get(key) == null)
- {
- return null;
- }
- if(ThaumcraftApiHelper.isResearchComplete(player.getCommandSenderName(), (String) (keyCache.get(key))[0]))
- {
- return keyCache.get(key);
- }
- else
- {
- return null;
- }
- }
- for(final ResearchCategoryList rcl : ResearchCategories.researchCategories.values())
- {
- for(final ResearchItem ri : rcl.research.values())
- {
- if(ri.getPages() == null)
- {
- continue;
- }
- for(int a = 0; a < ri.getPages().length; a++)
- {
- final ResearchPage page = ri.getPages()[a];
- if(page.recipe != null && page.recipe instanceof CrucibleRecipe[])
- {
- final CrucibleRecipe[] crs = (CrucibleRecipe[]) page.recipe;
- for(final CrucibleRecipe cr : crs)
- {
- if(cr.getRecipeOutput().isItemEqual(stack))
- {
- keyCache.put(key, new Object[] {ri.key, a});
- if(ThaumcraftApiHelper.isResearchComplete(player.getCommandSenderName(), ri.key))
- {
- return new Object[] {ri.key, a};
- }
- }
- }
- }
- else if(page.recipeOutput != null && stack != null && page.recipeOutput.isItemEqual(stack))
- {
- keyCache.put(key, new Object[] {ri.key, a});
- if(ThaumcraftApiHelper.isResearchComplete(player.getCommandSenderName(), ri.key))
- {
- return new Object[] {ri.key, a};
- }
- else
- {
- return null;
- }
- }
- }
- }
- }
- keyCache.put(key, null);
- return null;
- }
-
- //ASPECTS////////////////////////////////////////
-
- public static ConcurrentHashMap<List, AspectList> objectTags = new ConcurrentHashMap<List, AspectList>();
- public static ConcurrentHashMap<List, int[]> groupedObjectTags = new ConcurrentHashMap<List, int[]>();
-
- /**
- * Checks to see if the passed item/block already has aspects associated with it.
- * @param id
- * @param meta
- * @return
- */
- public static boolean exists(Item item, int meta)
- {
- AspectList tmp = ThaumcraftApi.objectTags.get(Arrays.asList(item, meta));
- if(tmp == null)
- {
- tmp = ThaumcraftApi.objectTags.get(Arrays.asList(item, OreDictionary.WILDCARD_VALUE));
- if(meta == OreDictionary.WILDCARD_VALUE && tmp == null)
- {
- int index = 0;
- do
- {
- tmp = ThaumcraftApi.objectTags.get(Arrays.asList(item, index));
- index++;
- }
- while(index < 16 && tmp == null);
- }
- if(tmp == null)
- {
- return false;
- }
- }
-
- return true;
- }
-
- /**
- * Used to assign apsects to the given item/block. Here is an example of the declaration for cobblestone:<p>
- * <i>ThaumcraftApi.registerObjectTag(new ItemStack(Blocks.cobblestone), (new AspectList()).add(Aspect.ENTROPY, 1).add(Aspect.EARTH, 1));</i>
- * @param item the item passed. Pass OreDictionary.WILDCARD_VALUE if all damage values of this item/block should have the same aspects
- * @param aspects A ObjectTags object of the associated aspects
- */
- public static void registerObjectTag(ItemStack item, AspectList aspects)
- {
- if(aspects == null)
- {
- aspects = new AspectList();
- }
- try
- {
- objectTags.put(Arrays.asList(item.getItem(), item.getItemDamage()), aspects);
- }
- catch(final Exception e)
- {
- }
- }
-
- /**
- * Used to assign apsects to the given item/block. Here is an example of the declaration for cobblestone:<p>
- * <i>ThaumcraftApi.registerObjectTag(new ItemStack(Blocks.cobblestone), new int[]{0,1}, (new AspectList()).add(Aspect.ENTROPY, 1).add(Aspect.EARTH, 1));</i>
- * @param item
- * @param meta A range of meta values if you wish to lump several item meta's together as being the "same" item (i.e. stair orientations)
- * @param aspects A ObjectTags object of the associated aspects
- */
- public static void registerObjectTag(ItemStack item, int[] meta, AspectList aspects)
- {
- if(aspects == null)
- {
- aspects = new AspectList();
- }
- try
- {
- objectTags.put(Arrays.asList(item.getItem(), meta[0]), aspects);
- for(final int m : meta)
- {
- groupedObjectTags.put(Arrays.asList(item.getItem(), m), meta);
- }
-
- }
- catch(final Exception e)
- {
- }
- }
-
- /**
- * Used to assign apsects to the given ore dictionary item.
- * @param oreDict the ore dictionary name
- * @param aspects A ObjectTags object of the associated aspects
- */
- public static void registerObjectTag(String oreDict, AspectList aspects)
- {
- if(aspects == null)
- {
- aspects = new AspectList();
- }
- final ArrayList<ItemStack> ores = OreDictionary.getOres(oreDict);
- if(ores != null && ores.size() > 0)
- {
- for(final ItemStack ore : ores)
- {
- try
- {
- objectTags.put(Arrays.asList(ore.getItem(), ore.getItemDamage()), aspects);
- }
- catch(final Exception e)
- {
- }
- }
- }
- }
-
- /**
- * Used to assign aspects to the given item/block.
- * Attempts to automatically generate aspect tags by checking registered recipes.
- * Here is an example of the declaration for pistons:<p>
- * <i>ThaumcraftApi.registerComplexObjectTag(new ItemStack(Blocks.cobblestone), (new AspectList()).add(Aspect.MECHANISM, 2).add(Aspect.MOTION, 4));</i>
- * IMPORTANT - this should only be used if you are not happy with the default aspects the object would be assigned.
- * @param item, pass OreDictionary.WILDCARD_VALUE to meta if all damage values of this item/block should have the same aspects
- * @param aspects A ObjectTags object of the associated aspects
- */
- public static void registerComplexObjectTag(ItemStack item, AspectList aspects)
- {
- if(!exists(item.getItem(), item.getItemDamage()))
- {
- final AspectList tmp = ThaumcraftApiHelper.generateTags(item.getItem(), item.getItemDamage());
- if(tmp != null && tmp.size() > 0)
- {
- for(final Aspect tag : tmp.getAspects())
- {
- aspects.add(tag, tmp.getAmount(tag));
- }
- }
- registerObjectTag(item, aspects);
- }
- else
- {
- final AspectList tmp = ThaumcraftApiHelper.getObjectAspects(item);
- for(final Aspect tag : aspects.getAspects())
- {
- tmp.merge(tag, tmp.getAmount(tag));
- }
- registerObjectTag(item, tmp);
- }
- }
-
- //WARP ///////////////////////////////////////////////////////////////////////////////////////
- private static HashMap<Object, Integer> warpMap = new HashMap<Object, Integer>();
-
- /**
- * This method is used to determine how much warp is gained if the item is crafted. The warp
- * added is "sticky" warp
- * @param craftresult The item crafted
- * @param amount how much warp is gained
- */
- public static void addWarpToItem(ItemStack craftresult, int amount)
- {
- warpMap.put(Arrays.asList(craftresult.getItem(), craftresult.getItemDamage()), amount);
- }
-
- /**
- * This method is used to determine how much permanent warp is gained if the research is completed
- * @param in The item crafted
- * @param amount how much warp is gained
- */
- public static void addWarpToResearch(String research, int amount)
- {
- warpMap.put(research, amount);
- }
-
- /**
- * Returns how much warp is gained from the item or research passed in
- * @param in itemstack or string
- * @return how much warp it will give
- */
- public static int getWarp(Object in)
- {
- if(in == null)
- {
- return 0;
- }
- if(in instanceof ItemStack && warpMap.containsKey(Arrays.asList(((ItemStack) in).getItem(), ((ItemStack) in).getItemDamage())))
- {
- return warpMap.get(Arrays.asList(((ItemStack) in).getItem(), ((ItemStack) in).getItemDamage()));
- }
- else if(in instanceof String && warpMap.containsKey(in))
- {
- return warpMap.get(in);
- }
- return 0;
- }
-
- //LOOT BAGS //////////////////////////////////////////////////////////////////////////////////////////
-
- /**
- * Used to add possible loot to treasure bags. As a reference, the weight of gold coins are 2000
- * and a diamond is 50.
- * The weights are the same for all loot bag types - the only difference is how many items the bag
- * contains.
- * @param item
- * @param weight
- * @param bagTypes array of which type of bag to add this loot to. Multiple types can be specified
- * 0 = common, 1 = uncommon, 2 = rare
- */
- public static void addLootBagItem(ItemStack item, int weight, int... bagTypes)
- {
- if(bagTypes == null || bagTypes.length == 0)
- {
- WeightedRandomLoot.lootBagCommon.add(new WeightedRandomLoot(item,
- weight));
- }
- else
- {
- for(final int rarity : bagTypes)
- {
- switch(rarity)
- {
- case 0:
- WeightedRandomLoot.lootBagCommon.add(new WeightedRandomLoot(
- item, weight));
- break;
- case 1:
- WeightedRandomLoot.lootBagUncommon.add(new WeightedRandomLoot(
- item, weight));
- break;
- case 2:
- WeightedRandomLoot.lootBagRare.add(new WeightedRandomLoot(
- item, weight));
- break;
- }
- }
- }
- }
-
- //CROPS //////////////////////////////////////////////////////////////////////////////////////////
-
- /**
- * To define mod crops you need to use FMLInterModComms in your @Mod.Init method.
- * There are two 'types' of crops you can add. Standard crops and clickable crops.
- *
- * Standard crops work like normal vanilla crops - they grow until a certain metadata
- * value is reached and you harvest them by destroying the block and collecting the blocks.
- * You need to create and ItemStack that tells the golem what block id and metadata represents
- * the crop when fully grown. Sending a metadata of [OreDictionary.WILDCARD_VALUE] will mean the metadata won't get
- * checked.
- * Example for vanilla wheat:
- * FMLInterModComms.sendMessage("Thaumcraft", "harvestStandardCrop", new ItemStack(Block.crops,1,7));
- *
- * Clickable crops are crops that you right click to gather their bounty instead of destroying them.
- * As for standard crops, you need to create and ItemStack that tells the golem what block id
- * and metadata represents the crop when fully grown. The golem will trigger the blocks onBlockActivated method.
- * Sending a metadata of [OreDictionary.WILDCARD_VALUE] will mean the metadata won't get checked.
- * Example (this will technically do nothing since clicking wheat does nothing, but you get the idea):
- * FMLInterModComms.sendMessage("Thaumcraft", "harvestClickableCrop", new ItemStack(Block.crops,1,7));
- *
- * Stacked crops (like reeds) are crops that you wish the bottom block should remain after harvesting.
- * As for standard crops, you need to create and ItemStack that tells the golem what block id
- * and metadata represents the crop when fully grown. Sending a metadata of [OreDictionary.WILDCARD_VALUE] will mean the actualy md won't get
- * checked. If it has the order upgrade it will only harvest if the crop is more than one block high.
- * Example:
- * FMLInterModComms.sendMessage("Thaumcraft", "harvestStackedCrop", new ItemStack(Block.reed,1,7));
- */
-
- //NATIVE CLUSTERS //////////////////////////////////////////////////////////////////////////////////
-
- /**
- * You can define certain ores that will have a chance to produce native clusters via FMLInterModComms
- * in your @Mod.Init method using the "nativeCluster" string message.
- * The format should be:
- * "[ore item/block id],[ore item/block metadata],[cluster item/block id],[cluster item/block metadata],[chance modifier float]"
- *
- * NOTE: The chance modifier is a multiplier applied to the default chance for that cluster to be produced (default 27.5% for a pickaxe of the core)
- *
- * Example for vanilla iron ore to produce one of my own native iron clusters (assuming default id's) at double the default chance:
- * FMLInterModComms.sendMessage("Thaumcraft", "nativeCluster","15,0,25016,16,2.0");
- */
-
- //LAMP OF GROWTH BLACKLIST ///////////////////////////////////////////////////////////////////////////
- /**
- * You can blacklist crops that should not be effected by the Lamp of Growth via FMLInterModComms
- * in your @Mod.Init method using the "lampBlacklist" itemstack message.
- * Sending a metadata of [OreDictionary.WILDCARD_VALUE] will mean the metadata won't get checked.
- * Example for vanilla wheat:
- * FMLInterModComms.sendMessage("Thaumcraft", "lampBlacklist", new ItemStack(Block.crops,1,OreDictionary.WILDCARD_VALUE));
- */
-
- //DIMENSION BLACKLIST ///////////////////////////////////////////////////////////////////////////
- /**
- * You can blacklist a dimension to not spawn certain thaumcraft features
- * in your @Mod.Init method using the "dimensionBlacklist" string message in the format "[dimension]:[level]"
- * The level values are as follows:
- * [0] stop all tc spawning and generation
- * [1] allow ore and node generation (and node special features)
- * [2] allow mob spawning
- * [3] allow ore and node gen + mob spawning (and node special features)
- * Example:
- * FMLInterModComms.sendMessage("Thaumcraft", "dimensionBlacklist", "15:1");
- */
-
- //BIOME BLACKLIST ///////////////////////////////////////////////////////////////////////////
- /**
- * You can blacklist a biome to not spawn certain thaumcraft features
- * in your @Mod.Init method using the "biomeBlacklist" string message in the format "[biome id]:[level]"
- * The level values are as follows:
- * [0] stop all tc spawning and generation
- * [1] allow ore and node generation (and node special features)
- * [2] allow mob spawning
- * [3] allow ore and node gen + mob spawning (and node special features)
- * Example:
- * FMLInterModComms.sendMessage("Thaumcraft", "biomeBlacklist", "180:2");
- */
-
- //CHAMPION MOB WHITELIST ///////////////////////////////////////////////////////////////////////////
- /**
- * You can whitelist an entity class so it can rarely spawn champion versions in your @Mod.Init method using
- * the "championWhiteList" string message in the format "[Entity]:[level]"
- * The entity must extend EntityMob.
- * [Entity] is in a similar format to what is used for mob spawners and such (see EntityList.class for vanilla examples).
- * The [level] value indicate how rare the champion version will be - the higher the number the more common.
- * The number roughly equals the [n] in 100 chance of a mob being a champion version.
- * You can give 0 or negative numbers to allow champions to spawn with a very low chance only in particularly dangerous places.
- * However anything less than about -2 will probably result in no spawns at all.
- * Example:
- * FMLInterModComms.sendMessage("Thaumcraft", "championWhiteList", "Thaumcraft.Wisp:1");
- */
-}
diff --git a/src/api/java/thaumcraft/api/ThaumcraftApiHelper.java b/src/api/java/thaumcraft/api/ThaumcraftApiHelper.java
deleted file mode 100644
index 83ac4d2..0000000
--- a/src/api/java/thaumcraft/api/ThaumcraftApiHelper.java
+++ /dev/null
@@ -1,523 +0,0 @@
-package thaumcraft.api;
-
-import java.util.HashMap;
-import java.util.Iterator;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.Vec3;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.oredict.OreDictionary;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-import thaumcraft.api.aspects.IEssentiaTransport;
-
-public class ThaumcraftApiHelper
-{
-
- public static AspectList cullTags(AspectList temp)
- {
- final AspectList temp2 = new AspectList();
- for(final Aspect tag : temp.getAspects())
- {
- if(tag != null)
- {
- temp2.add(tag, temp.getAmount(tag));
- }
- }
- while(temp2 != null && temp2.size() > 6)
- {
- Aspect lowest = null;
- float low = Short.MAX_VALUE;
- for(final Aspect tag : temp2.getAspects())
- {
- if(tag == null)
- {
- continue;
- }
- float ta = temp2.getAmount(tag);
- if(tag.isPrimal())
- {
- ta *= .9f;
- }
- else
- {
- if(!tag.getComponents()[0].isPrimal())
- {
- ta *= 1.1f;
- if(!tag.getComponents()[0].getComponents()[0].isPrimal())
- {
- ta *= 1.05f;
- }
- if(!tag.getComponents()[0].getComponents()[1].isPrimal())
- {
- ta *= 1.05f;
- }
- }
- if(!tag.getComponents()[1].isPrimal())
- {
- ta *= 1.1f;
- if(!tag.getComponents()[1].getComponents()[0].isPrimal())
- {
- ta *= 1.05f;
- }
- if(!tag.getComponents()[1].getComponents()[1].isPrimal())
- {
- ta *= 1.05f;
- }
- }
- }
-
- if(ta < low)
- {
- low = ta;
- lowest = tag;
- }
- }
- temp2.aspects.remove(lowest);
- }
- return temp2;
- }
-
- public static boolean areItemsEqual(ItemStack s1, ItemStack s2)
- {
- if(s1.isItemStackDamageable() && s2.isItemStackDamageable())
- {
- return s1.getItem() == s2.getItem();
- }
- else
- {
- return s1.getItem() == s2.getItem() && s1.getItemDamage() == s2.getItemDamage();
- }
- }
-
- public static boolean isResearchComplete(String username, String researchkey)
- {
- return ThaumcraftApi.internalMethods.isResearchComplete(username, researchkey);
- }
-
- public static boolean hasDiscoveredAspect(String username, Aspect aspect)
- {
- return ThaumcraftApi.internalMethods.hasDiscoveredAspect(username, aspect);
- }
-
- public static AspectList getDiscoveredAspects(String username)
- {
- return ThaumcraftApi.internalMethods.getDiscoveredAspects(username);
- }
-
- public static ItemStack getStackInRowAndColumn(Object instance, int row, int column)
- {
- return ThaumcraftApi.internalMethods.getStackInRowAndColumn(instance, row, column);
- }
-
- public static AspectList getObjectAspects(ItemStack is)
- {
- return ThaumcraftApi.internalMethods.getObjectAspects(is);
- }
-
- public static AspectList getBonusObjectTags(ItemStack is, AspectList ot)
- {
- return ThaumcraftApi.internalMethods.getBonusObjectTags(is, ot);
- }
-
- public static AspectList generateTags(Item item, int meta)
- {
- return ThaumcraftApi.internalMethods.generateTags(item, meta);
- }
-
- public static boolean containsMatch(boolean strict, ItemStack[] inputs, ItemStack... targets)
- {
- for(final ItemStack input : inputs)
- {
- for(final ItemStack target : targets)
- {
- if(itemMatches(target, input, strict))
- {
- return true;
- }
- }
- }
- return false;
- }
-
- public static boolean areItemStackTagsEqualForCrafting(ItemStack slotItem, ItemStack recipeItem)
- {
- if(recipeItem == null || slotItem == null)
- {
- return false;
- }
- if(recipeItem.stackTagCompound != null && slotItem.stackTagCompound == null)
- {
- return false;
- }
- if(recipeItem.stackTagCompound == null)
- {
- return true;
- }
-
- final Iterator iterator = recipeItem.stackTagCompound.func_150296_c().iterator();
- while(iterator.hasNext())
- {
- final String s = (String) iterator.next();
- if(slotItem.stackTagCompound.hasKey(s))
- {
- if(!slotItem.stackTagCompound.getTag(s).toString().equals(recipeItem.stackTagCompound.getTag(s).toString()))
- {
- return false;
- }
- }
- else
- {
- return false;
- }
-
- }
- return true;
- }
-
- public static boolean itemMatches(ItemStack target, ItemStack input, boolean strict)
- {
- if(input == null && target != null || input != null && target == null)
- {
- return false;
- }
- return(target.getItem() == input.getItem() && ((target.getItemDamage() == OreDictionary.WILDCARD_VALUE && !strict) || target.getItemDamage() == input.getItemDamage()));
- }
-
- public static TileEntity getConnectableTile(World world, int x, int y, int z, ForgeDirection face)
- {
- final TileEntity te = world.getTileEntity(x + face.offsetX, y + face.offsetY, z + face.offsetZ);
- if(te instanceof IEssentiaTransport && ((IEssentiaTransport) te).isConnectable(face.getOpposite()))
- {
- return te;
- }
- else
- {
- return null;
- }
- }
-
- public static TileEntity getConnectableTile(IBlockAccess world, int x, int y, int z, ForgeDirection face)
- {
- final TileEntity te = world.getTileEntity(x + face.offsetX, y + face.offsetY, z + face.offsetZ);
- if(te instanceof IEssentiaTransport && ((IEssentiaTransport) te).isConnectable(face.getOpposite()))
- {
- return te;
- }
- else
- {
- return null;
- }
- }
-
- private static HashMap<Integer, AspectList> allAspects = new HashMap<Integer, AspectList>();
- private static HashMap<Integer, AspectList> allCompoundAspects = new HashMap<Integer, AspectList>();
-
- public static AspectList getAllAspects(int amount)
- {
- if(allAspects.get(amount) == null)
- {
- final AspectList al = new AspectList();
- for(final Aspect aspect : Aspect.aspects.values())
- {
- al.add(aspect, amount);
- }
- allAspects.put(amount, al);
- }
- return allAspects.get(amount);
- }
-
- public static AspectList getAllCompoundAspects(int amount)
- {
- if(allCompoundAspects.get(amount) == null)
- {
- final AspectList al = new AspectList();
- for(final Aspect aspect : Aspect.getCompoundAspects())
- {
- al.add(aspect, amount);
- }
- allCompoundAspects.put(amount, al);
- }
- return allCompoundAspects.get(amount);
- }
-
- /**
- * Use to subtract vis from a wand for most operations
- * Wands store vis differently so "real" vis costs need to be multiplied by 100 before calling this method
- * @param wand the wand itemstack
- * @param player the player using the wand
- * @param cost the cost of the operation.
- * @param doit actually subtract the vis from the wand if true - if false just simulate the result
- * @param crafting is this a crafting operation or not - if
- * false then things like frugal and potency will apply to the costs
- * @return was the vis successfully subtracted
- */
- public static boolean consumeVisFromWand(ItemStack wand, EntityPlayer player, AspectList cost, boolean doit, boolean crafting)
- {
- return ThaumcraftApi.internalMethods.consumeVisFromWand(wand, player, cost, doit, crafting);
- }
-
- /**
- * Subtract vis for use by a crafting mechanic. Costs are calculated slightly
- * differently and things like the frugal enchant is ignored
- * Must NOT be multiplied by 100 - send the actual vis cost
- * @param wand the wand itemstack
- * @param player the player using the wand
- * @param cost the cost of the operation.
- * @param doit actually subtract the vis from the wand if true - if false just simulate the result
- * @return was the vis successfully subtracted
- */
- public static boolean consumeVisFromWandCrafting(ItemStack wand, EntityPlayer player, AspectList cost, boolean doit)
- {
- return ThaumcraftApi.internalMethods.consumeVisFromWandCrafting(wand, player, cost, doit);
- }
-
- /**
- * Subtract vis from a wand the player is carrying. Works like consumeVisFromWand in that actual vis
- * costs should be multiplied by 100. The costs are handled like crafting however and things like
- * frugal don't effect them
- * @param player the player using the wand
- * @param cost the cost of the operation.
- * @return was the vis successfully subtracted
- */
- public static boolean consumeVisFromInventory(EntityPlayer player, AspectList cost)
- {
- return ThaumcraftApi.internalMethods.consumeVisFromInventory(player, cost);
- }
-
- /**
- * This adds permanents or temporary warp to a player. It will automatically be synced clientside
- * @param player the player using the wand
- * @param amount how much warp to add. Negative amounts are only valid for temporary warp
- * @param temporary add temporary warp instead of permanent
- */
- public static void addWarpToPlayer(EntityPlayer player, int amount, boolean temporary)
- {
- ThaumcraftApi.internalMethods.addWarpToPlayer(player, amount, temporary);
- }
-
- /**
- * This "sticky" warp to a player. Sticky warp is permanent warp that can be removed.
- * It will automatically be synced clientside
- * @param player the player using the wand
- * @param amount how much warp to add. Can have negative amounts.
- */
- public static void addStickyWarpToPlayer(EntityPlayer player, int amount)
- {
- ThaumcraftApi.internalMethods.addStickyWarpToPlayer(player, amount);
- }
-
- public static MovingObjectPosition rayTraceIgnoringSource(World world, Vec3 v1, Vec3 v2, boolean bool1, boolean bool2, boolean bool3)
- {
- if(!Double.isNaN(v1.xCoord) && !Double.isNaN(v1.yCoord) && !Double.isNaN(v1.zCoord))
- {
- if(!Double.isNaN(v2.xCoord) && !Double.isNaN(v2.yCoord) && !Double.isNaN(v2.zCoord))
- {
- final int i = MathHelper.floor_double(v2.xCoord);
- final int j = MathHelper.floor_double(v2.yCoord);
- final int k = MathHelper.floor_double(v2.zCoord);
- int l = MathHelper.floor_double(v1.xCoord);
- int i1 = MathHelper.floor_double(v1.yCoord);
- int j1 = MathHelper.floor_double(v1.zCoord);
- world.getBlock(l, i1, j1);
- int k1 = world.getBlockMetadata(l, i1, j1);
-
- MovingObjectPosition movingobjectposition2 = null;
- k1 = 200;
-
- while(k1-- >= 0)
- {
- if(Double.isNaN(v1.xCoord) || Double.isNaN(v1.yCoord) || Double.isNaN(v1.zCoord))
- {
- return null;
- }
-
- if(l == i && i1 == j && j1 == k)
- {
- continue;
- }
-
- boolean flag6 = true;
- boolean flag3 = true;
- boolean flag4 = true;
- double d0 = 999.0D;
- double d1 = 999.0D;
- double d2 = 999.0D;
-
- if(i > l)
- {
- d0 = l + 1.0D;
- }
- else if(i < l)
- {
- d0 = l + 0.0D;
- }
- else
- {
- flag6 = false;
- }
-
- if(j > i1)
- {
- d1 = i1 + 1.0D;
- }
- else if(j < i1)
- {
- d1 = i1 + 0.0D;
- }
- else
- {
- flag3 = false;
- }
-
- if(k > j1)
- {
- d2 = j1 + 1.0D;
- }
- else if(k < j1)
- {
- d2 = j1 + 0.0D;
- }
- else
- {
- flag4 = false;
- }
-
- double d3 = 999.0D;
- double d4 = 999.0D;
- double d5 = 999.0D;
- final double d6 = v2.xCoord - v1.xCoord;
- final double d7 = v2.yCoord - v1.yCoord;
- final double d8 = v2.zCoord - v1.zCoord;
-
- if(flag6)
- {
- d3 = (d0 - v1.xCoord) / d6;
- }
-
- if(flag3)
- {
- d4 = (d1 - v1.yCoord) / d7;
- }
-
- if(flag4)
- {
- d5 = (d2 - v1.zCoord) / d8;
- }
-
- byte b0;
-
- if(d3 < d4 && d3 < d5)
- {
- if(i > l)
- {
- b0 = 4;
- }
- else
- {
- b0 = 5;
- }
-
- v1.xCoord = d0;
- v1.yCoord += d7 * d3;
- v1.zCoord += d8 * d3;
- }
- else if(d4 < d5)
- {
- if(j > i1)
- {
- b0 = 0;
- }
- else
- {
- b0 = 1;
- }
-
- v1.xCoord += d6 * d4;
- v1.yCoord = d1;
- v1.zCoord += d8 * d4;
- }
- else
- {
- if(k > j1)
- {
- b0 = 2;
- }
- else
- {
- b0 = 3;
- }
-
- v1.xCoord += d6 * d5;
- v1.yCoord += d7 * d5;
- v1.zCoord = d2;
- }
-
- final Vec3 vec32 = Vec3.createVectorHelper(v1.xCoord, v1.yCoord, v1.zCoord);
- l = (int) (vec32.xCoord = MathHelper.floor_double(v1.xCoord));
-
- if(b0 == 5)
- {
- --l;
- ++vec32.xCoord;
- }
-
- i1 = (int) (vec32.yCoord = MathHelper.floor_double(v1.yCoord));
-
- if(b0 == 1)
- {
- --i1;
- ++vec32.yCoord;
- }
-
- j1 = (int) (vec32.zCoord = MathHelper.floor_double(v1.zCoord));
-
- if(b0 == 3)
- {
- --j1;
- ++vec32.zCoord;
- }
-
- final Block block1 = world.getBlock(l, i1, j1);
- final int l1 = world.getBlockMetadata(l, i1, j1);
-
- if(!bool2 || block1.getCollisionBoundingBoxFromPool(world, l, i1, j1) != null)
- {
- if(block1.canCollideCheck(l1, bool1))
- {
- final MovingObjectPosition movingobjectposition1 = block1.collisionRayTrace(world, l, i1, j1, v1, v2);
-
- if(movingobjectposition1 != null)
- {
- return movingobjectposition1;
- }
- }
- else
- {
- movingobjectposition2 = new MovingObjectPosition(l,
- i1, j1, b0, v1, false);
- }
- }
- }
-
- return bool3 ? movingobjectposition2 : null;
- }
- else
- {
- return null;
- }
- }
- else
- {
- return null;
- }
- }
-}
diff --git a/src/api/java/thaumcraft/api/TileThaumcraft.java b/src/api/java/thaumcraft/api/TileThaumcraft.java
deleted file mode 100644
index 8bcb4c7..0000000
--- a/src/api/java/thaumcraft/api/TileThaumcraft.java
+++ /dev/null
@@ -1,64 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
-import net.minecraft.tileentity.TileEntity;
-
-/**
- *
- * @author azanor
- *
- * Custom tile entity class I use for most of my tile entities. Setup in such a way that only
- * the nbt data within readCustomNBT / writeCustomNBT will be sent to the client when the tile
- * updates. Apart from all the normal TE data that gets sent that is.
- *
- */
-public class TileThaumcraft extends TileEntity
-{
-
- //NBT stuff
-
- @Override
- public void readFromNBT(NBTTagCompound nbttagcompound)
- {
- super.readFromNBT(nbttagcompound);
- readCustomNBT(nbttagcompound);
- }
-
- public void readCustomNBT(NBTTagCompound nbttagcompound)
- {
- //TODO
- }
-
- @Override
- public void writeToNBT(NBTTagCompound nbttagcompound)
- {
- super.writeToNBT(nbttagcompound);
- writeCustomNBT(nbttagcompound);
- }
-
- public void writeCustomNBT(NBTTagCompound nbttagcompound)
- {
- //TODO
- }
-
- //Client Packet stuff
- @Override
- public Packet getDescriptionPacket()
- {
- final NBTTagCompound nbttagcompound = new NBTTagCompound();
- writeCustomNBT(nbttagcompound);
- return new S35PacketUpdateTileEntity(xCoord, yCoord,
- zCoord, -999, nbttagcompound);
- }
-
- @Override
- public void onDataPacket(NetworkManager net, S35PacketUpdateTileEntity pkt)
- {
- super.onDataPacket(net, pkt);
- readCustomNBT(pkt.func_148857_g());
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/WorldCoordinates.java b/src/api/java/thaumcraft/api/WorldCoordinates.java
deleted file mode 100644
index cab4082..0000000
--- a/src/api/java/thaumcraft/api/WorldCoordinates.java
+++ /dev/null
@@ -1,123 +0,0 @@
-package thaumcraft.api;
-
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-
-public class WorldCoordinates implements Comparable
-{
- public int x;
-
- /** the y coordinate */
- public int y;
-
- /** the z coordinate */
- public int z;
-
- public int dim;
-
- public WorldCoordinates()
- {
- }
-
- public WorldCoordinates(int par1, int par2, int par3, int d)
- {
- x = par1;
- y = par2;
- z = par3;
- dim = d;
- }
-
- public WorldCoordinates(TileEntity tile)
- {
- x = tile.xCoord;
- y = tile.yCoord;
- z = tile.zCoord;
- dim = tile.getWorldObj().provider.dimensionId;
- }
-
- public WorldCoordinates(WorldCoordinates par1ChunkCoordinates)
- {
- x = par1ChunkCoordinates.x;
- y = par1ChunkCoordinates.y;
- z = par1ChunkCoordinates.z;
- dim = par1ChunkCoordinates.dim;
- }
-
- @Override
- public boolean equals(Object par1Obj)
- {
- if(!(par1Obj instanceof WorldCoordinates))
- {
- return false;
- }
- else
- {
- final WorldCoordinates coordinates = (WorldCoordinates) par1Obj;
- return x == coordinates.x && y == coordinates.y && z == coordinates.z && dim == coordinates.dim;
- }
- }
-
- @Override
- public int hashCode()
- {
- return x + y << 8 + z << 16 + dim << 24;
- }
-
- /**
- * Compare the coordinate with another coordinate
- */
- public int compareWorldCoordinate(WorldCoordinates par1)
- {
- return dim == par1.dim ? (y == par1.y ? (z == par1.z ? x - par1.x : z - par1.z) : y - par1.y) : -1;
- }
-
- public void set(int par1, int par2, int par3, int d)
- {
- x = par1;
- y = par2;
- z = par3;
- dim = d;
- }
-
- /**
- * Returns the squared distance between this coordinates and the coordinates given as argument.
- */
- public float getDistanceSquared(int par1, int par2, int par3)
- {
- final float f = x - par1;
- final float f1 = y - par2;
- final float f2 = z - par3;
- return f * f + f1 * f1 + f2 * f2;
- }
-
- /**
- * Return the squared distance between this coordinates and the ChunkCoordinates given as argument.
- */
- public float getDistanceSquaredToWorldCoordinates(WorldCoordinates par1ChunkCoordinates)
- {
- return getDistanceSquared(par1ChunkCoordinates.x, par1ChunkCoordinates.y, par1ChunkCoordinates.z);
- }
-
- @Override
- public int compareTo(Object par1Obj)
- {
- return compareWorldCoordinate((WorldCoordinates) par1Obj);
- }
-
- public void readNBT(NBTTagCompound nbt)
- {
- x = nbt.getInteger("w_x");
- y = nbt.getInteger("w_y");
- z = nbt.getInteger("w_z");
- dim = nbt.getInteger("w_d");
- }
-
- public void writeNBT(NBTTagCompound nbt)
- {
- nbt.setInteger("w_x", x);
- nbt.setInteger("w_y", y);
- nbt.setInteger("w_z", z);
- nbt.setInteger("w_d", dim);
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/aspects/Aspect.java b/src/api/java/thaumcraft/api/aspects/Aspect.java
deleted file mode 100644
index c6c548e..0000000
--- a/src/api/java/thaumcraft/api/aspects/Aspect.java
+++ /dev/null
@@ -1,377 +0,0 @@
-package thaumcraft.api.aspects;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.LinkedHashMap;
-
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-
-import org.apache.commons.lang3.text.WordUtils;
-
-public class Aspect
-{
-
- String tag;
- Aspect[] components;
- int color;
- private String chatcolor;
- ResourceLocation image;
- int blend;
-
- /**
- * Use this constructor to register your own aspects.
- * @param tag the key that will be used to reference this aspect, as well as its latin display name
- * @param color color to display the tag in
- * @param components the aspects this one is formed from
- * @param image ResourceLocation pointing to a 32x32 icon of the aspect
- * @param blend GL11 blendmode (1 or 771). Used for rendering nodes. Default is 1
- */
- public Aspect(String tag, int color, Aspect[] components, ResourceLocation image, int blend)
- {
- if(aspects.containsKey(tag))
- {
- throw new IllegalArgumentException(tag + " already registered!");
- }
- this.tag = tag;
- this.components = components;
- this.color = color;
- this.image = image;
- this.blend = blend;
- aspects.put(tag, this);
- }
-
- /**
- * Shortcut constructor I use for the default aspects - you shouldn't be using this.
- */
- public Aspect(String tag, int color, Aspect[] components)
- {
- this(tag, color, components, new ResourceLocation("thaumcraft",
- "textures/aspects/" + tag.toLowerCase() + ".png"), 1);
- }
-
- /**
- * Shortcut constructor I use for the default aspects - you shouldn't be using this.
- */
- public Aspect(String tag, int color, Aspect[] components, int blend)
- {
- this(tag, color, components, new ResourceLocation("thaumcraft",
- "textures/aspects/" + tag.toLowerCase() + ".png"), blend);
- }
-
- /**
- * Shortcut constructor I use for the primal aspects -
- * you shouldn't use this as making your own primal aspects will break all the things.
- */
- public Aspect(String tag, int color, String chatcolor, int blend)
- {
- this(tag, color, (Aspect[]) null, blend);
- setChatcolor(chatcolor);
- }
-
- public int getColor()
- {
- return color;
- }
-
- public String getName()
- {
- return WordUtils.capitalizeFully(tag);
- }
-
- public String getLocalizedDescription()
- {
- return StatCollector.translateToLocal("tc.aspect." + tag);
- }
-
- public String getTag()
- {
- return tag;
- }
-
- public void setTag(String tag)
- {
- this.tag = tag;
- }
-
- public Aspect[] getComponents()
- {
- return components;
- }
-
- public void setComponents(Aspect[] components)
- {
- this.components = components;
- }
-
- public ResourceLocation getImage()
- {
- return image;
- }
-
- public static Aspect getAspect(String tag)
- {
- return aspects.get(tag);
- }
-
- public int getBlend()
- {
- return blend;
- }
-
- public void setBlend(int blend)
- {
- this.blend = blend;
- }
-
- public boolean isPrimal()
- {
- return getComponents() == null || getComponents().length != 2;
- }
-
- ///////////////////////////////
- public static ArrayList<Aspect> getPrimalAspects()
- {
- final ArrayList<Aspect> primals = new ArrayList<Aspect>();
- final Collection<Aspect> pa = aspects.values();
- for(final Aspect aspect : pa)
- {
- if(aspect.isPrimal())
- {
- primals.add(aspect);
- }
- }
- return primals;
- }
-
- public static ArrayList<Aspect> getCompoundAspects()
- {
- final ArrayList<Aspect> compounds = new ArrayList<Aspect>();
- final Collection<Aspect> pa = aspects.values();
- for(final Aspect aspect : pa)
- {
- if(!aspect.isPrimal())
- {
- compounds.add(aspect);
- }
- }
- return compounds;
- }
-
- public String getChatcolor()
- {
- return chatcolor;
- }
-
- public void setChatcolor(String chatcolor)
- {
- this.chatcolor = chatcolor;
- }
-
- ///////////////////////////////
- public static LinkedHashMap<String, Aspect> aspects = new LinkedHashMap<String, Aspect>();
-
- //PRIMAL
- public static final Aspect AIR = new Aspect("aer",
- 0xffff7e,
- "e", 1);
- public static final Aspect EARTH = new Aspect(
- "terra",
- 0x56c000,
- "2", 1);
- public static final Aspect FIRE = new Aspect(
- "ignis",
- 0xff5a01,
- "c", 1);
- public static final Aspect WATER = new Aspect(
- "aqua",
- 0x3cd4fc,
- "3", 1);
- public static final Aspect ORDER = new Aspect(
- "ordo",
- 0xd5d4ec,
- "7", 1);
- public static final Aspect ENTROPY = new Aspect(
- "perditio",
- 0x404040,
- "8", 771);
-
- //SECONDARY
- public static final Aspect VOID = new Aspect(
- "vacuos",
- 0x888888,
- new Aspect[] {AIR, ENTROPY},
- 771);
- public static final Aspect LIGHT = new Aspect(
- "lux",
- 0xfff663,
- new Aspect[] {AIR, FIRE});
- public static final Aspect WEATHER = new Aspect(
- "tempestas",
- 0xFFFFFF,
- new Aspect[] {AIR, WATER});
- public static final Aspect MOTION = new Aspect(
- "motus",
- 0xcdccf4,
- new Aspect[] {AIR, ORDER});
- public static final Aspect COLD = new Aspect(
- "gelum",
- 0xe1ffff,
- new Aspect[] {FIRE, ENTROPY});
- public static final Aspect CRYSTAL = new Aspect(
- "vitreus",
- 0x80ffff,
- new Aspect[] {EARTH, ORDER});
- public static final Aspect LIFE = new Aspect(
- "victus",
- 0xde0005,
- new Aspect[] {WATER, EARTH});
- public static final Aspect POISON = new Aspect(
- "venenum",
- 0x89f000,
- new Aspect[] {WATER, ENTROPY});
- public static final Aspect ENERGY = new Aspect(
- "potentia",
- 0xc0ffff,
- new Aspect[] {ORDER, FIRE});
- public static final Aspect EXCHANGE = new Aspect(
- "permutatio",
- 0x578357,
- new Aspect[] {ENTROPY, ORDER});
- // public static final Aspect ?? = new Aspect("??",0xcdccf4, new Aspect[] {AIR, EARTH});
- // public static final Aspect ?? = new Aspect("??",0xcdccf4, new Aspect[] {FIRE, EARTH});
- // public static final Aspect ?? = new Aspect("??",0xcdccf4, new Aspect[] {FIRE, WATER});
- // public static final Aspect ?? = new Aspect("??",0xcdccf4, new Aspect[] {ORDER, WATER});
- // public static final Aspect ?? = new Aspect("??",0xcdccf4, new Aspect[] {EARTH, ENTROPY});
-
- //TERTIARY
- public static final Aspect METAL = new Aspect(
- "metallum",
- 0xb5b5cd,
- new Aspect[] {EARTH, CRYSTAL});
- public static final Aspect DEATH = new Aspect(
- "mortuus",
- 0x887788,
- new Aspect[] {LIFE, ENTROPY});
- public static final Aspect FLIGHT = new Aspect(
- "volatus",
- 0xe7e7d7,
- new Aspect[] {AIR, MOTION});
- public static final Aspect DARKNESS = new Aspect(
- "tenebrae",
- 0x222222,
- new Aspect[] {VOID, LIGHT});
- public static final Aspect SOUL = new Aspect(
- "spiritus",
- 0xebebfb,
- new Aspect[] {LIFE, DEATH});
- public static final Aspect HEAL = new Aspect(
- "sano",
- 0xff2f34,
- new Aspect[] {LIFE, ORDER});
- public static final Aspect TRAVEL = new Aspect(
- "iter",
- 0xe0585b,
- new Aspect[] {MOTION, EARTH});
- public static final Aspect ELDRITCH = new Aspect(
- "alienis",
- 0x805080,
- new Aspect[] {VOID, DARKNESS});
- public static final Aspect MAGIC = new Aspect(
- "praecantatio",
- 0x9700c0,
- new Aspect[] {VOID, ENERGY});
- public static final Aspect AURA = new Aspect(
- "auram",
- 0xffc0ff,
- new Aspect[] {MAGIC, AIR});
- public static final Aspect TAINT = new Aspect(
- "vitium",
- 0x800080,
- new Aspect[] {MAGIC, ENTROPY});
- public static final Aspect SLIME = new Aspect(
- "limus",
- 0x01f800,
- new Aspect[] {LIFE, WATER});
- public static final Aspect PLANT = new Aspect(
- "herba",
- 0x01ac00,
- new Aspect[] {LIFE, EARTH});
- public static final Aspect TREE = new Aspect(
- "arbor",
- 0x876531,
- new Aspect[] {AIR, PLANT});
- public static final Aspect BEAST = new Aspect(
- "bestia",
- 0x9f6409,
- new Aspect[] {MOTION, LIFE});
- public static final Aspect FLESH = new Aspect(
- "corpus",
- 0xee478d,
- new Aspect[] {DEATH, BEAST});
- public static final Aspect UNDEAD = new Aspect(
- "exanimis",
- 0x3a4000,
- new Aspect[] {MOTION, DEATH});
- public static final Aspect MIND = new Aspect(
- "cognitio",
- 0xffc2b3,
- new Aspect[] {FIRE, SOUL});
- public static final Aspect SENSES = new Aspect(
- "sensus",
- 0x0fd9ff,
- new Aspect[] {AIR, SOUL});
- public static final Aspect MAN = new Aspect(
- "humanus",
- 0xffd7c0,
- new Aspect[] {BEAST, MIND});
- public static final Aspect CROP = new Aspect(
- "messis",
- 0xe1b371,
- new Aspect[] {PLANT, MAN});
- public static final Aspect MINE = new Aspect(
- "perfodio",
- 0xdcd2d8,
- new Aspect[] {MAN, EARTH});
- public static final Aspect TOOL = new Aspect(
- "instrumentum",
- 0x4040ee,
- new Aspect[] {MAN, ORDER});
- public static final Aspect HARVEST = new Aspect(
- "meto",
- 0xeead82,
- new Aspect[] {CROP, TOOL});
- public static final Aspect WEAPON = new Aspect(
- "telum",
- 0xc05050,
- new Aspect[] {TOOL, FIRE});
- public static final Aspect ARMOR = new Aspect(
- "tutamen",
- 0x00c0c0,
- new Aspect[] {TOOL, EARTH});
- public static final Aspect HUNGER = new Aspect(
- "fames",
- 0x9a0305,
- new Aspect[] {LIFE, VOID});
- public static final Aspect GREED = new Aspect(
- "lucrum",
- 0xe6be44,
- new Aspect[] {MAN, HUNGER});
- public static final Aspect CRAFT = new Aspect(
- "fabrico",
- 0x809d80,
- new Aspect[] {MAN, TOOL});
- public static final Aspect CLOTH = new Aspect(
- "pannus",
- 0xeaeac2,
- new Aspect[] {TOOL, BEAST});
- public static final Aspect MECHANISM = new Aspect(
- "machina",
- 0x8080a0,
- new Aspect[] {MOTION, TOOL});
- public static final Aspect TRAP = new Aspect(
- "vinculum",
- 0x9a8080,
- new Aspect[] {MOTION, ENTROPY});
-
-}
diff --git a/src/api/java/thaumcraft/api/aspects/AspectList.java b/src/api/java/thaumcraft/api/aspects/AspectList.java
deleted file mode 100644
index fb80b48..0000000
--- a/src/api/java/thaumcraft/api/aspects/AspectList.java
+++ /dev/null
@@ -1,358 +0,0 @@
-package thaumcraft.api.aspects;
-
-import java.io.Serializable;
-import java.util.LinkedHashMap;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.nbt.NBTTagList;
-import thaumcraft.api.ThaumcraftApiHelper;
-
-public class AspectList implements Serializable
-{
-
- public LinkedHashMap<Aspect, Integer> aspects = new LinkedHashMap<Aspect, Integer>(); //aspects associated with this object
-
- /**
- * this creates a new aspect list with preloaded values based off the aspects of the given item.
- * @param the itemstack of the given item
- */
- public AspectList(ItemStack stack)
- {
- try
- {
- final AspectList temp = ThaumcraftApiHelper.getObjectAspects(stack);
- if(temp != null)
- {
- for(final Aspect tag : temp.getAspects())
- {
- add(tag, temp.getAmount(tag));
- }
- }
- }
- catch(final Exception e)
- {
- }
- }
-
- public AspectList()
- {
- }
-
- public AspectList copy()
- {
- final AspectList out = new AspectList();
- for(final Aspect a : getAspects())
- {
- out.add(a, getAmount(a));
- }
- return out;
- }
-
- /**
- * @return the amount of different aspects in this collection
- */
- public int size()
- {
- return aspects.size();
- }
-
- /**
- * @return the amount of total vis in this collection
- */
- public int visSize()
- {
- int q = 0;
-
- for(final Aspect as : aspects.keySet())
- {
- q += getAmount(as);
- }
-
- return q;
- }
-
- /**
- * @return an array of all the aspects in this collection
- */
- public Aspect[] getAspects()
- {
- final Aspect[] q = new Aspect[1];
- return aspects.keySet().toArray(q);
- }
-
- /**
- * @return an array of all the aspects in this collection
- */
- public Aspect[] getPrimalAspects()
- {
- final AspectList t = new AspectList();
- for(final Aspect as : aspects.keySet())
- {
- if(as.isPrimal())
- {
- t.add(as, 1);
- }
- }
- final Aspect[] q = new Aspect[1];
- return t.aspects.keySet().toArray(q);
- }
-
- /**
- * @return an array of all the aspects in this collection sorted by name
- */
- public Aspect[] getAspectsSorted()
- {
- try
- {
- final Aspect[] out = aspects.keySet().toArray(new Aspect[] {});
- boolean change = false;
- do
- {
- change = false;
- for(int a = 0; a < out.length - 1; a++)
- {
- final Aspect e1 = out[a];
- final Aspect e2 = out[a + 1];
- if(e1 != null && e2 != null && e1.getTag().compareTo(e2.getTag()) > 0)
- {
- out[a] = e2;
- out[a + 1] = e1;
- change = true;
- break;
- }
- }
- }
- while(change == true);
- return out;
- }
- catch(final Exception e)
- {
- return getAspects();
- }
- }
-
- /**
- * @return an array of all the aspects in this collection sorted by amount
- */
- public Aspect[] getAspectsSortedAmount()
- {
- try
- {
- final Aspect[] out = aspects.keySet().toArray(new Aspect[1]);
- boolean change = false;
- do
- {
- change = false;
- for(int a = 0; a < out.length - 1; a++)
- {
- final int e1 = getAmount(out[a]);
- final int e2 = getAmount(out[a + 1]);
- if(e1 > 0 && e2 > 0 && e2 > e1)
- {
- final Aspect ea = out[a];
- final Aspect eb = out[a + 1];
- out[a] = eb;
- out[a + 1] = ea;
- change = true;
- break;
- }
- }
- }
- while(change == true);
- return out;
- }
- catch(final Exception e)
- {
- return getAspects();
- }
- }
-
- /**
- * @param key
- * @return the amount associated with the given aspect in this collection
- */
- public int getAmount(Aspect key)
- {
- return aspects.get(key) == null ? 0 : aspects.get(key);
- }
-
- /**
- * Reduces the amount of an aspect in this collection by the given amount.
- * @param key
- * @param amount
- * @return
- */
- public boolean reduce(Aspect key, int amount)
- {
- if(getAmount(key) >= amount)
- {
- final int am = getAmount(key) - amount;
- aspects.put(key, am);
- return true;
- }
- return false;
- }
-
- /**
- * Reduces the amount of an aspect in this collection by the given amount.
- * If reduced to 0 or less the aspect will be removed completely.
- * @param key
- * @param amount
- * @return
- */
- public AspectList remove(Aspect key, int amount)
- {
- final int am = getAmount(key) - amount;
- if(am <= 0)
- {
- aspects.remove(key);
- }
- else
- {
- aspects.put(key, am);
- }
- return this;
- }
-
- /**
- * Simply removes the aspect from the list
- * @param key
- * @param amount
- * @return
- */
- public AspectList remove(Aspect key)
- {
- aspects.remove(key);
- return this;
- }
-
- /**
- * Adds this aspect and amount to the collection.
- * If the aspect exists then its value will be increased by the given amount.
- * @param aspect
- * @param amount
- * @return
- */
- public AspectList add(Aspect aspect, int amount)
- {
- if(aspects.containsKey(aspect))
- {
- final int oldamount = aspects.get(aspect);
- amount += oldamount;
- }
- aspects.put(aspect, amount);
- return this;
- }
-
- /**
- * Adds this aspect and amount to the collection.
- * If the aspect exists then only the highest of the old or new amount will be used.
- * @param aspect
- * @param amount
- * @return
- */
- public AspectList merge(Aspect aspect, int amount)
- {
- if(aspects.containsKey(aspect))
- {
- final int oldamount = aspects.get(aspect);
- if(amount < oldamount)
- {
- amount = oldamount;
- }
-
- }
- aspects.put(aspect, amount);
- return this;
- }
-
- public AspectList add(AspectList in)
- {
- for(final Aspect a : in.getAspects())
- {
- this.add(a, in.getAmount(a));
- }
- return this;
- }
-
- public AspectList merge(AspectList in)
- {
- for(final Aspect a : in.getAspects())
- {
- this.merge(a, in.getAmount(a));
- }
- return this;
- }
-
- /**
- * Reads the list of aspects from nbt
- * @param nbttagcompound
- * @return
- */
- public void readFromNBT(NBTTagCompound nbttagcompound)
- {
- aspects.clear();
- final NBTTagList tlist = nbttagcompound.getTagList("Aspects", (byte) 10);
- for(int j = 0; j < tlist.tagCount(); j++)
- {
- final NBTTagCompound rs = tlist.getCompoundTagAt(j);
- if(rs.hasKey("key"))
- {
- add(Aspect.getAspect(rs.getString("key")), rs.getInteger("amount"));
- }
- }
- }
-
- public void readFromNBT(NBTTagCompound nbttagcompound, String label)
- {
- aspects.clear();
- final NBTTagList tlist = nbttagcompound.getTagList(label, (byte) 10);
- for(int j = 0; j < tlist.tagCount(); j++)
- {
- final NBTTagCompound rs = tlist.getCompoundTagAt(j);
- if(rs.hasKey("key"))
- {
- add(Aspect.getAspect(rs.getString("key")), rs.getInteger("amount"));
- }
- }
- }
-
- /**
- * Writes the list of aspects to nbt
- * @param nbttagcompound
- * @return
- */
- public void writeToNBT(NBTTagCompound nbttagcompound)
- {
- final NBTTagList tlist = new NBTTagList();
- nbttagcompound.setTag("Aspects", tlist);
- for(final Aspect aspect : getAspects())
- {
- if(aspect != null)
- {
- final NBTTagCompound f = new NBTTagCompound();
- f.setString("key", aspect.getTag());
- f.setInteger("amount", getAmount(aspect));
- tlist.appendTag(f);
- }
- }
- }
-
- public void writeToNBT(NBTTagCompound nbttagcompound, String label)
- {
- final NBTTagList tlist = new NBTTagList();
- nbttagcompound.setTag(label, tlist);
- for(final Aspect aspect : getAspects())
- {
- if(aspect != null)
- {
- final NBTTagCompound f = new NBTTagCompound();
- f.setString("key", aspect.getTag());
- f.setInteger("amount", getAmount(aspect));
- tlist.appendTag(f);
- }
- }
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/aspects/AspectSourceHelper.java b/src/api/java/thaumcraft/api/aspects/AspectSourceHelper.java
deleted file mode 100644
index 03abe6c..0000000
--- a/src/api/java/thaumcraft/api/aspects/AspectSourceHelper.java
+++ /dev/null
@@ -1,70 +0,0 @@
-package thaumcraft.api.aspects;
-
-import java.lang.reflect.Method;
-
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.util.ForgeDirection;
-import cpw.mods.fml.common.FMLLog;
-
-public class AspectSourceHelper
-{
-
- static Method drainEssentia;
- static Method findEssentia;
-
- /**
- * This method is what is used to drain essentia from jars and other sources for things like
- * infusion crafting or powering the arcane furnace. A record of possible sources are kept track of
- * and refreshed as needed around the calling tile entity. This also renders the essentia trail particles.
- * Only 1 essentia is drained at a time
- * @param tile the tile entity that is draining the essentia
- * @param aspect the aspect that you are looking for
- * @param direction the direction from which you wish to drain. Forgedirection.Unknown simply seeks in all directions.
- * @param range how many blocks you wish to search for essentia sources.
- * @return boolean returns true if essentia was found and removed from a source.
- */
- public static boolean drainEssentia(TileEntity tile, Aspect aspect, ForgeDirection direction, int range)
- {
- try
- {
- if(drainEssentia == null)
- {
- final Class fake = Class.forName("thaumcraft.common.lib.events.EssentiaHandler");
- drainEssentia = fake.getMethod("drainEssentia", TileEntity.class, Aspect.class, ForgeDirection.class, int.class);
- }
- return (Boolean) drainEssentia.invoke(null, tile, aspect, direction, range);
- }
- catch(final Exception ex)
- {
- FMLLog.warning("[Thaumcraft API] Could not invoke thaumcraft.common.lib.events.EssentiaHandler method drainEssentia");
- }
- return false;
- }
-
- /**
- * This method returns if there is any essentia of the passed type that can be drained. It in no way checks how
- * much there is, only if an essentia container nearby contains at least 1 point worth.
- * @param tile the tile entity that is checking the essentia
- * @param aspect the aspect that you are looking for
- * @param direction the direction from which you wish to drain. Forgedirection.Unknown simply seeks in all directions.
- * @param range how many blocks you wish to search for essentia sources.
- * @return boolean returns true if essentia was found and removed from a source.
- */
- public static boolean findEssentia(TileEntity tile, Aspect aspect, ForgeDirection direction, int range)
- {
- try
- {
- if(findEssentia == null)
- {
- final Class fake = Class.forName("thaumcraft.common.lib.events.EssentiaHandler");
- findEssentia = fake.getMethod("findEssentia", TileEntity.class, Aspect.class, ForgeDirection.class, int.class);
- }
- return (Boolean) findEssentia.invoke(null, tile, aspect, direction, range);
- }
- catch(final Exception ex)
- {
- FMLLog.warning("[Thaumcraft API] Could not invoke thaumcraft.common.lib.events.EssentiaHandler method findEssentia");
- }
- return false;
- }
-}
diff --git a/src/api/java/thaumcraft/api/aspects/IAspectContainer.java b/src/api/java/thaumcraft/api/aspects/IAspectContainer.java
deleted file mode 100644
index 6b34db3..0000000
--- a/src/api/java/thaumcraft/api/aspects/IAspectContainer.java
+++ /dev/null
@@ -1,75 +0,0 @@
-package thaumcraft.api.aspects;
-
-/**
- *
- * @author azanor
- *
- * Used by blocks like the crucible and alembic to hold their aspects.
- * Tiles extending this interface will have their aspects show up when viewed by goggles of revealing
- *
- */
-public interface IAspectContainer
-{
- public AspectList getAspects();
-
- public void setAspects(AspectList aspects);
-
- /**
- * This method is used to determine of a specific aspect can be added to this container.
- * @param tag
- * @return true or false
- */
- public boolean doesContainerAccept(Aspect tag);
-
- /**
- * This method is used to add a certain amount of an aspect to the tile entity.
- * @param tag
- * @param amount
- * @return the amount of aspect left over that could not be added.
- */
- public int addToContainer(Aspect tag, int amount);
-
- /**
- * Removes a certain amount of a specific aspect from the tile entity
- * @param tag
- * @param amount
- * @return true if that amount of aspect was available and was removed
- */
- public boolean takeFromContainer(Aspect tag, int amount);
-
- /**
- * removes a bunch of different aspects and amounts from the tile entity.
- * @param ot the ObjectTags object that contains the aspects and their amounts.
- * @return true if all the aspects and their amounts were available and successfully removed
- *
- * Going away in the next major patch
- */
- @Deprecated
- public boolean takeFromContainer(AspectList ot);
-
- /**
- * Checks if the tile entity contains the listed amount (or more) of the aspect
- * @param tag
- * @param amount
- * @return
- */
- public boolean doesContainerContainAmount(Aspect tag, int amount);
-
- /**
- * Checks if the tile entity contains all the listed aspects and their amounts
- * @param ot the ObjectTags object that contains the aspects and their amounts.
- * @return
- *
- * Going away in the next major patch
- */
- @Deprecated
- public boolean doesContainerContain(AspectList ot);
-
- /**
- * Returns how much of the aspect this tile entity contains
- * @param tag
- * @return the amount of that aspect found
- */
- public int containerContains(Aspect tag);
-
-}
diff --git a/src/api/java/thaumcraft/api/aspects/IAspectSource.java b/src/api/java/thaumcraft/api/aspects/IAspectSource.java
deleted file mode 100644
index a24ffdd..0000000
--- a/src/api/java/thaumcraft/api/aspects/IAspectSource.java
+++ /dev/null
@@ -1,13 +0,0 @@
-package thaumcraft.api.aspects;
-
-/**
- * @author Azanor
- *
- * This interface is implemented by tile entites (or possibly anything else) like jars
- * so that they can act as an essentia source for blocks like the infusion altar.
- *
- */
-public interface IAspectSource extends IAspectContainer
-{
-
-}
diff --git a/src/api/java/thaumcraft/api/aspects/IEssentiaContainerItem.java b/src/api/java/thaumcraft/api/aspects/IEssentiaContainerItem.java
deleted file mode 100644
index fba289a..0000000
--- a/src/api/java/thaumcraft/api/aspects/IEssentiaContainerItem.java
+++ /dev/null
@@ -1,38 +0,0 @@
-package thaumcraft.api.aspects;
-
-import net.minecraft.item.ItemStack;
-
-/**
- *
- * @author azanor
- *
- * Used by wispy essences and essentia phials to hold their aspects.
- * Useful for similar item containers that store their aspect information in nbt form so TC
- * automatically picks up the aspects they contain
- *
- */
-public interface IEssentiaContainerItem
-{
- public AspectList getAspects(ItemStack itemstack);
-
- public void setAspects(ItemStack itemstack, AspectList aspects);
-}
-
-//Example implementation
-/*
- @Override
- public AspectList getAspects(ItemStack itemstack) {
- if (itemstack.hasTagCompound()) {
- AspectList aspects = new AspectList();
- aspects.readFromNBT(itemstack.getTagCompound());
- return aspects.size()>0?aspects:null;
- }
- return null;
- }
-
- @Override
- public void setAspects(ItemStack itemstack, AspectList aspects) {
- if (!itemstack.hasTagCompound()) itemstack.setTagCompound(new NBTTagCompound());
- aspects.writeToNBT(itemstack.getTagCompound());
- }
- */
diff --git a/src/api/java/thaumcraft/api/aspects/IEssentiaTransport.java b/src/api/java/thaumcraft/api/aspects/IEssentiaTransport.java
deleted file mode 100644
index 5e69de5..0000000
--- a/src/api/java/thaumcraft/api/aspects/IEssentiaTransport.java
+++ /dev/null
@@ -1,95 +0,0 @@
-package thaumcraft.api.aspects;
-
-import net.minecraftforge.common.util.ForgeDirection;
-
-/**
- * @author Azanor
- * This interface is used by tiles that use or transport vis.
- * Only tiles that implement this interface will be able to connect to vis conduits or other thaumic devices
- */
-public interface IEssentiaTransport
-{
- /**
- * Is this tile able to connect to other vis users/sources on the specified side?
- * @param face
- * @return
- */
- public boolean isConnectable(ForgeDirection face);
-
- /**
- * Is this side used to input essentia?
- * @param face
- * @return
- */
- boolean canInputFrom(ForgeDirection face);
-
- /**
- * Is this side used to output essentia?
- * @param face
- * @return
- */
- boolean canOutputTo(ForgeDirection face);
-
- /**
- * Sets the amount of suction this block will apply
- * @param suction
- */
- public void setSuction(Aspect aspect, int amount);
-
- /**
- * Returns the type of suction this block is applying.
- * @param loc
- * the location from where the suction is being checked
- * @return
- * a return type of null indicates the suction is untyped and the first thing available will be drawn
- */
- public Aspect getSuctionType(ForgeDirection face);
-
- /**
- * Returns the strength of suction this block is applying.
- * @param loc
- * the location from where the suction is being checked
- * @return
- */
- public int getSuctionAmount(ForgeDirection face);
-
- /**
- * remove the specified amount of essentia from this transport tile
- * @return how much was actually taken
- */
- public int takeEssentia(Aspect aspect, int amount, ForgeDirection face);
-
- /**
- * add the specified amount of essentia to this transport tile
- * @return how much was actually added
- */
- public int addEssentia(Aspect aspect, int amount, ForgeDirection face);
-
- /**
- * What type of essentia this contains
- * @param face
- * @return
- */
- public Aspect getEssentiaType(ForgeDirection face);
-
- /**
- * How much essentia this block contains
- * @param face
- * @return
- */
- public int getEssentiaAmount(ForgeDirection face);
-
- /**
- * Essentia will not be drawn from this container unless the suction exceeds this amount.
- * @return the amount
- */
- public int getMinimumSuction();
-
- /**
- * Return true if you want the conduit to extend a little further into the block.
- * Used by jars and alembics that have smaller than normal hitboxes
- * @return
- */
- boolean renderExtendedTube();
-
-}
diff --git a/src/api/java/thaumcraft/api/crafting/CrucibleRecipe.java b/src/api/java/thaumcraft/api/crafting/CrucibleRecipe.java
deleted file mode 100644
index 725e21a..0000000
--- a/src/api/java/thaumcraft/api/crafting/CrucibleRecipe.java
+++ /dev/null
@@ -1,116 +0,0 @@
-package thaumcraft.api.crafting;
-
-import java.util.ArrayList;
-
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
-import thaumcraft.api.ThaumcraftApiHelper;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-
-public class CrucibleRecipe
-{
-
- private final ItemStack recipeOutput;
-
- public Object catalyst;
- public AspectList aspects;
- public String key;
-
- public int hash;
-
- public CrucibleRecipe(String researchKey, ItemStack result, Object cat, AspectList tags)
- {
- recipeOutput = result;
- aspects = tags;
- key = researchKey;
- catalyst = cat;
- if(cat instanceof String)
- {
- catalyst = OreDictionary.getOres((String) cat);
- }
- String hc = researchKey + result.toString();
- for(final Aspect tag : tags.getAspects())
- {
- hc += tag.getTag() + tags.getAmount(tag);
- }
- if(cat instanceof ItemStack)
- {
- hc += ((ItemStack) cat).toString();
- }
- else if(cat instanceof ArrayList && ((ArrayList<ItemStack>) catalyst).size() > 0)
- {
- for(final ItemStack is : (ArrayList<ItemStack>) catalyst)
- {
- hc += is.toString();
- }
- }
-
- hash = hc.hashCode();
- }
-
- public boolean matches(AspectList itags, ItemStack cat)
- {
- if(catalyst instanceof ItemStack && !ThaumcraftApiHelper.itemMatches((ItemStack) catalyst, cat, false))
- {
- return false;
- }
- else if(catalyst instanceof ArrayList && ((ArrayList<ItemStack>) catalyst).size() > 0)
- {
- final ItemStack[] ores = ((ArrayList<ItemStack>) catalyst).toArray(new ItemStack[] {});
- if(!ThaumcraftApiHelper.containsMatch(false, new ItemStack[] {cat}, ores))
- {
- return false;
- }
- }
- if(itags == null)
- {
- return false;
- }
- for(final Aspect tag : aspects.getAspects())
- {
- if(itags.getAmount(tag) < aspects.getAmount(tag))
- {
- return false;
- }
- }
- return true;
- }
-
- public boolean catalystMatches(ItemStack cat)
- {
- if(catalyst instanceof ItemStack && ThaumcraftApiHelper.itemMatches((ItemStack) catalyst, cat, false))
- {
- return true;
- }
- else if(catalyst instanceof ArrayList && ((ArrayList<ItemStack>) catalyst).size() > 0)
- {
- final ItemStack[] ores = ((ArrayList<ItemStack>) catalyst).toArray(new ItemStack[] {});
- if(ThaumcraftApiHelper.containsMatch(false, new ItemStack[] {cat}, ores))
- {
- return true;
- }
- }
- return false;
- }
-
- public AspectList removeMatching(AspectList itags)
- {
- final AspectList temptags = new AspectList();
- temptags.aspects.putAll(itags.aspects);
-
- for(final Aspect tag : aspects.getAspects())
- {
- temptags.remove(tag, aspects.getAmount(tag));
- }
-
- itags = temptags;
- return itags;
- }
-
- public ItemStack getRecipeOutput()
- {
- return recipeOutput;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/crafting/IArcaneRecipe.java b/src/api/java/thaumcraft/api/crafting/IArcaneRecipe.java
deleted file mode 100644
index 1b0a933..0000000
--- a/src/api/java/thaumcraft/api/crafting/IArcaneRecipe.java
+++ /dev/null
@@ -1,36 +0,0 @@
-package thaumcraft.api.crafting;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import thaumcraft.api.aspects.AspectList;
-
-public interface IArcaneRecipe
-{
-
- /**
- * Used to check if a recipe matches current crafting inventory
- * @param player
- */
- boolean matches(IInventory var1, World world, EntityPlayer player);
-
- /**
- * Returns an Item that is the result of this recipe
- */
- ItemStack getCraftingResult(IInventory var1);
-
- /**
- * Returns the size of the recipe area
- */
- int getRecipeSize();
-
- ItemStack getRecipeOutput();
-
- AspectList getAspects();
-
- AspectList getAspects(IInventory var1);
-
- String getResearch();
-
-}
diff --git a/src/api/java/thaumcraft/api/crafting/IInfusionStabiliser.java b/src/api/java/thaumcraft/api/crafting/IInfusionStabiliser.java
deleted file mode 100644
index f0a1226..0000000
--- a/src/api/java/thaumcraft/api/crafting/IInfusionStabiliser.java
+++ /dev/null
@@ -1,20 +0,0 @@
-package thaumcraft.api.crafting;
-
-import net.minecraft.world.World;
-
-/**
- *
- * @author Azanor
- *
- * Blocks that implement this interface act as infusion crafting stabilisers like candles and skulls
- *
- */
-public interface IInfusionStabiliser
-{
-
- /**
- * returns true if the block can stabilise things
- */
- public boolean canStabaliseInfusion(World world, int x, int y, int z);
-
-}
diff --git a/src/api/java/thaumcraft/api/crafting/InfusionEnchantmentRecipe.java b/src/api/java/thaumcraft/api/crafting/InfusionEnchantmentRecipe.java
deleted file mode 100644
index 60ed52e..0000000
--- a/src/api/java/thaumcraft/api/crafting/InfusionEnchantmentRecipe.java
+++ /dev/null
@@ -1,188 +0,0 @@
-package thaumcraft.api.crafting;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.Map;
-
-import net.minecraft.enchantment.Enchantment;
-import net.minecraft.enchantment.EnchantmentHelper;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import net.minecraftforge.oredict.OreDictionary;
-import thaumcraft.api.ThaumcraftApiHelper;
-import thaumcraft.api.aspects.AspectList;
-
-public class InfusionEnchantmentRecipe
-{
-
- public AspectList aspects;
- public String research;
- public ItemStack[] components;
- public Enchantment enchantment;
- public int recipeXP;
- public int instability;
-
- public InfusionEnchantmentRecipe(String research, Enchantment input, int inst, AspectList aspects2, ItemStack[] recipe)
- {
- this.research = research;
- enchantment = input;
- aspects = aspects2;
- components = recipe;
- instability = inst;
- recipeXP = Math.max(1, input.getMinEnchantability(1) / 3);
- }
-
- /**
- * Used to check if a recipe matches current crafting inventory
- * @param player
- */
- public boolean matches(ArrayList<ItemStack> input, ItemStack central, World world, EntityPlayer player)
- {
- if(research.length() > 0 && !ThaumcraftApiHelper.isResearchComplete(player.getCommandSenderName(), research))
- {
- return false;
- }
-
- if(!enchantment.canApply(central) || !central.getItem().isItemTool(central))
- {
- return false;
- }
-
- final Map map1 = EnchantmentHelper.getEnchantments(central);
- final Iterator iterator = map1.keySet().iterator();
- while(iterator.hasNext())
- {
- final int j1 = ((Integer) iterator.next()).intValue();
- final Enchantment ench = Enchantment.enchantmentsList[j1];
- if(j1 == enchantment.effectId && EnchantmentHelper.getEnchantmentLevel(j1, central) >= ench.getMaxLevel())
- {
- return false;
- }
- if(enchantment.effectId != ench.effectId && (!enchantment.canApplyTogether(ench) || !ench.canApplyTogether(enchantment)))
- {
- return false;
- }
- }
-
- ItemStack i2 = null;
-
- final ArrayList<ItemStack> ii = new ArrayList<ItemStack>();
- for(final ItemStack is : input)
- {
- ii.add(is.copy());
- }
-
- for(final ItemStack comp : components)
- {
- boolean b = false;
- for(int a = 0; a < ii.size(); a++)
- {
- i2 = ii.get(a).copy();
- if(comp.getItemDamage() == OreDictionary.WILDCARD_VALUE)
- {
- i2.setItemDamage(OreDictionary.WILDCARD_VALUE);
- }
- if(areItemStacksEqual(i2, comp, true))
- {
- ii.remove(a);
- b = true;
- break;
- }
- }
- if(!b)
- {
- return false;
- }
- }
- // System.out.println(ii.size());
- return ii.size() == 0 ? true : false;
- }
-
- protected boolean areItemStacksEqual(ItemStack stack0, ItemStack stack1, boolean fuzzy)
- {
- if(stack0 == null && stack1 != null)
- {
- return false;
- }
- if(stack0 != null && stack1 == null)
- {
- return false;
- }
- if(stack0 == null && stack1 == null)
- {
- return true;
- }
- final boolean t1 = ThaumcraftApiHelper.areItemStackTagsEqualForCrafting(stack0, stack1);
- if(!t1)
- {
- return false;
- }
- if(fuzzy)
- {
- final Integer od = OreDictionary.getOreID(stack0);
- if(od != -1)
- {
- final ItemStack[] ores = OreDictionary.getOres(od).toArray(new ItemStack[] {});
- if(ThaumcraftApiHelper.containsMatch(false, new ItemStack[] {stack1}, ores))
- {
- return true;
- }
- }
- }
- return stack0.getItem() != stack1.getItem() ? false : (stack0.getItemDamage() != stack1.getItemDamage() ? false : stack0.stackSize <= stack0.getMaxStackSize());
- }
-
- public Enchantment getEnchantment()
- {
- return enchantment;
-
- }
-
- public AspectList getAspects()
- {
- return aspects;
-
- }
-
- public String getResearch()
- {
- return research;
-
- }
-
- public int calcInstability(ItemStack recipeInput)
- {
- int i = 0;
- final Map map1 = EnchantmentHelper.getEnchantments(recipeInput);
- final Iterator iterator = map1.keySet().iterator();
- while(iterator.hasNext())
- {
- final int j1 = ((Integer) iterator.next()).intValue();
- i += EnchantmentHelper.getEnchantmentLevel(j1, recipeInput);
- }
- return (i / 2) + instability;
- }
-
- public int calcXP(ItemStack recipeInput)
- {
- return recipeXP * (1 + EnchantmentHelper.getEnchantmentLevel(enchantment.effectId, recipeInput));
- }
-
- public float getEssentiaMod(ItemStack recipeInput)
- {
- float mod = EnchantmentHelper.getEnchantmentLevel(enchantment.effectId, recipeInput);
- final Map map1 = EnchantmentHelper.getEnchantments(recipeInput);
- final Iterator iterator = map1.keySet().iterator();
- while(iterator.hasNext())
- {
- final int j1 = ((Integer) iterator.next()).intValue();
- if(j1 != enchantment.effectId)
- {
- mod += EnchantmentHelper.getEnchantmentLevel(j1, recipeInput) * .1f;
- }
- }
- return mod;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/crafting/InfusionRecipe.java b/src/api/java/thaumcraft/api/crafting/InfusionRecipe.java
deleted file mode 100644
index 93d1121..0000000
--- a/src/api/java/thaumcraft/api/crafting/InfusionRecipe.java
+++ /dev/null
@@ -1,174 +0,0 @@
-package thaumcraft.api.crafting;
-
-import java.util.ArrayList;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import net.minecraftforge.oredict.OreDictionary;
-import thaumcraft.api.ThaumcraftApiHelper;
-import thaumcraft.api.aspects.AspectList;
-
-public class InfusionRecipe
-{
- protected AspectList aspects;
- protected String research;
- private final ItemStack[] components;
- private final ItemStack recipeInput;
- protected Object recipeOutput;
- protected int instability;
-
- public InfusionRecipe(String research, Object output, int inst, AspectList aspects2, ItemStack input, ItemStack[] recipe)
- {
- this.research = research;
- recipeOutput = output;
- recipeInput = input;
- aspects = aspects2;
- components = recipe;
- instability = inst;
- }
-
- /**
- * Used to check if a recipe matches current crafting inventory
- * @param player
- */
- public boolean matches(ArrayList<ItemStack> input, ItemStack central, World world, EntityPlayer player)
- {
- if(getRecipeInput() == null)
- {
- return false;
- }
-
- if(research.length() > 0 && !ThaumcraftApiHelper.isResearchComplete(player.getCommandSenderName(), research))
- {
- return false;
- }
-
- ItemStack i2 = central.copy();
- if(getRecipeInput().getItemDamage() == OreDictionary.WILDCARD_VALUE)
- {
- i2.setItemDamage(OreDictionary.WILDCARD_VALUE);
- }
-
- if(!areItemStacksEqual(i2, getRecipeInput(), true))
- {
- return false;
- }
-
- final ArrayList<ItemStack> ii = new ArrayList<ItemStack>();
- for(final ItemStack is : input)
- {
- ii.add(is.copy());
- }
-
- for(final ItemStack comp : getComponents())
- {
- boolean b = false;
- for(int a = 0; a < ii.size(); a++)
- {
- i2 = ii.get(a).copy();
- if(comp.getItemDamage() == OreDictionary.WILDCARD_VALUE)
- {
- i2.setItemDamage(OreDictionary.WILDCARD_VALUE);
- }
- if(areItemStacksEqual(i2, comp, true))
- {
- ii.remove(a);
- b = true;
- break;
- }
- }
- if(!b)
- {
- return false;
- }
- }
- return ii.size() == 0 ? true : false;
- }
-
- public static boolean areItemStacksEqual(ItemStack stack0, ItemStack stack1, boolean fuzzy)
- {
- if(stack0 == null && stack1 != null)
- {
- return false;
- }
- if(stack0 != null && stack1 == null)
- {
- return false;
- }
- if(stack0 == null && stack1 == null)
- {
- return true;
- }
-
- //nbt
- final boolean t1 = ThaumcraftApiHelper.areItemStackTagsEqualForCrafting(stack0, stack1);
- if(!t1)
- {
- return false;
- }
-
- if(fuzzy)
- {
- final Integer od = OreDictionary.getOreID(stack0);
- if(od != -1)
- {
- final ItemStack[] ores = OreDictionary.getOres(od).toArray(new ItemStack[] {});
- if(ThaumcraftApiHelper.containsMatch(false, new ItemStack[] {stack1}, ores))
- {
- return true;
- }
- }
- }
-
- //damage
- final boolean damage = stack0.getItemDamage() == stack1.getItemDamage() || stack1.getItemDamage() == OreDictionary.WILDCARD_VALUE;
-
- return stack0.getItem() != stack1.getItem() ? false : (!damage ? false : stack0.stackSize <= stack0.getMaxStackSize());
- }
-
- public Object getRecipeOutput()
- {
- return getRecipeOutput(getRecipeInput());
- }
-
- public AspectList getAspects()
- {
- return getAspects(getRecipeInput());
- }
-
- public int getInstability()
- {
- return getInstability(getRecipeInput());
- }
-
- public String getResearch()
- {
- return research;
- }
-
- public ItemStack getRecipeInput()
- {
- return recipeInput;
- }
-
- public ItemStack[] getComponents()
- {
- return components;
- }
-
- public Object getRecipeOutput(ItemStack input)
- {
- return recipeOutput;
- }
-
- public AspectList getAspects(ItemStack input)
- {
- return aspects;
- }
-
- public int getInstability(ItemStack input)
- {
- return instability;
- }
-}
diff --git a/src/api/java/thaumcraft/api/crafting/ShapedArcaneRecipe.java b/src/api/java/thaumcraft/api/crafting/ShapedArcaneRecipe.java
deleted file mode 100644
index a76eed0..0000000
--- a/src/api/java/thaumcraft/api/crafting/ShapedArcaneRecipe.java
+++ /dev/null
@@ -1,281 +0,0 @@
-package thaumcraft.api.crafting;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import net.minecraftforge.oredict.OreDictionary;
-import thaumcraft.api.ThaumcraftApiHelper;
-import thaumcraft.api.aspects.AspectList;
-
-public class ShapedArcaneRecipe implements IArcaneRecipe
-{
- //Added in for future ease of change, but hard coded for now.
- private static final int MAX_CRAFT_GRID_WIDTH = 3;
- private static final int MAX_CRAFT_GRID_HEIGHT = 3;
-
- public ItemStack output = null;
- public Object[] input = null;
- public AspectList aspects = null;
- public String research;
- public int width = 0;
- public int height = 0;
- private boolean mirrored = true;
-
- public ShapedArcaneRecipe(String research, Block result, AspectList aspects, Object... recipe)
- {
- this(research, new ItemStack(result), aspects, recipe);
- }
-
- public ShapedArcaneRecipe(String research, Item result, AspectList aspects, Object... recipe)
- {
- this(research, new ItemStack(result), aspects, recipe);
- }
-
- public ShapedArcaneRecipe(String research, ItemStack result, AspectList aspects, Object... recipe)
- {
- output = result.copy();
- this.research = research;
- this.aspects = aspects;
- String shape = "";
-
- int idx = 0;
-
- if(recipe[idx] instanceof Boolean)
- {
- mirrored = (Boolean) recipe[idx];
- if(recipe[idx + 1] instanceof Object[])
- {
- recipe = (Object[]) recipe[idx + 1];
- }
- else
- {
- idx = 1;
- }
- }
-
- if(recipe[idx] instanceof String[])
- {
- final String[] parts = ((String[]) recipe[idx++]);
-
- for(final String s : parts)
- {
- width = s.length();
- shape += s;
- }
-
- height = parts.length;
- }
- else
- {
- while(recipe[idx] instanceof String)
- {
- final String s = (String) recipe[idx++];
- shape += s;
- width = s.length();
- height++;
- }
- }
-
- if(width * height != shape.length())
- {
- String ret = "Invalid shaped ore recipe: ";
- for(final Object tmp : recipe)
- {
- ret += tmp + ", ";
- }
- ret += output;
- throw new RuntimeException(ret);
- }
-
- final HashMap<Character, Object> itemMap = new HashMap<Character, Object>();
-
- for(; idx < recipe.length; idx += 2)
- {
- final Character chr = (Character) recipe[idx];
- final Object in = recipe[idx + 1];
-
- if(in instanceof ItemStack)
- {
- itemMap.put(chr, ((ItemStack) in).copy());
- }
- else if(in instanceof Item)
- {
- itemMap.put(chr, new ItemStack((Item) in));
- }
- else if(in instanceof Block)
- {
- itemMap.put(chr, new ItemStack((Block) in, 1,
- OreDictionary.WILDCARD_VALUE));
- }
- else if(in instanceof String)
- {
- itemMap.put(chr, OreDictionary.getOres((String) in));
- }
- else
- {
- String ret = "Invalid shaped ore recipe: ";
- for(final Object tmp : recipe)
- {
- ret += tmp + ", ";
- }
- ret += output;
- throw new RuntimeException(ret);
- }
- }
-
- input = new Object[width * height];
- int x = 0;
- for(final char chr : shape.toCharArray())
- {
- input[x++] = itemMap.get(chr);
- }
- }
-
- @Override
- public ItemStack getCraftingResult(IInventory var1)
- {
- return output.copy();
- }
-
- @Override
- public int getRecipeSize()
- {
- return input.length;
- }
-
- @Override
- public ItemStack getRecipeOutput()
- {
- return output;
- }
-
- @Override
- public boolean matches(IInventory inv, World world, EntityPlayer player)
- {
- if(research.length() > 0 && !ThaumcraftApiHelper.isResearchComplete(player.getCommandSenderName(), research))
- {
- return false;
- }
- for(int x = 0; x <= MAX_CRAFT_GRID_WIDTH - width; x++)
- {
- for(int y = 0; y <= MAX_CRAFT_GRID_HEIGHT - height; ++y)
- {
- if(checkMatch(inv, x, y, false))
- {
- return true;
- }
-
- if(mirrored && checkMatch(inv, x, y, true))
- {
- return true;
- }
- }
- }
-
- return false;
- }
-
- private boolean checkMatch(IInventory inv, int startX, int startY, boolean mirror)
- {
- for(int x = 0; x < MAX_CRAFT_GRID_WIDTH; x++)
- {
- for(int y = 0; y < MAX_CRAFT_GRID_HEIGHT; y++)
- {
- final int subX = x - startX;
- final int subY = y - startY;
- Object target = null;
-
- if(subX >= 0 && subY >= 0 && subX < width && subY < height)
- {
- if(mirror)
- {
- target = input[width - subX - 1 + subY * width];
- }
- else
- {
- target = input[subX + subY * width];
- }
- }
-
- final ItemStack slot = ThaumcraftApiHelper.getStackInRowAndColumn(inv, x, y);
-
- if(target instanceof ItemStack)
- {
- if(!checkItemEquals((ItemStack) target, slot))
- {
- return false;
- }
- }
- else if(target instanceof ArrayList)
- {
- boolean matched = false;
-
- for(final ItemStack item : (ArrayList<ItemStack>) target)
- {
- matched = matched || checkItemEquals(item, slot);
- }
-
- if(!matched)
- {
- return false;
- }
- }
- else if(target == null && slot != null)
- {
- return false;
- }
- }
- }
-
- return true;
- }
-
- private boolean checkItemEquals(ItemStack target, ItemStack input)
- {
- if(input == null && target != null || input != null && target == null)
- {
- return false;
- }
- return(target.getItem() == input.getItem() && (!target.hasTagCompound() || ThaumcraftApiHelper.areItemStackTagsEqualForCrafting(input, target)) && (target.getItemDamage() == OreDictionary.WILDCARD_VALUE || target.getItemDamage() == input.getItemDamage()));
- }
-
- public ShapedArcaneRecipe setMirrored(boolean mirror)
- {
- mirrored = mirror;
- return this;
- }
-
- /**
- * Returns the input for this recipe, any mod accessing this value should never
- * manipulate the values in this array as it will effect the recipe itself.
- * @return The recipes input vales.
- */
- public Object[] getInput()
- {
- return input;
- }
-
- @Override
- public AspectList getAspects()
- {
- return aspects;
- }
-
- @Override
- public AspectList getAspects(IInventory inv)
- {
- return aspects;
- }
-
- @Override
- public String getResearch()
- {
- return research;
- }
-}
diff --git a/src/api/java/thaumcraft/api/crafting/ShapelessArcaneRecipe.java b/src/api/java/thaumcraft/api/crafting/ShapelessArcaneRecipe.java
deleted file mode 100644
index d6890c1..0000000
--- a/src/api/java/thaumcraft/api/crafting/ShapelessArcaneRecipe.java
+++ /dev/null
@@ -1,179 +0,0 @@
-package thaumcraft.api.crafting;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import net.minecraftforge.oredict.OreDictionary;
-import thaumcraft.api.ThaumcraftApiHelper;
-import thaumcraft.api.aspects.AspectList;
-
-public class ShapelessArcaneRecipe implements IArcaneRecipe
-{
- private ItemStack output = null;
- private final ArrayList input = new ArrayList();
-
- public AspectList aspects = null;
- public String research;
-
- public ShapelessArcaneRecipe(String research, Block result, AspectList aspects, Object... recipe)
- {
- this(research, new ItemStack(result), aspects, recipe);
- }
-
- public ShapelessArcaneRecipe(String research, Item result, AspectList aspects, Object... recipe)
- {
- this(research, new ItemStack(result), aspects, recipe);
- }
-
- public ShapelessArcaneRecipe(String research, ItemStack result, AspectList aspects, Object... recipe)
- {
- output = result.copy();
- this.research = research;
- this.aspects = aspects;
- for(final Object in : recipe)
- {
- if(in instanceof ItemStack)
- {
- input.add(((ItemStack) in).copy());
- }
- else if(in instanceof Item)
- {
- input.add(new ItemStack((Item) in));
- }
- else if(in instanceof Block)
- {
- input.add(new ItemStack((Block) in));
- }
- else if(in instanceof String)
- {
- input.add(OreDictionary.getOres((String) in));
- }
- else
- {
- String ret = "Invalid shapeless ore recipe: ";
- for(final Object tmp : recipe)
- {
- ret += tmp + ", ";
- }
- ret += output;
- throw new RuntimeException(ret);
- }
- }
- }
-
- @Override
- public int getRecipeSize()
- {
- return input.size();
- }
-
- @Override
- public ItemStack getRecipeOutput()
- {
- return output;
- }
-
- @Override
- public ItemStack getCraftingResult(IInventory var1)
- {
- return output.copy();
- }
-
- @Override
- public boolean matches(IInventory var1, World world, EntityPlayer player)
- {
- if(research.length() > 0 && !ThaumcraftApiHelper.isResearchComplete(player.getCommandSenderName(), research))
- {
- return false;
- }
-
- final ArrayList required = new ArrayList(input);
-
- for(int x = 0; x < 9; x++)
- {
- final ItemStack slot = var1.getStackInSlot(x);
-
- if(slot != null)
- {
- boolean inRecipe = false;
- final Iterator req = required.iterator();
-
- while(req.hasNext())
- {
- boolean match = false;
-
- final Object next = req.next();
-
- if(next instanceof ItemStack)
- {
- match = checkItemEquals((ItemStack) next, slot);
- }
- else if(next instanceof ArrayList)
- {
- for(final ItemStack item : (ArrayList<ItemStack>) next)
- {
- match = match || checkItemEquals(item, slot);
- }
- }
-
- if(match)
- {
- inRecipe = true;
- required.remove(next);
- break;
- }
- }
-
- if(!inRecipe)
- {
- return false;
- }
- }
- }
-
- return required.isEmpty();
- }
-
- private boolean checkItemEquals(ItemStack target, ItemStack input)
- {
- if(input == null && target != null || input != null && target == null)
- {
- return false;
- }
- return(target.getItem() == input.getItem() && (!target.hasTagCompound() || ThaumcraftApiHelper.areItemStackTagsEqualForCrafting(input, target)) && (target.getItemDamage() == OreDictionary.WILDCARD_VALUE || target.getItemDamage() == input.getItemDamage()));
- }
-
- /**
- * Returns the input for this recipe, any mod accessing this value should never
- * manipulate the values in this array as it will effect the recipe itself.
- * @return The recipes input vales.
- */
- public ArrayList getInput()
- {
- return input;
- }
-
- @Override
- public AspectList getAspects()
- {
- return aspects;
- }
-
- @Override
- public AspectList getAspects(IInventory inv)
- {
- return aspects;
- }
-
- @Override
- public String getResearch()
- {
- return research;
- }
-}
diff --git a/src/api/java/thaumcraft/api/damagesource/DamageSourceIndirectThaumcraftEntity.java b/src/api/java/thaumcraft/api/damagesource/DamageSourceIndirectThaumcraftEntity.java
deleted file mode 100644
index 52fc3c3..0000000
--- a/src/api/java/thaumcraft/api/damagesource/DamageSourceIndirectThaumcraftEntity.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package thaumcraft.api.damagesource;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.util.DamageSource;
-import net.minecraft.util.EntityDamageSourceIndirect;
-
-public class DamageSourceIndirectThaumcraftEntity extends EntityDamageSourceIndirect
-{
-
- public DamageSourceIndirectThaumcraftEntity(String par1Str, Entity par2Entity, Entity par3Entity)
- {
- super(par1Str, par2Entity, par3Entity);
- }
-
- @Override
- public DamageSource setFireDamage()
- {
- return this;
- }
-
- @Override
- public DamageSource setDamageBypassesArmor()
- {
- return this;
- }
-}
diff --git a/src/api/java/thaumcraft/api/damagesource/DamageSourceThaumcraft.java b/src/api/java/thaumcraft/api/damagesource/DamageSourceThaumcraft.java
deleted file mode 100644
index a05f5c5..0000000
--- a/src/api/java/thaumcraft/api/damagesource/DamageSourceThaumcraft.java
+++ /dev/null
@@ -1,34 +0,0 @@
-package thaumcraft.api.damagesource;
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.util.DamageSource;
-import net.minecraft.util.EntityDamageSource;
-
-public class DamageSourceThaumcraft extends DamageSource
-{
-
- public static DamageSource taint = new DamageSourceThaumcraft(
- "taint").setDamageBypassesArmor().setMagicDamage();
- public static DamageSource tentacle = new DamageSourceThaumcraft(
- "tentacle");
- public static DamageSource swarm = new DamageSourceThaumcraft(
- "swarm");
- public static DamageSource dissolve = new DamageSourceThaumcraft(
- "dissolve").setDamageBypassesArmor();
-
- protected DamageSourceThaumcraft(String par1Str)
- {
- super(par1Str);
- }
-
- public static DamageSource causeSwarmDamage(EntityLivingBase par0EntityLiving)
- {
- return new EntityDamageSource("swarm", par0EntityLiving);
- }
-
- public static DamageSource causeTentacleDamage(EntityLivingBase par0EntityLiving)
- {
- return new EntityDamageSource("tentacle", par0EntityLiving);
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/entities/IEldritchMob.java b/src/api/java/thaumcraft/api/entities/IEldritchMob.java
deleted file mode 100644
index a23d228..0000000
--- a/src/api/java/thaumcraft/api/entities/IEldritchMob.java
+++ /dev/null
@@ -1,6 +0,0 @@
-package thaumcraft.api.entities;
-
-public interface IEldritchMob
-{
-
-}
diff --git a/src/api/java/thaumcraft/api/entities/ITaintedMob.java b/src/api/java/thaumcraft/api/entities/ITaintedMob.java
deleted file mode 100644
index 1b1b793..0000000
--- a/src/api/java/thaumcraft/api/entities/ITaintedMob.java
+++ /dev/null
@@ -1,6 +0,0 @@
-package thaumcraft.api.entities;
-
-public interface ITaintedMob
-{
-
-}
diff --git a/src/api/java/thaumcraft/api/internal/DummyInternalMethodHandler.java b/src/api/java/thaumcraft/api/internal/DummyInternalMethodHandler.java
deleted file mode 100644
index fcf31de..0000000
--- a/src/api/java/thaumcraft/api/internal/DummyInternalMethodHandler.java
+++ /dev/null
@@ -1,88 +0,0 @@
-package thaumcraft.api.internal;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-
-public class DummyInternalMethodHandler implements IInternalMethodHandler
-{
-
- @Override
- public void generateVisEffect(int dim, int x, int y, int z, int x2, int y2, int z2, int color)
- {
-
- }
-
- @Override
- public boolean isResearchComplete(String username, String researchkey)
- {
- return false;
- }
-
- @Override
- public boolean hasDiscoveredAspect(String username, Aspect aspect)
- {
- return false;
- }
-
- @Override
- public AspectList getDiscoveredAspects(String username)
- {
- return null;
- }
-
- @Override
- public ItemStack getStackInRowAndColumn(Object instance, int row, int column)
- {
- return null;
- }
-
- @Override
- public AspectList getObjectAspects(ItemStack is)
- {
- return null;
- }
-
- @Override
- public AspectList getBonusObjectTags(ItemStack is, AspectList ot)
- {
- return null;
- }
-
- @Override
- public AspectList generateTags(Item item, int meta)
- {
- return null;
- }
-
- @Override
- public boolean consumeVisFromWand(ItemStack wand, EntityPlayer player, AspectList cost, boolean doit, boolean crafting)
- {
- return false;
- }
-
- @Override
- public boolean consumeVisFromWandCrafting(ItemStack wand, EntityPlayer player, AspectList cost, boolean doit)
- {
- return false;
- }
-
- @Override
- public boolean consumeVisFromInventory(EntityPlayer player, AspectList cost)
- {
- return false;
- }
-
- @Override
- public void addWarpToPlayer(EntityPlayer player, int amount, boolean temporary)
- {
- }
-
- @Override
- public void addStickyWarpToPlayer(EntityPlayer player, int amount)
- {
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/internal/IInternalMethodHandler.java b/src/api/java/thaumcraft/api/internal/IInternalMethodHandler.java
deleted file mode 100644
index 749c954..0000000
--- a/src/api/java/thaumcraft/api/internal/IInternalMethodHandler.java
+++ /dev/null
@@ -1,38 +0,0 @@
-package thaumcraft.api.internal;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-
-public interface IInternalMethodHandler
-{
-
- public void generateVisEffect(int dim, int x, int y, int z, int x2, int y2, int z2, int color);
-
- public boolean isResearchComplete(String username, String researchkey);
-
- public ItemStack getStackInRowAndColumn(Object instance, int row, int column);
-
- public AspectList getObjectAspects(ItemStack is);
-
- public AspectList getBonusObjectTags(ItemStack is, AspectList ot);
-
- public AspectList generateTags(Item item, int meta);
-
- public boolean consumeVisFromWand(ItemStack wand, EntityPlayer player, AspectList cost, boolean doit, boolean crafting);
-
- public boolean consumeVisFromWandCrafting(ItemStack wand, EntityPlayer player, AspectList cost, boolean doit);
-
- public boolean consumeVisFromInventory(EntityPlayer player, AspectList cost);
-
- public void addWarpToPlayer(EntityPlayer player, int amount, boolean temporary);
-
- public void addStickyWarpToPlayer(EntityPlayer player, int amount);
-
- public boolean hasDiscoveredAspect(String username, Aspect aspect);
-
- public AspectList getDiscoveredAspects(String username);
-
-}
diff --git a/src/api/java/thaumcraft/api/internal/WeightedRandomLoot.java b/src/api/java/thaumcraft/api/internal/WeightedRandomLoot.java
deleted file mode 100644
index 9ea95dd..0000000
--- a/src/api/java/thaumcraft/api/internal/WeightedRandomLoot.java
+++ /dev/null
@@ -1,24 +0,0 @@
-package thaumcraft.api.internal;
-
-import java.util.ArrayList;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.WeightedRandom;
-
-public class WeightedRandomLoot extends WeightedRandom.Item
-{
-
- /** The Item/Block ID to generate in the bag. */
- public ItemStack item;
-
- public WeightedRandomLoot(ItemStack stack, int weight)
- {
- super(weight);
- item = stack;
- }
-
- public static ArrayList<WeightedRandomLoot> lootBagCommon = new ArrayList<WeightedRandomLoot>();
- public static ArrayList<WeightedRandomLoot> lootBagUncommon = new ArrayList<WeightedRandomLoot>();
- public static ArrayList<WeightedRandomLoot> lootBagRare = new ArrayList<WeightedRandomLoot>();
-
-}
diff --git a/src/api/java/thaumcraft/api/nodes/INode.java b/src/api/java/thaumcraft/api/nodes/INode.java
deleted file mode 100644
index 4ef8fee..0000000
--- a/src/api/java/thaumcraft/api/nodes/INode.java
+++ /dev/null
@@ -1,54 +0,0 @@
-package thaumcraft.api.nodes;
-
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-import thaumcraft.api.aspects.IAspectContainer;
-
-public interface INode extends IAspectContainer
-{
-
- /**
- * Unique identifier to distinguish nodes. Normal node id's are based on world id and coordinates
- * @return
- */
- public String getId();
-
- public AspectList getAspectsBase();
-
- /**
- * Return the type of node
- * @return
- */
- public NodeType getNodeType();
-
- /**
- * Set the type of node
- * @return
- */
- public void setNodeType(NodeType nodeType);
-
- /**
- * Set the node modifier
- * @return
- */
- public void setNodeModifier(NodeModifier nodeModifier);
-
- /**
- * Return the node modifier
- * @return
- */
- public NodeModifier getNodeModifier();
-
- /**
- * Return the maximum capacity of each aspect the node can hold
- * @return
- */
- public int getNodeVisBase(Aspect aspect);
-
- /**
- * Set the maximum capacity of each aspect the node can hold
- * @return
- */
- public void setNodeVisBase(Aspect aspect, short nodeVisBase);
-
-}
diff --git a/src/api/java/thaumcraft/api/nodes/IRevealer.java b/src/api/java/thaumcraft/api/nodes/IRevealer.java
deleted file mode 100644
index 0f241e1..0000000
--- a/src/api/java/thaumcraft/api/nodes/IRevealer.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package thaumcraft.api.nodes;
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.item.ItemStack;
-
-/**
- *
- * @author Azanor
- *
- * Equipped head slot items that extend this class will make nodes visible in world.
- *
- */
-
-public interface IRevealer
-{
-
- /*
- * If this method returns true the nodes will be visible.
- */
- public boolean showNodes(ItemStack itemstack, EntityLivingBase player);
-
-}
diff --git a/src/api/java/thaumcraft/api/nodes/NodeModifier.java b/src/api/java/thaumcraft/api/nodes/NodeModifier.java
deleted file mode 100644
index 2e0e95e..0000000
--- a/src/api/java/thaumcraft/api/nodes/NodeModifier.java
+++ /dev/null
@@ -1,6 +0,0 @@
-package thaumcraft.api.nodes;
-
-public enum NodeModifier
-{
- BRIGHT, PALE, FADING
-}
diff --git a/src/api/java/thaumcraft/api/nodes/NodeType.java b/src/api/java/thaumcraft/api/nodes/NodeType.java
deleted file mode 100644
index 4fc26c3..0000000
--- a/src/api/java/thaumcraft/api/nodes/NodeType.java
+++ /dev/null
@@ -1,6 +0,0 @@
-package thaumcraft.api.nodes;
-
-public enum NodeType
-{
- NORMAL, UNSTABLE, DARK, TAINTED, HUNGRY, PURE
-}
diff --git a/src/api/java/thaumcraft/api/package-info.java b/src/api/java/thaumcraft/api/package-info.java
deleted file mode 100644
index 4de2404..0000000
--- a/src/api/java/thaumcraft/api/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(owner = "Thaumcraft", apiVersion = "4.2.2.0", provides = "Thaumcraft|API")
-package thaumcraft.api;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/thaumcraft/api/potions/PotionFluxTaint.java b/src/api/java/thaumcraft/api/potions/PotionFluxTaint.java
deleted file mode 100644
index facc2cc..0000000
--- a/src/api/java/thaumcraft/api/potions/PotionFluxTaint.java
+++ /dev/null
@@ -1,70 +0,0 @@
-package thaumcraft.api.potions;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.potion.Potion;
-import net.minecraft.util.ResourceLocation;
-import thaumcraft.api.damagesource.DamageSourceThaumcraft;
-import thaumcraft.api.entities.ITaintedMob;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class PotionFluxTaint extends Potion
-{
- public static PotionFluxTaint instance = null; // will be instantiated at runtime
- public PotionFluxTaint(int par1, boolean par2, int par3)
- {
- super(par1, par2, par3);
- setIconIndex(0, 0);
- }
-
- public static void init()
- {
- instance.setPotionName("potion.fluxtaint");
- instance.setIconIndex(3, 1);
- instance.setEffectiveness(0.25D);
- }
-
- @Override
- public boolean isBadEffect()
- {
- return true;
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public int getStatusIconIndex()
- {
- Minecraft.getMinecraft().renderEngine.bindTexture(rl);
- return super.getStatusIconIndex();
- }
-
- static final ResourceLocation rl = new ResourceLocation("thaumcraft",
- "textures/misc/potions.png");
-
- @Override
- public void performEffect(EntityLivingBase target, int par2)
- {
- if(target instanceof ITaintedMob)
- {
- target.heal(1);
- }
- else if(!target.isEntityUndead() && !(target instanceof EntityPlayer))
- {
- target.attackEntityFrom(DamageSourceThaumcraft.taint, 1);
- }
- else if(!target.isEntityUndead() && (target.getMaxHealth() > 1 || (target instanceof EntityPlayer)))
- {
- target.attackEntityFrom(DamageSourceThaumcraft.taint, 1);
- }
- }
-
- @Override
- public boolean isReady(int par1, int par2)
- {
- final int k = 40 >> par2;
- return k > 0 ? par1 % k == 0 : true;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/potions/PotionVisExhaust.java b/src/api/java/thaumcraft/api/potions/PotionVisExhaust.java
deleted file mode 100644
index baa0f9c..0000000
--- a/src/api/java/thaumcraft/api/potions/PotionVisExhaust.java
+++ /dev/null
@@ -1,49 +0,0 @@
-package thaumcraft.api.potions;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.potion.Potion;
-import net.minecraft.util.ResourceLocation;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class PotionVisExhaust extends Potion
-{
- public static PotionVisExhaust instance = null; // will be instantiated at runtime
- public PotionVisExhaust(int par1, boolean par2, int par3)
- {
- super(par1, par2, par3);
- setIconIndex(0, 0);
- }
-
- public static void init()
- {
- instance.setPotionName("potion.visexhaust");
- instance.setIconIndex(5, 1);
- instance.setEffectiveness(0.25D);
- }
-
- @Override
- public boolean isBadEffect()
- {
- return true;
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public int getStatusIconIndex()
- {
- Minecraft.getMinecraft().renderEngine.bindTexture(rl);
- return super.getStatusIconIndex();
- }
-
- static final ResourceLocation rl = new ResourceLocation("thaumcraft",
- "textures/misc/potions.png");
-
- @Override
- public void performEffect(EntityLivingBase target, int par2)
- {
-
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/research/IScanEventHandler.java b/src/api/java/thaumcraft/api/research/IScanEventHandler.java
deleted file mode 100644
index 219cb5d..0000000
--- a/src/api/java/thaumcraft/api/research/IScanEventHandler.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package thaumcraft.api.research;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-
-public interface IScanEventHandler
-{
- ScanResult scanPhenomena(ItemStack stack, World world, EntityPlayer player);
-}
diff --git a/src/api/java/thaumcraft/api/research/ResearchCategories.java b/src/api/java/thaumcraft/api/research/ResearchCategories.java
deleted file mode 100644
index 01c648b..0000000
--- a/src/api/java/thaumcraft/api/research/ResearchCategories.java
+++ /dev/null
@@ -1,116 +0,0 @@
-package thaumcraft.api.research;
-
-import java.util.Collection;
-import java.util.LinkedHashMap;
-
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-
-import org.apache.logging.log4j.Level;
-
-import cpw.mods.fml.common.FMLLog;
-
-public class ResearchCategories
-{
-
- //Research
- public static LinkedHashMap<String, ResearchCategoryList> researchCategories = new LinkedHashMap<String, ResearchCategoryList>();
-
- /**
- * @param key
- * @return the research item linked to this key
- */
- public static ResearchCategoryList getResearchList(String key)
- {
- return researchCategories.get(key);
- }
-
- /**
- * @param key
- * @return the name of the research category linked to this key.
- * Must be stored as localization information in the LanguageRegistry.
- */
- public static String getCategoryName(String key)
- {
- return StatCollector.translateToLocal("tc.research_category." + key);
- }
-
- /**
- * @param key the research key
- * @return the ResearchItem object.
- */
- public static ResearchItem getResearch(String key)
- {
- final Collection rc = researchCategories.values();
- for(final Object cat : rc)
- {
- final Collection rl = ((ResearchCategoryList) cat).research.values();
- for(final Object ri : rl)
- {
- if((((ResearchItem) ri).key).equals(key))
- {
- return (ResearchItem) ri;
- }
- }
- }
- return null;
- }
-
- /**
- * This should only be done at the PostInit stage
- * @param key the key used for this category
- * @param icon the icon to be used for the research category tab
- * @param background the resource location of the background image to use for this category
- * @return the name of the research linked to this key
- */
- public static void registerCategory(String key, ResourceLocation icon, ResourceLocation background)
- {
- if(getResearchList(key) == null)
- {
- final ResearchCategoryList rl = new ResearchCategoryList(icon, background);
- researchCategories.put(key, rl);
- }
- }
-
- public static void addResearch(ResearchItem ri)
- {
- final ResearchCategoryList rl = getResearchList(ri.category);
- if(rl != null && !rl.research.containsKey(ri.key))
- {
-
- if(!ri.isVirtual())
- {
- for(final ResearchItem rr : rl.research.values())
- {
- if(rr.displayColumn == ri.displayColumn && rr.displayRow == ri.displayRow)
- {
- FMLLog.log(Level.FATAL, "[Thaumcraft] Research [" + ri.getName() + "] not added as it overlaps with existing research [" + rr.getName() + "]");
- return;
- }
- }
- }
-
- rl.research.put(ri.key, ri);
-
- if(ri.displayColumn < rl.minDisplayColumn)
- {
- rl.minDisplayColumn = ri.displayColumn;
- }
-
- if(ri.displayRow < rl.minDisplayRow)
- {
- rl.minDisplayRow = ri.displayRow;
- }
-
- if(ri.displayColumn > rl.maxDisplayColumn)
- {
- rl.maxDisplayColumn = ri.displayColumn;
- }
-
- if(ri.displayRow > rl.maxDisplayRow)
- {
- rl.maxDisplayRow = ri.displayRow;
- }
- }
- }
-}
diff --git a/src/api/java/thaumcraft/api/research/ResearchCategoryList.java b/src/api/java/thaumcraft/api/research/ResearchCategoryList.java
deleted file mode 100644
index 289604d..0000000
--- a/src/api/java/thaumcraft/api/research/ResearchCategoryList.java
+++ /dev/null
@@ -1,36 +0,0 @@
-package thaumcraft.api.research;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import net.minecraft.util.ResourceLocation;
-
-public class ResearchCategoryList
-{
-
- /** Is the smallest column used on the GUI. */
- public int minDisplayColumn;
-
- /** Is the smallest row used on the GUI. */
- public int minDisplayRow;
-
- /** Is the biggest column used on the GUI. */
- public int maxDisplayColumn;
-
- /** Is the biggest row used on the GUI. */
- public int maxDisplayRow;
-
- /** display variables **/
- public ResourceLocation icon;
- public ResourceLocation background;
-
- public ResearchCategoryList(ResourceLocation icon, ResourceLocation background)
- {
- this.icon = icon;
- this.background = background;
- }
-
- //Research
- public Map<String, ResearchItem> research = new HashMap<String, ResearchItem>();
-
-}
diff --git a/src/api/java/thaumcraft/api/research/ResearchItem.java b/src/api/java/thaumcraft/api/research/ResearchItem.java
deleted file mode 100644
index b8b9e88..0000000
--- a/src/api/java/thaumcraft/api/research/ResearchItem.java
+++ /dev/null
@@ -1,394 +0,0 @@
-package thaumcraft.api.research;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-
-public class ResearchItem
-{
- /**
- * A short string used as a key for this research. Must be unique
- */
- public final String key;
-
- /**
- * A short string used as a reference to the research category to which this must be added.
- */
- public final String category;
-
- /**
- * The aspect tags and their values required to complete this research
- */
- public final AspectList tags;
-
- /**
- * This links to any research that needs to be completed before this research can be discovered or learnt.
- */
- public String[] parents = null;
-
- /**
- * Like parent above, but a line will not be displayed in the thaumonomicon linking them. Just used to prevent clutter.
- */
- public String[] parentsHidden = null;
- /**
- * any research linked to this that will be unlocked automatically when this research is complete
- */
- public String[] siblings = null;
-
- /**
- * the horizontal position of the research icon
- */
- public final int displayColumn;
-
- /**
- * the vertical position of the research icon
- */
- public final int displayRow;
-
- /**
- * the icon to be used for this research
- */
- public final ItemStack icon_item;
-
- /**
- * the icon to be used for this research
- */
- public final ResourceLocation icon_resource;
-
- /**
- * How large the research grid is. Valid values are 1 to 3.
- */
- private int complexity;
-
- /**
- * Special research has a spiky border. Used for important research milestones.
- */
- private boolean isSpecial;
-
- /**
- * Research that can be directly purchased with RP in normal research difficulty.
- */
- private boolean isSecondary;
-
- /**
- * This indicates if the research should use a circular icon border. Usually used for "passive" research
- * that doesn't have recipes and grants passive effects, or that unlock automatically.
- */
- private boolean isRound;
-
- /**
- * Stub research cannot be discovered by normal means, but can be unlocked via the sibling system.
- */
- private boolean isStub;
-
- /**
- * This indicated that the research is completely hidden and cannot be discovered by any
- * player-controlled means. The recipes will never show up in the thaumonomicon.
- * Usually used to unlock "hidden" recipes via sibling unlocking, like
- * the various cap and rod combos for wands.
- */
- private boolean isVirtual;
-
- /**
- * Concealed research does not display in the thaumonomicon until parent researches are discovered.
- */
- private boolean isConcealed;
-
- /**
- * Hidden research can only be discovered via scanning or knowledge fragments
- */
- private boolean isHidden;
-
- /**
- * This is the same as isHidden, except it cannot be discovered with knowledge fragments, only scanning.
- */
- private boolean isLost;
-
- /**
- * These research items will automatically unlock for all players on game start
- */
- private boolean isAutoUnlock;
-
- /**
- * Scanning these items will have a chance of revealing hidden knowledge in the thaumonomicon
- */
- private ItemStack[] itemTriggers;
-
- /**
- * Scanning these entities will have a chance of revealing hidden knowledge in the thaumonomicon
- */
- private String[] entityTriggers;
-
- /**
- * Scanning things with these aspects will have a chance of revealing hidden knowledge in the thaumonomicon
- */
- private Aspect[] aspectTriggers;
-
- private ResearchPage[] pages = null;
-
- public ResearchItem(String key, String category)
- {
- this.key = key;
- this.category = category;
- tags = new AspectList();
- icon_resource = null;
- icon_item = null;
- displayColumn = 0;
- displayRow = 0;
- setVirtual();
-
- }
-
- public ResearchItem(String key, String category, AspectList tags, int col, int row, int complex, ResourceLocation icon)
- {
- this.key = key;
- this.category = category;
- this.tags = tags;
- icon_resource = icon;
- icon_item = null;
- displayColumn = col;
- displayRow = row;
- complexity = complex;
- if(complexity < 1)
- {
- complexity = 1;
- }
- if(complexity > 3)
- {
- complexity = 3;
- }
- }
-
- public ResearchItem(String key, String category, AspectList tags, int col, int row, int complex, ItemStack icon)
- {
- this.key = key;
- this.category = category;
- this.tags = tags;
- icon_item = icon;
- icon_resource = null;
- displayColumn = col;
- displayRow = row;
- complexity = complex;
- if(complexity < 1)
- {
- complexity = 1;
- }
- if(complexity > 3)
- {
- complexity = 3;
- }
- }
-
- public ResearchItem setSpecial()
- {
- isSpecial = true;
- return this;
- }
-
- public ResearchItem setStub()
- {
- isStub = true;
- return this;
- }
-
- public ResearchItem setLost()
- {
- isLost = true;
- return this;
- }
-
- public ResearchItem setConcealed()
- {
- isConcealed = true;
- return this;
- }
-
- public ResearchItem setHidden()
- {
- isHidden = true;
- return this;
- }
-
- public ResearchItem setVirtual()
- {
- isVirtual = true;
- return this;
- }
-
- public ResearchItem setParents(String... par)
- {
- parents = par;
- return this;
- }
-
- public ResearchItem setParentsHidden(String... par)
- {
- parentsHidden = par;
- return this;
- }
-
- public ResearchItem setSiblings(String... sib)
- {
- siblings = sib;
- return this;
- }
-
- public ResearchItem setPages(ResearchPage... par)
- {
- pages = par;
- return this;
- }
-
- public ResearchPage[] getPages()
- {
- return pages;
- }
-
- public ResearchItem setItemTriggers(ItemStack... par)
- {
- itemTriggers = par;
- return this;
- }
-
- public ResearchItem setEntityTriggers(String... par)
- {
- entityTriggers = par;
- return this;
- }
-
- public ResearchItem setAspectTriggers(Aspect... par)
- {
- aspectTriggers = par;
- return this;
- }
-
- public ItemStack[] getItemTriggers()
- {
- return itemTriggers;
- }
-
- public String[] getEntityTriggers()
- {
- return entityTriggers;
- }
-
- public Aspect[] getAspectTriggers()
- {
- return aspectTriggers;
- }
-
- public ResearchItem registerResearchItem()
- {
- ResearchCategories.addResearch(this);
- return this;
- }
-
- public String getName()
- {
- return StatCollector.translateToLocal("tc.research_name." + key);
- }
-
- public String getText()
- {
- return StatCollector.translateToLocal("tc.research_text." + key);
- }
-
- public boolean isSpecial()
- {
- return isSpecial;
- }
-
- public boolean isStub()
- {
- return isStub;
- }
-
- public boolean isLost()
- {
- return isLost;
- }
-
- public boolean isConcealed()
- {
- return isConcealed;
- }
-
- public boolean isHidden()
- {
- return isHidden;
- }
-
- public boolean isVirtual()
- {
- return isVirtual;
- }
-
- public boolean isAutoUnlock()
- {
- return isAutoUnlock;
- }
-
- public ResearchItem setAutoUnlock()
- {
- isAutoUnlock = true;
- return this;
- }
-
- public boolean isRound()
- {
- return isRound;
- }
-
- public ResearchItem setRound()
- {
- isRound = true;
- return this;
- }
-
- public boolean isSecondary()
- {
- return isSecondary;
- }
-
- public ResearchItem setSecondary()
- {
- isSecondary = true;
- return this;
- }
-
- public int getComplexity()
- {
- return complexity;
- }
-
- public ResearchItem setComplexity(int complexity)
- {
- this.complexity = complexity;
- return this;
- }
-
- /**
- * @return the aspect aspects ordinal with the highest value. Used to determine scroll color and similar things
- */
- public Aspect getResearchPrimaryTag()
- {
- Aspect aspect = null;
- int highest = 0;
- if(tags != null)
- {
- for(final Aspect tag : tags.getAspects())
- {
- if(tags.getAmount(tag) > highest)
- {
- aspect = tag;
- highest = tags.getAmount(tag);
- }
- ;
- }
- }
- return aspect;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/research/ResearchPage.java b/src/api/java/thaumcraft/api/research/ResearchPage.java
deleted file mode 100644
index 415350a..0000000
--- a/src/api/java/thaumcraft/api/research/ResearchPage.java
+++ /dev/null
@@ -1,206 +0,0 @@
-package thaumcraft.api.research;
-
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.item.crafting.FurnaceRecipes;
-import net.minecraft.item.crafting.IRecipe;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-import thaumcraft.api.aspects.AspectList;
-import thaumcraft.api.crafting.CrucibleRecipe;
-import thaumcraft.api.crafting.IArcaneRecipe;
-import thaumcraft.api.crafting.InfusionEnchantmentRecipe;
-import thaumcraft.api.crafting.InfusionRecipe;
-
-public class ResearchPage
-{
- public static enum PageType
- {
- TEXT, TEXT_CONCEALED, IMAGE, CRUCIBLE_CRAFTING, ARCANE_CRAFTING, ASPECTS, NORMAL_CRAFTING, INFUSION_CRAFTING, COMPOUND_CRAFTING, INFUSION_ENCHANTMENT, SMELTING
- }
-
- public PageType type = PageType.TEXT;
-
- public String text = null;
- public String research = null;
- public ResourceLocation image = null;
- public AspectList aspects = null;
- public Object recipe = null;
- public ItemStack recipeOutput = null;
-
- /**
- * @param text this can (but does not have to) be a reference to a localization variable, not the actual text.
- */
- public ResearchPage(String text)
- {
- type = PageType.TEXT;
- this.text = text;
- }
-
- /**
- * @param research this page will only be displayed if the player has discovered this research
- * @param text this can (but does not have to) be a reference to a localization variable, not the actual text.
- */
- public ResearchPage(String research, String text)
- {
- type = PageType.TEXT_CONCEALED;
- this.research = research;
- this.text = text;
- }
-
- /**
- * @param recipe a vanilla crafting recipe.
- */
- public ResearchPage(IRecipe recipe)
- {
- type = PageType.NORMAL_CRAFTING;
- this.recipe = recipe;
- recipeOutput = recipe.getRecipeOutput();
- }
-
- /**
- * @param recipe a collection of vanilla crafting recipes.
- */
- public ResearchPage(IRecipe[] recipe)
- {
- type = PageType.NORMAL_CRAFTING;
- this.recipe = recipe;
- }
-
- /**
- * @param recipe a collection of arcane crafting recipes.
- */
- public ResearchPage(IArcaneRecipe[] recipe)
- {
- type = PageType.ARCANE_CRAFTING;
- this.recipe = recipe;
- }
-
- /**
- * @param recipe a collection of arcane crafting recipes.
- */
- public ResearchPage(CrucibleRecipe[] recipe)
- {
- type = PageType.CRUCIBLE_CRAFTING;
- this.recipe = recipe;
- }
-
- /**
- * @param recipe a collection of infusion crafting recipes.
- */
- public ResearchPage(InfusionRecipe[] recipe)
- {
- type = PageType.INFUSION_CRAFTING;
- this.recipe = recipe;
- }
-
- /**
- * @param recipe a compound crafting recipe.
- */
- public ResearchPage(List recipe)
- {
- type = PageType.COMPOUND_CRAFTING;
- this.recipe = recipe;
- }
-
- /**
- * @param recipe an arcane worktable crafting recipe.
- */
- public ResearchPage(IArcaneRecipe recipe)
- {
- type = PageType.ARCANE_CRAFTING;
- this.recipe = recipe;
- recipeOutput = recipe.getRecipeOutput();
- }
-
- /**
- * @param recipe an alchemy crafting recipe.
- */
- public ResearchPage(CrucibleRecipe recipe)
- {
- type = PageType.CRUCIBLE_CRAFTING;
- this.recipe = recipe;
- recipeOutput = recipe.getRecipeOutput();
- }
-
- /**
- * @param recipe a furnace smelting crafting recipe.
- */
- public ResearchPage(ItemStack input)
- {
- type = PageType.SMELTING;
- recipe = input;
- recipeOutput = FurnaceRecipes.smelting().getSmeltingResult(input);
- }
-
- /**
- * @param recipe an infusion crafting recipe.
- */
- public ResearchPage(InfusionRecipe recipe)
- {
- type = PageType.INFUSION_CRAFTING;
- this.recipe = recipe;
- if(recipe.getRecipeOutput() instanceof ItemStack)
- {
- recipeOutput = (ItemStack) recipe.getRecipeOutput();
- }
- else
- {
- recipeOutput = recipe.getRecipeInput();
- }
- }
-
- /**
- * @param recipe an infusion crafting recipe.
- */
- public ResearchPage(InfusionEnchantmentRecipe recipe)
- {
- type = PageType.INFUSION_ENCHANTMENT;
- this.recipe = recipe;
- // if (recipe.recipeOutput instanceof ItemStack) {
- // this.recipeOutput = (ItemStack) recipe.recipeOutput;
- // } else {
- // this.recipeOutput = recipe.recipeInput;
- // }
- }
-
- /**
- * @param image
- * @param caption this can (but does not have to) be a reference to a localization variable, not the actual text.
- */
- public ResearchPage(ResourceLocation image, String caption)
- {
- type = PageType.IMAGE;
- this.image = image;
- text = caption;
- }
-
- /**
- * This function should really not be called directly - used internally
- */
- public ResearchPage(AspectList as)
- {
- type = PageType.ASPECTS;
- aspects = as;
- }
-
- /**
- * returns a localized text of the text field (if one exists). Returns the text field itself otherwise.
- * @return
- */
- public String getTranslatedText()
- {
- String ret = "";
- if(text != null)
- {
- ret = StatCollector.translateToLocal(text);
- if(ret.isEmpty())
- {
- ret = text;
- }
- }
- return ret;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/research/ScanResult.java b/src/api/java/thaumcraft/api/research/ScanResult.java
deleted file mode 100644
index 8c04c69..0000000
--- a/src/api/java/thaumcraft/api/research/ScanResult.java
+++ /dev/null
@@ -1,49 +0,0 @@
-package thaumcraft.api.research;
-
-import net.minecraft.entity.Entity;
-
-public class ScanResult
-{
- public byte type = 0; //1=blocks,2=entities,3=phenomena
- public int id;
- public int meta;
- public Entity entity;
- public String phenomena;
-
- public ScanResult(byte type, int blockId, int blockMeta, Entity entity, String phenomena)
- {
- super();
- this.type = type;
- id = blockId;
- meta = blockMeta;
- this.entity = entity;
- this.phenomena = phenomena;
- }
-
- @Override
- public boolean equals(Object obj)
- {
- if(obj instanceof ScanResult)
- {
- final ScanResult sr = (ScanResult) obj;
- if(type != sr.type)
- {
- return false;
- }
- if(type == 1 && (id != sr.id || meta != sr.meta))
- {
- return false;
- }
- if(type == 2 && entity.getEntityId() != sr.entity.getEntityId())
- {
- return false;
- }
- if(type == 3 && !phenomena.equals(sr.phenomena))
- {
- return false;
- }
- }
- return true;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/visnet/TileVisNode.java b/src/api/java/thaumcraft/api/visnet/TileVisNode.java
deleted file mode 100644
index 56dbafe..0000000
--- a/src/api/java/thaumcraft/api/visnet/TileVisNode.java
+++ /dev/null
@@ -1,217 +0,0 @@
-package thaumcraft.api.visnet;
-
-import java.lang.ref.WeakReference;
-import java.util.ArrayList;
-import java.util.HashMap;
-
-import thaumcraft.api.TileThaumcraft;
-import thaumcraft.api.WorldCoordinates;
-import thaumcraft.api.aspects.Aspect;
-
-/**
- * @author Azanor
- *
- * The tile entity used by nodes in the vis energy network. A node is either a source (like an aura node),
- * a transport relay or vis receiver (like the infernal furnace).
- *
- */
-public abstract class TileVisNode extends TileThaumcraft
-{
-
- WeakReference<TileVisNode> parent = null;
- ArrayList<WeakReference<TileVisNode>> children = new ArrayList<WeakReference<TileVisNode>>();
-
- /**
- * @return the WorldCoordinates location of where this node is located
- */
- public WorldCoordinates getLocation()
- {
- return new WorldCoordinates(this);
- }
-
- /**
- * @return the number of blocks away this node will check for parent nodes to connect to.
- */
- public abstract int getRange();
-
- /**
- * @return true if this is the source or root node of the vis network.
- */
- public abstract boolean isSource();
-
- /**
- * This method should never be called directly. Use VisNetHandler.drainVis() instead
- * @param aspect what aspect to drain
- * @param vis how much to drain
- * @return how much was actually drained
- */
- public int consumeVis(Aspect aspect, int vis)
- {
- if(VisNetHandler.isNodeValid(getParent()))
- {
- final int out = getParent().get().consumeVis(aspect, vis);
- if(out > 0)
- {
- triggerConsumeEffect(aspect);
- }
- return out;
- }
- return 0;
- }
-
- public void removeThisNode()
- {
- for(final WeakReference<TileVisNode> n : getChildren())
- {
- if(n != null && n.get() != null)
- {
- n.get().removeThisNode();
- }
- }
-
- children = new ArrayList<WeakReference<TileVisNode>>();
- if(VisNetHandler.isNodeValid(getParent()))
- {
- getParent().get().nodeRefresh = true;
- }
- setParent(null);
- parentChanged();
-
- if(isSource())
- {
- HashMap<WorldCoordinates, WeakReference<TileVisNode>> sourcelist = VisNetHandler.sources.get(worldObj.provider.dimensionId);
- if(sourcelist == null)
- {
- sourcelist = new HashMap<WorldCoordinates, WeakReference<TileVisNode>>();
- }
- sourcelist.remove(getLocation());
- VisNetHandler.sources.put(worldObj.provider.dimensionId, sourcelist);
- }
-
- worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
- }
-
- @Override
- public void invalidate()
- {
- removeThisNode();
- super.invalidate();
- }
-
- public void triggerConsumeEffect(Aspect aspect)
- {
- }
-
- /**
- * @return
- */
- public WeakReference<TileVisNode> getParent()
- {
- return parent;
- }
-
- /**
- * @return
- */
- public WeakReference<TileVisNode> getRootSource()
- {
- return VisNetHandler.isNodeValid(getParent()) ? getParent().get().getRootSource() : isSource() ? new WeakReference(
- this) : null;
- }
-
- /**
- * @param parent
- */
- public void setParent(WeakReference<TileVisNode> parent)
- {
- this.parent = parent;
- }
-
- /**
- * @return
- */
- public ArrayList<WeakReference<TileVisNode>> getChildren()
- {
- return children;
- }
-
- @Override
- public boolean canUpdate()
- {
- return true;
- }
-
- protected int nodeCounter = 0;
- private boolean nodeRegged = false;
- public boolean nodeRefresh = false;
-
- @Override
- public void updateEntity()
- {
-
- if(!worldObj.isRemote && ((nodeCounter++) % 40 == 0 || nodeRefresh))
- {
- //check for changes
- if(!nodeRefresh && children.size() > 0)
- {
- for(final WeakReference<TileVisNode> n : children)
- {
- if(n == null || n.get() == null || !VisNetHandler.canNodeBeSeen(this, n.get()))
- {
- nodeRefresh = true;
- break;
- }
- }
- }
-
- //refresh linked nodes
- if(nodeRefresh)
- {
- for(final WeakReference<TileVisNode> n : children)
- {
- if(n.get() != null)
- {
- n.get().nodeRefresh = true;
- }
- }
- children.clear();
- parent = null;
- }
-
- //redo stuff
- if(isSource() && !nodeRegged)
- {
- VisNetHandler.addSource(getWorldObj(), this);
- nodeRegged = true;
- }
- else if(!isSource() && !VisNetHandler.isNodeValid(getParent()))
- {
- setParent(VisNetHandler.addNode(getWorldObj(), this));
- nodeRefresh = true;
- }
-
- if(nodeRefresh)
- {
- worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
- parentChanged();
- }
- nodeRefresh = false;
- }
-
- }
-
- public void parentChanged()
- {
- }
-
- /**
- * @return the type of shard this is attuned to:
- * none -1, air 0, fire 1, water 2, earth 3, order 4, entropy 5
- * Should return -1 for most implementations
- */
- public byte getAttunement()
- {
- return -1;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/visnet/VisNetHandler.java b/src/api/java/thaumcraft/api/visnet/VisNetHandler.java
deleted file mode 100644
index c8a4826..0000000
--- a/src/api/java/thaumcraft/api/visnet/VisNetHandler.java
+++ /dev/null
@@ -1,317 +0,0 @@
-package thaumcraft.api.visnet;
-
-import java.lang.ref.WeakReference;
-import java.util.ArrayList;
-import java.util.HashMap;
-
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.MovingObjectPosition.MovingObjectType;
-import net.minecraft.util.Vec3;
-import net.minecraft.world.World;
-import thaumcraft.api.ThaumcraftApi;
-import thaumcraft.api.ThaumcraftApiHelper;
-import thaumcraft.api.WorldCoordinates;
-import thaumcraft.api.aspects.Aspect;
-
-public class VisNetHandler
-{
-
- // NODE DRAINING
- /**
- * This method drains vis from a relay or source near the passed in
- * location. The amount received can be less than the amount requested so
- * take that into account.
- *
- * @param world
- * @param x the x position of the draining block or entity
- * @param y the y position of the draining block or entity
- * @param z the z position of the draining block or entity
- * @param aspect what aspect to drain
- * @param amount how much to drain
- * @return how much was actually drained
- */
- public static int drainVis(World world, int x, int y, int z, Aspect aspect, int amount)
- {
-
- int drainedAmount = 0;
-
- final WorldCoordinates drainer = new WorldCoordinates(x, y, z,
- world.provider.dimensionId);
- if(!nearbyNodes.containsKey(drainer))
- {
- calculateNearbyNodes(world, x, y, z);
- }
-
- final ArrayList<WeakReference<TileVisNode>> nodes = nearbyNodes.get(drainer);
- if(nodes != null && nodes.size() > 0)
- {
- for(final WeakReference<TileVisNode> noderef : nodes)
- {
-
- final TileVisNode node = noderef.get();
-
- if(node == null)
- {
- continue;
- }
-
- final int a = node.consumeVis(aspect, amount);
- drainedAmount += a;
- amount -= a;
- if(a > 0)
- {
- final int color = Aspect.getPrimalAspects().indexOf(aspect);
- generateVisEffect(world.provider.dimensionId, x, y, z, node.xCoord, node.yCoord, node.zCoord, color);
- }
- if(amount <= 0)
- {
- break;
- }
- }
- }
-
- return drainedAmount;
- }
-
- public static void generateVisEffect(int dim, int x, int y, int z, int x2, int y2, int z2, int color)
- {
- ThaumcraftApi.internalMethods.generateVisEffect(dim, x, y, z, x2, y2, z2, color);
- }
-
- public static HashMap<Integer, HashMap<WorldCoordinates, WeakReference<TileVisNode>>> sources = new HashMap<Integer, HashMap<WorldCoordinates, WeakReference<TileVisNode>>>();
-
- public static void addSource(World world, TileVisNode vs)
- {
- HashMap<WorldCoordinates, WeakReference<TileVisNode>> sourcelist = sources.get(world.provider.dimensionId);
- if(sourcelist == null)
- {
- sourcelist = new HashMap<WorldCoordinates, WeakReference<TileVisNode>>();
- }
- sourcelist.put(vs.getLocation(), new WeakReference(vs));
- sources.put(world.provider.dimensionId, sourcelist);
- nearbyNodes.clear();
- }
-
- public static boolean isNodeValid(WeakReference<TileVisNode> node)
- {
- if(node == null || node.get() == null || node.get().isInvalid())
- {
- return false;
- }
- return true;
- }
-
- public static WeakReference<TileVisNode> addNode(World world, TileVisNode vn)
- {
- final WeakReference ref = new WeakReference(vn);
-
- HashMap<WorldCoordinates, WeakReference<TileVisNode>> sourcelist = sources.get(world.provider.dimensionId);
- if(sourcelist == null)
- {
- sourcelist = new HashMap<WorldCoordinates, WeakReference<TileVisNode>>();
- return null;
- }
-
- ArrayList<Object[]> nearby = new ArrayList<Object[]>();
-
- for(final WeakReference<TileVisNode> root : sourcelist.values())
- {
- if(!isNodeValid(root))
- {
- continue;
- }
-
- final TileVisNode source = root.get();
-
- final float r = inRange(world, vn.getLocation(), source.getLocation(), vn.getRange());
- if(r > 0)
- {
- nearby.add(new Object[] {source, r - vn.getRange() * 2});
- }
-
- nearby = findClosestNodes(vn, source, nearby);
- cache.clear();
- }
-
- float dist = Float.MAX_VALUE;
- TileVisNode closest = null;
- if(nearby.size() > 0)
- {
- for(final Object[] o : nearby)
- {
- if((Float) o[1] < dist && (vn.getAttunement() == -1 || ((TileVisNode) o[0]).getAttunement() == -1 || vn.getAttunement() == ((TileVisNode) o[0]).getAttunement())//) {
- && canNodeBeSeen(vn, (TileVisNode) o[0]))
- {
- dist = (Float) o[1];
- closest = (TileVisNode) o[0];
- }
- }
- }
- if(closest != null)
- {
- closest.getChildren().add(ref);
- nearbyNodes.clear();
- return new WeakReference(closest);
- }
-
- return null;
- }
-
- static ArrayList<WorldCoordinates> cache = new ArrayList<WorldCoordinates>();
-
- public static ArrayList<Object[]> findClosestNodes(TileVisNode target, TileVisNode parent, ArrayList<Object[]> in)
- {
-
- if(cache.size() > 512 || cache.contains(new WorldCoordinates(parent)))
- {
- return in;
- }
- cache.add(new WorldCoordinates(parent));
-
- for(final WeakReference<TileVisNode> childWR : parent.getChildren())
- {
- final TileVisNode child = childWR.get();
-
- if(child != null && !child.equals(target) && !child.equals(parent))
- {
- final float r2 = inRange(child.getWorldObj(), child.getLocation(), target.getLocation(), target.getRange());
- if(r2 > 0)
- {
- in.add(new Object[] {child, r2});
- }
-
- in = findClosestNodes(target, child, in);
- }
- }
- return in;
- }
-
- private static float inRange(World world, WorldCoordinates cc1, WorldCoordinates cc2, int range)
- {
- final float distance = cc1.getDistanceSquaredToWorldCoordinates(cc2);
- return distance > range * range ? -1 : distance;
- }
-
- private static HashMap<WorldCoordinates, ArrayList<WeakReference<TileVisNode>>> nearbyNodes = new HashMap<WorldCoordinates, ArrayList<WeakReference<TileVisNode>>>();
-
- private static void calculateNearbyNodes(World world, int x, int y, int z)
- {
-
- HashMap<WorldCoordinates, WeakReference<TileVisNode>> sourcelist = sources.get(world.provider.dimensionId);
- if(sourcelist == null)
- {
- sourcelist = new HashMap<WorldCoordinates, WeakReference<TileVisNode>>();
- return;
- }
-
- final ArrayList<WeakReference<TileVisNode>> cn = new ArrayList<WeakReference<TileVisNode>>();
- final WorldCoordinates drainer = new WorldCoordinates(x, y, z,
- world.provider.dimensionId);
-
- new ArrayList<Object[]>();
-
- for(final WeakReference<TileVisNode> root : sourcelist.values())
- {
-
- if(!isNodeValid(root))
- {
- continue;
- }
-
- final TileVisNode source = root.get();
-
- TileVisNode closest = null;
- float range = Float.MAX_VALUE;
-
- final float r = inRange(world, drainer, source.getLocation(), source.getRange());
- if(r > 0)
- {
- range = r;
- closest = source;
- }
-
- ArrayList<WeakReference<TileVisNode>> children = new ArrayList<WeakReference<TileVisNode>>();
- children = getAllChildren(source, children);
-
- for(final WeakReference<TileVisNode> child : children)
- {
- final TileVisNode n = child.get();
- if(n != null && !n.equals(root))
- {
-
- final float r2 = inRange(n.getWorldObj(), n.getLocation(), drainer, n.getRange());
- if(r2 > 0 && r2 < range)
- {
- range = r2;
- closest = n;
- }
- }
- }
-
- if(closest != null)
- {
-
- cn.add(new WeakReference(closest));
- }
- }
-
- nearbyNodes.put(drainer, cn);
- }
-
- private static ArrayList<WeakReference<TileVisNode>> getAllChildren(TileVisNode source, ArrayList<WeakReference<TileVisNode>> list)
- {
- for(final WeakReference<TileVisNode> child : source.getChildren())
- {
- final TileVisNode n = child.get();
-
- if(n != null && n.getWorldObj() != null && isChunkLoaded(n.getWorldObj(), n.xCoord, n.zCoord))
- {
- list.add(child);
- list = getAllChildren(n, list);
- }
- }
- return list;
- }
-
- public static boolean isChunkLoaded(World world, int x, int z)
- {
- final int xx = x >> 4;
- final int zz = z >> 4;
- return world.getChunkProvider().chunkExists(xx, zz);
- }
-
- public static boolean canNodeBeSeen(TileVisNode source, TileVisNode target)
- {
- final MovingObjectPosition mop = ThaumcraftApiHelper.rayTraceIgnoringSource(source.getWorldObj(), Vec3.createVectorHelper(source.xCoord + .5, source.yCoord + .5, source.zCoord + .5), Vec3.createVectorHelper(target.xCoord + .5, target.yCoord + .5, target.zCoord + .5), false, true, false);
- return mop == null || (mop.typeOfHit == MovingObjectType.BLOCK && mop.blockX == target.xCoord && mop.blockY == target.yCoord && mop.blockZ == target.zCoord);
- }
-
- // public static HashMap<WorldCoordinates,WeakReference<TileVisNode>>
- // noderef = new HashMap<WorldCoordinates,WeakReference<TileVisNode>>();
- //
- // public static TileVisNode getClosestNodeWithinRadius(World world, int x,
- // int y, int z, int radius) {
- // TileVisNode out = null;
- // WorldCoordinates wc = null;
- // float cd = Float.MAX_VALUE;
- // for (int sx = x - radius; sx <= x + radius; sx++) {
- // for (int sy = y - radius; sy <= y + radius; sy++) {
- // for (int sz = z - radius; sz <= z + radius; sz++) {
- // wc = new WorldCoordinates(sx,sy,sz,world.provider.dimensionId);
- // if (noderef.containsKey(wc)) {
- // float d = wc.getDistanceSquared(x, y, z);
- // if (d<radius*radius && noderef.get(wc).get()!=null &&
- // !noderef.get(wc).get().isReceiver() &&
- // isNodeValid(noderef.get(wc).get().getParent())
- // ) {
- // out = noderef.get(wc).get();
- // cd = d;
- // }
- // }
- // }
- // }
- // }
- // return out;
- // }
-
-}
diff --git a/src/api/java/thaumcraft/api/wands/FocusUpgradeType.java b/src/api/java/thaumcraft/api/wands/FocusUpgradeType.java
deleted file mode 100644
index 32ee1ef..0000000
--- a/src/api/java/thaumcraft/api/wands/FocusUpgradeType.java
+++ /dev/null
@@ -1,159 +0,0 @@
-package thaumcraft.api.wands;
-
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-
-import org.apache.logging.log4j.LogManager;
-
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-
-public class FocusUpgradeType
-{
-
- public static FocusUpgradeType[] types = new FocusUpgradeType[20];
-
- public short id;
-
- public ResourceLocation icon;
-
- public String name;
-
- public String text;
-
- /**
- * What aspects are used to calculate the cost of this upgrade. The amounts given is ignored, just the type is used for the calculation.
- */
- public AspectList aspects;
-
- public FocusUpgradeType(int id, ResourceLocation icon, String name, String text, AspectList aspects)
- {
- this.id = (short) id;
- this.icon = icon;
- this.name = name;
- this.text = text;
- this.aspects = aspects;
-
- if(id < types.length && types[id] != null)
- {
- LogManager.getLogger("THAUMCRAFT").fatal("Focus Upgrade id " + id + " already occupied. Ignoring.");
- return;
- }
-
- // allocate space
- if(id >= types.length)
- {
- final FocusUpgradeType[] temp = new FocusUpgradeType[id + 1];
- System.arraycopy(types, 0, temp, 0, types.length);
- types = temp;
- }
-
- types[id] = this;
- }
-
- public String getLocalizedName()
- {
- return StatCollector.translateToLocal(name);
- }
-
- public String getLocalizedText()
- {
- return StatCollector.translateToLocal(text);
- }
-
- @Override
- public boolean equals(Object obj)
- {
- if(obj instanceof FocusUpgradeType)
- {
- return id == ((FocusUpgradeType) obj).id;
- }
- else
- {
- return false;
- }
- }
-
- // basic upgrade types
- public static FocusUpgradeType potency = new FocusUpgradeType(
- 0,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/potency.png"),
- "focus.upgrade.potency.name",
- "focus.upgrade.potency.text",
- new AspectList().add(Aspect.WEAPON, 1));
-
- public static FocusUpgradeType frugal = new FocusUpgradeType(
- 1,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/frugal.png"),
- "focus.upgrade.frugal.name",
- "focus.upgrade.frugal.text",
- new AspectList().add(Aspect.HUNGER, 1));
-
- public static FocusUpgradeType treasure = new FocusUpgradeType(
- 2,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/treasure.png"),
- "focus.upgrade.treasure.name",
- "focus.upgrade.treasure.text",
- new AspectList().add(Aspect.GREED, 1));
-
- public static FocusUpgradeType enlarge = new FocusUpgradeType(
- 3,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/enlarge.png"),
- "focus.upgrade.enlarge.name",
- "focus.upgrade.enlarge.text",
- new AspectList().add(Aspect.TRAVEL, 1));
-
- public static FocusUpgradeType alchemistsfire = new FocusUpgradeType(
- 4,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/alchemistsfire.png"),
- "focus.upgrade.alchemistsfire.name",
- "focus.upgrade.alchemistsfire.text",
- new AspectList().add(Aspect.ENERGY, 1).add(Aspect.SLIME, 1));
-
- public static FocusUpgradeType alchemistsfrost = new FocusUpgradeType(
- 5,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/alchemistsfrost.png"),
- "focus.upgrade.alchemistsfrost.name",
- "focus.upgrade.alchemistsfrost.text",
- new AspectList().add(Aspect.COLD, 1).add(Aspect.TRAP, 1));
-
- public static FocusUpgradeType architect = new FocusUpgradeType(
- 6,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/architect.png"),
- "focus.upgrade.architect.name",
- "focus.upgrade.architect.text",
- new AspectList().add(Aspect.CRAFT, 1));
-
- public static FocusUpgradeType extend = new FocusUpgradeType(
- 7,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/extend.png"),
- "focus.upgrade.extend.name",
- "focus.upgrade.extend.text",
- new AspectList().add(Aspect.EXCHANGE, 1));
-
- public static FocusUpgradeType silktouch = new FocusUpgradeType(
- 8,
- new ResourceLocation(
- "thaumcraft",
- "textures/foci/silktouch.png"),
- "focus.upgrade.silktouch.name",
- "focus.upgrade.silktouch.text",
- new AspectList().add(Aspect.GREED, 1));
-
-}
diff --git a/src/api/java/thaumcraft/api/wands/IWandRodOnUpdate.java b/src/api/java/thaumcraft/api/wands/IWandRodOnUpdate.java
deleted file mode 100644
index dbceaa5..0000000
--- a/src/api/java/thaumcraft/api/wands/IWandRodOnUpdate.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package thaumcraft.api.wands;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-
-/**
- *
- * @author azanor
- *
- * Implemented by a class that you wish to be called whenever a wand with this rod performs its
- * update tick.
- *
- */
-public interface IWandRodOnUpdate
-{
- void onUpdate(ItemStack itemstack, EntityPlayer player);
-}
diff --git a/src/api/java/thaumcraft/api/wands/IWandTriggerManager.java b/src/api/java/thaumcraft/api/wands/IWandTriggerManager.java
deleted file mode 100644
index ae47992..0000000
--- a/src/api/java/thaumcraft/api/wands/IWandTriggerManager.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package thaumcraft.api.wands;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-
-public interface IWandTriggerManager
-{
-
- /**
- * This class will be called by wands with the proper parameters. It is up to you to decide what to do with them.
- */
- public boolean performTrigger(World world, ItemStack wand, EntityPlayer player, int x, int y, int z, int side, int event);
-
-}
diff --git a/src/api/java/thaumcraft/api/wands/IWandable.java b/src/api/java/thaumcraft/api/wands/IWandable.java
deleted file mode 100644
index 7cc0362..0000000
--- a/src/api/java/thaumcraft/api/wands/IWandable.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package thaumcraft.api.wands;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-
-/**
- *
- * @author azanor
- *
- * Add this to a tile entity that you wish wands to interact with in some way.
- *
- */
-
-public interface IWandable
-{
-
- public int onWandRightClick(World world, ItemStack wandstack, EntityPlayer player, int x, int y, int z, int side, int md);
-
- public ItemStack onWandRightClick(World world, ItemStack wandstack, EntityPlayer player);
-
- public void onUsingWandTick(ItemStack wandstack, EntityPlayer player, int count);
-
- public void onWandStoppedUsing(ItemStack wandstack, World world, EntityPlayer player, int count);
-
-}
diff --git a/src/api/java/thaumcraft/api/wands/ItemFocusBasic.java b/src/api/java/thaumcraft/api/wands/ItemFocusBasic.java
deleted file mode 100644
index 70d0dba..0000000
--- a/src/api/java/thaumcraft/api/wands/ItemFocusBasic.java
+++ /dev/null
@@ -1,314 +0,0 @@
-package thaumcraft.api.wands;
-
-import java.text.DecimalFormat;
-import java.util.LinkedHashMap;
-import java.util.List;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.EnumRarity;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.nbt.NBTTagList;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.World;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class ItemFocusBasic extends Item
-{
-
- public ItemFocusBasic()
- {
- super();
- maxStackSize = 1;
- canRepair = false;
- setMaxDamage(0);
- }
-
- public IIcon icon;
-
- @SideOnly(Side.CLIENT)
- @Override
- public IIcon getIconFromDamage(int par1)
- {
- return icon;
- }
-
- @Override
- public boolean isDamageable()
- {
- return false;
- }
-
- @Override
- public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean par4)
- {
- final AspectList al = getVisCost(stack);
- if(al != null && al.size() > 0)
- {
- list.add(StatCollector.translateToLocal(isVisCostPerTick(stack) ? "item.Focus.cost2" : "item.Focus.cost1"));
- for(final Aspect aspect : al.getAspectsSorted())
- {
- final DecimalFormat myFormatter = new DecimalFormat("#####.##");
- final String amount = myFormatter.format(al.getAmount(aspect) / 100f);
- list.add(" \u00A7" + aspect.getChatcolor() + aspect.getName() + "\u00A7r x " + amount);
- }
- }
- addFocusInformation(stack, player, list, par4);
- }
-
- public void addFocusInformation(ItemStack focusstack, EntityPlayer player, List list, boolean par4)
- {
- final LinkedHashMap<Short, Integer> map = new LinkedHashMap<Short, Integer>();
- for(final short id : getAppliedUpgrades(focusstack))
- {
- if(id >= 0)
- {
- int amt = 1;
- if(map.containsKey(id))
- {
- amt = map.get(id) + 1;
- }
- map.put(id, amt);
- }
- }
- for(final Short id : map.keySet())
- {
- list.add(EnumChatFormatting.DARK_PURPLE + FocusUpgradeType.types[id].getLocalizedName() + (map.get(id) > 1 ? " " + StatCollector.translateToLocal("enchantment.level." + map.get(id)) : ""));
- }
- }
-
- /**
- * Purely for display on the focus tooltip (see addInformation method above)
- */
- public boolean isVisCostPerTick(ItemStack focusstack)
- {
- return false;
- }
-
- @Override
- public EnumRarity getRarity(ItemStack focusstack)
- {
- return EnumRarity.rare;
- }
-
- /**
- * What color will the focus orb be rendered on the held wand
- */
- public int getFocusColor(ItemStack focusstack)
- {
- return 0;
- }
-
- /**
- * Does the focus have ornamentation like the focus of the nine hells. Ornamentation is a standard icon rendered in a cross around the focus
- */
- public IIcon getOrnament(ItemStack focusstack)
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- /**
- * An icon to be rendered inside the focus itself
- */
- public IIcon getFocusDepthLayerIcon(ItemStack focusstack)
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- public enum WandFocusAnimation
- {
- WAVE, CHARGE;
- }
-
- public WandFocusAnimation getAnimation(ItemStack focusstack)
- {
- return WandFocusAnimation.WAVE;
- }
-
- /**
- * Just insert two alphanumeric characters before this string in your focus item class
- */
- public String getSortingHelper(ItemStack focusstack)
- {
- String out = "";
- for(final short id : getAppliedUpgrades(focusstack))
- {
- out = out + id;
- }
- return out;
- }
-
- /**
- * How much vis does this focus consume per activation.
- */
- public AspectList getVisCost(ItemStack focusstack)
- {
- return null;
- }
-
- /**
- * This returns how many milliseconds must pass before the focus can be activated again.
- */
- public int getActivationCooldown(ItemStack focusstack)
- {
- return 0;
- }
-
- /**
- * Used by foci like equal trade to determine their area in artchitect mode
- */
- public int getMaxAreaSize(ItemStack focusstack)
- {
- return 1;
- }
-
- /**
- * What upgrades can be applied to this focus for ranks 1 to 5
- */
- public FocusUpgradeType[] getPossibleUpgradesByRank(ItemStack focusstack, int rank)
- {
- return null;
- }
-
- /**
- * What upgrades does the focus currently have
- */
- public short[] getAppliedUpgrades(ItemStack focusstack)
- {
- final short[] l = new short[] {-1, -1, -1, -1, -1};
- final NBTTagList nbttaglist = getFocusUpgradeTagList(focusstack);
- if(nbttaglist == null)
- {
- return l;
- }
- else
- {
- for(int j = 0; j < nbttaglist.tagCount(); ++j)
- {
- if(j >= 5)
- {
- break;
- }
- l[j] = nbttaglist.getCompoundTagAt(j).getShort("id");
- }
-
- return l;
- }
- }
-
- public boolean applyUpgrade(ItemStack focusstack, FocusUpgradeType type, int rank)
- {
- final short[] upgrades = getAppliedUpgrades(focusstack);
- if(upgrades[rank - 1] != -1 || rank < 1 || rank > 5)
- {
- return false;
- }
- upgrades[rank - 1] = type.id;
- setFocusUpgradeTagList(focusstack, upgrades);
- return true;
- }
-
- /**
- * Use this method to define custom logic about which upgrades can be applied. This can be used to set up upgrade "trees"
- * that make certain upgrades available only when others are unlocked first, when certain research is completed, or similar logic.
- *
- */
- public boolean canApplyUpgrade(ItemStack focusstack, EntityPlayer player, FocusUpgradeType type, int rank)
- {
- return true;
- }
-
- /**
- * Does this focus have the passed upgrade type
- */
- public boolean isUpgradedWith(ItemStack focusstack, FocusUpgradeType focusUpgradetype)
- {
- return getUpgradeLevel(focusstack, focusUpgradetype) > 0;
- }
-
- /**
- * What level is the passed upgrade type on the focus. If it is not present it returns 0
- */
- public int getUpgradeLevel(ItemStack focusstack, FocusUpgradeType focusUpgradetype)
- {
- final short[] list = getAppliedUpgrades(focusstack);
- int level = 0;
- for(final short id : list)
- {
- if(id == focusUpgradetype.id)
- {
- level++;
- }
- }
- return level;
- }
-
- public ItemStack onFocusRightClick(ItemStack wandstack, World world, EntityPlayer player, MovingObjectPosition movingobjectposition)
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void onUsingFocusTick(ItemStack wandstack, EntityPlayer player, int count)
- {
- // TODO Auto-generated method stub
- }
-
- public void onPlayerStoppedUsingFocus(ItemStack wandstack, World world, EntityPlayer player, int count)
- {
- // TODO Auto-generated method stub
-
- }
-
- public boolean onFocusBlockStartBreak(ItemStack wandstack, int x, int y, int z, EntityPlayer player)
- {
- // TODO Auto-generated method stub
- return false;
- }
-
- /**
- * Internal helper methods
- */
- private NBTTagList getFocusUpgradeTagList(ItemStack focusstack)
- {
- return focusstack.stackTagCompound == null ? null : focusstack.stackTagCompound.getTagList("upgrade", 10);
- }
-
- private void setFocusUpgradeTagList(ItemStack focusstack, short[] upgrades)
- {
- if(!focusstack.hasTagCompound())
- {
- focusstack.setTagCompound(new NBTTagCompound());
- }
- final NBTTagCompound nbttagcompound = focusstack.getTagCompound();
- final NBTTagList tlist = new NBTTagList();
- nbttagcompound.setTag("upgrade", tlist);
- for(final short id : upgrades)
- {
- final NBTTagCompound f = new NBTTagCompound();
- f.setShort("id", id);
- tlist.appendTag(f);
- }
- }
-
- @Override
- public void onUpdate(ItemStack stack, World world, Entity entity, int p_77663_4_, boolean p_77663_5_)
- {
- if(stack.stackTagCompound != null && stack.stackTagCompound.hasKey("ench"))
- {
- stack.stackTagCompound.removeTag("ench");
- }
- super.onUpdate(stack, world, entity, p_77663_4_, p_77663_5_);
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/wands/StaffRod.java b/src/api/java/thaumcraft/api/wands/StaffRod.java
deleted file mode 100644
index 1dc474c..0000000
--- a/src/api/java/thaumcraft/api/wands/StaffRod.java
+++ /dev/null
@@ -1,53 +0,0 @@
-package thaumcraft.api.wands;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ResourceLocation;
-
-/**
- *
- * @author Azanor
- *
- * This class is used to keep the material information for the various rods.
- * It is also used to generate the wand recipes ingame.
- *
- */
-public class StaffRod extends WandRod
-{
-
- boolean runes = false;
-
- public StaffRod(String tag, int capacity, ItemStack item, int craftCost)
- {
- super(tag + "_staff", capacity, item, craftCost);
- texture = new ResourceLocation("thaumcraft",
- "textures/models/wand_rod_" + tag + ".png");
- }
-
- public StaffRod(String tag, int capacity, ItemStack item, int craftCost, IWandRodOnUpdate onUpdate, ResourceLocation texture)
- {
- super(tag + "_staff", capacity, item, craftCost, onUpdate, texture);
- }
-
- public StaffRod(String tag, int capacity, ItemStack item, int craftCost, IWandRodOnUpdate onUpdate)
- {
- super(tag + "_staff", capacity, item, craftCost, onUpdate);
- texture = new ResourceLocation("thaumcraft",
- "textures/models/wand_rod_" + tag + ".png");
- }
-
- public StaffRod(String tag, int capacity, ItemStack item, int craftCost, ResourceLocation texture)
- {
- super(tag + "_staff", capacity, item, craftCost, texture);
- }
-
- public boolean hasRunes()
- {
- return runes;
- }
-
- public void setRunes(boolean hasRunes)
- {
- runes = hasRunes;
- }
-
-}
diff --git a/src/api/java/thaumcraft/api/wands/WandCap.java b/src/api/java/thaumcraft/api/wands/WandCap.java
deleted file mode 100644
index e5726ef..0000000
--- a/src/api/java/thaumcraft/api/wands/WandCap.java
+++ /dev/null
@@ -1,145 +0,0 @@
-package thaumcraft.api.wands;
-
-import java.util.LinkedHashMap;
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ResourceLocation;
-import thaumcraft.api.aspects.Aspect;
-
-/**
- * This class is used to keep the material information for the various caps.
- * It is also used to generate the wand recipes ingame.
- * @author Azanor
- *
- */
-public class WandCap
-{
-
- private String tag;
-
- /**
- * Cost to craft this wand. Combined with the rod cost.
- */
- private int craftCost;
-
- /**
- * the amount by which all aspect costs are multiplied
- */
- float baseCostModifier;
-
- /**
- * specifies a list of primal aspects that use the special discount figure instead of the normal discount.
- */
- List<Aspect> specialCostModifierAspects;
-
- /**
- * the amount by which the specified aspect costs are multiplied
- */
- float specialCostModifier;
-
- /**
- * The texture that will be used for the ingame wand cap
- */
- ResourceLocation texture;
-
- /**
- * the actual item that makes up this cap and will be used to generate the wand recipes
- */
- ItemStack item;
-
- public static LinkedHashMap<String, WandCap> caps = new LinkedHashMap<String, WandCap>();
-
- public WandCap(String tag, float discount, ItemStack item, int craftCost)
- {
- setTag(tag);
- baseCostModifier = discount;
- specialCostModifierAspects = null;
- texture = new ResourceLocation("thaumcraft",
- "textures/models/wand_cap_" + getTag() + ".png");
- this.item = item;
- setCraftCost(craftCost);
- caps.put(tag, this);
- }
-
- public WandCap(String tag, float discount, List<Aspect> specialAspects, float discountSpecial, ItemStack item, int craftCost)
- {
- setTag(tag);
- baseCostModifier = discount;
- specialCostModifierAspects = specialAspects;
- specialCostModifier = discountSpecial;
- texture = new ResourceLocation("thaumcraft",
- "textures/models/wand_cap_" + getTag() + ".png");
- this.item = item;
- setCraftCost(craftCost);
- caps.put(tag, this);
- }
-
- public float getBaseCostModifier()
- {
- return baseCostModifier;
- }
-
- public List<Aspect> getSpecialCostModifierAspects()
- {
- return specialCostModifierAspects;
- }
-
- public float getSpecialCostModifier()
- {
- return specialCostModifier;
- }
-
- public ResourceLocation getTexture()
- {
- return texture;
- }
-
- public void setTexture(ResourceLocation texture)
- {
- this.texture = texture;
- }
-
- public String getTag()
- {
- return tag;
- }
-
- public void setTag(String tag)
- {
- this.tag = tag;
- }
-
- public ItemStack getItem()
- {
- return item;
- }
-
- public void setItem(ItemStack item)
- {
- this.item = item;
- }
-
- public int getCraftCost()
- {
- return craftCost;
- }
-
- public void setCraftCost(int craftCost)
- {
- this.craftCost = craftCost;
- }
-
- /**
- * The research a player needs to have finished to be able to craft a wand with this cap.
- */
- public String getResearch()
- {
- return "CAP_" + getTag();
- }
-
- // Some examples:
- // WandCap WAND_CAP_IRON = new WandCap("iron", 1.1f, Arrays.asList(Aspect.ORDER),1, new ItemStack(ConfigItems.itemWandCap,1,0),1);
- // WandCap WAND_CAP_GOLD = new WandCap("gold", 1f, new ItemStack(ConfigItems.itemWandCap,1,1),3);
-
-}
diff --git a/src/api/java/thaumcraft/api/wands/WandRod.java b/src/api/java/thaumcraft/api/wands/WandRod.java
deleted file mode 100644
index 9b6907d..0000000
--- a/src/api/java/thaumcraft/api/wands/WandRod.java
+++ /dev/null
@@ -1,179 +0,0 @@
-package thaumcraft.api.wands;
-
-import java.util.LinkedHashMap;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ResourceLocation;
-
-/**
- *
- * @author Azanor
- *
- * This class is used to keep the material information for the various rods.
- * It is also used to generate the wand recipes ingame.
- *
- */
-public class WandRod
-{
-
- private String tag;
-
- /**
- * Cost to craft this wand. Combined with the rod cost.
- */
- private int craftCost;
-
- /**
- * The amount of vis that can be stored - this number is actually multiplied
- * by 100 for use by the wands internals
- */
- int capacity;
-
- /**
- * The texture that will be used for the ingame wand rod
- */
- protected ResourceLocation texture;
-
- /**
- * the actual item that makes up this rod and will be used to generate the wand recipes
- */
- ItemStack item;
-
- /**
- * A class that will be called whenever the wand onUpdate tick is run
- */
- IWandRodOnUpdate onUpdate;
-
- /**
- * Does the rod glow in the dark?
- */
- boolean glow;
-
- public static LinkedHashMap<String, WandRod> rods = new LinkedHashMap<String, WandRod>();
-
- public WandRod(String tag, int capacity, ItemStack item, int craftCost, ResourceLocation texture)
- {
- setTag(tag);
- this.capacity = capacity;
- this.texture = texture;
- this.item = item;
- setCraftCost(craftCost);
- rods.put(tag, this);
- }
-
- public WandRod(String tag, int capacity, ItemStack item, int craftCost, IWandRodOnUpdate onUpdate, ResourceLocation texture)
- {
- setTag(tag);
- this.capacity = capacity;
- this.texture = texture;
- this.item = item;
- setCraftCost(craftCost);
- rods.put(tag, this);
- this.onUpdate = onUpdate;
- }
-
- public WandRod(String tag, int capacity, ItemStack item, int craftCost)
- {
- setTag(tag);
- this.capacity = capacity;
- texture = new ResourceLocation("thaumcraft",
- "textures/models/wand_rod_" + getTag() + ".png");
- this.item = item;
- setCraftCost(craftCost);
- rods.put(tag, this);
- }
-
- public WandRod(String tag, int capacity, ItemStack item, int craftCost, IWandRodOnUpdate onUpdate)
- {
- setTag(tag);
- this.capacity = capacity;
- texture = new ResourceLocation("thaumcraft",
- "textures/models/wand_rod_" + getTag() + ".png");
- this.item = item;
- setCraftCost(craftCost);
- rods.put(tag, this);
- this.onUpdate = onUpdate;
- }
-
- public String getTag()
- {
- return tag;
- }
-
- public void setTag(String tag)
- {
- this.tag = tag;
- }
-
- public int getCapacity()
- {
- return capacity;
- }
-
- public void setCapacity(int capacity)
- {
- this.capacity = capacity;
- }
-
- public ResourceLocation getTexture()
- {
- return texture;
- }
-
- public void setTexture(ResourceLocation texture)
- {
- this.texture = texture;
- }
-
- public ItemStack getItem()
- {
- return item;
- }
-
- public void setItem(ItemStack item)
- {
- this.item = item;
- }
-
- public int getCraftCost()
- {
- return craftCost;
- }
-
- public void setCraftCost(int craftCost)
- {
- this.craftCost = craftCost;
- }
-
- public IWandRodOnUpdate getOnUpdate()
- {
- return onUpdate;
- }
-
- public void setOnUpdate(IWandRodOnUpdate onUpdate)
- {
- this.onUpdate = onUpdate;
- }
-
- public boolean isGlowing()
- {
- return glow;
- }
-
- public void setGlowing(boolean hasGlow)
- {
- glow = hasGlow;
- }
-
- /**
- * The research a player needs to have finished to be able to craft a wand with this rod.
- */
- public String getResearch()
- {
- return "ROD_" + getTag();
- }
-
- // Some examples:
- // WandRod WAND_ROD_WOOD = new WandRod("wood",25,new ItemStack(Item.stick),1);
- // WandRod WAND_ROD_BLAZE = new WandRod("blaze",100,new ItemStack(Item.blazeRod),7,new WandRodBlazeOnUpdate());
-}
diff --git a/src/api/java/thaumcraft/api/wands/WandTriggerRegistry.java b/src/api/java/thaumcraft/api/wands/WandTriggerRegistry.java
deleted file mode 100644
index c9c24f2..0000000
--- a/src/api/java/thaumcraft/api/wands/WandTriggerRegistry.java
+++ /dev/null
@@ -1,158 +0,0 @@
-package thaumcraft.api.wands;
-
-import java.util.Arrays;
-import java.util.HashMap;
-import java.util.List;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-
-/**
- * This class serves a similar function to IWandable in that it allows wands to interact
- * with object in the world. In this case it is most useful for adding interaction with non-mod
- * blocks where you can't control what happens in their code.
- * Example where it is used is in crafting the thaumonomicon from a bookshelf and the
- * crucible from a cauldron
- *
- * @author azanor
- *
- */
-public class WandTriggerRegistry
-{
-
- private static HashMap<String, HashMap<List, List>> triggers = new HashMap<String, HashMap<List, List>>();
- private static final String DEFAULT = "default";
-
- /**
- * Registers an action to perform when a casting wand right clicks on a specific block.
- * A manager class needs to be created that implements IWandTriggerManager.
- * @param manager
- * @param event a logical number that you can use to differentiate different events or actions
- * @param block
- * @param meta send -1 as a wildcard value for all possible meta values
- * @param modid a unique identifier. It is best to register your own triggers using your mod id to avoid conflicts with mods that register triggers for the same block
- */
- public static void registerWandBlockTrigger(IWandTriggerManager manager, int event, Block block, int meta, String modid)
- {
- if(!triggers.containsKey(modid))
- {
- triggers.put(modid, new HashMap<List, List>());
- }
- final HashMap<List, List> temp = triggers.get(modid);
- temp.put(Arrays.asList(block, meta), Arrays.asList(manager, event));
- triggers.put(modid, temp);
- }
-
- /**
- * for legacy support
- */
- public static void registerWandBlockTrigger(IWandTriggerManager manager, int event, Block block, int meta)
- {
- registerWandBlockTrigger(manager, event, block, meta, DEFAULT);
- }
-
- /**
- * Checks all trigger registries if one exists for the given block and meta
- * @param block
- * @param meta
- * @return
- */
- public static boolean hasTrigger(Block block, int meta)
- {
- for(final String modid : triggers.keySet())
- {
- final HashMap<List, List> temp = triggers.get(modid);
- if(temp.containsKey(Arrays.asList(block, meta)) || temp.containsKey(Arrays.asList(block, -1)))
- {
- return true;
- }
- }
- return false;
- }
-
- /**
- * modid sensitive version
- */
- public static boolean hasTrigger(Block block, int meta, String modid)
- {
- if(!triggers.containsKey(modid))
- {
- return false;
- }
- final HashMap<List, List> temp = triggers.get(modid);
- if(temp.containsKey(Arrays.asList(block, meta)) || temp.containsKey(Arrays.asList(block, -1)))
- {
- return true;
- }
- return false;
- }
-
- /**
- * This is called by the onItemUseFirst function in wands.
- * Parameters and return value functions like you would expect for that function.
- * @param world
- * @param wand
- * @param player
- * @param x
- * @param y
- * @param z
- * @param side
- * @param block
- * @param meta
- * @return
- */
- public static boolean performTrigger(World world, ItemStack wand, EntityPlayer player, int x, int y, int z, int side, Block block, int meta)
- {
-
- for(final String modid : triggers.keySet())
- {
- final HashMap<List, List> temp = triggers.get(modid);
- List l = temp.get(Arrays.asList(block, meta));
- if(l == null)
- {
- l = temp.get(Arrays.asList(block, -1));
- }
- if(l == null)
- {
- continue;
- }
-
- final IWandTriggerManager manager = (IWandTriggerManager) l.get(0);
- final int event = (Integer) l.get(1);
- final boolean result = manager.performTrigger(world, wand, player, x, y, z, side, event);
- if(result)
- {
- return true;
- }
- }
- return false;
- }
-
- /**
- * modid sensitive version
- */
- public static boolean performTrigger(World world, ItemStack wand, EntityPlayer player, int x, int y, int z, int side, Block block, int meta, String modid)
- {
- if(!triggers.containsKey(modid))
- {
- return false;
- }
- final HashMap<List, List> temp = triggers.get(modid);
- List l = temp.get(Arrays.asList(block, meta));
- if(l == null)
- {
- l = temp.get(Arrays.asList(block, -1));
- }
- if(l == null)
- {
- return false;
- }
-
- final IWandTriggerManager manager = (IWandTriggerManager) l.get(0);
- final int event = (Integer) l.get(1);
- return manager.performTrigger(world, wand, player, x, y, z, side, event);
- }
-
-}
diff --git a/src/api/java/zeldaswordskills/api/item/ISword.java b/src/api/java/zeldaswordskills/api/item/ISword.java
deleted file mode 100644
index 5a996fe..0000000
--- a/src/api/java/zeldaswordskills/api/item/ISword.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/**
- Copyright (C) <2014> <coolAlias>
-
- This file is part of coolAlias' Zelda Sword Skills Minecraft Mod; as such,
- you can redistribute it and/or modify it under the terms of the GNU
- General Public License as published by the Free Software Foundation,
- either version 3 of the License, or (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-
-package zeldaswordskills.api.item;
-
-/**
- *
- * For the purpose of using certain skills, this item will be considered a sword.
- *
- * Skills which require a sword are:
- * {@link LeapingBlow}, {@link MortalDraw}, {@link RisingCut}, and {@link SwordBeam}
- *
- */
-public interface ISword
-{
-
-}
diff --git a/src/api/java/zeldaswordskills/api/item/package-info.java b/src/api/java/zeldaswordskills/api/item/package-info.java
deleted file mode 100644
index 3719df9..0000000
--- a/src/api/java/zeldaswordskills/api/item/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(owner = "zeldaswordskills", provides = "ZeldaItemAPI", apiVersion = "0.3")
-package zeldaswordskills.api.item;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/api/java/zeldaswordskills/api/package-info.java b/src/api/java/zeldaswordskills/api/package-info.java
deleted file mode 100644
index 89fe947..0000000
--- a/src/api/java/zeldaswordskills/api/package-info.java
+++ /dev/null
@@ -1,5 +0,0 @@
-@API(owner = "zeldaswordskills", provides = "ZeldaAPI", apiVersion = "0.3")
-package zeldaswordskills.api;
-
-import cpw.mods.fml.common.API;
-
diff --git a/src/main/java/lance5057/tDefense/PacketHandler.java b/src/main/java/lance5057/tDefense/PacketHandler.java
new file mode 100644
index 0000000..f48202c
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/PacketHandler.java
@@ -0,0 +1,18 @@
+
+package lance5057.tDefense;
+
+import lance5057.tDefense.core.blocks.crestMount.Handler_CrestMount;
+import lance5057.tDefense.core.blocks.crestMount.Message_CrestMount;
+import net.minecraftforge.fml.relauncher.Side;
+
+public class PacketHandler
+{
+ private static int id = 0;
+
+ public static void init()
+ {
+ TinkersDefense.INSTANCE.registerMessage(Handler_CrestMount.class, Message_CrestMount.class, id++, Side.SERVER);
+ //TinkersDefense.INSTANCE.registerMessage(Handler_FinishingAnvil.class, Message_FinishingAnvil.class, id++, Side.SERVER);
+
+ }
+} \ No newline at end of file
diff --git a/src/main/java/lance5057/tDefense/Reference.java b/src/main/java/lance5057/tDefense/Reference.java
index ad316d1..61a1aec 100644
--- a/src/main/java/lance5057/tDefense/Reference.java
+++ b/src/main/java/lance5057/tDefense/Reference.java
@@ -4,7 +4,7 @@ public class Reference
{
public static final String MOD_ID = "tinkersdefense";
- public static final String VERSION = "1.4.0.4a";
+ public static final String VERSION = "1.4.0.8a";
public static final String MOD_NAME = "Tinkers' Defense";
}
diff --git a/src/main/java/lance5057/tDefense/TDIntegration.java b/src/main/java/lance5057/tDefense/TDIntegration.java
deleted file mode 100644
index 6ce662d..0000000
--- a/src/main/java/lance5057/tDefense/TDIntegration.java
+++ /dev/null
@@ -1,31 +0,0 @@
-package lance5057.tDefense;
-
-import cpw.mods.fml.common.Loader;
-
-public final class TDIntegration
-{
- public static boolean mineAndBlade = false;
- public static boolean thaumcraft = false;
- public static boolean botania = false;
- public static boolean bloodMagic = false;
-
- public static void Integrate()
- {
- if(Loader.isModLoaded("battlegear2") && TinkersDefense.config.MineAndBladeAddon)
- {
- mineAndBlade = true;
- }
- if(Loader.isModLoaded("Thaumcraft") && TinkersDefense.config.ThaumcraftAddon)
- {
- thaumcraft = true;
- }
- if(Loader.isModLoaded("Botania") && TinkersDefense.config.BotaniaAddon)
- {
- botania = true;
- }
- if(Loader.isModLoaded("AWWayofTime") && TinkersDefense.config.BloodMagicAddon)
- {
- bloodMagic = true;
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/TD_Commands.java b/src/main/java/lance5057/tDefense/TD_Commands.java
index 66e40c4..e97f303 100644
--- a/src/main/java/lance5057/tDefense/TD_Commands.java
+++ b/src/main/java/lance5057/tDefense/TD_Commands.java
@@ -44,22 +44,22 @@ public class TD_Commands extends CommandBase implements ICommand
// }
@Override
- public String getCommandName()
+ public String getName()
{
return "TinkersDefense";
}
@Override
- public String getCommandUsage(ICommandSender p_71518_1_)
+ public String getUsage(ICommandSender p_71518_1_)
{
return "TinkersDefense <text>";
}
- @Override
- public List getCommandAliases()
- {
- return aliases;
- }
+// @Override
+// public List getCommandAliases()
+// {
+// return aliases;
+// }
@Override
public void execute(MinecraftServer server, ICommandSender p_71515_1_, String[] p_71515_2_)
@@ -93,12 +93,12 @@ public class TD_Commands extends CommandBase implements ICommand
TinkersDefense.config.debug = !TinkersDefense.config.debug;
if(TinkersDefense.config.debug)
{
- p_71515_1_.addChatMessage(new TextComponentString(
+ p_71515_1_.sendMessage(new TextComponentString(
"§9[TDefense]§f - Debug Mode on."));
}
else
{
- p_71515_1_.addChatMessage(new TextComponentString(
+ p_71515_1_.sendMessage(new TextComponentString(
"§9[TDefense]§f - Debug Mode off."));
}
@@ -109,7 +109,7 @@ public class TD_Commands extends CommandBase implements ICommand
}
else
{
- p_71515_1_.addChatMessage(new TextComponentString(
+ p_71515_1_.sendMessage(new TextComponentString(
"§c[TDefense]§f - Invalid Command"));
}
}
@@ -133,6 +133,7 @@ public class TD_Commands extends CommandBase implements ICommand
return false;
}
+
// public void reloadModels()
// {
// TinkersDefense.proxy.registerRenderers();
diff --git a/src/main/java/lance5057/tDefense/TinkersDefense.java b/src/main/java/lance5057/tDefense/TinkersDefense.java
index bf58ba3..e75fdf2 100644
--- a/src/main/java/lance5057/tDefense/TinkersDefense.java
+++ b/src/main/java/lance5057/tDefense/TinkersDefense.java
@@ -3,6 +3,7 @@ package lance5057.tDefense;
import java.util.Iterator;
import java.util.List;
+import lance5057.tDefense.baubles.BaublesBase;
import lance5057.tDefense.core.CoreBase;
import lance5057.tDefense.core.materials.TDMaterials;
import lance5057.tDefense.core.tools.TDTools;
@@ -29,14 +30,17 @@ public class TinkersDefense {
private static int modGuiIndex = 0;
public static final int GUI_CREST_INV = modGuiIndex++;
- public static final int GUI_ANVIL_INV = modGuiIndex++;
- public static final int GUI_GUIDEBOOK = modGuiIndex++;
+ //public static final int GUI_ANVIL_INV = modGuiIndex++;
+ //public static final int GUI_GUIDEBOOK = modGuiIndex++;
@Instance(Reference.MOD_ID)
public static TinkersDefense instance = new TinkersDefense();
+
+ PacketHandler phandler = new PacketHandler();
HolidayBase holiday;
ModuleBase core;
+ ModuleBase baubles;
// public static TDEventHandler TDevents;
@@ -117,6 +121,8 @@ public class TinkersDefense {
public void preInit(FMLPreInitializationEvent e) {
core = new CoreBase();
holiday = new HolidayBase();
+ baubles = new BaublesBase();
+
mats = new TDMaterials();
tools = new TDTools();
config = new TD_Config(e);
@@ -315,9 +321,10 @@ public class TinkersDefense {
// mods.preInit();
// proxy.registerRenderers();
- core.preInit();
- holiday.preInit();
+ core.preInit(e);
+ holiday.preInit(e);
tools.preInit(e);
+ baubles.preInit(e);
proxy.preInit();
}
@@ -326,16 +333,20 @@ public class TinkersDefense {
// I reject your moss and substitute my own!
if (config.mossEnabled || config.mossHard) {
- }
+
final List<IRecipe> recipes = CraftingManager.getInstance()
.getRecipeList();
final Iterator<IRecipe> recipe = recipes.iterator();
+ }
- core.init();
- holiday.init();
+ core.init(e);
+ holiday.init(e);
mats.setupMaterials(e);
tools.init(e);
- proxy.Init();
+ baubles.init(e);
+ proxy.init();
+
+ phandler.init();
}
@EventHandler
diff --git a/src/main/java/lance5057/tDefense/armor/ArmorCore.java b/src/main/java/lance5057/tDefense/armor/ArmorCore.java
index 1c63062..3291523 100644
--- a/src/main/java/lance5057/tDefense/armor/ArmorCore.java
+++ b/src/main/java/lance5057/tDefense/armor/ArmorCore.java
@@ -1,69 +1,54 @@
package lance5057.tDefense.armor;
-import lance5057.tDefense.TDIntegration;
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.parts.ClothMaterial;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.core.tools.modifiers.Modifiers;
import net.minecraft.client.model.ModelBiped;
-import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
+import net.minecraft.inventory.EntityEquipmentSlot;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.DamageSource;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.world.World;
import net.minecraftforge.common.ISpecialArmor;
-
-import org.lwjgl.opengl.GL11;
-
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.tools.AbilityHelper;
-import tconstruct.library.tools.CustomMaterial;
-import tconstruct.library.tools.ToolCore;
-import thaumcraft.api.IRunicArmor;
-import vazkii.botania.api.item.IPixieSpawner;
-import cpw.mods.fml.client.FMLClientHandler;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IRunicArmor", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.item.IPixieSpawner", striprefs = true)})
-public abstract class ArmorCore extends ToolCore implements ISpecialArmor, IRunicArmor, IPixieSpawner
+import net.minecraftforge.fml.relauncher.Side;
+import net.minecraftforge.fml.relauncher.SideOnly;
+import slimeknights.tconstruct.library.tinkering.PartMaterialType;
+import slimeknights.tconstruct.library.tools.ToolCore;
+
+//@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IRunicArmor", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.item.IPixieSpawner", striprefs = true)})
+public abstract class ArmorCore extends ToolCore implements ISpecialArmor// ,
+ // IRunicArmor,
+ // IPixieSpawner
{
- int slot;
- public float reductionPercent = 0f;
- protected int maxReduction = 100;
+ public final EntityEquipmentSlot armorType;
+ public float reductionPercent = 0f;
+ protected int maxReduction = 100;
- //public String[] renderParts;
+ // public String[] renderParts;
- //Thaumcraft
- boolean Charge = false;
+ // Thaumcraft
+ boolean Charge = false;
- public ArmorCore(int baseProtection, int slot)
- {
- super(baseProtection);
-
- this.slot = slot;
+ public ArmorCore(EntityEquipmentSlot slot, PartMaterialType... requiredComponents) {
+ super(requiredComponents);
+ armorType = slot;
//MinecraftForge.EVENT_BUS.register(this);
}
+ @SideOnly(Side.CLIENT)
+ public EntityEquipmentSlot getEquipmentSlot() {
+ return this.armorType;
+ }
+
@Override
- public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage, int slot)
- {
+ public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage,
+ int slot) {
ArmorProperties armorp;
- if(!source.isUnblockable())
- {
+ if (!source.isUnblockable()) {
armorp = new ArmorProperties(0, reductionPercent, maxReduction); // 0.04
// per
// half
// shirt
- }
- else
- {
+ } else {
armorp = new ArmorProperties(0, 0, 0);
}
@@ -71,239 +56,223 @@ public abstract class ArmorCore extends ToolCore implements ISpecialArmor, IRuni
}
@Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
+ public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot) {
return (int) ((int) reductionPercent / 0.04);
}
- public int getSlot()
- {
- return slot;
- }
-
@SideOnly(Side.CLIENT)
- public ModelBiped getModel(String[] color, NBTTagCompound tags)
- {
+ public ModelBiped getModel(String[] color, NBTTagCompound tags) {
return null;
}
- @Override
- public boolean isValidArmor(ItemStack stack, int armorType, Entity entity)
- {
- return armorType == slot;
- }
-
- @Override
- public void damageArmor(EntityLivingBase entity, ItemStack stack, DamageSource source, int damage, int slot)
- {
- AbilityHelper.damageTool(stack, damage, entity, false);
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ModelBiped getArmorModel(EntityLivingBase entityLiving, ItemStack itemStack, int armorSlot)
- {
- if(itemStack.getItem() instanceof ToolCore)
- {
- final String[] color = new String[10];
- final ToolCore tool = (ToolCore) itemStack.getItem();
-
- for(int j = 0; j < 10; j++)
- {
- color[j] = Integer.toHexString(itemStack.getItem().getColorFromItemStack(itemStack, j));
-
- switch(j)
- {
- case 0:
- if(tool.getHandleItem() == TinkersDefense.partCloth)
- {
- final int ID = itemStack.getTagCompound().getCompoundTag("InfiTool").getInteger("RenderHandle");
-
- final CustomMaterial newColor = TConstructRegistry.getCustomMaterial(ID, ClothMaterial.class);
- color[j] = Integer.toHexString(newColor.color);
- }
- break;
-
- case 1:
- if(tool.getHeadItem() == TinkersDefense.partCloth)
- {
- final int ID = itemStack.getTagCompound().getCompoundTag("InfiTool").getInteger("RenderHead");
-
- final CustomMaterial newColor = TConstructRegistry.getCustomMaterial(ID, ClothMaterial.class);
- color[j] = Integer.toHexString(newColor.color);
- }
- break;
-
- case 2:
- if(tool.getAccessoryItem() != null && tool.getAccessoryItem() == TinkersDefense.partCloth)
- {
- final int ID = itemStack.getTagCompound().getCompoundTag("InfiTool").getInteger("RenderAccessory");
-
- final CustomMaterial newColor = TConstructRegistry.getCustomMaterial(ID, ClothMaterial.class);
- color[j] = Integer.toHexString(newColor.color);
- }
- break;
-
- case 3:
- if(tool.getExtraItem() != null && tool.getExtraItem() == TinkersDefense.partCloth)
- {
- final int ID = itemStack.getTagCompound().getCompoundTag("InfiTool").getInteger("RenderExtra");
-
- final CustomMaterial newColor = TConstructRegistry.getCustomMaterial(ID, ClothMaterial.class);
- color[j] = Integer.toHexString(newColor.color);
- }
- break;
- }
- }
-
- final ArmorRenderer model = getRenderer();
- model.SetColors(color, getDefaultFolder(), itemStack);
- return model;
- }
- return null;
- }
-
- @SideOnly(Side.CLIENT)
- public abstract ArmorRenderer getRenderer();
-
- @Override
- public Item getAccessoryItem()
- {
- return null;
- }
-
- @Override
- public String getDefaultFolder()
- {
- return null;
- }
-
- @Override
- public String getEffectSuffix()
- {
- return null;
- }
-
- @Override
- public Item getHeadItem()
- {
- return null;
- }
-
- @Override
- public String getIconSuffix(int arg0)
- {
- return null;
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor"};
- }
-
- @Override
- public void onArmorTick(World world, EntityPlayer player, ItemStack itemStack)
- {
-
- Modifiers.AMod.UpdateAll((ToolCore) itemStack.getItem(), itemStack, world, player, itemStack.getTagCompound().getCompoundTag("InfiTool"));
- }
-
- @Override
- public int getRunicCharge(ItemStack itemstack)
- {
- return 0;
- }
-
- @Override
- public void onUpdate(ItemStack stack, World world, Entity ent, int p_77663_4_, boolean p_77663_5_)
- {
- //Check if runic shielding level has changed
- if(TDIntegration.thaumcraft)
- {
- final NBTTagCompound tcTag = stack.getTagCompound();
- final NBTTagCompound ticoTag = stack.getTagCompound().getCompoundTag("InfiTool");
-
- final byte rs = tcTag.getByte("RS.HARDEN");
- if(!Charge && rs > 0)
- {
- if(ticoTag.getInteger("Modifiers") > 0)
- {
- ticoTag.setInteger("Modifiers", ticoTag.getInteger("Modifiers") - 1);
- Charge = true;
- }
- else
- {
- tcTag.removeTag("RS.HARDEN");
- }
- }
- }
- }
-
- @SideOnly(Side.CLIENT)
- public void renderArmor(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, String[] colors, ItemStack stack, int pass)
- {
-
- final ResourceLocation rc = new ResourceLocation(
- "tinkersdefense:textures/" + getDefaultFolder() + "/" + getTexture(pass, stack) + ".png");
- FMLClientHandler.instance().getClient().renderEngine.bindTexture(rc);
-
- final float size = 1.6f;
- GL11.glScalef(1.0F / size, 1.0F / size, 1.0F / size);
- GL11.glTranslatef(0.0F, -0.01F, 0.0F);
-
- final int[] intColors = TinkersDefense.hexToRGB(colors[pass]);
- GL11.glColor3d((float) intColors[0] / 255, (float) intColors[1] / 255, (float) intColors[2] / 255);
-
- }
-
- @SideOnly(Side.CLIENT)
- public String getTexture(int pass, ItemStack stack)
- {
- final NBTTagCompound tags = stack.getTagCompound().getCompoundTag("InfiTool");
- String renderReturn = "";
- switch(pass)
- {
- case 0:
- renderReturn = handleStrings.get(tags.getInteger("RenderHandle"));
- break;
- case 1:
- renderReturn = headStrings.get(tags.getInteger("RenderHead"));
- break;
- case 2:
- renderReturn = accessoryStrings.get(tags.getInteger("RenderAccessory"));
- break;
- case 3:
- renderReturn = extraStrings.get(tags.getInteger("RenderExtra"));
- break;
- //
- // default:
- // if(tags != null && tags.hasKey("Effect" + (pass - getPartAmount())))
- // {
- // final String effect = effectStrings.get(tags.getInteger("Effect" + (pass - getPartAmount())));
- // if(effect != null)
- // return effect.substring(effect.lastIndexOf("/") + 1);
- // else
- // return "";
- //
- // }
- }
- if(renderReturn != null && renderReturn != "")
- {
- renderReturn = renderReturn.substring(renderReturn.indexOf("_"));
- }
- else
- {
- renderReturn = "";
- }
-
- return renderReturn;
- }
-
- @Override
- public float getPixieChance(ItemStack stack)
- {
- final float chance = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ElementiumCore") * 5 / 100f;
- return chance;
- }
+// @Override
+// public void damageArmor(EntityLivingBase entity, ItemStack stack, DamageSource source, int damage, int slot) {
+// AbilityHelper.damageTool(stack, damage, entity, false);
+// }
+
+// @Override
+// @SideOnly(Side.CLIENT)
+// public ModelBiped getArmorModel(EntityLivingBase entityLiving, ItemStack itemStack, int armorSlot) {
+// if (itemStack.getItem() instanceof ToolCore) {
+// final String[] color = new String[10];
+// final ToolCore tool = (ToolCore) itemStack.getItem();
+//
+// for (int j = 0; j < 10; j++) {
+// color[j] = Integer.toHexString(itemStack.getItem().getColorFromItemStack(itemStack, j));
+//
+// switch (j) {
+// case 0:
+// if (tool.getHandleItem() == TinkersDefense.partCloth) {
+// final int ID = itemStack.getTagCompound().getCompoundTag("InfiTool").getInteger("RenderHandle");
+//
+// final CustomMaterial newColor = TConstructRegistry.getCustomMaterial(ID, ClothMaterial.class);
+// color[j] = Integer.toHexString(newColor.color);
+// }
+// break;
+//
+// case 1:
+// if (tool.getHeadItem() == TinkersDefense.partCloth) {
+// final int ID = itemStack.getTagCompound().getCompoundTag("InfiTool").getInteger("RenderHead");
+//
+// final CustomMaterial newColor = TConstructRegistry.getCustomMaterial(ID, ClothMaterial.class);
+// color[j] = Integer.toHexString(newColor.color);
+// }
+// break;
+//
+// case 2:
+// if (tool.getAccessoryItem() != null && tool.getAccessoryItem() == TinkersDefense.partCloth) {
+// final int ID = itemStack.getTagCompound().getCompoundTag("InfiTool")
+// .getInteger("RenderAccessory");
+//
+// final CustomMaterial newColor = TConstructRegistry.getCustomMaterial(ID, ClothMaterial.class);
+// color[j] = Integer.toHexString(newColor.color);
+// }
+// break;
+//
+// case 3:
+// if (tool.getExtraItem() != null && tool.getExtraItem() == TinkersDefense.partCloth) {
+// final int ID = itemStack.getTagCompound().getCompoundTag("InfiTool").getInteger("RenderExtra");
+//
+// final CustomMaterial newColor = TConstructRegistry.getCustomMaterial(ID, ClothMaterial.class);
+// color[j] = Integer.toHexString(newColor.color);
+// }
+// break;
+// }
+// }
+//
+// final ArmorRenderer model = getRenderer();
+// model.SetColors(color, getDefaultFolder(), itemStack);
+// return model;
+// }
+// return null;
+// }
+
+// @SideOnly(Side.CLIENT)
+// public abstract ArmorRenderer getRenderer();
+
+// @Override
+// public Item getAccessoryItem() {
+// return null;
+// }
+//
+// @Override
+// public String getDefaultFolder() {
+// return null;
+// }
+//
+// @Override
+// public String getEffectSuffix() {
+// return null;
+// }
+//
+// @Override
+// public Item getHeadItem() {
+// return null;
+// }
+//
+// @Override
+// public String getIconSuffix(int arg0) {
+// return null;
+// }
+//
+// @Override
+// public String[] getTraits() {
+// return new String[] { "armor" };
+// }
+
+// @Override
+// public void onArmorTick(World world, EntityPlayer player, ItemStack itemStack) {
+//
+// Modifiers.AMod.UpdateAll((ToolCore) itemStack.getItem(), itemStack, world, player,
+// itemStack.getTagCompound().getCompoundTag("InfiTool"));
+// }
+//
+// @Override
+// public int getRunicCharge(ItemStack itemstack) {
+// return 0;
+// }
+
+// @Override
+// public void onUpdate(ItemStack stack, World world, Entity ent, int p_77663_4_, boolean p_77663_5_) {
+// // Check if runic shielding level has changed
+// if (TDIntegration.thaumcraft) {
+// final NBTTagCompound tcTag = stack.getTagCompound();
+// final NBTTagCompound ticoTag = stack.getTagCompound().getCompoundTag("InfiTool");
+//
+// final byte rs = tcTag.getByte("RS.HARDEN");
+// if (!Charge && rs > 0) {
+// if (ticoTag.getInteger("Modifiers") > 0) {
+// ticoTag.setInteger("Modifiers", ticoTag.getInteger("Modifiers") - 1);
+// Charge = true;
+// } else {
+// tcTag.removeTag("RS.HARDEN");
+// }
+// }
+// }
+// }
+
+// public void renderArmor(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, String[] colors,
+// ItemStack stack, int pass) {
+//
+// final ResourceLocation rc = new ResourceLocation(
+// "tinkersdefense:textures/" + getDefaultFolder() + "/" + getTexture(pass, stack) + ".png");
+// FMLClientHandler.instance().getClient().renderEngine.bindTexture(rc);
+//
+// final float size = 1.6f;
+// GL11.glScalef(1.0F / size, 1.0F / size, 1.0F / size);
+// GL11.glTranslatef(0.0F, -0.01F, 0.0F);
+//
+// final int[] intColors = TinkersDefense.hexToRGB(colors[pass]);
+// GL11.glColor3d((float) intColors[0] / 255, (float) intColors[1] / 255, (float) intColors[2] / 255);
+//
+// }
+//
+// public String getTexture(int pass, ItemStack stack) {
+// final NBTTagCompound tags = stack.getTagCompound().getCompoundTag("InfiTool");
+// String renderReturn = "";
+// switch (pass) {
+// case 0:
+// renderReturn = handleStrings.get(tags.getInteger("RenderHandle"));
+// break;
+// case 1:
+// renderReturn = headStrings.get(tags.getInteger("RenderHead"));
+// break;
+// case 2:
+// renderReturn = accessoryStrings.get(tags.getInteger("RenderAccessory"));
+// break;
+// case 3:
+// renderReturn = extraStrings.get(tags.getInteger("RenderExtra"));
+// break;
+// //
+// // default:
+// // if(tags != null && tags.hasKey("Effect" + (pass - getPartAmount())))
+// // {
+// // final String effect = effectStrings.get(tags.getInteger("Effect" +
+// // (pass - getPartAmount())));
+// // if(effect != null)
+// // return effect.substring(effect.lastIndexOf("/") + 1);
+// // else
+// // return "";
+// //
+// // }
+// }
+// if (renderReturn != null && renderReturn != "") {
+// renderReturn = renderReturn.substring(renderReturn.indexOf("_"));
+// } else {
+// renderReturn = "";
+// }
+//
+// return renderReturn;
+// }
+//
+// @Override
+// public float getPixieChance(ItemStack stack) {
+// final float chance = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ElementiumCore") * 5 / 100f;
+// return chance;
+// }
+//
+// @SubscribeEvent
+// public void ToolCraftedEvent(NormalTool event) {
+// if (event.tool instanceof ArmorCore) {
+// final ArmorCore armor = (ArmorCore) event.tool;
+// final ArmorRenderer render = armor.getRenderer();
+// final NBTTagCompound tooltags = event.toolTag;
+// final NBTTagCompound tags = render.defaultTags;// stack.setTagCompound();
+//
+// // for(int i = 0; i < render.defaultTags.; i++)
+// // {
+// // final String rendertag = ((ModelRenderer)
+// // render.boxList.get(i)).boxName;
+// // if(rendertag != null)
+// // {
+// // tags.setBoolean(rendertag, ((ModelRenderer)
+// // render.boxList.get(i)).isHidden);
+// // }
+// // }
+//
+// if (!tags.hasNoTags()) {
+// tooltags.setTag("ArmorRenderer", tags);
+// }
+// }
+// }
}
diff --git a/src/main/java/lance5057/tDefense/armor/TDArmorAddon.java b/src/main/java/lance5057/tDefense/armor/TDArmorAddon.java
index 98223ce..4ad8e64 100644
--- a/src/main/java/lance5057/tDefense/armor/TDArmorAddon.java
+++ b/src/main/java/lance5057/tDefense/armor/TDArmorAddon.java
@@ -1,198 +1,187 @@
-package lance5057.tDefense.armor;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.blocks.GlowstoneCrumbs;
-import lance5057.tDefense.armor.blocks.UnstableBlock;
-import lance5057.tDefense.armor.blocks.UnstableItemBlock;
-import lance5057.tDefense.armor.events.ArmorModEvents;
-import lance5057.tDefense.armor.events.ArmorRenderEvent;
-import lance5057.tDefense.armor.items.Sheath;
-import lance5057.tDefense.armor.items.TinkersGauntlets;
-import lance5057.tDefense.armor.items.cloth.TinkersHood;
-import lance5057.tDefense.armor.items.cloth.TinkersRobe;
-import lance5057.tDefense.armor.items.cloth.TinkersShawl;
-import lance5057.tDefense.armor.items.cloth.TinkersShoes;
-import lance5057.tDefense.armor.items.heavy.TinkersBreastplate;
-import lance5057.tDefense.armor.items.heavy.TinkersGrieves;
-import lance5057.tDefense.armor.items.heavy.TinkersHelm;
-import lance5057.tDefense.armor.items.heavy.TinkersSabatons;
-import lance5057.tDefense.armor.items.light.TinkersBoots;
-import lance5057.tDefense.armor.items.light.TinkersChausses;
-import lance5057.tDefense.armor.items.light.TinkersCoif;
-import lance5057.tDefense.armor.items.light.TinkersHauberk;
-import net.minecraft.block.Block;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.client.MinecraftForgeClient;
-import net.minecraftforge.common.MinecraftForge;
-import tconstruct.client.FlexibleToolRenderer;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.crafting.ToolBuilder;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.common.event.FMLInitializationEvent;
-import cpw.mods.fml.common.event.FMLPostInitializationEvent;
-import cpw.mods.fml.common.event.FMLPreInitializationEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-import cpw.mods.fml.relauncher.Side;
-
-public class TDArmorAddon
-{
- public static CreativeTabs tabName;
-
- public static ToolCore armor_TinkerHood;
- public static ToolCore armor_TinkerShawl;
- public static ToolCore armor_TinkerRobe;
- public static ToolCore armor_TinkerShoes;
-
- public static ToolCore armor_TinkerCoif;
- public static ToolCore armor_TinkerHauberk;
- public static ToolCore armor_TinkerChausses;
- public static ToolCore armor_TinkerBoots;
-
- public static ToolCore armor_TinkerHelm;
- public static ToolCore armor_TinkerBreastplate;
- public static ToolCore armor_TinkerGrieves;
- public static ToolCore armor_TinkerSabatons;
- public static ToolCore armor_TinkerGauntlets;
-
- public static ToolCore accessory_sheath;
-
- public static Block block_Unstable;
- public static Block block_GlowCrumbs;
-
- public void preInit(FMLPreInitializationEvent e)
- {
- tabName = new CreativeTabs("TabArmor")
- {
-
- @Override
- public Item getTabIconItem()
- {
- return ToolBuilder.instance.buildTool(new ItemStack(
- TinkerTools.largePlate, 1, 2), new ItemStack(
- TinkerTools.toughRod, 1, 2), new ItemStack(
- TinkersDefense.partArmorplate, 1, 2), new ItemStack(
- TinkersDefense.partChainmaille, 1, 2), "ArmorTab").getItem();
- }
-
- };
-
- if(e.getSide() == Side.CLIENT)
- {
- MinecraftForge.EVENT_BUS.register(new ArmorRenderEvent());
- }
-
- MinecraftForge.EVENT_BUS.register(new ArmorModEvents());
-
- armor_TinkerHelm = new TinkersHelm();
- armor_TinkerBreastplate = new TinkersBreastplate();
- armor_TinkerGrieves = new TinkersGrieves();
- armor_TinkerSabatons = new TinkersSabatons();
- armor_TinkerGauntlets = new TinkersGauntlets();
-
- armor_TinkerRobe = new TinkersRobe();
- armor_TinkerShawl = new TinkersShawl();
- armor_TinkerHood = new TinkersHood();
- armor_TinkerShoes = new TinkersShoes();
-
- armor_TinkerCoif = new TinkersCoif();
- armor_TinkerHauberk = new TinkersHauberk();
- armor_TinkerChausses = new TinkersChausses();
- armor_TinkerBoots = new TinkersBoots();
-
- accessory_sheath = new Sheath();
-
- block_Unstable = new UnstableBlock();
- block_GlowCrumbs = new GlowstoneCrumbs();
-
- GameRegistry.registerItem(armor_TinkerHelm, "tinkerhelm");
- GameRegistry.registerItem(armor_TinkerBreastplate, "tinkerbreastplate");
- GameRegistry.registerItem(armor_TinkerGrieves, "tinkergrieves");
- GameRegistry.registerItem(armor_TinkerSabatons, "tinkersabatons");
- GameRegistry.registerItem(armor_TinkerGauntlets, "tinkergauntlets");
-
- GameRegistry.registerItem(armor_TinkerCoif, "tinkercoif");
- GameRegistry.registerItem(armor_TinkerHauberk, "tinkerhauberk");
- GameRegistry.registerItem(armor_TinkerChausses, "tinkerchausses");
- GameRegistry.registerItem(armor_TinkerBoots, "tinkerboots");
-
- GameRegistry.registerItem(armor_TinkerRobe, "tinkerrobe");
- GameRegistry.registerItem(armor_TinkerShawl, "tinkershawl");
- GameRegistry.registerItem(armor_TinkerHood, "tinkerhood");
- GameRegistry.registerItem(armor_TinkerShoes, "tinkershoes");
-
- GameRegistry.registerItem(accessory_sheath, "Sheath");
-
- GameRegistry.registerBlock(block_Unstable, UnstableItemBlock.class, "Unstable");
- GameRegistry.registerBlock(block_GlowCrumbs, "Block_GlowCrumbs");
-
- TConstructRegistry.addItemToDirectory("tinkerhelm", armor_TinkerHelm);
- TConstructRegistry.addItemToDirectory("tinkerbreastplate", armor_TinkerBreastplate);
- TConstructRegistry.addItemToDirectory("tinkergrieves", armor_TinkerGrieves);
- TConstructRegistry.addItemToDirectory("tinkersabatons", armor_TinkerSabatons);
- TConstructRegistry.addItemToDirectory("tinkergauntlets", armor_TinkerGauntlets);
-
- TConstructRegistry.addItemToDirectory("tinkercoif", armor_TinkerCoif);
- TConstructRegistry.addItemToDirectory("tinkerhauberk", armor_TinkerHauberk);
- TConstructRegistry.addItemToDirectory("tinkerchausses", armor_TinkerChausses);
- TConstructRegistry.addItemToDirectory("tinkerboots", armor_TinkerBoots);
-
- TConstructRegistry.addItemToDirectory("tinkerrobe", armor_TinkerRobe);
- TConstructRegistry.addItemToDirectory("tinkershawl", armor_TinkerShawl);
- TConstructRegistry.addItemToDirectory("tinkerhood", armor_TinkerHood);
- TConstructRegistry.addItemToDirectory("tinkershoes", armor_TinkerShoes);
-
- TConstructRegistry.addItemToDirectory("Sheath", accessory_sheath);
- }
-
- public void init(FMLInitializationEvent e)
- {
-
- TConstructRegistry.addToolRecipe(armor_TinkerHelm, TinkerTools.frypanHead, TinkerTools.toughRod, TinkersDefense.partArmorplate, TinkersDefense.partChainmaille);
- TConstructRegistry.addToolRecipe(armor_TinkerBreastplate, TinkerTools.largePlate, TinkerTools.toughRod, TinkersDefense.partArmorplate, TinkersDefense.partChainmaille);
- TConstructRegistry.addToolRecipe(armor_TinkerGrieves, TinkersDefense.partArmorplate, TinkerTools.toughRod, TinkersDefense.partChainmaille, TinkersDefense.partCloth);
- TConstructRegistry.addToolRecipe(armor_TinkerSabatons, TinkersDefense.partArmorplate, TinkerTools.toughRod, TinkersDefense.partArmorplate, TinkersDefense.partCloth);
- TConstructRegistry.addToolRecipe(armor_TinkerGauntlets, TinkersDefense.partArmorplate, TinkerTools.toughRod, TinkersDefense.partRivet);
-
- TConstructRegistry.addToolRecipe(armor_TinkerRobe, TinkersDefense.partCloth, TinkersDefense.partClasp, TinkersDefense.partCloth);
- TConstructRegistry.addToolRecipe(armor_TinkerShawl, TinkersDefense.partCloth, TinkersDefense.partArmorplate, TinkersDefense.partCloth);
- TConstructRegistry.addToolRecipe(armor_TinkerHood, TinkersDefense.partCloth, TinkerTools.toolRod, TinkersDefense.partCloth);
- TConstructRegistry.addToolRecipe(armor_TinkerShoes, TinkersDefense.partCloth, TinkersDefense.partRivet, TinkersDefense.partCloth);
-
- TConstructRegistry.addToolRecipe(armor_TinkerCoif, TinkersDefense.partChainmaille, TinkerTools.toughRod, TinkersDefense.partCloth);
- TConstructRegistry.addToolRecipe(armor_TinkerHauberk, TinkersDefense.partChainmaille, TinkerTools.largePlate, TinkersDefense.partCloth);
- TConstructRegistry.addToolRecipe(armor_TinkerChausses, TinkersDefense.partChainmaille, TinkersDefense.partArmorplate, TinkersDefense.partCloth);
- TConstructRegistry.addToolRecipe(armor_TinkerBoots, TinkersDefense.partChainmaille, TinkersDefense.partCloth, TinkersDefense.partRivet);
-
- TConstructRegistry.addToolRecipe(accessory_sheath, TinkersDefense.partCloth, TinkersDefense.partCloth, TinkersDefense.partCloth);
-
- }
-
- public void postInit(FMLPostInitializationEvent e)
- {
-
- }
-
- public static void clientProxy(FlexibleToolRenderer renderer)
- {
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.accessory_sheath, renderer);
-
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerHelm, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerBreastplate, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerGrieves, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerSabatons, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerGauntlets, renderer);
-
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerRobe, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerShawl, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerHood, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerShoes, renderer);
-
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerCoif, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerHauberk, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerChausses, renderer);
- MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerBoots, renderer);
- }
-}
+//package lance5057.tDefense.armor;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.blocks.GlowstoneCrumbs;
+//import lance5057.tDefense.armor.blocks.UnstableBlock;
+//import lance5057.tDefense.armor.blocks.UnstableItemBlock;
+//import lance5057.tDefense.armor.items.Sheath;
+//import lance5057.tDefense.armor.items.TinkersGauntlets;
+//import lance5057.tDefense.armor.items.cloth.TinkersHood;
+//import lance5057.tDefense.armor.items.cloth.TinkersRobe;
+//import lance5057.tDefense.armor.items.cloth.TinkersShawl;
+//import lance5057.tDefense.armor.items.cloth.TinkersShoes;
+//import lance5057.tDefense.armor.items.heavy.TinkersBreastplate;
+//import lance5057.tDefense.armor.items.heavy.TinkersGrieves;
+//import lance5057.tDefense.armor.items.heavy.TinkersHelm;
+//import lance5057.tDefense.armor.items.heavy.TinkersSabatons;
+//import lance5057.tDefense.armor.items.light.TinkersBoots;
+//import lance5057.tDefense.armor.items.light.TinkersChausses;
+//import lance5057.tDefense.armor.items.light.TinkersCoif;
+//import lance5057.tDefense.armor.items.light.TinkersHauberk;
+//import net.minecraft.block.Block;
+//import net.minecraft.creativetab.CreativeTabs;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import net.minecraftforge.client.MinecraftForgeClient;
+//import tconstruct.client.FlexibleToolRenderer;
+//import tconstruct.library.TConstructRegistry;
+//import tconstruct.library.crafting.ToolBuilder;
+//import tconstruct.library.tools.ToolCore;
+//import tconstruct.tools.TinkerTools;
+//import cpw.mods.fml.common.event.FMLInitializationEvent;
+//import cpw.mods.fml.common.event.FMLPostInitializationEvent;
+//import cpw.mods.fml.common.event.FMLPreInitializationEvent;
+//import cpw.mods.fml.common.registry.GameRegistry;
+//
+//public class TDArmorAddon
+//{
+// public static CreativeTabs tabName;
+//
+// public static ToolCore armor_TinkerHood;
+// public static ToolCore armor_TinkerShawl;
+// public static ToolCore armor_TinkerRobe;
+// public static ToolCore armor_TinkerShoes;
+//
+// public static ToolCore armor_TinkerCoif;
+// public static ToolCore armor_TinkerHauberk;
+// public static ToolCore armor_TinkerChausses;
+// public static ToolCore armor_TinkerBoots;
+//
+// public static ToolCore armor_TinkerHelm;
+// public static ToolCore armor_TinkerBreastplate;
+// public static ToolCore armor_TinkerGrieves;
+// public static ToolCore armor_TinkerSabatons;
+// public static ToolCore armor_TinkerGauntlets;
+//
+// public static ToolCore accessory_sheath;
+//
+// public static Block block_Unstable;
+// public static Block block_GlowCrumbs;
+//
+// public void preInit(FMLPreInitializationEvent e)
+// {
+// tabName = new CreativeTabs("TabArmor")
+// {
+//
+// @Override
+// public Item getTabIconItem()
+// {
+// return ToolBuilder.instance.buildTool(new ItemStack(
+// TinkerTools.largePlate, 1, 2), new ItemStack(
+// TinkerTools.toughRod, 1, 2), new ItemStack(
+// TinkersDefense.partArmorplate, 1, 2), new ItemStack(
+// TinkersDefense.partChainmaille, 1, 2), "ArmorTab").getItem();
+// }
+//
+// };
+//
+// armor_TinkerHelm = new TinkersHelm();
+// armor_TinkerBreastplate = new TinkersBreastplate();
+// armor_TinkerGrieves = new TinkersGrieves();
+// armor_TinkerSabatons = new TinkersSabatons();
+// armor_TinkerGauntlets = new TinkersGauntlets();
+//
+// armor_TinkerRobe = new TinkersRobe();
+// armor_TinkerShawl = new TinkersShawl();
+// armor_TinkerHood = new TinkersHood();
+// armor_TinkerShoes = new TinkersShoes();
+//
+// armor_TinkerCoif = new TinkersCoif();
+// armor_TinkerHauberk = new TinkersHauberk();
+// armor_TinkerChausses = new TinkersChausses();
+// armor_TinkerBoots = new TinkersBoots();
+//
+// accessory_sheath = new Sheath();
+//
+// block_Unstable = new UnstableBlock();
+// block_GlowCrumbs = new GlowstoneCrumbs();
+//
+// GameRegistry.registerItem(armor_TinkerHelm, "tinkerhelm");
+// GameRegistry.registerItem(armor_TinkerBreastplate, "tinkerbreastplate");
+// GameRegistry.registerItem(armor_TinkerGrieves, "tinkergrieves");
+// GameRegistry.registerItem(armor_TinkerSabatons, "tinkersabatons");
+// GameRegistry.registerItem(armor_TinkerGauntlets, "tinkergauntlets");
+//
+// GameRegistry.registerItem(armor_TinkerCoif, "tinkercoif");
+// GameRegistry.registerItem(armor_TinkerHauberk, "tinkerhauberk");
+// GameRegistry.registerItem(armor_TinkerChausses, "tinkerchausses");
+// GameRegistry.registerItem(armor_TinkerBoots, "tinkerboots");
+//
+// GameRegistry.registerItem(armor_TinkerRobe, "tinkerrobe");
+// GameRegistry.registerItem(armor_TinkerShawl, "tinkershawl");
+// GameRegistry.registerItem(armor_TinkerHood, "tinkerhood");
+// GameRegistry.registerItem(armor_TinkerShoes, "tinkershoes");
+//
+// GameRegistry.registerItem(accessory_sheath, "Sheath");
+//
+// GameRegistry.registerBlock(block_Unstable, UnstableItemBlock.class, "Unstable");
+// GameRegistry.registerBlock(block_GlowCrumbs, "Block_GlowCrumbs");
+//
+// TConstructRegistry.addItemToDirectory("tinkerhelm", armor_TinkerHelm);
+// TConstructRegistry.addItemToDirectory("tinkerbreastplate", armor_TinkerBreastplate);
+// TConstructRegistry.addItemToDirectory("tinkergrieves", armor_TinkerGrieves);
+// TConstructRegistry.addItemToDirectory("tinkersabatons", armor_TinkerSabatons);
+// TConstructRegistry.addItemToDirectory("tinkergauntlets", armor_TinkerGauntlets);
+//
+// TConstructRegistry.addItemToDirectory("tinkercoif", armor_TinkerCoif);
+// TConstructRegistry.addItemToDirectory("tinkerhauberk", armor_TinkerHauberk);
+// TConstructRegistry.addItemToDirectory("tinkerchausses", armor_TinkerChausses);
+// TConstructRegistry.addItemToDirectory("tinkerboots", armor_TinkerBoots);
+//
+// TConstructRegistry.addItemToDirectory("tinkerrobe", armor_TinkerRobe);
+// TConstructRegistry.addItemToDirectory("tinkershawl", armor_TinkerShawl);
+// TConstructRegistry.addItemToDirectory("tinkerhood", armor_TinkerHood);
+// TConstructRegistry.addItemToDirectory("tinkershoes", armor_TinkerShoes);
+//
+// TConstructRegistry.addItemToDirectory("Sheath", accessory_sheath);
+// }
+//
+// public void init(FMLInitializationEvent e)
+// {
+//
+// TConstructRegistry.addToolRecipe(armor_TinkerHelm, TinkerTools.frypanHead, TinkerTools.toughRod, TinkersDefense.partArmorplate, TinkersDefense.partChainmaille);
+// TConstructRegistry.addToolRecipe(armor_TinkerBreastplate, TinkerTools.largePlate, TinkerTools.toughRod, TinkersDefense.partArmorplate, TinkersDefense.partChainmaille);
+// TConstructRegistry.addToolRecipe(armor_TinkerGrieves, TinkersDefense.partArmorplate, TinkerTools.toughRod, TinkersDefense.partChainmaille, TinkersDefense.partCloth);
+// TConstructRegistry.addToolRecipe(armor_TinkerSabatons, TinkersDefense.partArmorplate, TinkerTools.toughRod, TinkersDefense.partArmorplate, TinkersDefense.partCloth);
+// TConstructRegistry.addToolRecipe(armor_TinkerGauntlets, TinkersDefense.partArmorplate, TinkerTools.toughRod, TinkersDefense.partRivet);
+//
+// TConstructRegistry.addToolRecipe(armor_TinkerRobe, TinkersDefense.partCloth, TinkersDefense.partClasp, TinkersDefense.partCloth);
+// TConstructRegistry.addToolRecipe(armor_TinkerShawl, TinkersDefense.partCloth, TinkersDefense.partArmorplate, TinkersDefense.partCloth);
+// TConstructRegistry.addToolRecipe(armor_TinkerHood, TinkersDefense.partCloth, TinkerTools.toolRod, TinkersDefense.partCloth);
+// TConstructRegistry.addToolRecipe(armor_TinkerShoes, TinkersDefense.partCloth, TinkersDefense.partRivet, TinkersDefense.partCloth);
+//
+// TConstructRegistry.addToolRecipe(armor_TinkerCoif, TinkersDefense.partChainmaille, TinkerTools.toughRod, TinkersDefense.partCloth);
+// TConstructRegistry.addToolRecipe(armor_TinkerHauberk, TinkersDefense.partChainmaille, TinkerTools.largePlate, TinkersDefense.partCloth);
+// TConstructRegistry.addToolRecipe(armor_TinkerChausses, TinkersDefense.partChainmaille, TinkersDefense.partArmorplate, TinkersDefense.partCloth);
+// TConstructRegistry.addToolRecipe(armor_TinkerBoots, TinkersDefense.partChainmaille, TinkersDefense.partCloth, TinkersDefense.partRivet);
+//
+// TConstructRegistry.addToolRecipe(accessory_sheath, TinkersDefense.partCloth, TinkersDefense.partCloth, TinkersDefense.partCloth);
+//
+// }
+//
+// public void postInit(FMLPostInitializationEvent e)
+// {
+//
+// }
+//
+// public static void clientProxy(FlexibleToolRenderer renderer)
+// {
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.accessory_sheath, renderer);
+//
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerHelm, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerBreastplate, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerGrieves, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerSabatons, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerGauntlets, renderer);
+//
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerRobe, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerShawl, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerHood, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerShoes, renderer);
+//
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerCoif, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerHauberk, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerChausses, renderer);
+// MinecraftForgeClient.registerItemRenderer(TDArmorAddon.armor_TinkerBoots, renderer);
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/blocks/GlowstoneCrumbs.java b/src/main/java/lance5057/tDefense/armor/blocks/GlowstoneCrumbs.java
deleted file mode 100644
index 13648c2..0000000
--- a/src/main/java/lance5057/tDefense/armor/blocks/GlowstoneCrumbs.java
+++ /dev/null
@@ -1,115 +0,0 @@
-package lance5057.tDefense.armor.blocks;
-
-import java.util.Random;
-
-import lance5057.tDefense.Reference;
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.item.Item;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.world.World;
-
-public class GlowstoneCrumbs extends Block
-{
- public GlowstoneCrumbs()
- {
- super(Material.ground);
- setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 0.0625F, 1.0F);
- setBlockName("glowstonecrumbs");
- setBlockTextureName(Reference.MOD_ID + ":glowstonecrumbs");
- setLightLevel(1f);
- }
-
- /**
- * Returns a bounding box from the pool of bounding boxes (this means this box can change after the pool has been
- * cleared to be reused)
- */
- @Override
- public AxisAlignedBB getCollisionBoundingBoxFromPool(World p_149668_1_, int p_149668_2_, int p_149668_3_, int p_149668_4_)
- {
- return null;
- }
-
- /**
- * Is this block (a) opaque and (b) a full 1m cube? This determines whether or not to render the shared face of two
- * adjacent blocks and also whether the player can attach torches, redstone wire, etc to this block.
- */
- @Override
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- /**
- * If this block doesn't render as an ordinary block it will return False (examples: signs, buttons, stairs, etc)
- */
- @Override
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- /**
- * The type of render function that is called for this block
- */
- @Override
- public int getRenderType()
- {
- return 23;
- }
-
- @Override
- public Item getItemDropped(int p_149650_1_, Random p_149650_2_, int p_149650_3_)
- {
- return null;
- }
-
- /**
- * Checks to see if its valid to put this block at the specified coordinates. Args: world, x, y, z
- */
- @Override
- public boolean canPlaceBlockAt(World p_149742_1_, int p_149742_2_, int p_149742_3_, int p_149742_4_)
- {
- return super.canPlaceBlockAt(p_149742_1_, p_149742_2_, p_149742_3_, p_149742_4_) && canBlockStay(p_149742_1_, p_149742_2_, p_149742_3_, p_149742_4_);
- }
-
- /**
- * Lets the block know when one of its neighbor changes. Doesn't know which neighbor changed (coordinates passed are
- * their own) Args: x, y, z, neighbor Block
- */
- @Override
- public void onNeighborBlockChange(World p_149695_1_, int p_149695_2_, int p_149695_3_, int p_149695_4_, Block p_149695_5_)
- {
- super.onNeighborBlockChange(p_149695_1_, p_149695_2_, p_149695_3_, p_149695_4_, p_149695_5_);
- checkAndDropBlock(p_149695_1_, p_149695_2_, p_149695_3_, p_149695_4_);
- }
-
- /**
- * Ticks the block if it's been scheduled
- */
- @Override
- public void updateTick(World p_149674_1_, int p_149674_2_, int p_149674_3_, int p_149674_4_, Random p_149674_5_)
- {
- checkAndDropBlock(p_149674_1_, p_149674_2_, p_149674_3_, p_149674_4_);
- }
-
- /**
- * checks if the block can stay, if not drop as item
- */
- protected void checkAndDropBlock(World p_149855_1_, int p_149855_2_, int p_149855_3_, int p_149855_4_)
- {
- if(!canBlockStay(p_149855_1_, p_149855_2_, p_149855_3_, p_149855_4_))
- {
- p_149855_1_.setBlock(p_149855_2_, p_149855_3_, p_149855_4_, getBlockById(0), 0, 2);
- }
- }
-
- /**
- * Can this block stay at this position. Similar to canPlaceBlockAt except gets checked often with plants.
- */
- @Override
- public boolean canBlockStay(World p_149718_1_, int p_149718_2_, int p_149718_3_, int p_149718_4_)
- {
- return p_149718_1_.getBlock(p_149718_2_, p_149718_3_ - 1, p_149718_4_).isNormalCube(p_149718_1_, p_149718_2_, p_149718_3_ - 1, p_149718_4_) && !p_149718_1_.getBlock(p_149718_2_, p_149718_3_ - 1, p_149718_4_).isAir(p_149718_1_, p_149718_2_, p_149718_3_ - 1, p_149718_4_);
- }
-}
diff --git a/src/main/java/lance5057/tDefense/armor/blocks/UnstableBlock.java b/src/main/java/lance5057/tDefense/armor/blocks/UnstableBlock.java
deleted file mode 100644
index adf0c44..0000000
--- a/src/main/java/lance5057/tDefense/armor/blocks/UnstableBlock.java
+++ /dev/null
@@ -1,123 +0,0 @@
-package lance5057.tDefense.armor.blocks;
-
-import java.util.List;
-import java.util.Random;
-
-import lance5057.tDefense.Reference;
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import net.minecraft.world.World;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class UnstableBlock extends Block
-{
- public static final String[] types = {"ice", "obsidian"};
- public int timer;
-
- public static final String[] field_150096_a = new String[] {"ice", "obsidian"};
- @SideOnly(Side.CLIENT)
- private IIcon[] field_150095_b;
-
- public UnstableBlock()
- {
- super(Material.rock);
- setBlockName("unstable");
- setBlockTextureName("unstable");
- setTickRandomly(true);
- }
-
- /**
- * Gets the block's texture. Args: side, meta
- */
- @Override
- @SideOnly(Side.CLIENT)
- public IIcon getIcon(int p_149691_1_, int p_149691_2_)
- {
- if(p_149691_2_ < 0 || p_149691_2_ >= field_150095_b.length)
- {
- p_149691_2_ = 0;
- }
-
- return field_150095_b[p_149691_2_];
- }
-
- /**
- * Determines the damage on the item the block drops. Used in cloth and
- * wood.
- */
- @Override
- public int damageDropped(int p_149692_1_)
- {
- return p_149692_1_;
- }
-
- /**
- * returns a list of blocks with the same ID, but different meta (eg: wood
- * returns 4 blocks)
- */
- @Override
- @SideOnly(Side.CLIENT)
- public void getSubBlocks(Item p_149666_1_, CreativeTabs p_149666_2_, List p_149666_3_)
- {
- p_149666_3_.add(new ItemStack(p_149666_1_, 1, 0));
- p_149666_3_.add(new ItemStack(p_149666_1_, 1, 1));
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public void registerBlockIcons(IIconRegister p_149651_1_)
- {
- field_150095_b = new IIcon[field_150096_a.length];
-
- for(int i = 0; i < field_150095_b.length; ++i)
- {
- field_150095_b[i] = p_149651_1_.registerIcon(Reference.MOD_ID + ":" + getTextureName() + field_150096_a[i]);
- }
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public int getRenderBlockPass()
- {
- return 1;
- }
-
- @Override
- public void breakBlock(World par1World, int par2, int par3, int par4, Block p_149749_5_, int meta)
- {
- //int meta = par1World.getBlockMetadata(par2, par3, par4);
-
- if(meta == 0)
- {
- par1World.setBlock(par2, par3, par4, Blocks.water, 0, 3);
- }
- if(meta == 1)
- {
- par1World.setBlock(par2, par3, par4, Blocks.lava, 0, 3);
- }
- par1World.notifyBlockOfNeighborChange(par2, par3, par4, par1World.getBlock(par2, par3, par4));
- }
-
- @Override
- public void updateTick(World par1World, int par2, int par3, int par4, Random par5Random)
- {
- final int meta = par1World.getBlockMetadata(par2, par3, par4);
-
- if(meta == 0)
- {
- par1World.setBlock(par2, par3, par4, Blocks.water, 0, 3);
- }
- if(meta == 1)
- {
- par1World.setBlock(par2, par3, par4, Blocks.lava, 0, 3);
- }
- par1World.notifyBlockOfNeighborChange(par2, par3, par4, par1World.getBlock(par2, par3, par4));
- }
-}
diff --git a/src/main/java/lance5057/tDefense/armor/blocks/UnstableItemBlock.java b/src/main/java/lance5057/tDefense/armor/blocks/UnstableItemBlock.java
deleted file mode 100644
index 2461704..0000000
--- a/src/main/java/lance5057/tDefense/armor/blocks/UnstableItemBlock.java
+++ /dev/null
@@ -1,20 +0,0 @@
-package lance5057.tDefense.armor.blocks;
-
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemBlockWithMetadata;
-import net.minecraft.item.ItemStack;
-
-public class UnstableItemBlock extends ItemBlockWithMetadata
-{
-
- public UnstableItemBlock(Block block)
- {
- super(block, block);
- }
-
- @Override
- public String getUnlocalizedName(ItemStack stack)
- {
- return this.getUnlocalizedName() + "_" + UnstableBlock.types[stack.getItemDamage()];
- }
-}
diff --git a/src/main/java/lance5057/tDefense/armor/events/ArmorModEvents.java b/src/main/java/lance5057/tDefense/armor/events/ArmorModEvents.java
index c2ee519..7ee9eb5 100644
--- a/src/main/java/lance5057/tDefense/armor/events/ArmorModEvents.java
+++ b/src/main/java/lance5057/tDefense/armor/events/ArmorModEvents.java
@@ -1,116 +1,85 @@
-package lance5057.tDefense.armor.events;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.DamageSource;
-import net.minecraft.util.MathHelper;
-import net.minecraftforge.event.entity.living.LivingHurtEvent;
-import tconstruct.library.event.ToolCraftEvent.NormalTool;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class ArmorModEvents
-{
- @SideOnly(Side.CLIENT)
- @SubscribeEvent
- public void ToolCraftedEvent(NormalTool event)
- {
- if(event.tool instanceof ArmorCore)
- {
- final ArmorCore armor = (ArmorCore) event.tool;
- final ArmorRenderer render = armor.getRenderer();
- final NBTTagCompound tooltags = event.toolTag;
- final NBTTagCompound tags = armor.getRenderer().defaultTags;//stack.setTagCompound();
-
- // for(int i = 0; i < render.defaultTags.; i++)
- // {
- // final String rendertag = ((ModelRenderer) render.boxList.get(i)).boxName;
- // if(rendertag != null)
- // {
- // tags.setBoolean(rendertag, ((ModelRenderer) render.boxList.get(i)).isHidden);
- // }
- // }
-
- if(!tags.hasNoTags())
- {
- tooltags.setTag("ArmorRenderer", tags);
- }
- }
- }
-
- @SubscribeEvent
- public void AddProtections(LivingHurtEvent event)
- {
- int epf = 0;
-
- if(TinkersDefense.config.debug && event.entityLiving instanceof EntityPlayer)
- {
- ((EntityPlayer) event.entityLiving).addChatComponentMessage(new ChatComponentText(
- event.source.getDamageType() + " - Max: " + Double.toString(event.ammount)));
- }
-
- for(int i = 0; i < 4; i++)
- {
- final ItemStack armor = event.entityLiving.getEquipmentInSlot(i + 1);
- if(armor != null && armor.getItem() instanceof ArmorCore)
- {
- final NBTTagCompound tags = armor.getTagCompound().getCompoundTag("InfiTool");
-
- if(!event.source.isUnblockable())
- {
- if(tags.hasKey("Protection"))
- {
- epf += (calcModifierDamage(tags.getInteger("Protection"), 1f, event.source));
- }
- else if(tags.hasKey("Fire Protection") && event.source.isFireDamage())
- {
- epf += (calcModifierDamage(tags.getInteger("Fire Protection"), 2f, event.source));
- }
- else if(tags.hasKey("Blast Protection") && event.source.isExplosion())
- {
- epf += (calcModifierDamage(tags.getInteger("Blast Protection"), 2f, event.source));
- }
- else if(tags.hasKey("Projectile Protection") && event.source.isProjectile())
- {
- epf += (calcModifierDamage(tags.getInteger("Projectile Protection"), 2f, event.source));
- }
- }
- else if(tags.hasKey("Featherfall") && event.source.getDamageType() == DamageSource.fall.getDamageType())
- {
- epf += (calcModifierDamage(tags.getInteger("Featherfall"), 3f, event.source));
- }
- }
- }
-
- if(epf > 20)
- {
- epf = 20;
- }
-
- final float adjustedPerc = (float) (1f - (epf * 0.04));
- event.ammount = adjustedPerc * event.ammount;
-
- if(TinkersDefense.config.debug && event.entityLiving instanceof EntityPlayer)
- {
- ((EntityPlayer) event.entityLiving).addChatComponentMessage(new ChatComponentText(
- event.source.getDamageType() + " - Adjusted: " + Double.toString(event.ammount)));
- }
- }
-
- public int calcModifierDamage(int level, float typeMod, DamageSource source)
- {
- if(source.canHarmInCreative())
- return 0;
- else
- {
- final float f = (6 + level * level) / 3.0F;
- return MathHelper.floor_float(f * typeMod);
- }
- }
-}
+//package lance5057.tDefense.armor.events;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.nbt.NBTTagCompound;
+//import net.minecraft.util.ChatComponentText;
+//import net.minecraft.util.DamageSource;
+//import net.minecraft.util.MathHelper;
+//import net.minecraftforge.event.entity.living.LivingHurtEvent;
+//import cpw.mods.fml.common.eventhandler.SubscribeEvent;
+//
+//public class ArmorModEvents
+//{
+// @SubscribeEvent
+// public void AddProtections(LivingHurtEvent event)
+// {
+// int epf = 0;
+//
+// if(TinkersDefense.config.debug && event.entityLiving instanceof EntityPlayer)
+// {
+// ((EntityPlayer) event.entityLiving).addChatComponentMessage(new ChatComponentText(
+// event.source.getDamageType() + " - Max: " + Double.toString(event.ammount)));
+// }
+//
+// for(int i = 0; i < 4; i++)
+// {
+// final ItemStack armor = event.entityLiving.getEquipmentInSlot(i + 1);
+// if(armor != null && armor.getItem() instanceof ArmorCore)
+// {
+// final NBTTagCompound tags = armor.getTagCompound().getCompoundTag("InfiTool");
+//
+// if(!event.source.isUnblockable())
+// {
+// if(tags.hasKey("Protection"))
+// {
+// epf += (calcModifierDamage(tags.getInteger("Protection"), 1f, event.source));
+// }
+// else if(tags.hasKey("Fire Protection") && event.source.isFireDamage())
+// {
+// epf += (calcModifierDamage(tags.getInteger("Fire Protection"), 2f, event.source));
+// }
+// else if(tags.hasKey("Blast Protection") && event.source.isExplosion())
+// {
+// epf += (calcModifierDamage(tags.getInteger("Blast Protection"), 2f, event.source));
+// }
+// else if(tags.hasKey("Projectile Protection") && event.source.isProjectile())
+// {
+// epf += (calcModifierDamage(tags.getInteger("Projectile Protection"), 2f, event.source));
+// }
+// }
+// else if(tags.hasKey("Featherfall") && event.source.getDamageType() == DamageSource.fall.getDamageType())
+// {
+// epf += (calcModifierDamage(tags.getInteger("Featherfall"), 3f, event.source));
+// }
+// }
+// }
+//
+// if(epf > 20)
+// {
+// epf = 20;
+// }
+//
+// final float adjustedPerc = (float) (1f - (epf * 0.04));
+// event.ammount = adjustedPerc * event.ammount;
+//
+// if(TinkersDefense.config.debug && event.entityLiving instanceof EntityPlayer)
+// {
+// ((EntityPlayer) event.entityLiving).addChatComponentMessage(new ChatComponentText(
+// event.source.getDamageType() + " - Adjusted: " + Double.toString(event.ammount)));
+// }
+// }
+//
+// public int calcModifierDamage(int level, float typeMod, DamageSource source)
+// {
+// if(source.canHarmInCreative())
+// return 0;
+// else
+// {
+// final float f = (6 + level * level) / 3.0F;
+// return MathHelper.floor_float(f * typeMod);
+// }
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/events/ArmorRenderEvent.java b/src/main/java/lance5057/tDefense/armor/events/ArmorRenderEvent.java
index 535dc35..a4e44b2 100644
--- a/src/main/java/lance5057/tDefense/armor/events/ArmorRenderEvent.java
+++ b/src/main/java/lance5057/tDefense/armor/events/ArmorRenderEvent.java
@@ -1,94 +1,94 @@
-package lance5057.tDefense.armor.events;
-
-import lance5057.tDefense.armor.ArmorCore;
-import net.minecraft.client.model.ModelBiped;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.EnumAction;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.client.event.RenderPlayerEvent;
-import tconstruct.armor.ArmorProxyClient;
-import tconstruct.armor.player.ArmorExtended;
-import tconstruct.library.tools.ToolCore;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class ArmorRenderEvent
-{
-
- @SideOnly(Side.CLIENT)
- @SubscribeEvent
- public void renderArmorEvent(RenderPlayerEvent.SetArmorModel event)
- {
- if(event.entityPlayer != null)
- {
- final ArmorExtended armorEx = ArmorProxyClient.armorExtended;
-
- final ItemStack Armor = event.entityPlayer.inventory.armorItemInSlot(event.slot);
-
- if(Armor != null && Armor.getItem() instanceof ArmorCore)
- {
- final ModelBiped armorModel = Armor.getItem().getArmorModel(event.entityLiving, Armor, event.slot);
-
- TrimArmor(armorModel, event);
- }
-
- final ItemStack Accessory = armorEx.getStackInSlot(event.slot);
-
- if(Accessory != null && Accessory.getItem() instanceof ToolCore)
- {
- final ModelBiped accessoryModel = Accessory.getItem().getArmorModel(event.entityLiving, Accessory, event.slot);
-
- TrimArmor(accessoryModel, event);
- }
-
- }
- }
-
- private void TrimArmor(ModelBiped armorModel, RenderPlayerEvent.SetArmorModel event)
- {
- if(armorModel != null)
- {
- armorModel.isSneak = event.entityPlayer.isSneaking();
- armorModel.isRiding = event.entityPlayer.isRiding();
- armorModel.isChild = event.entityPlayer.isChild();
-
- armorModel.onGround = event.entityPlayer.getSwingProgress(event.partialRenderTick);
-
- if(event.entityPlayer instanceof EntityPlayer)
- {
- final ItemStack itemstack = event.entityPlayer.inventory.getCurrentItem();
- armorModel.heldItemRight = 0;
- armorModel.aimedBow = false;
- if(itemstack != null)
- {
- if(event.entityPlayer.getItemInUseCount() > 0)
- {
- final EnumAction enumaction = itemstack.getItemUseAction();
-
- if(enumaction == EnumAction.block)
- {
- armorModel.heldItemRight = 3;
- }
- else if(enumaction == EnumAction.bow)
- {
- armorModel.aimedBow = true;
- }
- }
- else
- {
- armorModel.heldItemRight = event.entityPlayer.getHeldItem() != null ? 1 : 0;
- }
- }
- }
-
- final float yaw = event.entityPlayer.prevRotationYawHead + (event.entityPlayer.rotationYawHead - event.entityPlayer.prevRotationYawHead) * event.partialRenderTick;
- final float yawOffset = event.entityPlayer.prevRenderYawOffset + (event.entityPlayer.renderYawOffset - event.entityPlayer.prevRenderYawOffset) * event.partialRenderTick;
- final float limbs = event.entityPlayer.prevLimbSwingAmount + (event.entityPlayer.limbSwingAmount - event.entityPlayer.prevLimbSwingAmount) * event.partialRenderTick;
- final float limbSwing = event.entityPlayer.limbSwing - event.entityPlayer.limbSwingAmount * (1.0F - event.partialRenderTick);
-
- armorModel.setRotationAngles(limbSwing, limbs, event.entityPlayer.ticksExisted, yaw - yawOffset, event.entityPlayer.rotationPitch, 0.1f, event.entityPlayer);
- armorModel.render(event.entityPlayer, limbSwing, limbs, event.entityPlayer.ticksExisted, yaw - yawOffset, event.entityPlayer.rotationPitch, 0.1f);
- }
- }
-}
+//package lance5057.tDefense.armor.events;
+//
+//import lance5057.tDefense.armor.ArmorCore;
+//import net.minecraft.client.model.ModelBiped;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.EnumAction;
+//import net.minecraft.item.ItemStack;
+//import net.minecraftforge.client.event.RenderPlayerEvent;
+//import tconstruct.armor.ArmorProxyClient;
+//import tconstruct.armor.player.ArmorExtended;
+//import tconstruct.library.tools.ToolCore;
+//import cpw.mods.fml.common.eventhandler.SubscribeEvent;
+//import cpw.mods.fml.relauncher.Side;
+//import cpw.mods.fml.relauncher.SideOnly;
+//
+//public class ArmorRenderEvent
+//{
+//
+// @SideOnly(Side.CLIENT)
+// @SubscribeEvent
+// public void renderArmorEvent(RenderPlayerEvent.SetArmorModel event)
+// {
+// if(event.entityPlayer != null)
+// {
+// final ArmorExtended armorEx = ArmorProxyClient.armorExtended;
+//
+// final ItemStack Armor = event.entityPlayer.inventory.armorItemInSlot(event.slot);
+//
+// if(Armor != null && Armor.getItem() instanceof ArmorCore)
+// {
+// final ModelBiped armorModel = Armor.getItem().getArmorModel(event.entityLiving, Armor, event.slot);
+//
+// TrimArmor(armorModel, event);
+// }
+//
+// final ItemStack Accessory = armorEx.getStackInSlot(event.slot);
+//
+// if(Accessory != null && Accessory.getItem() instanceof ToolCore)
+// {
+// final ModelBiped accessoryModel = Accessory.getItem().getArmorModel(event.entityLiving, Accessory, event.slot);
+//
+// TrimArmor(accessoryModel, event);
+// }
+//
+// }
+// }
+//
+// private void TrimArmor(ModelBiped armorModel, RenderPlayerEvent.SetArmorModel event)
+// {
+// if(armorModel != null)
+// {
+// armorModel.isSneak = event.entityPlayer.isSneaking();
+// armorModel.isRiding = event.entityPlayer.isRiding();
+// armorModel.isChild = event.entityPlayer.isChild();
+//
+// armorModel.onGround = event.entityPlayer.getSwingProgress(event.partialRenderTick);
+//
+// if(event.entityPlayer instanceof EntityPlayer)
+// {
+// final ItemStack itemstack = event.entityPlayer.inventory.getCurrentItem();
+// armorModel.heldItemRight = 0;
+// armorModel.aimedBow = false;
+// if(itemstack != null)
+// {
+// if(event.entityPlayer.getItemInUseCount() > 0)
+// {
+// final EnumAction enumaction = itemstack.getItemUseAction();
+//
+// if(enumaction == EnumAction.block)
+// {
+// armorModel.heldItemRight = 3;
+// }
+// else if(enumaction == EnumAction.bow)
+// {
+// armorModel.aimedBow = true;
+// }
+// }
+// else
+// {
+// armorModel.heldItemRight = event.entityPlayer.getHeldItem() != null ? 1 : 0;
+// }
+// }
+// }
+//
+// final float yaw = event.entityPlayer.prevRotationYawHead + (event.entityPlayer.rotationYawHead - event.entityPlayer.prevRotationYawHead) * event.partialRenderTick;
+// final float yawOffset = event.entityPlayer.prevRenderYawOffset + (event.entityPlayer.renderYawOffset - event.entityPlayer.prevRenderYawOffset) * event.partialRenderTick;
+// final float limbs = event.entityPlayer.prevLimbSwingAmount + (event.entityPlayer.limbSwingAmount - event.entityPlayer.prevLimbSwingAmount) * event.partialRenderTick;
+// final float limbSwing = event.entityPlayer.limbSwing - event.entityPlayer.limbSwingAmount * (1.0F - event.partialRenderTick);
+//
+// armorModel.setRotationAngles(limbSwing, limbs, event.entityPlayer.ticksExisted, yaw - yawOffset, event.entityPlayer.rotationPitch, 0.1f, event.entityPlayer);
+// armorModel.render(event.entityPlayer, limbSwing, limbs, event.entityPlayer.ticksExisted, yaw - yawOffset, event.entityPlayer.rotationPitch, 0.1f);
+// }
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/Sheath.java b/src/main/java/lance5057/tDefense/armor/items/Sheath.java
deleted file mode 100644
index 165c187..0000000
--- a/src/main/java/lance5057/tDefense/armor/items/Sheath.java
+++ /dev/null
@@ -1,106 +0,0 @@
-package lance5057.tDefense.armor.items;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import tconstruct.library.accessory.IAccessory;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class Sheath extends ArmorCore implements IAccessory
-{
-
- public Sheath()
- {
- super(0, -1);
- }
-
- @Override
- public boolean canEquipAccessory(ItemStack item, int slot)
- {
- return slot == 3;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toolRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partCloth;
- }
-
- // @Override
- // public Item getExtraItem()
- // {
- // return TinkersDefense.partCloth;
- // }
-
- @Override
- public String getDefaultFolder()
- {
- // TODO Auto-generated method stub
- return "Armor/Sheath";
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_sheath_effect";
- }
-
- @SideOnly(Side.CLIENT)
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_tabard_cloth";
- case 1:
- return "_shield_base_broken"; //useless
- case 2:
- return "_tabard_trim";
- case 3:
- return "_tabard_filigree";
- // case 4:
- // return "_sheath_clasp";
- default:
- return "";
- }
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"sheath", "cosmetic"};
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- // TODO Auto-generated method stub
- return ClientProxy.sheath;
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/armor/items/TinkersGauntlets.java b/src/main/java/lance5057/tDefense/armor/items/TinkersGauntlets.java
index f516225..b5d9f6e 100644
--- a/src/main/java/lance5057/tDefense/armor/items/TinkersGauntlets.java
+++ b/src/main/java/lance5057/tDefense/armor/items/TinkersGauntlets.java
@@ -1,134 +1,130 @@
-package lance5057.tDefense.armor.items;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import tconstruct.library.accessory.IAccessory;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class TinkersGauntlets extends ArmorCore implements IAccessory
-{
- public TinkersGauntlets()
- {
- super(0, -1);
- setUnlocalizedName("tinkersgauntlets");
- }
-
- @Override
- public boolean canEquipAccessory(ItemStack item, int slot)
- {
- return slot == 1;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toughRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partRivet;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 2;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 2.5f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 0f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_gauntlet_plate";
- case 1:
- return "_gauntlet_plate_broken";
- case 2:
- return "_gauntlet_trim";
- case 3:
- return "_gauntlet_rivet";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_gauntlet_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/gauntlets";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int
- // par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/Tinkersgauntlet.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"hands", "gauntlet"};
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.gauntlets;
- }
-}
+//package lance5057.tDefense.armor.items;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import tconstruct.library.accessory.IAccessory;
+//import tconstruct.tools.TinkerTools;
+//
+//public class TinkersGauntlets extends ArmorCore implements IAccessory
+//{
+// public TinkersGauntlets()
+// {
+// super(0, -1);
+// setUnlocalizedName("tinkersgauntlets");
+// }
+//
+// @Override
+// public boolean canEquipAccessory(ItemStack item, int slot)
+// {
+// return slot == 1;
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partArmorplate;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkerTools.toughRod;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partRivet;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 2;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 2.5f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 0f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_gauntlet_plate";
+// case 1:
+// return "_gauntlet_plate_broken";
+// case 2:
+// return "_gauntlet_trim";
+// case 3:
+// return "_gauntlet_rivet";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_gauntlet_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/gauntlets";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int
+// // par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/Tinkersgauntlet.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"hands", "gauntlet"};
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.gauntlets;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersHood.java b/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersHood.java
index 756237d..1ebc963 100644
--- a/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersHood.java
+++ b/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersHood.java
@@ -1,186 +1,182 @@
-package lance5057.tDefense.armor.items.cloth;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import tconstruct.tools.TinkerTools;
-import thaumcraft.api.IGoggles;
-import thaumcraft.api.IVisDiscountGear;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.nodes.IRevealer;
-import vazkii.botania.api.mana.IManaDiscountArmor;
-import WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles;
-import WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IGoggles", striprefs = true), @Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.nodes.IRevealer", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles", striprefs = true), @Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IVisDiscountGear", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.mana.IManaDiscountArmor", striprefs = true)})
-public class TinkersHood extends ArmorCore implements IRevealer, IGoggles, ILPGauge, IAlchemyGoggles, IVisDiscountGear, IManaDiscountArmor
-{
- public TinkersHood()
- {
- super(0, 0);
- setUnlocalizedName("tinkershood");
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toolRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 1;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_hood_cloth";
- case 1:
- return "_hood_cloth_broken";
- case 2:
- return "_hood_metal";
- case 3:
- return "_hood_trim";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_hood_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/hood";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersHood.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "head", "hood", "cloth"};
- }
-
- @Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
- return 0;
- }
-
- @Override
- @Optional.Method(modid = "Thaumcraft")
- public int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect)
- {
- return stack.getTagCompound().getCompoundTag("InfiTool").getInteger("VisEmbroidery");
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.hood;
- }
-
- @Override
- public float getDiscount(ItemStack stack, int arg1, EntityPlayer arg2)
- {
- final float i = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ManaEmbroidery") / 100f;
- return i;
- }
-
- @Optional.Method(modid = "Thaumcraft")
- @Override
- public boolean showIngamePopups(ItemStack itemstack, EntityLivingBase player)
- {
- return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
- }
-
- @Optional.Method(modid = "Thaumcraft")
- @Override
- public boolean showNodes(ItemStack itemstack, EntityLivingBase player)
- {
- return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
- }
-
- @Optional.Method(modid = "AWWayofTime")
- @Override
- public boolean canSeeLPBar(ItemStack stack)
- {
- return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
- }
-
- @Optional.Method(modid = "AWWayofTime")
- @Override
- public boolean showIngameHUD(World world, ItemStack stack, EntityPlayer player)
- {
- return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
- }
-}
+//package lance5057.tDefense.armor.items.cloth;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.EntityLivingBase;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.world.World;
+//import tconstruct.tools.TinkerTools;
+//import thaumcraft.api.IGoggles;
+//import thaumcraft.api.IVisDiscountGear;
+//import thaumcraft.api.aspects.Aspect;
+//import thaumcraft.api.nodes.IRevealer;
+//import vazkii.botania.api.mana.IManaDiscountArmor;
+//import WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles;
+//import WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge;
+//import cpw.mods.fml.common.Optional;
+//
+//@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IGoggles", striprefs = true), @Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.nodes.IRevealer", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles", striprefs = true), @Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IVisDiscountGear", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.mana.IManaDiscountArmor", striprefs = true)})
+//public class TinkersHood extends ArmorCore implements IRevealer, IGoggles, ILPGauge, IAlchemyGoggles, IVisDiscountGear, IManaDiscountArmor
+//{
+// public TinkersHood()
+// {
+// super(0, 0);
+// setUnlocalizedName("tinkershood");
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkerTools.toolRod;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 1;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_hood_cloth";
+// case 1:
+// return "_hood_cloth_broken";
+// case 2:
+// return "_hood_metal";
+// case 3:
+// return "_hood_trim";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_hood_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/hood";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersHood.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "head", "hood", "cloth"};
+// }
+//
+// @Override
+// public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
+// {
+// return 0;
+// }
+//
+// @Override
+// @Optional.Method(modid = "Thaumcraft")
+// public int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect)
+// {
+// return stack.getTagCompound().getCompoundTag("InfiTool").getInteger("VisEmbroidery");
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.hood;
+// }
+//
+// @Override
+// public float getDiscount(ItemStack stack, int arg1, EntityPlayer arg2)
+// {
+// final float i = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ManaEmbroidery") / 100f;
+// return i;
+// }
+//
+// @Optional.Method(modid = "Thaumcraft")
+// @Override
+// public boolean showIngamePopups(ItemStack itemstack, EntityLivingBase player)
+// {
+// return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
+// }
+//
+// @Optional.Method(modid = "Thaumcraft")
+// @Override
+// public boolean showNodes(ItemStack itemstack, EntityLivingBase player)
+// {
+// return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
+// }
+//
+// @Optional.Method(modid = "AWWayofTime")
+// @Override
+// public boolean canSeeLPBar(ItemStack stack)
+// {
+// return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
+// }
+//
+// @Optional.Method(modid = "AWWayofTime")
+// @Override
+// public boolean showIngameHUD(World world, ItemStack stack, EntityPlayer player)
+// {
+// return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersRobe.java b/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersRobe.java
index bad02bd..c0c0df4 100644
--- a/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersRobe.java
+++ b/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersRobe.java
@@ -1,152 +1,148 @@
-package lance5057.tDefense.armor.items.cloth;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import thaumcraft.api.IVisDiscountGear;
-import thaumcraft.api.aspects.Aspect;
-import vazkii.botania.api.mana.IManaDiscountArmor;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IVisDiscountGear", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.mana.IManaDiscountArmor", striprefs = true)})
-public class TinkersRobe extends ArmorCore implements IVisDiscountGear, IManaDiscountArmor
-{
- public TinkersRobe()
- {
- super(0, 2);
- setUnlocalizedName("tinkerrobe");
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkersDefense.partClasp;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 1;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_robe_cloth";
- case 1:
- return "_robe_cloth_broken";
- case 2:
- return "_robe_metal";
- case 3:
- return "_robe_trim";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_robe_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/robe";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersRobe.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "pants", "robe", "cloth"};
- }
-
- @Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
- return 0;
- }
-
- @Override
- @Optional.Method(modid = "Thaumcraft")
- public int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect)
- {
- final int vis = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("VisEmbroidery");
- return vis;
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.robe;
- }
-
- @Override
- public float getDiscount(ItemStack stack, int arg1, EntityPlayer arg2)
- {
- final float i = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ManaEmbroidery") / 100f;
- return i;
- }
-}
+//package lance5057.tDefense.armor.items.cloth;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import thaumcraft.api.IVisDiscountGear;
+//import thaumcraft.api.aspects.Aspect;
+//import vazkii.botania.api.mana.IManaDiscountArmor;
+//import cpw.mods.fml.common.Optional;
+//
+//@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IVisDiscountGear", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.mana.IManaDiscountArmor", striprefs = true)})
+//public class TinkersRobe extends ArmorCore implements IVisDiscountGear, IManaDiscountArmor
+//{
+// public TinkersRobe()
+// {
+// super(0, 2);
+// setUnlocalizedName("tinkerrobe");
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkersDefense.partClasp;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 1;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_robe_cloth";
+// case 1:
+// return "_robe_cloth_broken";
+// case 2:
+// return "_robe_metal";
+// case 3:
+// return "_robe_trim";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_robe_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/robe";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersRobe.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "pants", "robe", "cloth"};
+// }
+//
+// @Override
+// public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
+// {
+// return 0;
+// }
+//
+// @Override
+// @Optional.Method(modid = "Thaumcraft")
+// public int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect)
+// {
+// final int vis = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("VisEmbroidery");
+// return vis;
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.robe;
+// }
+//
+// @Override
+// public float getDiscount(ItemStack stack, int arg1, EntityPlayer arg2)
+// {
+// final float i = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ManaEmbroidery") / 100f;
+// return i;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShawl.java b/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShawl.java
index 17b84a2..bb913a2 100644
--- a/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShawl.java
+++ b/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShawl.java
@@ -1,154 +1,150 @@
-package lance5057.tDefense.armor.items.cloth;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import thaumcraft.api.IVisDiscountGear;
-import thaumcraft.api.aspects.Aspect;
-import vazkii.botania.api.mana.IManaDiscountArmor;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IVisDiscountGear", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.mana.IManaDiscountArmor", striprefs = true)})
-public class TinkersShawl extends ArmorCore implements IVisDiscountGear, IManaDiscountArmor
-{
- public TinkersShawl()
- {
- super(0, 1);
- setUnlocalizedName("tinkersshawl");
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partCloth;
-
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 1;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_shawl_cloth";
- case 1:
- return "_shawl_cloth_broken";
- case 2:
- return "_shawl_metal";
- case 3:
- return "_shawl_trim";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_shawl_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/shawl";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersShawl.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "chest", "shawl", "cloth"};
- }
-
- @Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
- return 0;
- }
-
- @Override
- @Optional.Method(modid = "Thaumcraft")
- public int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect)
- {
- final int test = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("VisEmbroidery");
- return test;
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- // TODO Auto-generated method stub
- return ClientProxy.shawl;
- }
-
- @Override
- public float getDiscount(ItemStack stack, int arg1, EntityPlayer arg2)
- {
- final float i = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ManaEmbroidery") / 100f;
- return i;
- }
-}
+//package lance5057.tDefense.armor.items.cloth;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import thaumcraft.api.IVisDiscountGear;
+//import thaumcraft.api.aspects.Aspect;
+//import vazkii.botania.api.mana.IManaDiscountArmor;
+//import cpw.mods.fml.common.Optional;
+//
+//@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IVisDiscountGear", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.mana.IManaDiscountArmor", striprefs = true)})
+//public class TinkersShawl extends ArmorCore implements IVisDiscountGear, IManaDiscountArmor
+//{
+// public TinkersShawl()
+// {
+// super(0, 1);
+// setUnlocalizedName("tinkersshawl");
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkersDefense.partArmorplate;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partCloth;
+//
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 1;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_shawl_cloth";
+// case 1:
+// return "_shawl_cloth_broken";
+// case 2:
+// return "_shawl_metal";
+// case 3:
+// return "_shawl_trim";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_shawl_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/shawl";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersShawl.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "chest", "shawl", "cloth"};
+// }
+//
+// @Override
+// public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
+// {
+// return 0;
+// }
+//
+// @Override
+// @Optional.Method(modid = "Thaumcraft")
+// public int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect)
+// {
+// final int test = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("VisEmbroidery");
+// return test;
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// // TODO Auto-generated method stub
+// return ClientProxy.shawl;
+// }
+//
+// @Override
+// public float getDiscount(ItemStack stack, int arg1, EntityPlayer arg2)
+// {
+// final float i = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ManaEmbroidery") / 100f;
+// return i;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShoes.java b/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShoes.java
index a0c77ff..742af0e 100644
--- a/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShoes.java
+++ b/src/main/java/lance5057/tDefense/armor/items/cloth/TinkersShoes.java
@@ -1,151 +1,147 @@
-package lance5057.tDefense.armor.items.cloth;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import thaumcraft.api.IVisDiscountGear;
-import thaumcraft.api.aspects.Aspect;
-import vazkii.botania.api.mana.IManaDiscountArmor;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IVisDiscountGear", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.mana.IManaDiscountArmor", striprefs = true)})
-public class TinkersShoes extends ArmorCore implements IVisDiscountGear, IManaDiscountArmor
-{
- public TinkersShoes()
- {
- super(0, 3);
- setUnlocalizedName("tinkersshoes");
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkersDefense.partRivet;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 1;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_shoes_cloth";
- case 1:
- return "_shoes_cloth_broken";
- case 2:
- return "_shoes_metal";
- case 3:
- return "_shoes_sole";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_shoes_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/shoes";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersShoes.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "feet", "shoes", "cloth"};
- }
-
- @Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
- return 0;
- }
-
- @Override
- @Optional.Method(modid = "Thaumcraft")
- public int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect)
- {
- return stack.getTagCompound().getCompoundTag("InfiTool").getInteger("VisEmbroidery");
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.shoes;
- }
-
- @Override
- public float getDiscount(ItemStack stack, int arg1, EntityPlayer arg2)
- {
- final float i = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ManaEmbroidery") / 100f;
- return i;
- }
-}
+//package lance5057.tDefense.armor.items.cloth;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import thaumcraft.api.IVisDiscountGear;
+//import thaumcraft.api.aspects.Aspect;
+//import vazkii.botania.api.mana.IManaDiscountArmor;
+//import cpw.mods.fml.common.Optional;
+//
+//@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IVisDiscountGear", striprefs = true), @Optional.Interface(modid = "Botania", iface = "vazkii.botania.api.mana.IManaDiscountArmor", striprefs = true)})
+//public class TinkersShoes extends ArmorCore implements IVisDiscountGear, IManaDiscountArmor
+//{
+// public TinkersShoes()
+// {
+// super(0, 3);
+// setUnlocalizedName("tinkersshoes");
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkersDefense.partRivet;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 1;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_shoes_cloth";
+// case 1:
+// return "_shoes_cloth_broken";
+// case 2:
+// return "_shoes_metal";
+// case 3:
+// return "_shoes_sole";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_shoes_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/shoes";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersShoes.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "feet", "shoes", "cloth"};
+// }
+//
+// @Override
+// public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
+// {
+// return 0;
+// }
+//
+// @Override
+// @Optional.Method(modid = "Thaumcraft")
+// public int getVisDiscount(ItemStack stack, EntityPlayer player, Aspect aspect)
+// {
+// return stack.getTagCompound().getCompoundTag("InfiTool").getInteger("VisEmbroidery");
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.shoes;
+// }
+//
+// @Override
+// public float getDiscount(ItemStack stack, int arg1, EntityPlayer arg2)
+// {
+// final float i = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("ManaEmbroidery") / 100f;
+// return i;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersBreastplate.java b/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersBreastplate.java
index af6ccfb..07905a4 100644
--- a/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersBreastplate.java
+++ b/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersBreastplate.java
@@ -1,129 +1,64 @@
package lance5057.tDefense.armor.items.heavy;
-import lance5057.tDefense.TinkersDefense;
+import java.util.List;
+
import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.Item;
+import net.minecraft.entity.EntityLivingBase;
+import net.minecraft.inventory.EntityEquipmentSlot;
import net.minecraft.item.ItemStack;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.DamageSource;
+import slimeknights.tconstruct.library.materials.Material;
+import slimeknights.tconstruct.library.tinkering.PartMaterialType;
+import slimeknights.tconstruct.tools.TinkerTools;
public class TinkersBreastplate extends ArmorCore
{
public TinkersBreastplate()
{
- super(2, 1);
+ super(EntityEquipmentSlot.CHEST,
+ PartMaterialType.head(TinkerTools.largePlate),
+ PartMaterialType.head(TinkerTools.largePlate),
+ PartMaterialType.handle(TinkerTools.toughToolRod),
+ PartMaterialType.extra(TinkerTools.bowString));
setUnlocalizedName("tinkersbreastplate");
maxReduction = 100;
reductionPercent = 8 * 0.04f;
}
@Override
- public Item getHeadItem()
- {
- return TinkerTools.largePlate;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toughRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getExtraItem()
- {
- return TinkersDefense.partChainmaille;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 2;
- }
-
- @Override
- public float getRepairCost()
- {
- return 4.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 2.5f;
+ public void damageArmor(EntityLivingBase entity, ItemStack stack, DamageSource source, int damage, int slot) {
+ // TODO Auto-generated method stub
+
}
@Override
- public float getDamageModifier()
- {
- return 1.4f;
+ public float damagePotential() {
+ // TODO Auto-generated method stub
+ return 0;
}
@Override
- public int getPartAmount()
- {
- return 4;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_breastplate_plate";
- case 1:
- return "_breastplate_plate_broken";
- case 2:
- return "_breastplate_trim";
- case 3:
- return "_breastplate_smallplate";
- case 4:
- return "_breastplate_chain";
- default:
- return "";
- }
+ public double attackSpeed() {
+ // TODO Auto-generated method stub
+ return 0;
}
@Override
- public String getEffectSuffix()
- {
- return "_breastplate_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/breastplate";
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/Tinkersbreastplate.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "chest", "breastplate", "heavyarmor"};
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.breastplate;
- }
+ public NBTTagCompound buildTag(List<Material> materials) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/Tinkersbreastplate.png";
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.breastplate;
+// }
}
diff --git a/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersGrieves.java b/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersGrieves.java
index 3a019c8..e763ff8 100644
--- a/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersGrieves.java
+++ b/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersGrieves.java
@@ -1,136 +1,132 @@
-package lance5057.tDefense.armor.items.heavy;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class TinkersGrieves extends ArmorCore
-{
- public TinkersGrieves()
- {
- super(2, 2);
- setUnlocalizedName("tinkergrieves");
- maxReduction = 100;
- reductionPercent = 6 * 0.04f;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toughRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partChainmaille;
- }
-
- @Override
- public Item getExtraItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 2;
- }
-
- @Override
- public float getRepairCost()
- {
- return 4.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 2.5f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1.4f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 4;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_grieves_plate";
- case 1:
- return "_grieves_plate_broken";
- case 2:
- return "_grieves_trim";
- case 3:
- return "_grieves_chain";
- case 4:
- return "_grieves_cloth";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_grieves_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/grieves";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersGrieves.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "pants", "grieves", "heavyarmor"};
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.grieves;
- }
-}
+//package lance5057.tDefense.armor.items.heavy;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import tconstruct.tools.TinkerTools;
+//
+//public class TinkersGrieves extends ArmorCore
+//{
+// public TinkersGrieves()
+// {
+// super(2, 2);
+// setUnlocalizedName("tinkergrieves");
+// maxReduction = 100;
+// reductionPercent = 6 * 0.04f;
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partArmorplate;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkerTools.toughRod;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partChainmaille;
+// }
+//
+// @Override
+// public Item getExtraItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 2;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 4.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 2.5f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1.4f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 4;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_grieves_plate";
+// case 1:
+// return "_grieves_plate_broken";
+// case 2:
+// return "_grieves_trim";
+// case 3:
+// return "_grieves_chain";
+// case 4:
+// return "_grieves_cloth";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_grieves_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/grieves";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersGrieves.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "pants", "grieves", "heavyarmor"};
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.grieves;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersHelm.java b/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersHelm.java
index 02754bf..8e47805 100644
--- a/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersHelm.java
+++ b/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersHelm.java
@@ -1,173 +1,169 @@
-package lance5057.tDefense.armor.items.heavy;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import tconstruct.tools.TinkerTools;
-import thaumcraft.api.IGoggles;
-import thaumcraft.api.nodes.IRevealer;
-import WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles;
-import WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IGoggles", striprefs = true), @Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.nodes.IRevealer", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles", striprefs = true)})
-public class TinkersHelm extends ArmorCore implements IRevealer, IGoggles, ILPGauge, IAlchemyGoggles
-{
- public TinkersHelm()
- {
- super(2, 0);
- setUnlocalizedName("tinkershelm");
- maxReduction = 100;
- reductionPercent = 3 * 0.04f;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkerTools.frypanHead;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toughRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getExtraItem()
- {
- return TinkersDefense.partChainmaille;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 2;
- }
-
- @Override
- public float getRepairCost()
- {
- return 4.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 2.5f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1.4f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 4;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_helm_top";
- case 1:
- return "_helm_top_broken";
- case 2:
- return "_helm_chain";
- case 3:
- return "_helm_plate";
- case 4:
- return "_helm_visor";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_helm_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/helm";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersHelm.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "head", "helm", "heavyarmor"};
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.helm;
- }
-
- @Optional.Method(modid = "Thaumcraft")
- @Override
- public boolean showIngamePopups(ItemStack itemstack, EntityLivingBase player)
- {
- return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
- }
-
- @Optional.Method(modid = "Thaumcraft")
- @Override
- public boolean showNodes(ItemStack itemstack, EntityLivingBase player)
- {
- return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
- }
-
- @Optional.Method(modid = "AWWayofTime")
- @Override
- public boolean canSeeLPBar(ItemStack stack)
- {
- return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
- }
-
- @Optional.Method(modid = "AWWayofTime")
- @Override
- public boolean showIngameHUD(World world, ItemStack stack, EntityPlayer player)
- {
- return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
- }
-}
+//package lance5057.tDefense.armor.items.heavy;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.EntityLivingBase;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.world.World;
+//import tconstruct.tools.TinkerTools;
+//import thaumcraft.api.IGoggles;
+//import thaumcraft.api.nodes.IRevealer;
+//import WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles;
+//import WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge;
+//import cpw.mods.fml.common.Optional;
+//
+//@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IGoggles", striprefs = true), @Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.nodes.IRevealer", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles", striprefs = true)})
+//public class TinkersHelm extends ArmorCore implements IRevealer, IGoggles, ILPGauge, IAlchemyGoggles
+//{
+// public TinkersHelm()
+// {
+// super(2, 0);
+// setUnlocalizedName("tinkershelm");
+// maxReduction = 100;
+// reductionPercent = 3 * 0.04f;
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkerTools.frypanHead;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkerTools.toughRod;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partArmorplate;
+// }
+//
+// @Override
+// public Item getExtraItem()
+// {
+// return TinkersDefense.partChainmaille;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 2;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 4.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 2.5f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1.4f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 4;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_helm_top";
+// case 1:
+// return "_helm_top_broken";
+// case 2:
+// return "_helm_chain";
+// case 3:
+// return "_helm_plate";
+// case 4:
+// return "_helm_visor";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_helm_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/helm";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersHelm.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "head", "helm", "heavyarmor"};
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.helm;
+// }
+//
+// @Optional.Method(modid = "Thaumcraft")
+// @Override
+// public boolean showIngamePopups(ItemStack itemstack, EntityLivingBase player)
+// {
+// return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
+// }
+//
+// @Optional.Method(modid = "Thaumcraft")
+// @Override
+// public boolean showNodes(ItemStack itemstack, EntityLivingBase player)
+// {
+// return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
+// }
+//
+// @Optional.Method(modid = "AWWayofTime")
+// @Override
+// public boolean canSeeLPBar(ItemStack stack)
+// {
+// return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
+// }
+//
+// @Optional.Method(modid = "AWWayofTime")
+// @Override
+// public boolean showIngameHUD(World world, ItemStack stack, EntityPlayer player)
+// {
+// return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersSabatons.java b/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersSabatons.java
index c7f83d0..47bcc77 100644
--- a/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersSabatons.java
+++ b/src/main/java/lance5057/tDefense/armor/items/heavy/TinkersSabatons.java
@@ -1,136 +1,132 @@
-package lance5057.tDefense.armor.items.heavy;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class TinkersSabatons extends ArmorCore
-{
- public TinkersSabatons()
- {
- super(2, 3);
- setUnlocalizedName("tinkersabatons");
- maxReduction = 100;
- reductionPercent = 3 * 0.04f;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toughRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getExtraItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 2;
- }
-
- @Override
- public float getRepairCost()
- {
- return 4.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 2.5f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1.4f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 4;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_sabatons_plates";
- case 1:
- return "_sabatons_plate_broken";
- case 2:
- return "_sabatons_trim";
- case 3:
- return "_sabatons_caps";
- case 4:
- return "_sabatons_soles";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_sabatons_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/sabatons";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersSabatons.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "feet", "sabatons", "heavyarmor"};
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.sabatons;
- }
-}
+//package lance5057.tDefense.armor.items.heavy;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import tconstruct.tools.TinkerTools;
+//
+//public class TinkersSabatons extends ArmorCore
+//{
+// public TinkersSabatons()
+// {
+// super(2, 3);
+// setUnlocalizedName("tinkersabatons");
+// maxReduction = 100;
+// reductionPercent = 3 * 0.04f;
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partArmorplate;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkerTools.toughRod;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partArmorplate;
+// }
+//
+// @Override
+// public Item getExtraItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 2;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 4.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 2.5f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1.4f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 4;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_sabatons_plates";
+// case 1:
+// return "_sabatons_plate_broken";
+// case 2:
+// return "_sabatons_trim";
+// case 3:
+// return "_sabatons_caps";
+// case 4:
+// return "_sabatons_soles";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_sabatons_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/sabatons";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersSabatons.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "feet", "sabatons", "heavyarmor"};
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.sabatons;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/light/TinkersBoots.java b/src/main/java/lance5057/tDefense/armor/items/light/TinkersBoots.java
index 4043a06..9bc9a4f 100644
--- a/src/main/java/lance5057/tDefense/armor/items/light/TinkersBoots.java
+++ b/src/main/java/lance5057/tDefense/armor/items/light/TinkersBoots.java
@@ -1,134 +1,130 @@
-package lance5057.tDefense.armor.items.light;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class TinkersBoots extends ArmorCore
-{
- public TinkersBoots()
- {
- super(1, 3);
- setUnlocalizedName("tinkersboots");
- maxReduction = 100;
- reductionPercent = 0.08f;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partChainmaille;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partRivet;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 1;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_boots_chain";
- case 1:
- return "_boots_chain_broken";
- case 2:
- return "_boots_cloth";
- case 3:
- return "_boots_rivet";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_boots_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/boots";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersBoots.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "feet", "boots", "lightarmor"};
- }
-
- @Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
- return 2;
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.boots;
- }
-}
+//package lance5057.tDefense.armor.items.light;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//
+//public class TinkersBoots extends ArmorCore
+//{
+// public TinkersBoots()
+// {
+// super(1, 3);
+// setUnlocalizedName("tinkersboots");
+// maxReduction = 100;
+// reductionPercent = 0.08f;
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partChainmaille;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partRivet;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 1;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_boots_chain";
+// case 1:
+// return "_boots_chain_broken";
+// case 2:
+// return "_boots_cloth";
+// case 3:
+// return "_boots_rivet";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_boots_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/boots";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersBoots.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "feet", "boots", "lightarmor"};
+// }
+//
+// @Override
+// public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
+// {
+// return 2;
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.boots;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/light/TinkersChausses.java b/src/main/java/lance5057/tDefense/armor/items/light/TinkersChausses.java
index 3786d7f..41b189c 100644
--- a/src/main/java/lance5057/tDefense/armor/items/light/TinkersChausses.java
+++ b/src/main/java/lance5057/tDefense/armor/items/light/TinkersChausses.java
@@ -1,144 +1,140 @@
-package lance5057.tDefense.armor.items.light;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.DamageSource;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class TinkersChausses extends ArmorCore
-{
- public TinkersChausses()
- {
- super(1, 2);
- setUnlocalizedName("tinkerschausses");
- maxReduction = 100;
- reductionPercent = 0.2f;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partChainmaille;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 1;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_chausses_chain";
- case 1:
- return "_chausses_chain_broken";
- case 2:
- return "_chausses_plate";
- case 3:
- return "_chausses_cloth";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_chausses_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/chausses";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersChausses.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "pants", "chausses", "lightarmor"};
- }
-
- @Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
- return 5;
- }
-
- @Override
- public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage, int slot)
- {
- final ArmorProperties armorp = new ArmorProperties(0, 0.2, 100); //0.04 per half shirt
- //((EntityPlayer)player).addChatComponentMessage(new ChatComponentText(Double.toString(damage)));
- return armorp;
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.chausses;
- }
-}
+//package lance5057.tDefense.armor.items.light;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.EntityLivingBase;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.util.DamageSource;
+//
+//public class TinkersChausses extends ArmorCore
+//{
+// public TinkersChausses()
+// {
+// super(1, 2);
+// setUnlocalizedName("tinkerschausses");
+// maxReduction = 100;
+// reductionPercent = 0.2f;
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partChainmaille;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkersDefense.partArmorplate;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 1;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_chausses_chain";
+// case 1:
+// return "_chausses_chain_broken";
+// case 2:
+// return "_chausses_plate";
+// case 3:
+// return "_chausses_cloth";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_chausses_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/chausses";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersChausses.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "pants", "chausses", "lightarmor"};
+// }
+//
+// @Override
+// public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
+// {
+// return 5;
+// }
+//
+// @Override
+// public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage, int slot)
+// {
+// final ArmorProperties armorp = new ArmorProperties(0, 0.2, 100); //0.04 per half shirt
+// //((EntityPlayer)player).addChatComponentMessage(new ChatComponentText(Double.toString(damage)));
+// return armorp;
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.chausses;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/light/TinkersCoif.java b/src/main/java/lance5057/tDefense/armor/items/light/TinkersCoif.java
index 4489fdf..26c6581 100644
--- a/src/main/java/lance5057/tDefense/armor/items/light/TinkersCoif.java
+++ b/src/main/java/lance5057/tDefense/armor/items/light/TinkersCoif.java
@@ -1,181 +1,177 @@
-package lance5057.tDefense.armor.items.light;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.DamageSource;
-import net.minecraft.world.World;
-import tconstruct.tools.TinkerTools;
-import thaumcraft.api.IGoggles;
-import thaumcraft.api.nodes.IRevealer;
-import WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles;
-import WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IGoggles", striprefs = true), @Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.nodes.IRevealer", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles", striprefs = true)})
-public class TinkersCoif extends ArmorCore implements IRevealer, IGoggles, ILPGauge, IAlchemyGoggles
-{
- public TinkersCoif()
- {
- super(1, 0);
- setUnlocalizedName("tinkerscoif");
- maxReduction = 100;
- reductionPercent = 0.08f;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partChainmaille;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toughRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 1;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_coif_chain";
- case 1:
- return "_coif_chain_broken";
- case 2:
- return "_coif_circlet";
- case 3:
- return "_coif_cloth";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_coif_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/coif";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersCoif.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "head", "coif", "lightarmor"};
- }
-
- @Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
- return 2;
- }
-
- @Override
- public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage, int slot)
- {
- final ArmorProperties armorp = new ArmorProperties(0, 0.08, 100); //0.04 per half shirt
- //((EntityPlayer)player).addChatComponentMessage(new ChatComponentText(Double.toString(damage)));
- return armorp;
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- // TODO Auto-generated method stub
- return ClientProxy.coif;
- }
-
- @Optional.Method(modid = "Thaumcraft")
- @Override
- public boolean showIngamePopups(ItemStack itemstack, EntityLivingBase player)
- {
- return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
- }
-
- @Optional.Method(modid = "Thaumcraft")
- @Override
- public boolean showNodes(ItemStack itemstack, EntityLivingBase player)
- {
- return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
- }
-
- @Optional.Method(modid = "AWWayofTime")
- @Override
- public boolean canSeeLPBar(ItemStack stack)
- {
- return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
- }
-
- @Optional.Method(modid = "AWWayofTime")
- @Override
- public boolean showIngameHUD(World world, ItemStack stack, EntityPlayer player)
- {
- return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
- }
-}
+//package lance5057.tDefense.armor.items.light;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.EntityLivingBase;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.util.DamageSource;
+//import net.minecraft.world.World;
+//import tconstruct.tools.TinkerTools;
+//import thaumcraft.api.IGoggles;
+//import thaumcraft.api.nodes.IRevealer;
+//import WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles;
+//import WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge;
+//import cpw.mods.fml.common.Optional;
+//
+//@Optional.InterfaceList({@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IGoggles", striprefs = true), @Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.nodes.IRevealer", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.items.interfaces.ILPGauge", striprefs = true), @Optional.Interface(modid = "AWWayofTime", iface = "WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles", striprefs = true)})
+//public class TinkersCoif extends ArmorCore implements IRevealer, IGoggles, ILPGauge, IAlchemyGoggles
+//{
+// public TinkersCoif()
+// {
+// super(1, 0);
+// setUnlocalizedName("tinkerscoif");
+// maxReduction = 100;
+// reductionPercent = 0.08f;
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partChainmaille;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkerTools.toughRod;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 1;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_coif_chain";
+// case 1:
+// return "_coif_chain_broken";
+// case 2:
+// return "_coif_circlet";
+// case 3:
+// return "_coif_cloth";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_coif_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/coif";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersCoif.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "head", "coif", "lightarmor"};
+// }
+//
+// @Override
+// public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
+// {
+// return 2;
+// }
+//
+// @Override
+// public ArmorProperties getProperties(EntityLivingBase player, ItemStack armor, DamageSource source, double damage, int slot)
+// {
+// final ArmorProperties armorp = new ArmorProperties(0, 0.08, 100); //0.04 per half shirt
+// //((EntityPlayer)player).addChatComponentMessage(new ChatComponentText(Double.toString(damage)));
+// return armorp;
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// // TODO Auto-generated method stub
+// return ClientProxy.coif;
+// }
+//
+// @Optional.Method(modid = "Thaumcraft")
+// @Override
+// public boolean showIngamePopups(ItemStack itemstack, EntityLivingBase player)
+// {
+// return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
+// }
+//
+// @Optional.Method(modid = "Thaumcraft")
+// @Override
+// public boolean showNodes(ItemStack itemstack, EntityLivingBase player)
+// {
+// return itemstack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Revealing");
+// }
+//
+// @Optional.Method(modid = "AWWayofTime")
+// @Override
+// public boolean canSeeLPBar(ItemStack stack)
+// {
+// return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
+// }
+//
+// @Optional.Method(modid = "AWWayofTime")
+// @Override
+// public boolean showIngameHUD(World world, ItemStack stack, EntityPlayer player)
+// {
+// return stack.getTagCompound().getCompoundTag("InfiTool").getBoolean("Divination");
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/items/light/TinkersHauberk.java b/src/main/java/lance5057/tDefense/armor/items/light/TinkersHauberk.java
index 94c2b5f..b6ca11c 100644
--- a/src/main/java/lance5057/tDefense/armor/items/light/TinkersHauberk.java
+++ b/src/main/java/lance5057/tDefense/armor/items/light/TinkersHauberk.java
@@ -1,135 +1,131 @@
-package lance5057.tDefense.armor.items.light;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class TinkersHauberk extends ArmorCore
-{
- public TinkersHauberk()
- {
- super(1, 1);
- setUnlocalizedName("tinkershauberk");
- maxReduction = 100;
- reductionPercent = 0.24f;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partChainmaille;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.largePlate;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partCloth;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 1;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 1f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_hauberk_chain";
- case 1:
- return "_hauberk_chain_broken";
- case 2:
- return "_hauberk_plate";
- case 3:
- return "_hauberk_cloth";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_hauberk_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "armor/hauberk";
- }
-
- // @Override
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- //
- // }
-
- @Override
- @SideOnly(Side.CLIENT)
- public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
- {
- return "tinkersdefense:textures/armor/TinkersHauberk.png";
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"armor", "chest", "hauberk", "lightarmor"};
- }
-
- @Override
- public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
- {
- return 6;
- }
-
- @Override
- @SideOnly(Side.CLIENT)
- public ArmorRenderer getRenderer()
- {
- return ClientProxy.hauberk;
- }
-}
+//package lance5057.tDefense.armor.items.light;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import lance5057.tDefense.proxy.ClientProxy;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import tconstruct.tools.TinkerTools;
+//
+//public class TinkersHauberk extends ArmorCore
+//{
+// public TinkersHauberk()
+// {
+// super(1, 1);
+// setUnlocalizedName("tinkershauberk");
+// maxReduction = 100;
+// reductionPercent = 0.24f;
+// }
+//
+// @Override
+// public Item getHeadItem()
+// {
+// return TinkersDefense.partChainmaille;
+// }
+//
+// @Override
+// public Item getHandleItem()
+// {
+// return TinkerTools.largePlate;
+// }
+//
+// @Override
+// public Item getAccessoryItem()
+// {
+// return TinkersDefense.partCloth;
+// }
+//
+// @Override
+// public int durabilityTypeAccessory()
+// {
+// return 1;
+// }
+//
+// @Override
+// public float getRepairCost()
+// {
+// return 1.0f;
+// }
+//
+// @Override
+// public float getDurabilityModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public float getDamageModifier()
+// {
+// return 1f;
+// }
+//
+// @Override
+// public int getPartAmount()
+// {
+// return 3;
+// }
+//
+// @Override
+// public String getIconSuffix(int partType)
+// {
+// switch(partType)
+// {
+// case 0:
+// return "_hauberk_chain";
+// case 1:
+// return "_hauberk_chain_broken";
+// case 2:
+// return "_hauberk_plate";
+// case 3:
+// return "_hauberk_cloth";
+// default:
+// return "";
+// }
+// }
+//
+// @Override
+// public String getEffectSuffix()
+// {
+// return "_hauberk_effect";
+// }
+//
+// @Override
+// public String getDefaultFolder()
+// {
+// return "armor/hauberk";
+// }
+//
+// // @Override
+// // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
+// // boolean par5) {
+// // super.onUpdate(stack, world, entity, par4, par5);
+// //
+// // }
+//
+// @Override
+// public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
+// {
+// return "tinkersdefense:textures/armor/TinkersHauberk.png";
+// }
+//
+// @Override
+// public String[] getTraits()
+// {
+// return new String[] {"armor", "chest", "hauberk", "lightarmor"};
+// }
+//
+// @Override
+// public int getArmorDisplay(EntityPlayer player, ItemStack armor, int slot)
+// {
+// return 6;
+// }
+//
+// @Override
+// public ArmorRenderer getRenderer()
+// {
+// return ClientProxy.hauberk;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/modifiers/ArmorMods.java b/src/main/java/lance5057/tDefense/armor/modifiers/ArmorMods.java
index 208031f..e15f44c 100644
--- a/src/main/java/lance5057/tDefense/armor/modifiers/ArmorMods.java
+++ b/src/main/java/lance5057/tDefense/armor/modifiers/ArmorMods.java
@@ -1,560 +1,560 @@
-package lance5057.tDefense.armor.modifiers;
-
-import lance5057.tDefense.TDIntegration;
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.TDArmorAddon;
-import lance5057.tDefense.armor.items.cloth.TinkersRobe;
-import lance5057.tDefense.armor.items.heavy.TinkersGrieves;
-import lance5057.tDefense.armor.items.light.TinkersChausses;
-import lance5057.tDefense.armor.modifiers.BloodMagic.BloodArmorMods;
-import lance5057.tDefense.armor.modifiers.Botania.BotaniaArmorMods;
-import lance5057.tDefense.armor.modifiers.Thaumcraft.ThaumArmorMods;
-import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifierIntExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockLiquid;
-import net.minecraft.block.material.Material;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.world.World;
-import net.minecraftforge.event.entity.living.LivingEvent.LivingJumpEvent;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.client.TConstructClientRegistry;
-import tconstruct.library.crafting.ModifyBuilder;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.common.gameevent.TickEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-
-public class ArmorMods extends ModifiersBase
-{
- ThaumArmorMods tcmods;
- BotaniaArmorMods botmods;
- BloodArmorMods bloodmods;
-
- // Item item_Canister;
- // Item item_Emptycanister;
- // Item item_Rebreather;
- // Item item_NightvisionGoggles;
- //
- // Item item_Glowsole;
- // Item item_Firesole;
- // Item item_Icesole;
- // Item item_Feathersole;
- // Item item_Flippers;
-
- public ArmorMods()
- {
- super(new String[] {"Canister", "EmptyCanister", "Rebreather", "NightvisionGoggles", "Glowstep", "Firewalker", "Frostwalker", "FeatherFall", "Flippers"}, "modItemsArmor");
- FMLCommonHandler.instance().bus().register(this);
-
- if(TDIntegration.thaumcraft)
- {
- tcmods = new ThaumArmorMods();
- }
- if(TDIntegration.botania)
- {
- botmods = new BotaniaArmorMods();
- }
- if(TDIntegration.bloodMagic)
- {
- bloodmods = new BloodArmorMods();
- }
- }
-
- @Override
- public void RegisterRecipes()
- {
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 0), new Object[] {"-c-", "ses", "-s-", 'c', new ItemStack(
- Items.coal, 1, 1), 's', new ItemStack(Blocks.sapling, 1), 'e', new ItemStack(
- modItems, 1, 1)});
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 1), new Object[] {"gsg", "lil", "gig", 'g', new ItemStack(
- Items.gold_nugget, 1, 0), 's', new ItemStack(Items.slime_ball,
- 1, 0), 'l', new ItemStack(Items.dye, 1, 4), 'i', new ItemStack(
- Items.iron_ingot, 1, 0)});
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 2), new Object[] {"-s-", "eie", "-d-", 's', new ItemStack(
- Items.slime_ball, 1, 0), 'e', new ItemStack(modItems, 1, 1), 'i', new ItemStack(
- TinkersDefense.partArmorplate, 1, 2), 'd', new ItemStack(
- Items.dye, 1, 4)});
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 3), new Object[] {"-s-", "eie", "-d-", 's', new ItemStack(
- Items.potionitem, 1, 8262), 'e', new ItemStack(
- Blocks.glass_pane, 1, 0), 'i', new ItemStack(Items.iron_ingot,
- 1, 0), 'd', new ItemStack(Items.dye, 1, 2)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 4), new Object[] {"ggg", "ala", "ggg", 'g', new ItemStack(
- Blocks.glowstone, 1, 0), 'a', new ItemStack(
- Items.glowstone_dust, 1, 0), 'l', TConstructRegistry.getItemStack("lavaCrystal")});
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 5), new Object[] {"lol", "oao", "lol", 'o', new ItemStack(
- Blocks.obsidian, 1, 0), 'a', TConstructRegistry.getItemStack("ingotArdite"), 'l', TConstructRegistry.getItemStack("lavaCrystal")});
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 7), new Object[] {"fgf", 'g', new ItemStack(
- Items.gold_nugget, 1, 0), 'f', new ItemStack(Items.feather, 1,
- 0)});
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 6), new Object[] {"ili", "lcl", "ili", 'l', new ItemStack(
- Blocks.lapis_block, 1, 0), 'i', new ItemStack(Blocks.ice, 1, 0), 'c', TConstructRegistry.getItemStack("ingotCobalt")});
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 8), new Object[] {"-b-", "rlr", "-s-", 'b', new ItemStack(
- Items.leather_boots, 1, 0), 'l', new ItemStack(Items.leather,
- 1, 0), 'r', new ItemStack(TinkerTools.toolRod, 1, 2), 's', new ItemStack(
- Items.slime_ball, 1, 0)});
-
- if(TDIntegration.thaumcraft)
- {
- tcmods.RegisterRecipes();
- }
- if(TDIntegration.botania)
- {
- botmods.RegisterRecipes();
- }
- if(TDIntegration.bloodMagic)
- {
- bloodmods.RegisterRecipes();
- }
- }
-
- @Override
- public void RegisterModifiers()
- {
- //Head only
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 2)},
- TinkersDefense.config.ArmorRebreatherID, "Rebreather",
- EnumChatFormatting.GOLD.toString(), "Rebreather",
- new String[] {"head"}, 1, null));
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 3)},
- TinkersDefense.config.ArmorNightvisionID, "Nightvision",
- EnumChatFormatting.GREEN.toString(), "Nightvision",
- new String[] {"head"}, 1, null));
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {new ItemStack(Items.ghast_tear, 1, 0)},
- TinkersDefense.config.ArmorAntiBlindnessID, "AntiBlindness", 1,
- EnumChatFormatting.AQUA.toString(), "AntiBlindness",
- new String[] {"head"}, 1, null));
- //ModifyBuilder.registerModifier(new modifierBoolExclusive(new ItemStack[] {new ItemStack(Blocks.pumpkin, 1, 0)}, TinkersDefense.config.ArmorPumpkinID, "Pumpkin", EnumChatFormatting.GOLD.toString(), "Pumpkin", new String[] {"head"}, 1, null));
-
- //Legs only
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(Blocks.sticky_piston, 1, 0)},
- TinkersDefense.config.ArmorHighstepID, "Highstep",
- EnumChatFormatting.LIGHT_PURPLE.toString(), "Highstep",
- new String[] {"pants"}, 1, null));
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {new ItemStack(Blocks.redstone_block, 1, 0)},
- TinkersDefense.config.ArmorSpeedID, "Speed", 1,
- EnumChatFormatting.DARK_RED.toString(), "Haste",
- new String[] {"pants"}, 1, null));
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {new ItemStack(Blocks.piston, 1, 0)},
- TinkersDefense.config.ArmorJumpboostID, "Jump", 1,
- EnumChatFormatting.WHITE.toString(), "Jump Boost",
- new String[] {"pants"}, 1, null));
-
- //Excluding Cloth
- ModifyBuilder.registerModifier(new modifierProtection(
- new ItemStack[] {new ItemStack(TinkersDefense.partArmorplate,
- 1, 2)}, TinkersDefense.config.ArmorProtectionID, 1,
- EnumChatFormatting.DARK_GRAY.toString(), "Protection"));
- ModifyBuilder.registerModifier(new modifierProtection(
- new ItemStack[] {new ItemStack(Items.magma_cream, 1)},
- TinkersDefense.config.ArmorFireProtectionID, 1,
- EnumChatFormatting.RED.toString(), "Fire Protection"));
- ModifyBuilder.registerModifier(new modifierProtection(
- new ItemStack[] {new ItemStack(Blocks.wool, 1)},
- TinkersDefense.config.ArmorBlastProtectionID, 1,
- EnumChatFormatting.DARK_GREEN.toString(), "Blast Protection"));
- ModifyBuilder.registerModifier(new modifierProtection(
- new ItemStack[] {new ItemStack(TinkersDefense.partRivet, 1, 2)},
- TinkersDefense.config.ArmorProjectileProtectionID, 1,
- EnumChatFormatting.GRAY.toString(), "Projectile Protection"));
- ModifyBuilder.registerModifier(new modifierProtection(
- new ItemStack[] {new ItemStack(modItems, 1, 7)},
- TinkersDefense.config.ArmorFeatherfallID, 1,
- EnumChatFormatting.WHITE.toString(), "Featherfall"));
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {TConstructRegistry.getItemStack("canisterRedHeart")},
- TinkersDefense.config.ArmorAbsorptionID, "HealthBoost", 1,
- EnumChatFormatting.DARK_RED.toString(), "HealthBoost",
- new String[] {"heavy", "light"}, 1, null));
-
- //Feet only
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 4)},
- TinkersDefense.config.ArmorGlowstepID, "GlowStep",
- EnumChatFormatting.YELLOW.toString(), "GlowStep",
- new String[] {"feet"}, 1, null));
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 5)},
- TinkersDefense.config.ArmorFirewalkerID, "Firewalker",
- EnumChatFormatting.RED.toString(), "Firewalker",
- new String[] {"feet"}, 1, new String[] {"Frostwalker"}));
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 6)},
- TinkersDefense.config.ArmorFrostwalkerID, "Frostwalker",
- EnumChatFormatting.BLUE.toString(), "Frostwalker",
- new String[] {"feet"}, 1, new String[] {"Firewalker"}));
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 8)},
- TinkersDefense.config.ArmorDepthstriderID, "Depthstrider",
- EnumChatFormatting.DARK_BLUE.toString(), "Depthstrider",
- new String[] {"feet"}, 1,
- new String[] {"Frostwalker", "Firewalker"}));
-
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorRebreatherID, "tinker", "rebreather", true);
-
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorProtectionID, "tinker", "protection", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorFireProtectionID, "tinker", "fireprotection", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorBlastProtectionID, "tinker", "blastprotection", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorProjectileProtectionID, "tinker", "projprotection", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorFeatherfallID, "tinker", "featherfall", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorAbsorptionID, "tinker", "healthboost", true);
-
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorGlowstepID, "tinker", "glowstep", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorFirewalkerID, "tinker", "firewalk", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorFrostwalkerID, "tinker", "frostwalk", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorDepthstriderID, "tinker", "depthstrider", true);
-
- }
-
- if(TDIntegration.thaumcraft)
- {
- tcmods.RegisterModifiers();
- }
- if(TDIntegration.botania)
- {
- botmods.RegisterModifiers();
- }
- if(TDIntegration.bloodMagic)
- {
- bloodmods.RegisterModifiers();
- }
- }
-
- @Override
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(!world.isRemote)
- {
- if(tags.hasKey("Frostwalker"))
- {
- UpdateWalker(tool, stack, world, entity, Material.water, TDArmorAddon.block_Unstable, 0);
- }
- if(tags.hasKey("Firewalker"))
- {
- UpdateWalker(tool, stack, world, entity, Material.lava, TDArmorAddon.block_Unstable, 1);
- }
- if(tags.hasKey("GlowStep"))
- {
- UpdateGlowstep(tool, stack, world, entity);
- }
- if(tags.hasKey("Rebreather"))
- {
- UpdateRebreather(tool, stack, world, entity);
- }
- if(tags.hasKey("Nightvision"))
- {
- UpdateNightvision(tool, stack, world, entity);
- }
- if(tags.hasKey("AntiBlindness"))
- {
- UpdateAntiBlind(tool, stack, world, entity);
- }
- if(tags.hasKey("HealthBoost"))
- {
- UpdateHealthBoost(tool, stack, world, entity, tags);
- //UpdateHighstep(tool, stack, world, entity);
- }
-
- }
- else
- {
- if(tags.hasKey("Depthstrider"))
- {
- UpdateFlippers(tool, stack, world, entity);
- }
- if(tags.hasKey("Speed"))
- {
- UpdateSpeed(tool, stack, world, entity, tags);
- // if(tags.hasKey("Jump"))
- // UpdateJump(tool, stack, world, entity, tags);
- }
- }
-
- if(TDIntegration.thaumcraft)
- {
- tcmods.UpdateAll(tool, stack, world, entity, tags);
- }
- if(TDIntegration.botania)
- {
- botmods.UpdateAll(tool, stack, world, entity, tags);
- }
- if(TDIntegration.bloodMagic)
- {
- bloodmods.UpdateAll(tool, stack, world, entity, tags);
- }
- }
-
- public void UpdateWalker(ToolCore tool, ItemStack stack, World world, Entity entity, Material mat, Block replacement, int meta)
- {
- final int x = (int) Math.floor(entity.posX);
- final int y = (int) (entity.posY - entity.getYOffset());
- final int z = (int) Math.floor(entity.posZ);
-
- Block block;
-
- for(int i = 0; i < 5; i++)
- {
- for(int j = 0; j < 5; j++)
- {
- block = world.getBlock(x + (i - 2), y - 1, z + (j - 2));
- if(block instanceof BlockLiquid)
- {
- if(((BlockLiquid) block).getMaterial() == mat && world.getBlockMetadata(x + (i - 2), y - 1, z + (j - 2)) == 0)
- {
- world.setBlock(x + (i - 2), y - 1, z + (j - 2), replacement, meta, 3);
- world.notifyBlocksOfNeighborChange(x + (i - 2), y - 1, z + (j - 2), world.getBlock(x + (i - 2), y - 1, z + (j - 2)));
- }
- }
- }
- }
- }
-
- int glowTimer = 8;
- int prevX = 0;
- int prevZ = 0;
-
- public void UpdateGlowstep(ToolCore tool, ItemStack stack, World world, Entity entity)
- {
- final int x = (int) Math.floor(entity.posX);
- final int y = (int) (entity.posY - entity.getYOffset());
- final int z = (int) Math.floor(entity.posZ);
-
- if(glowTimer == 0)
- {
- if(world.getBlock(x, y, z) == Blocks.air && world.getBlock(x, y - 1, z).isNormalCube())
- {
- world.setBlock(x, y, z, TDArmorAddon.block_GlowCrumbs, 0, 3);
- //world.notifyBlocksOfNeighborChange(x + (i - 2), y - 1, z + (j - 2), world.getBlock(x + (i - 2), y - 1, z + (j - 2)));
- }
- glowTimer = 8;
- }
- else if(Math.abs(x - prevX) >= 1 || Math.abs(z - prevZ) >= 1)
- {
- glowTimer--;
- }
-
- prevX = x;
- prevZ = z;
- }
-
- public void UpdateFlippers(ToolCore tool, ItemStack stack, World world, Entity entity)
- {
- if(entity.isInWater())
- {
- entity.motionX *= 1.2;
- entity.motionY *= 1.2;
- entity.motionZ *= 1.2;
- }
- }
-
- public void UpdateRebreather(ToolCore tool, ItemStack stack, World world, Entity entity)
- {
- final EntityPlayer player = (EntityPlayer) entity;
- if(player.getAir() <= 0)
- {
- ItemStack canStack;
- int i;
- int used = 0;
-
- for(i = 0; i < player.inventory.getSizeInventory(); i++)
- {
- if(player.inventory.getStackInSlot(i) != null && player.inventory.getStackInSlot(i).getItem() == modItems && player.inventory.getStackInSlot(i).getItemDamage() == 0)
- {
- canStack = player.inventory.getStackInSlot(i);
- if(used < 2 && canStack.stackSize == 1)
- {
- player.inventory.decrStackSize(i, 1);
- player.inventory.addItemStackToInventory(new ItemStack(
- modItems, 1, 1));
- player.setAir(150);
- used++;
- }
- if(used == 0 && canStack.stackSize >= 2)
- {
- player.inventory.decrStackSize(i, 2);
- player.inventory.addItemStackToInventory(new ItemStack(
- modItems, 2, 1));
- player.setAir(300);
- break;
- }
- }
- }
- }
- }
-
- public void UpdateNightvision(ToolCore tool, ItemStack stack, World world, Entity entity)
- {
- if(!((EntityPlayer) entity).isPotionActive(Potion.nightVision) || ((EntityPlayer) entity).getActivePotionEffect(Potion.nightVision).getDuration() < 1000)
- {
- ((EntityPlayer) entity).addPotionEffect(new PotionEffect(
- Potion.nightVision.id, 1000, 1, true));
- }
- }
-
- boolean isBlind = false;
-
- public void UpdateAntiBlind(ToolCore tool, ItemStack stack, World world, Entity entity)
- {
- final NBTTagCompound tags = stack.getTagCompound().getCompoundTag("InfiTool");
- if(((EntityPlayer) entity).isPotionActive(Potion.blindness) && !isBlind)
- {
- final int roll = world.rand.nextInt(100);
- final int antiLevel = tags.getInteger("AntiBlindness");
- if(roll < antiLevel * 10)
- {
- ((EntityPlayer) entity).removePotionEffect(Potion.blindness.id);
- }
- else
- {
- isBlind = true;
- }
- }
- if(!((EntityPlayer) entity).isPotionActive(Potion.blindness) && isBlind)
- {
- isBlind = false;
- }
- }
-
- public void UpdateSpeed(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- final EntityPlayer ent = (EntityPlayer) entity;
- if(!entity.isInWater() && !ent.isSneaking() && ent.moveForward > 0.0)
- {
- final float speed = (float) (tags.getInteger("Speed") * 0.05);
- if(entity.onGround)
- {
- ent.moveFlying(0.0f, 1.0f, speed);
- }
- else
- {
- ent.jumpMovementFactor = speed;
- }
- }
- }
-
- PotionEffect hb;
-
- public void UpdateHealthBoost(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(!((EntityPlayer) entity).isPotionActive(21))
- {
- ((EntityPlayer) entity).addPotionEffect(new PotionEffect(21, 100,
- tags.getInteger("HealthBoost") - 1, true));
- }
- else if(((EntityPlayer) entity).getActivePotionEffect(Potion.potionTypes[21]).getDuration() < 10)
- {
- ((EntityPlayer) entity).getActivePotionEffect(Potion.potionTypes[21]).combine(new PotionEffect(
- 21, 100, tags.getInteger("HealthBoost") - 1, true));
- }
- }
-
- // public void UpdateJump(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- // {
- // EntityPlayer ent = (EntityPlayer) entity;
- // if(!entity.isInWater() && !ent.isSneaking() && ent.motionY > 0.0)
- // {
- // float speed = (float) (tags.getInteger("Jump") * 0.15);
- //
- // ent.jumpMovementFactor = speed;
- //
- // }
- // }
-
- @SubscribeEvent
- public void Jump(LivingJumpEvent event)
- {
- if(event.entityLiving instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) event.entityLiving;
- if(player.getCurrentArmor(1) != null && player.getCurrentArmor(1).getItem() instanceof ArmorCore)
- {
- final ItemStack legs = player.getCurrentArmor(1);
- final Item armor = legs.getItem();
- final NBTTagCompound tags = legs.getTagCompound().getCompoundTag("InfiTool");
-
- if((armor instanceof TinkersRobe || armor instanceof TinkersChausses || armor instanceof TinkersGrieves) && tags.hasKey("Jump"))
- {
- final double speed = tags.getInteger("Jump") * 0.1;
- player.setVelocity(0, 0.4 + speed, 0);
- player.velocityChanged = true;
- }
- }
- }
- }
-
- @SubscribeEvent
- public void Highstep(TickEvent.PlayerTickEvent event)
- {
- event.player.stepHeight = 0.5f;
- if(event.player.getCurrentArmor(1) != null && event.player.getCurrentArmor(1).getItem() instanceof ArmorCore)
- {
- final ItemStack legs = event.player.getCurrentArmor(1);
- final Item armor = legs.getItem();
- final NBTTagCompound tags = legs.getTagCompound().getCompoundTag("InfiTool");
-
- if((armor instanceof TinkersRobe || armor instanceof TinkersChausses || armor instanceof TinkersGrieves) && tags.hasKey("Highstep") && !event.player.isSneaking())
- {
- event.player.stepHeight = 1.0f;
- }
- }
- }
- // public void UpdateHighstep(ToolCore tool, ItemStack stack, World world, Entity entity)
- // {
- // NBTTagCompound tags = stack.getTagCompound().getCompoundTag("InfiTool");
- // EntityPlayer ent = (EntityPlayer) entity;
- //
- // if(tool instanceof TinkersRobe || tool instanceof TinkersChausses || tool instanceof TinkersGrieves)
- // {
- // ent.stepHeight = 0.5f;
- // if(tags.hasKey("Highstep"))
- // {
- // if(!ent.isSneaking())
- // {
- // ent.stepHeight = 1f;
- // }
- // }
- // }
- //
- // }
-
- // @SubscribeEvent
- // public void CalmEndermen(LivingSetAttackTargetEvent event)
- // {
- // NBTTagCompound tags;
- //
- // if(event.target instanceof EntityPlayer)
- // {
- // if(((EntityPlayer) event.target).getCurrentArmor(3).hasTagCompound() && ((EntityPlayer) event.target).getCurrentArmor(3).getTagCompound().hasKey("InfiTool"))
- // {
- // tags = ((EntityPlayer) event.target).getCurrentArmor(3).getTagCompound().getCompoundTag("InfiTool");
- //
- // if(event.entityLiving instanceof EntityEnderman && tags.hasKey("Pumpkin"))
- // {
- // event.entityLiving.setRevengeTarget(null);
- // }
- // }
- // }
- // }
-}
+//package lance5057.tDefense.armor.modifiers;
+//
+//import lance5057.tDefense.TDIntegration;
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.armor.ArmorCore;
+//import lance5057.tDefense.armor.TDArmorAddon;
+//import lance5057.tDefense.armor.items.cloth.TinkersRobe;
+//import lance5057.tDefense.armor.items.heavy.TinkersGrieves;
+//import lance5057.tDefense.armor.items.light.TinkersChausses;
+//import lance5057.tDefense.armor.modifiers.BloodMagic.BloodArmorMods;
+//import lance5057.tDefense.armor.modifiers.Botania.BotaniaArmorMods;
+//import lance5057.tDefense.armor.modifiers.Thaumcraft.ThaumArmorMods;
+//import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
+//import lance5057.tDefense.core.tools.modifiers.ModifierIntExclusive;
+//import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
+//import net.minecraft.block.Block;
+//import net.minecraft.block.BlockLiquid;
+//import net.minecraft.block.material.Material;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.entity.player.EntityPlayer;
+//import net.minecraft.init.Blocks;
+//import net.minecraft.init.Items;
+//import net.minecraft.item.Item;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.nbt.NBTTagCompound;
+//import net.minecraft.potion.Potion;
+//import net.minecraft.potion.PotionEffect;
+//import net.minecraft.util.EnumChatFormatting;
+//import net.minecraft.world.World;
+//import net.minecraftforge.event.entity.living.LivingEvent.LivingJumpEvent;
+//import tconstruct.library.TConstructRegistry;
+//import tconstruct.library.client.TConstructClientRegistry;
+//import tconstruct.library.crafting.ModifyBuilder;
+//import tconstruct.library.tools.ToolCore;
+//import tconstruct.tools.TinkerTools;
+//import cpw.mods.fml.common.FMLCommonHandler;
+//import cpw.mods.fml.common.eventhandler.SubscribeEvent;
+//import cpw.mods.fml.common.gameevent.TickEvent;
+//import cpw.mods.fml.common.registry.GameRegistry;
+//
+//public class ArmorMods extends ModifiersBase
+//{
+// ThaumArmorMods tcmods;
+// BotaniaArmorMods botmods;
+// BloodArmorMods bloodmods;
+//
+// // Item item_Canister;
+// // Item item_Emptycanister;
+// // Item item_Rebreather;
+// // Item item_NightvisionGoggles;
+// //
+// // Item item_Glowsole;
+// // Item item_Firesole;
+// // Item item_Icesole;
+// // Item item_Feathersole;
+// // Item item_Flippers;
+//
+// public ArmorMods()
+// {
+// super(new String[] {"Canister", "EmptyCanister", "Rebreather", "NightvisionGoggles", "Glowstep", "Firewalker", "Frostwalker", "FeatherFall", "Flippers"}, "modItemsArmor");
+// FMLCommonHandler.instance().bus().register(this);
+//
+// if(TDIntegration.thaumcraft)
+// {
+// tcmods = new ThaumArmorMods();
+// }
+// if(TDIntegration.botania)
+// {
+// botmods = new BotaniaArmorMods();
+// }
+// if(TDIntegration.bloodMagic)
+// {
+// bloodmods = new BloodArmorMods();
+// }
+// }
+//
+// @Override
+// public void RegisterRecipes()
+// {
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 0), new Object[] {"-c-", "ses", "-s-", 'c', new ItemStack(
+// Items.coal, 1, 1), 's', new ItemStack(Blocks.sapling, 1), 'e', new ItemStack(
+// modItems, 1, 1)});
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 1), new Object[] {"gsg", "lil", "gig", 'g', new ItemStack(
+// Items.gold_nugget, 1, 0), 's', new ItemStack(Items.slime_ball,
+// 1, 0), 'l', new ItemStack(Items.dye, 1, 4), 'i', new ItemStack(
+// Items.iron_ingot, 1, 0)});
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 2), new Object[] {"-s-", "eie", "-d-", 's', new ItemStack(
+// Items.slime_ball, 1, 0), 'e', new ItemStack(modItems, 1, 1), 'i', new ItemStack(
+// TinkersDefense.partArmorplate, 1, 2), 'd', new ItemStack(
+// Items.dye, 1, 4)});
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 3), new Object[] {"-s-", "eie", "-d-", 's', new ItemStack(
+// Items.potionitem, 1, 8262), 'e', new ItemStack(
+// Blocks.glass_pane, 1, 0), 'i', new ItemStack(Items.iron_ingot,
+// 1, 0), 'd', new ItemStack(Items.dye, 1, 2)});
+//
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 4), new Object[] {"ggg", "ala", "ggg", 'g', new ItemStack(
+// Blocks.glowstone, 1, 0), 'a', new ItemStack(
+// Items.glowstone_dust, 1, 0), 'l', TConstructRegistry.getItemStack("lavaCrystal")});
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 5), new Object[] {"lol", "oao", "lol", 'o', new ItemStack(
+// Blocks.obsidian, 1, 0), 'a', TConstructRegistry.getItemStack("ingotArdite"), 'l', TConstructRegistry.getItemStack("lavaCrystal")});
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 7), new Object[] {"fgf", 'g', new ItemStack(
+// Items.gold_nugget, 1, 0), 'f', new ItemStack(Items.feather, 1,
+// 0)});
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 6), new Object[] {"ili", "lcl", "ili", 'l', new ItemStack(
+// Blocks.lapis_block, 1, 0), 'i', new ItemStack(Blocks.ice, 1, 0), 'c', TConstructRegistry.getItemStack("ingotCobalt")});
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 8), new Object[] {"-b-", "rlr", "-s-", 'b', new ItemStack(
+// Items.leather_boots, 1, 0), 'l', new ItemStack(Items.leather,
+// 1, 0), 'r', new ItemStack(TinkerTools.toolRod, 1, 2), 's', new ItemStack(
+// Items.slime_ball, 1, 0)});
+//
+// if(TDIntegration.thaumcraft)
+// {
+// tcmods.RegisterRecipes();
+// }
+// if(TDIntegration.botania)
+// {
+// botmods.RegisterRecipes();
+// }
+// if(TDIntegration.bloodMagic)
+// {
+// bloodmods.RegisterRecipes();
+// }
+// }
+//
+// @Override
+// public void RegisterModifiers()
+// {
+// //Head only
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {new ItemStack(modItems, 1, 2)},
+// TinkersDefense.config.ArmorRebreatherID, "Rebreather",
+// EnumChatFormatting.GOLD.toString(), "Rebreather",
+// new String[] {"head"}, 1, null));
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {new ItemStack(modItems, 1, 3)},
+// TinkersDefense.config.ArmorNightvisionID, "Nightvision",
+// EnumChatFormatting.GREEN.toString(), "Nightvision",
+// new String[] {"head"}, 1, null));
+// ModifyBuilder.registerModifier(new ModifierIntExclusive(
+// new ItemStack[] {new ItemStack(Items.ghast_tear, 1, 0)},
+// TinkersDefense.config.ArmorAntiBlindnessID, "AntiBlindness", 1,
+// EnumChatFormatting.AQUA.toString(), "AntiBlindness",
+// new String[] {"head"}, 1, null));
+// //ModifyBuilder.registerModifier(new modifierBoolExclusive(new ItemStack[] {new ItemStack(Blocks.pumpkin, 1, 0)}, TinkersDefense.config.ArmorPumpkinID, "Pumpkin", EnumChatFormatting.GOLD.toString(), "Pumpkin", new String[] {"head"}, 1, null));
+//
+// //Legs only
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {new ItemStack(Blocks.sticky_piston, 1, 0)},
+// TinkersDefense.config.ArmorHighstepID, "Highstep",
+// EnumChatFormatting.LIGHT_PURPLE.toString(), "Highstep",
+// new String[] {"pants"}, 1, null));
+// ModifyBuilder.registerModifier(new ModifierIntExclusive(
+// new ItemStack[] {new ItemStack(Blocks.redstone_block, 1, 0)},
+// TinkersDefense.config.ArmorSpeedID, "Speed", 1,
+// EnumChatFormatting.DARK_RED.toString(), "Haste",
+// new String[] {"pants"}, 1, null));
+// ModifyBuilder.registerModifier(new ModifierIntExclusive(
+// new ItemStack[] {new ItemStack(Blocks.piston, 1, 0)},
+// TinkersDefense.config.ArmorJumpboostID, "Jump", 1,
+// EnumChatFormatting.WHITE.toString(), "Jump Boost",
+// new String[] {"pants"}, 1, null));
+//
+// //Excluding Cloth
+// ModifyBuilder.registerModifier(new modifierProtection(
+// new ItemStack[] {new ItemStack(TinkersDefense.partArmorplate,
+// 1, 2)}, TinkersDefense.config.ArmorProtectionID, 1,
+// EnumChatFormatting.DARK_GRAY.toString(), "Protection"));
+// ModifyBuilder.registerModifier(new modifierProtection(
+// new ItemStack[] {new ItemStack(Items.magma_cream, 1)},
+// TinkersDefense.config.ArmorFireProtectionID, 1,
+// EnumChatFormatting.RED.toString(), "Fire Protection"));
+// ModifyBuilder.registerModifier(new modifierProtection(
+// new ItemStack[] {new ItemStack(Blocks.wool, 1)},
+// TinkersDefense.config.ArmorBlastProtectionID, 1,
+// EnumChatFormatting.DARK_GREEN.toString(), "Blast Protection"));
+// ModifyBuilder.registerModifier(new modifierProtection(
+// new ItemStack[] {new ItemStack(TinkersDefense.partRivet, 1, 2)},
+// TinkersDefense.config.ArmorProjectileProtectionID, 1,
+// EnumChatFormatting.GRAY.toString(), "Projectile Protection"));
+// ModifyBuilder.registerModifier(new modifierProtection(
+// new ItemStack[] {new ItemStack(modItems, 1, 7)},
+// TinkersDefense.config.ArmorFeatherfallID, 1,
+// EnumChatFormatting.WHITE.toString(), "Featherfall"));
+// ModifyBuilder.registerModifier(new ModifierIntExclusive(
+// new ItemStack[] {TConstructRegistry.getItemStack("canisterRedHeart")},
+// TinkersDefense.config.ArmorAbsorptionID, "HealthBoost", 1,
+// EnumChatFormatting.DARK_RED.toString(), "HealthBoost",
+// new String[] {"heavy", "light"}, 1, null));
+//
+// //Feet only
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {new ItemStack(modItems, 1, 4)},
+// TinkersDefense.config.ArmorGlowstepID, "GlowStep",
+// EnumChatFormatting.YELLOW.toString(), "GlowStep",
+// new String[] {"feet"}, 1, null));
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {new ItemStack(modItems, 1, 5)},
+// TinkersDefense.config.ArmorFirewalkerID, "Firewalker",
+// EnumChatFormatting.RED.toString(), "Firewalker",
+// new String[] {"feet"}, 1, new String[] {"Frostwalker"}));
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {new ItemStack(modItems, 1, 6)},
+// TinkersDefense.config.ArmorFrostwalkerID, "Frostwalker",
+// EnumChatFormatting.BLUE.toString(), "Frostwalker",
+// new String[] {"feet"}, 1, new String[] {"Firewalker"}));
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {new ItemStack(modItems, 1, 8)},
+// TinkersDefense.config.ArmorDepthstriderID, "Depthstrider",
+// EnumChatFormatting.DARK_BLUE.toString(), "Depthstrider",
+// new String[] {"feet"}, 1,
+// new String[] {"Frostwalker", "Firewalker"}));
+//
+// for(final ToolCore tool : TConstructRegistry.getToolMapping())
+// {
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorRebreatherID, "tinker", "rebreather", true);
+//
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorProtectionID, "tinker", "protection", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorFireProtectionID, "tinker", "fireprotection", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorBlastProtectionID, "tinker", "blastprotection", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorProjectileProtectionID, "tinker", "projprotection", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorFeatherfallID, "tinker", "featherfall", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorAbsorptionID, "tinker", "healthboost", true);
+//
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorGlowstepID, "tinker", "glowstep", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorFirewalkerID, "tinker", "firewalk", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorFrostwalkerID, "tinker", "frostwalk", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorDepthstriderID, "tinker", "depthstrider", true);
+//
+// }
+//
+// if(TDIntegration.thaumcraft)
+// {
+// tcmods.RegisterModifiers();
+// }
+// if(TDIntegration.botania)
+// {
+// botmods.RegisterModifiers();
+// }
+// if(TDIntegration.bloodMagic)
+// {
+// bloodmods.RegisterModifiers();
+// }
+// }
+//
+// @Override
+// public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
+// {
+// if(!world.isRemote)
+// {
+// if(tags.hasKey("Frostwalker"))
+// {
+// UpdateWalker(tool, stack, world, entity, Material.water, TDArmorAddon.block_Unstable, 0);
+// }
+// if(tags.hasKey("Firewalker"))
+// {
+// UpdateWalker(tool, stack, world, entity, Material.lava, TDArmorAddon.block_Unstable, 1);
+// }
+// if(tags.hasKey("GlowStep"))
+// {
+// UpdateGlowstep(tool, stack, world, entity);
+// }
+// if(tags.hasKey("Rebreather"))
+// {
+// UpdateRebreather(tool, stack, world, entity);
+// }
+// if(tags.hasKey("Nightvision"))
+// {
+// UpdateNightvision(tool, stack, world, entity);
+// }
+// if(tags.hasKey("AntiBlindness"))
+// {
+// UpdateAntiBlind(tool, stack, world, entity);
+// }
+// if(tags.hasKey("HealthBoost"))
+// {
+// UpdateHealthBoost(tool, stack, world, entity, tags);
+// //UpdateHighstep(tool, stack, world, entity);
+// }
+//
+// }
+// else
+// {
+// if(tags.hasKey("Depthstrider"))
+// {
+// UpdateFlippers(tool, stack, world, entity);
+// }
+// if(tags.hasKey("Speed"))
+// {
+// UpdateSpeed(tool, stack, world, entity, tags);
+// // if(tags.hasKey("Jump"))
+// // UpdateJump(tool, stack, world, entity, tags);
+// }
+// }
+//
+// if(TDIntegration.thaumcraft)
+// {
+// tcmods.UpdateAll(tool, stack, world, entity, tags);
+// }
+// if(TDIntegration.botania)
+// {
+// botmods.UpdateAll(tool, stack, world, entity, tags);
+// }
+// if(TDIntegration.bloodMagic)
+// {
+// bloodmods.UpdateAll(tool, stack, world, entity, tags);
+// }
+// }
+//
+// public void UpdateWalker(ToolCore tool, ItemStack stack, World world, Entity entity, Material mat, Block replacement, int meta)
+// {
+// final int x = (int) Math.floor(entity.posX);
+// final int y = (int) (entity.posY - entity.getYOffset());
+// final int z = (int) Math.floor(entity.posZ);
+//
+// Block block;
+//
+// for(int i = 0; i < 5; i++)
+// {
+// for(int j = 0; j < 5; j++)
+// {
+// block = world.getBlock(x + (i - 2), y - 1, z + (j - 2));
+// if(block instanceof BlockLiquid)
+// {
+// if(((BlockLiquid) block).getMaterial() == mat && world.getBlockMetadata(x + (i - 2), y - 1, z + (j - 2)) == 0)
+// {
+// world.setBlock(x + (i - 2), y - 1, z + (j - 2), replacement, meta, 3);
+// world.notifyBlocksOfNeighborChange(x + (i - 2), y - 1, z + (j - 2), world.getBlock(x + (i - 2), y - 1, z + (j - 2)));
+// }
+// }
+// }
+// }
+// }
+//
+// int glowTimer = 8;
+// int prevX = 0;
+// int prevZ = 0;
+//
+// public void UpdateGlowstep(ToolCore tool, ItemStack stack, World world, Entity entity)
+// {
+// final int x = (int) Math.floor(entity.posX);
+// final int y = (int) (entity.posY - entity.getYOffset());
+// final int z = (int) Math.floor(entity.posZ);
+//
+// if(glowTimer == 0)
+// {
+// if(world.getBlock(x, y, z) == Blocks.air && world.getBlock(x, y - 1, z).isNormalCube())
+// {
+// world.setBlock(x, y, z, TDArmorAddon.block_GlowCrumbs, 0, 3);
+// //world.notifyBlocksOfNeighborChange(x + (i - 2), y - 1, z + (j - 2), world.getBlock(x + (i - 2), y - 1, z + (j - 2)));
+// }
+// glowTimer = 8;
+// }
+// else if(Math.abs(x - prevX) >= 1 || Math.abs(z - prevZ) >= 1)
+// {
+// glowTimer--;
+// }
+//
+// prevX = x;
+// prevZ = z;
+// }
+//
+// public void UpdateFlippers(ToolCore tool, ItemStack stack, World world, Entity entity)
+// {
+// if(entity.isInWater())
+// {
+// entity.motionX *= 1.2;
+// entity.motionY *= 1.2;
+// entity.motionZ *= 1.2;
+// }
+// }
+//
+// public void UpdateRebreather(ToolCore tool, ItemStack stack, World world, Entity entity)
+// {
+// final EntityPlayer player = (EntityPlayer) entity;
+// if(player.getAir() <= 0)
+// {
+// ItemStack canStack;
+// int i;
+// int used = 0;
+//
+// for(i = 0; i < player.inventory.getSizeInventory(); i++)
+// {
+// if(player.inventory.getStackInSlot(i) != null && player.inventory.getStackInSlot(i).getItem() == modItems && player.inventory.getStackInSlot(i).getItemDamage() == 0)
+// {
+// canStack = player.inventory.getStackInSlot(i);
+// if(used < 2 && canStack.stackSize == 1)
+// {
+// player.inventory.decrStackSize(i, 1);
+// player.inventory.addItemStackToInventory(new ItemStack(
+// modItems, 1, 1));
+// player.setAir(150);
+// used++;
+// }
+// if(used == 0 && canStack.stackSize >= 2)
+// {
+// player.inventory.decrStackSize(i, 2);
+// player.inventory.addItemStackToInventory(new ItemStack(
+// modItems, 2, 1));
+// player.setAir(300);
+// break;
+// }
+// }
+// }
+// }
+// }
+//
+// public void UpdateNightvision(ToolCore tool, ItemStack stack, World world, Entity entity)
+// {
+// if(!((EntityPlayer) entity).isPotionActive(Potion.nightVision) || ((EntityPlayer) entity).getActivePotionEffect(Potion.nightVision).getDuration() < 1000)
+// {
+// ((EntityPlayer) entity).addPotionEffect(new PotionEffect(
+// Potion.nightVision.id, 1000, 1, true));
+// }
+// }
+//
+// boolean isBlind = false;
+//
+// public void UpdateAntiBlind(ToolCore tool, ItemStack stack, World world, Entity entity)
+// {
+// final NBTTagCompound tags = stack.getTagCompound().getCompoundTag("InfiTool");
+// if(((EntityPlayer) entity).isPotionActive(Potion.blindness) && !isBlind)
+// {
+// final int roll = world.rand.nextInt(100);
+// final int antiLevel = tags.getInteger("AntiBlindness");
+// if(roll < antiLevel * 10)
+// {
+// ((EntityPlayer) entity).removePotionEffect(Potion.blindness.id);
+// }
+// else
+// {
+// isBlind = true;
+// }
+// }
+// if(!((EntityPlayer) entity).isPotionActive(Potion.blindness) && isBlind)
+// {
+// isBlind = false;
+// }
+// }
+//
+// public void UpdateSpeed(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
+// {
+// final EntityPlayer ent = (EntityPlayer) entity;
+// if(!entity.isInWater() && !ent.isSneaking() && ent.moveForward > 0.0)
+// {
+// final float speed = (float) (tags.getInteger("Speed") * 0.05);
+// if(entity.onGround)
+// {
+// ent.moveFlying(0.0f, 1.0f, speed);
+// }
+// else
+// {
+// ent.jumpMovementFactor = speed;
+// }
+// }
+// }
+//
+// PotionEffect hb;
+//
+// public void UpdateHealthBoost(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
+// {
+// if(!((EntityPlayer) entity).isPotionActive(21))
+// {
+// ((EntityPlayer) entity).addPotionEffect(new PotionEffect(21, 100,
+// tags.getInteger("HealthBoost") - 1, true));
+// }
+// else if(((EntityPlayer) entity).getActivePotionEffect(Potion.potionTypes[21]).getDuration() < 10)
+// {
+// ((EntityPlayer) entity).getActivePotionEffect(Potion.potionTypes[21]).combine(new PotionEffect(
+// 21, 100, tags.getInteger("HealthBoost") - 1, true));
+// }
+// }
+//
+// // public void UpdateJump(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
+// // {
+// // EntityPlayer ent = (EntityPlayer) entity;
+// // if(!entity.isInWater() && !ent.isSneaking() && ent.motionY > 0.0)
+// // {
+// // float speed = (float) (tags.getInteger("Jump") * 0.15);
+// //
+// // ent.jumpMovementFactor = speed;
+// //
+// // }
+// // }
+//
+// @SubscribeEvent
+// public void Jump(LivingJumpEvent event)
+// {
+// if(event.entityLiving instanceof EntityPlayer)
+// {
+// final EntityPlayer player = (EntityPlayer) event.entityLiving;
+// if(player.getCurrentArmor(1) != null && player.getCurrentArmor(1).getItem() instanceof ArmorCore)
+// {
+// final ItemStack legs = player.getCurrentArmor(1);
+// final Item armor = legs.getItem();
+// final NBTTagCompound tags = legs.getTagCompound().getCompoundTag("InfiTool");
+//
+// if((armor instanceof TinkersRobe || armor instanceof TinkersChausses || armor instanceof TinkersGrieves) && tags.hasKey("Jump"))
+// {
+// final double speed = tags.getInteger("Jump") * 0.1;
+// player.setVelocity(0, 0.4 + speed, 0);
+// player.velocityChanged = true;
+// }
+// }
+// }
+// }
+//
+// @SubscribeEvent
+// public void Highstep(TickEvent.PlayerTickEvent event)
+// {
+// event.player.stepHeight = 0.5f;
+// if(event.player.getCurrentArmor(1) != null && event.player.getCurrentArmor(1).getItem() instanceof ArmorCore)
+// {
+// final ItemStack legs = event.player.getCurrentArmor(1);
+// final Item armor = legs.getItem();
+// final NBTTagCompound tags = legs.getTagCompound().getCompoundTag("InfiTool");
+//
+// if((armor instanceof TinkersRobe || armor instanceof TinkersChausses || armor instanceof TinkersGrieves) && tags.hasKey("Highstep") && !event.player.isSneaking())
+// {
+// event.player.stepHeight = 1.0f;
+// }
+// }
+// }
+// // public void UpdateHighstep(ToolCore tool, ItemStack stack, World world, Entity entity)
+// // {
+// // NBTTagCompound tags = stack.getTagCompound().getCompoundTag("InfiTool");
+// // EntityPlayer ent = (EntityPlayer) entity;
+// //
+// // if(tool instanceof TinkersRobe || tool instanceof TinkersChausses || tool instanceof TinkersGrieves)
+// // {
+// // ent.stepHeight = 0.5f;
+// // if(tags.hasKey("Highstep"))
+// // {
+// // if(!ent.isSneaking())
+// // {
+// // ent.stepHeight = 1f;
+// // }
+// // }
+// // }
+// //
+// // }
+//
+// // @SubscribeEvent
+// // public void CalmEndermen(LivingSetAttackTargetEvent event)
+// // {
+// // NBTTagCompound tags;
+// //
+// // if(event.target instanceof EntityPlayer)
+// // {
+// // if(((EntityPlayer) event.target).getCurrentArmor(3).hasTagCompound() && ((EntityPlayer) event.target).getCurrentArmor(3).getTagCompound().hasKey("InfiTool"))
+// // {
+// // tags = ((EntityPlayer) event.target).getCurrentArmor(3).getTagCompound().getCompoundTag("InfiTool");
+// //
+// // if(event.entityLiving instanceof EntityEnderman && tags.hasKey("Pumpkin"))
+// // {
+// // event.entityLiving.setRevengeTarget(null);
+// // }
+// // }
+// // }
+// // }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/modifiers/BloodMagic/BloodArmorMods.java b/src/main/java/lance5057/tDefense/armor/modifiers/BloodMagic/BloodArmorMods.java
index fca26a0..0010a66 100644
--- a/src/main/java/lance5057/tDefense/armor/modifiers/BloodMagic/BloodArmorMods.java
+++ b/src/main/java/lance5057/tDefense/armor/modifiers/BloodMagic/BloodArmorMods.java
@@ -1,56 +1,56 @@
-package lance5057.tDefense.armor.modifiers.BloodMagic;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.world.World;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.client.TConstructClientRegistry;
-import tconstruct.library.crafting.ModifyBuilder;
-import tconstruct.library.tools.ToolCore;
-import WayofTime.alchemicalWizardry.ModItems;
-
-public class BloodArmorMods extends ModifiersBase
-{
- public BloodArmorMods()
- {
- super(new String[] {}, "modItemsBloodArmor");
- // TODO Auto-generated constructor stub
- }
-
- @Override
- public void LoadItems()
- {
- }
-
- @Override
- public void RegisterRecipes()
- {
- }
-
- @Override
- public void RegisterModifiers()
- {
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(ModItems.divinationSigil, 1, 0)},
- TinkersDefense.config.DivinationModID, "Divination",
- EnumChatFormatting.DARK_RED.toString(), "Divination",
- new String[] {"head"}, 0, new String[] {}));
-
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.DivinationModID, "tinker", "divination", true);
- //TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.VisDiscountModID, "tinker", "visembroidery", true);
-
- }
- }
-
- @Override
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- }
-}
+//package lance5057.tDefense.armor.modifiers.BloodMagic;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
+//import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.nbt.NBTTagCompound;
+//import net.minecraft.util.EnumChatFormatting;
+//import net.minecraft.world.World;
+//import tconstruct.library.TConstructRegistry;
+//import tconstruct.library.client.TConstructClientRegistry;
+//import tconstruct.library.crafting.ModifyBuilder;
+//import tconstruct.library.tools.ToolCore;
+//import WayofTime.alchemicalWizardry.ModItems;
+//
+//public class BloodArmorMods extends ModifiersBase
+//{
+// public BloodArmorMods()
+// {
+// super(new String[] {}, "modItemsBloodArmor");
+// // TODO Auto-generated constructor stub
+// }
+//
+// @Override
+// public void LoadItems()
+// {
+// }
+//
+// @Override
+// public void RegisterRecipes()
+// {
+// }
+//
+// @Override
+// public void RegisterModifiers()
+// {
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {new ItemStack(ModItems.divinationSigil, 1, 0)},
+// TinkersDefense.config.DivinationModID, "Divination",
+// EnumChatFormatting.DARK_RED.toString(), "Divination",
+// new String[] {"head"}, 0, new String[] {}));
+//
+// for(final ToolCore tool : TConstructRegistry.getToolMapping())
+// {
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.DivinationModID, "tinker", "divination", true);
+// //TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.VisDiscountModID, "tinker", "visembroidery", true);
+//
+// }
+// }
+//
+// @Override
+// public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
+// {
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/modifiers/Botania/BotaniaArmorMods.java b/src/main/java/lance5057/tDefense/armor/modifiers/Botania/BotaniaArmorMods.java
index a2f9235..d399bf1 100644
--- a/src/main/java/lance5057/tDefense/armor/modifiers/Botania/BotaniaArmorMods.java
+++ b/src/main/java/lance5057/tDefense/armor/modifiers/Botania/BotaniaArmorMods.java
@@ -1,66 +1,66 @@
-package lance5057.tDefense.armor.modifiers.Botania;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.tools.modifiers.ModifierIntExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.world.World;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.client.TConstructClientRegistry;
-import tconstruct.library.crafting.ModifyBuilder;
-import tconstruct.library.tools.ToolCore;
-import vazkii.botania.common.item.ModItems;
-import cpw.mods.fml.common.registry.GameRegistry;
-
-public class BotaniaArmorMods extends ModifiersBase
-{
- public BotaniaArmorMods()
- {
- super(new String[] {"elementiumcore"}, "modItemsBotaniaArmor");
- }
-
- @Override
- public void RegisterRecipes()
- {
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 0), new Object[] {"sis", "idi", "sis", 'i', new ItemStack(
- ModItems.manaResource, 1, 7), 's', new ItemStack(
- ModItems.manaResource, 1, 12), 'd', new ItemStack(
- ModItems.manaResource, 1, 2)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 0), new Object[] {"sis", "idi", "sis", 'i', new ItemStack(
- ModItems.manaResource, 1, 7), 's', new ItemStack(
- ModItems.manaResource, 1, 12), 'd', new ItemStack(
- ModItems.manaResource, 1, 1)});
- }
-
- @Override
- public void RegisterModifiers()
- {
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {new ItemStack(ModItems.manaResource, 1, 22)},
- TinkersDefense.config.ArmorManaDiscountModID, "ManaEmbroidery",
- 1, EnumChatFormatting.AQUA.toString(), "Mana Embroidery",
- new String[] {"cloth"}, 1, new String[] {}));
-
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 4)},
- TinkersDefense.config.ArmorPixieCoreModID, "ElementiumCore", 1,
- EnumChatFormatting.LIGHT_PURPLE.toString(), "Elementium Core",
- new String[] {"armor"}, 1, new String[] {}));
-
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorManaDiscountModID, "tinker", "manaembroidery", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorPixieCoreModID, "tinker", "elementiumcore", true);
-
- }
- }
-
- @Override
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- }
-}
+//package lance5057.tDefense.armor.modifiers.Botania;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.core.tools.modifiers.ModifierIntExclusive;
+//import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.nbt.NBTTagCompound;
+//import net.minecraft.util.EnumChatFormatting;
+//import net.minecraft.world.World;
+//import tconstruct.library.TConstructRegistry;
+//import tconstruct.library.client.TConstructClientRegistry;
+//import tconstruct.library.crafting.ModifyBuilder;
+//import tconstruct.library.tools.ToolCore;
+//import vazkii.botania.common.item.ModItems;
+//import cpw.mods.fml.common.registry.GameRegistry;
+//
+//public class BotaniaArmorMods extends ModifiersBase
+//{
+// public BotaniaArmorMods()
+// {
+// super(new String[] {"elementiumcore"}, "modItemsBotaniaArmor");
+// }
+//
+// @Override
+// public void RegisterRecipes()
+// {
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 0), new Object[] {"sis", "idi", "sis", 'i', new ItemStack(
+// ModItems.manaResource, 1, 7), 's', new ItemStack(
+// ModItems.manaResource, 1, 12), 'd', new ItemStack(
+// ModItems.manaResource, 1, 2)});
+//
+// GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 0), new Object[] {"sis", "idi", "sis", 'i', new ItemStack(
+// ModItems.manaResource, 1, 7), 's', new ItemStack(
+// ModItems.manaResource, 1, 12), 'd', new ItemStack(
+// ModItems.manaResource, 1, 1)});
+// }
+//
+// @Override
+// public void RegisterModifiers()
+// {
+// ModifyBuilder.registerModifier(new ModifierIntExclusive(
+// new ItemStack[] {new ItemStack(ModItems.manaResource, 1, 22)},
+// TinkersDefense.config.ArmorManaDiscountModID, "ManaEmbroidery",
+// 1, EnumChatFormatting.AQUA.toString(), "Mana Embroidery",
+// new String[] {"cloth"}, 1, new String[] {}));
+//
+// ModifyBuilder.registerModifier(new ModifierIntExclusive(
+// new ItemStack[] {new ItemStack(modItems, 1, 4)},
+// TinkersDefense.config.ArmorPixieCoreModID, "ElementiumCore", 1,
+// EnumChatFormatting.LIGHT_PURPLE.toString(), "Elementium Core",
+// new String[] {"armor"}, 1, new String[] {}));
+//
+// for(final ToolCore tool : TConstructRegistry.getToolMapping())
+// {
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorManaDiscountModID, "tinker", "manaembroidery", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ArmorPixieCoreModID, "tinker", "elementiumcore", true);
+//
+// }
+// }
+//
+// @Override
+// public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
+// {
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/modifiers/Thaumcraft/ThaumArmorMods.java b/src/main/java/lance5057/tDefense/armor/modifiers/Thaumcraft/ThaumArmorMods.java
index 9b91556..c8839cf 100644
--- a/src/main/java/lance5057/tDefense/armor/modifiers/Thaumcraft/ThaumArmorMods.java
+++ b/src/main/java/lance5057/tDefense/armor/modifiers/Thaumcraft/ThaumArmorMods.java
@@ -1,59 +1,59 @@
-package lance5057.tDefense.armor.modifiers.Thaumcraft;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifierIntExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.world.World;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.client.TConstructClientRegistry;
-import tconstruct.library.crafting.ModifyBuilder;
-import tconstruct.library.tools.ToolCore;
-import thaumcraft.api.ItemApi;
-
-public class ThaumArmorMods extends ModifiersBase
-{
-
- //Runic Shielding is handled in ArmorCore.java
-
- public ThaumArmorMods()
- {
- super(new String[] {}, "modItemsThaumArmor");
- // TODO Auto-generated constructor stub
- }
-
- @Override
- public void RegisterRecipes()
- {
- }
-
- @Override
- public void RegisterModifiers()
- {
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {ItemApi.getItem("itemGoggles", 0)},
- TinkersDefense.config.RevealingModID, "Revealing", "\u00A75",
- "Revealing", new String[] {"head"}, 0, null));
-
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {ItemApi.getItem("itemResource", 7)},
- TinkersDefense.config.VisDiscountModID, "VisEmbroidery", 1,
- "\u00A79", "Vis Embroidery", new String[] {"cloth"}, 1,
- new String[] {}));
-
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.RevealingModID, "tinker", "revealing", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.VisDiscountModID, "tinker", "visembroidery", true);
-
- }
- }
-
- @Override
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- }
-}
+//package lance5057.tDefense.armor.modifiers.Thaumcraft;
+//
+//import lance5057.tDefense.TinkersDefense;
+//import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
+//import lance5057.tDefense.core.tools.modifiers.ModifierIntExclusive;
+//import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
+//import net.minecraft.entity.Entity;
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.nbt.NBTTagCompound;
+//import net.minecraft.world.World;
+//import tconstruct.library.TConstructRegistry;
+//import tconstruct.library.client.TConstructClientRegistry;
+//import tconstruct.library.crafting.ModifyBuilder;
+//import tconstruct.library.tools.ToolCore;
+//import thaumcraft.api.ItemApi;
+//
+//public class ThaumArmorMods extends ModifiersBase
+//{
+//
+// //Runic Shielding is handled in ArmorCore.java
+//
+// public ThaumArmorMods()
+// {
+// super(new String[] {}, "modItemsThaumArmor");
+// // TODO Auto-generated constructor stub
+// }
+//
+// @Override
+// public void RegisterRecipes()
+// {
+// }
+//
+// @Override
+// public void RegisterModifiers()
+// {
+// ModifyBuilder.registerModifier(new ModifierBoolExclusive(
+// new ItemStack[] {ItemApi.getItem("itemGoggles", 0)},
+// TinkersDefense.config.RevealingModID, "Revealing", "\u00A75",
+// "Revealing", new String[] {"head"}, 0, null));
+//
+// ModifyBuilder.registerModifier(new ModifierIntExclusive(
+// new ItemStack[] {ItemApi.getItem("itemResource", 7)},
+// TinkersDefense.config.VisDiscountModID, "VisEmbroidery", 1,
+// "\u00A79", "Vis Embroidery", new String[] {"cloth"}, 1,
+// new String[] {}));
+//
+// for(final ToolCore tool : TConstructRegistry.getToolMapping())
+// {
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.RevealingModID, "tinker", "revealing", true);
+// TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.VisDiscountModID, "tinker", "visembroidery", true);
+//
+// }
+// }
+//
+// @Override
+// public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
+// {
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/modifiers/modifierProtection.java b/src/main/java/lance5057/tDefense/armor/modifiers/modifierProtection.java
index 145764f..2e23b79 100644
--- a/src/main/java/lance5057/tDefense/armor/modifiers/modifierProtection.java
+++ b/src/main/java/lance5057/tDefense/armor/modifiers/modifierProtection.java
@@ -1,95 +1,95 @@
-package lance5057.tDefense.armor.modifiers;
-
-import java.util.Arrays;
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.modifiers.tools.ModInteger;
-
-public class modifierProtection extends ModInteger
-{
- String color;
- String type;
- String tooltipName = "";
- int initialIncrease;
- int secondaryIncrease;
- String[] types = {"Protection", "Fire Protection", "Blast Protection", "Projectile Protection", "Featherfall"};
-
- public modifierProtection(ItemStack[] items, int effect, int increase, String c, String t)
- {
- super(items, effect, t, increase, c, t);
- color = c;
- type = t;
- initialIncrease = secondaryIncrease = increase;
- }
-
- @Override
- protected boolean canModify(ItemStack tool, ItemStack[] input)
- {
- if(tool.getItem() instanceof ToolCore)
- {
- final List list = Arrays.asList(((ToolCore) tool.getItem()).getTraits());
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
-
- if(list.contains("heavyarmor") || list.contains("lightarmor"))
- {
- if(type != types[4])
- {
- for(int i = 0; i < 4; i++)
- {
- if(tags.hasKey(types[i]))
- {
- if(types[i] != type)
- {
- return false;
- }
- if(types[i] == type && tags.getInteger(types[i]) > 5)
- {
- return false;
- }
- }
- }
- return true;
- }
- else if(type == types[4] && tags.getInteger(types[4]) < 5)
- {
- if(list.contains("feet"))
- {
- return true;
- }
- return false;
- }
- }
-
- }
- return false;
- }
-
- @Override
- public void modify(ItemStack[] input, ItemStack tool)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
- if(tags.hasKey(key))
- {
- int increase = tags.getInteger(key);
- increase += secondaryIncrease;
- tags.setInteger(key, increase);
- }
- else
- {
- tags.setInteger(key, initialIncrease);
- }
-
- int modifiers = tags.getInteger("Modifiers");
- modifiers -= 1;
- tags.setInteger("Modifiers", modifiers);
-
- int prot = tags.getInteger(type);
- prot += 1;
- tags.setInteger(type, prot);
-
- addToolTip(tool, color + tooltipName, color + key);
- }
-}
+//package lance5057.tDefense.armor.modifiers;
+//
+//import java.util.Arrays;
+//import java.util.List;
+//
+//import net.minecraft.item.ItemStack;
+//import net.minecraft.nbt.NBTTagCompound;
+//import tconstruct.library.tools.ToolCore;
+//import tconstruct.modifiers.tools.ModInteger;
+//
+//public class modifierProtection extends ModInteger
+//{
+// String color;
+// String type;
+// String tooltipName = "";
+// int initialIncrease;
+// int secondaryIncrease;
+// String[] types = {"Protection", "Fire Protection", "Blast Protection", "Projectile Protection", "Featherfall"};
+//
+// public modifierProtection(ItemStack[] items, int effect, int increase, String c, String t)
+// {
+// super(items, effect, t, increase, c, t);
+// color = c;
+// type = t;
+// initialIncrease = secondaryIncrease = increase;
+// }
+//
+// @Override
+// protected boolean canModify(ItemStack tool, ItemStack[] input)
+// {
+// if(tool.getItem() instanceof ToolCore)
+// {
+// final List list = Arrays.asList(((ToolCore) tool.getItem()).getTraits());
+// final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
+//
+// if(list.contains("heavyarmor") || list.contains("lightarmor"))
+// {
+// if(type != types[4])
+// {
+// for(int i = 0; i < 4; i++)
+// {
+// if(tags.hasKey(types[i]))
+// {
+// if(types[i] != type)
+// {
+// return false;
+// }
+// if(types[i] == type && tags.getInteger(types[i]) > 5)
+// {
+// return false;
+// }
+// }
+// }
+// return true;
+// }
+// else if(type == types[4] && tags.getInteger(types[4]) < 5)
+// {
+// if(list.contains("feet"))
+// {
+// return true;
+// }
+// return false;
+// }
+// }
+//
+// }
+// return false;
+// }
+//
+// @Override
+// public void modify(ItemStack[] input, ItemStack tool)
+// {
+// final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
+// if(tags.hasKey(key))
+// {
+// int increase = tags.getInteger(key);
+// increase += secondaryIncrease;
+// tags.setInteger(key, increase);
+// }
+// else
+// {
+// tags.setInteger(key, initialIncrease);
+// }
+//
+// int modifiers = tags.getInteger("Modifiers");
+// modifiers -= 1;
+// tags.setInteger("Modifiers", modifiers);
+//
+// int prot = tags.getInteger(type);
+// prot += 1;
+// tags.setInteger(type, prot);
+//
+// addToolTip(tool, color + tooltipName, color + key);
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/parts/Cloth.java b/src/main/java/lance5057/tDefense/armor/parts/Cloth.java
index 480c153..2bce85a 100644
--- a/src/main/java/lance5057/tDefense/armor/parts/Cloth.java
+++ b/src/main/java/lance5057/tDefense/armor/parts/Cloth.java
@@ -1,46 +1,46 @@
-package lance5057.tDefense.armor.parts;
-
-import mantle.items.abstracts.CraftingItem;
-import net.minecraft.item.ItemStack;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.util.IToolPart;
-
-public class Cloth extends CraftingItem implements IToolPart
-{
- public Cloth()
- {
- super(toolMaterialNames, buildTextureNames("_cloth"), "parts/", "tinker", TConstructRegistry.materialTab);
- setHasSubtypes(true);
- setMaxDamage(0);
- }
-
- private static String[] buildTextureNames(String textureType)
- {
- final String[] names = new String[toolMaterialNames.length];
- for(int i = 0; i < toolMaterialNames.length; i++)
- {
- if(toolTextureNames[i].equals(""))
- {
- names[i] = "";
- }
- else
- {
- names[i] = toolTextureNames[i] + textureType;
- }
- }
- return names;
- }
-
- public static final String[] toolMaterialNames = new String[] {"white", "orange", "magenta", "lightblue", "yellow", "lime", "pink", "gray", "lightgray", "cyan", "purple", "blue", "brown", "green", "red", "black"};
- public static final String[] toolTextureNames = new String[] {"white", "orange", "magenta", "lightblue", "yellow", "lime", "pink", "gray", "lightgray", "cyan", "purple", "blue", "brown", "green", "red", "black"};
-
- @Override
- public int getMaterialID(ItemStack stack)
- {
- if(stack.getItemDamage() >= toolMaterialNames.length)
- {
- return -1;
- }
- return stack.getItemDamage();
- }
-}
+//package lance5057.tDefense.armor.parts;
+//
+//import mantle.items.abstracts.CraftingItem;
+//import net.minecraft.item.ItemStack;
+//import tconstruct.library.TConstructRegistry;
+//import tconstruct.library.util.IToolPart;
+//
+//public class Cloth extends CraftingItem implements IToolPart
+//{
+// public Cloth()
+// {
+// super(toolMaterialNames, buildTextureNames("_cloth"), "parts/", "tinker", TConstructRegistry.materialTab);
+// setHasSubtypes(true);
+// setMaxDamage(0);
+// }
+//
+// private static String[] buildTextureNames(String textureType)
+// {
+// final String[] names = new String[toolMaterialNames.length];
+// for(int i = 0; i < toolMaterialNames.length; i++)
+// {
+// if(toolTextureNames[i].equals(""))
+// {
+// names[i] = "";
+// }
+// else
+// {
+// names[i] = toolTextureNames[i] + textureType;
+// }
+// }
+// return names;
+// }
+//
+// public static final String[] toolMaterialNames = new String[] {"white", "orange", "magenta", "lightblue", "yellow", "lime", "pink", "gray", "lightgray", "cyan", "purple", "blue", "brown", "green", "red", "black"};
+// public static final String[] toolTextureNames = new String[] {"white", "orange", "magenta", "lightblue", "yellow", "lime", "pink", "gray", "lightgray", "cyan", "purple", "blue", "brown", "green", "red", "black"};
+//
+// @Override
+// public int getMaterialID(ItemStack stack)
+// {
+// if(stack.getItemDamage() >= toolMaterialNames.length)
+// {
+// return -1;
+// }
+// return stack.getItemDamage();
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/parts/ClothMaterial.java b/src/main/java/lance5057/tDefense/armor/parts/ClothMaterial.java
index 4b1733d..8368a61 100644
--- a/src/main/java/lance5057/tDefense/armor/parts/ClothMaterial.java
+++ b/src/main/java/lance5057/tDefense/armor/parts/ClothMaterial.java
@@ -1,14 +1,14 @@
-package lance5057.tDefense.armor.parts;
-
-import net.minecraft.item.ItemStack;
-import tconstruct.library.tools.CustomMaterial;
-
-public class ClothMaterial extends CustomMaterial
-{
-
- public ClothMaterial(int materialID, int value, ItemStack input, ItemStack craftingItem, int color)
- {
- super(materialID, value, input, craftingItem, color);
- }
-
-}
+//package lance5057.tDefense.armor.parts;
+//
+//import net.minecraft.item.ItemStack;
+//import tconstruct.library.tools.CustomMaterial;
+//
+//public class ClothMaterial extends CustomMaterial
+//{
+//
+// public ClothMaterial(int materialID, int value, ItemStack input, ItemStack craftingItem, int color)
+// {
+// super(materialID, value, input, craftingItem, color);
+// }
+//
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/ArmorRenderer.java b/src/main/java/lance5057/tDefense/armor/renderers/ArmorRenderer.java
index 2cace5c..36226ed 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/ArmorRenderer.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/ArmorRenderer.java
@@ -13,7 +13,7 @@ import net.minecraft.nbt.NBTTagCompound;
import org.lwjgl.opengl.GL11;
-public class ArmorRenderer extends ModelBiped
+public class ArmorRenderer extends ModelBiped
{
public String[] colors;
@@ -23,6 +23,7 @@ public class ArmorRenderer extends ModelBiped
private final int[] order = new int[] {1, 2, 3, 0, 4, 5, 6, 7, 8, 9};
public List<ModelRenderer> boxes = new ArrayList<ModelRenderer>();
+
public NBTTagCompound defaultTags = new NBTTagCompound();
public ArmorRenderer(float a, float b, int c, int d)
@@ -74,16 +75,16 @@ public class ArmorRenderer extends ModelBiped
for(int i = 0; i < 10; i++)
{
- final String texture = ((ArmorCore) stack.getItem()).getTexture(order[i], stack);
- if(texture != "")
- {
- GL11.glPushMatrix();
-
- ((ArmorCore) stack.getItem()).renderArmor(entity, f, f1, f2, f3, f4, f5, colors, stack, order[i]);
- super.render(entity, f, f1, f2, f3, f4, f5);
-
- GL11.glPopMatrix();
- }
+ //final String texture = ((ArmorCore) stack.getItem()).getTexture(order[i], stack);
+// if(texture != "")
+// {
+// GL11.glPushMatrix();
+//
+// //((ArmorCore) stack.getItem()).renderArmor(entity, f, f1, f2, f3, f4, f5, colors, stack, order[i]);
+// super.render(entity, f, f1, f2, f3, f4, f5);
+//
+// GL11.glPopMatrix();
+// }
}
if(TinkersDefense.config.transparency)
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/ModelSheath.java b/src/main/java/lance5057/tDefense/armor/renderers/ModelSheath.java
deleted file mode 100644
index 3a35160..0000000
--- a/src/main/java/lance5057/tDefense/armor/renderers/ModelSheath.java
+++ /dev/null
@@ -1,73 +0,0 @@
-package lance5057.tDefense.armor.renderers;
-
-import lance5057.tDefense.armor.ArmorCore;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-import org.lwjgl.opengl.GL11;
-
-/**
- * ModelBiped - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelSheath extends ArmorRenderer
-{
- public ModelRenderer sheath;
- public ModelRenderer belt;
-
- String Color[];
- int rgbColors[];
-
- public ModelSheath()
- {
- super(0.5f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- belt = new ModelRenderer(this, 16, 32);
- belt.setRotationPoint(-4.5F, 0.0F, 0.5F);
- belt.addBox(0.0F, 0.0F, -3.0F, 1, 12, 5, 0.0F);
- setRotateAngle(belt, 0.0F, 0.0F, -0.7853981633974483F);
- bipedBody.addChild(belt);
-
- sheath = new ModelRenderer(this, 0, 32);
- sheath.setRotationPoint(0f, 0f, 0f);
- sheath.addBox(-5.0F, 0.0F, 2.0F, 5, 16, 2, -0.4F);
- setRotateAngle(sheath, 0.0F, 0.0F, -0.45F);
- bipedBody.addChild(sheath);
- }
-
- @Override
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
- {
- GL11.glPushMatrix();
-
- for(int i = 0; i < 10; i++)
- {
- final String texture = ((ArmorCore) stack.getItem()).getTexture(i, stack);
- if(texture != "")
- {
-
- GL11.glPushMatrix();
-
- ((ArmorCore) stack.getItem()).renderArmor(entity, f, f1, f2, f3, f4, f5, colors, stack, i);
- super.render(entity, f, f1, f2, f3, f4, f5);
-
- GL11.glPopMatrix();
- }
- }
-
- GL11.glPopMatrix();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersGauntlets.java b/src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersGauntlets.java
index b64c0d9..5eac286 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersGauntlets.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersGauntlets.java
@@ -1,241 +1,241 @@
-package lance5057.tDefense.armor.renderers;
-
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * ModelTinkersGauntlet - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersGauntlets extends ArmorRenderer
-{
- public ModelRenderer GloveR;
- public ModelRenderer VambraceR;
- public ModelRenderer RebraceR;
- public ModelRenderer BoltR;
- public ModelRenderer KnuckleR;
- public ModelRenderer SettingR;
- public ModelRenderer GemR;
- public ModelRenderer ArmSpikesR;
- public ModelRenderer ArmSpikesBackR;
- public ModelRenderer KnuckleSpikesL;
- public ModelRenderer KnuckleSpikesR;
- public ModelRenderer KnuckleSpikesMidR;
- public ModelRenderer GloveL;
- public ModelRenderer VambraceL;
- public ModelRenderer RebraceL;
- public ModelRenderer BoltL;
- public ModelRenderer ArmSpikesL;
- public ModelRenderer KnuckleSpikesBackR;
- public ModelRenderer KnuckleSpikesBackL;
- public ModelRenderer KnuckleSpikesMidL;
- public ModelRenderer KnuckleL;
- public ModelRenderer GemL;
- public ModelRenderer SettingL;
- public ModelRenderer ArmSpikesBackL;
-
- public ModelTinkersGauntlets()
- {
- super(1.0f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- KnuckleSpikesL = new ModelRenderer(this, "Knuckle Spikes Left");
- KnuckleSpikesL.setTextureOffset(56, 40);
- KnuckleSpikesL.setRotationPoint(0.0F, 0.0F, 0.0F);
- KnuckleSpikesL.addBox(3.0F, 6.0F, -0.5F, 4, 8, 0, 0.0F);
- setRotateAngle(KnuckleSpikesL, 0.0F, 0.3490658503988659F, 0.0F);
- bipedLeftArm.addChild(KnuckleSpikesL);
-
- KnuckleSpikesBackL = new ModelRenderer(this, "Knuckle Spikes Back Left");
- KnuckleSpikesBackL.setTextureOffset(56, 40);
- KnuckleSpikesBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- KnuckleSpikesBackL.addBox(3.0F, 6.0F, 0.5F, 4, 8, 0, 0.0F);
- setRotateAngle(KnuckleSpikesBackL, 0.0F, -0.3490658503988659F, 0.0F);
- bipedLeftArm.addChild(KnuckleSpikesBackL);
-
- KnuckleL = new ModelRenderer(this, "Knuckle Left");
- KnuckleL.setTextureOffset(0, 41);
- KnuckleL.setRotationPoint(0.0F, 0.0F, 0.0F);
- KnuckleL.addBox(0.1F, 6.8F, -2.0F, 3, 3, 4, 0.4F);
- bipedLeftArm.addChild(KnuckleL);
-
- ArmSpikesR = new ModelRenderer(this, "Arm Spikes Right");
- ArmSpikesR.setTextureOffset(56, 32);
- ArmSpikesR.mirror = true;
- ArmSpikesR.setRotationPoint(0.0F, 0.0F, 0.0F);
- ArmSpikesR.addBox(-7.5F, 1.0F, 0.5F, 4, 8, 0, 0.0F);
- setRotateAngle(ArmSpikesR, 0.0F, -0.3490658503988659F, 0.0F);
- bipedRightArm.addChild(ArmSpikesR);
-
- RebraceL = new ModelRenderer(this, "Rebrace Left");
- RebraceL.setTextureOffset(14, 40);
- RebraceL.setRotationPoint(0.0F, 0.0F, 0.0F);
- RebraceL.addBox(-1.1F, 3.0F, -2.0F, 3, 5, 4, 0.2F);
- bipedLeftArm.addChild(RebraceL);
-
- BoltL = new ModelRenderer(this, "Bolt Left");
- BoltL.setTextureOffset(16, 32);
- BoltL.setRotationPoint(0.0F, 0.0F, 0.0F);
- BoltL.addBox(-5.8F, 3.7F, -3.0F, 2, 2, 6, -0.3F);
- setRotateAngle(BoltL, 0.0F, 0.0F, -0.7853981633974483F);
- bipedLeftArm.addChild(BoltL);
-
- KnuckleSpikesBackR = new ModelRenderer(this,
- "Knuckle Spikes Back Right");
- KnuckleSpikesBackR.setTextureOffset(56, 40);
- KnuckleSpikesBackR.mirror = true;
- KnuckleSpikesBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
- KnuckleSpikesBackR.addBox(-7.0F, 6.0F, 0.5F, 4, 8, 0, 0.0F);
- setRotateAngle(KnuckleSpikesBackR, 0.0F, 0.3490658503988659F, 0.0F);
- bipedRightArm.addChild(KnuckleSpikesBackR);
-
- GloveR = new ModelRenderer(this, "Glove Right");
- GloveR.setTextureOffset(0, 32);
- GloveR.mirror = true;
- GloveR.setRotationPoint(0.0F, 0.0F, 0.0F);
- GloveR.addBox(-3.0F, 5.0F, -2.0F, 4, 5, 4, 0.1F);
- bipedRightArm.addChild(GloveR);
-
- BoltR = new ModelRenderer(this, "Bolt Right");
- BoltR.setTextureOffset(16, 32);
- BoltR.mirror = true;
- BoltR.setRotationPoint(0.0F, 0.0F, 0.0F);
- BoltR.addBox(3.8F, 3.7F, -3.0F, 2, 2, 6, -0.3F);
- setRotateAngle(BoltR, 0.0F, 0.0F, 0.7853981633974483F);
- bipedRightArm.addChild(BoltR);
-
- KnuckleR = new ModelRenderer(this, "Knuckle Right");
- KnuckleR.setTextureOffset(0, 41);
- KnuckleR.mirror = true;
- KnuckleR.setRotationPoint(0.0F, 0.0F, 0.0F);
- KnuckleR.addBox(-2.9F, 6.8F, -2.0F, 3, 3, 4, 0.4F);
- bipedRightArm.addChild(KnuckleR);
-
- KnuckleSpikesR = new ModelRenderer(this, "Knuckle Spikes Right");
- KnuckleSpikesR.setTextureOffset(56, 40);
- KnuckleSpikesR.mirror = true;
- KnuckleSpikesR.setRotationPoint(0.0F, 0.0F, 0.0F);
- KnuckleSpikesR.addBox(-7.0F, 6.0F, -0.5F, 4, 8, 0, 0.0F);
- setRotateAngle(KnuckleSpikesR, 0.0F, -0.3490658503988659F, 0.0F);
- bipedRightArm.addChild(KnuckleSpikesR);
-
- KnuckleSpikesMidL = new ModelRenderer(this, "Knuckle Spikes Mid Left");
- KnuckleSpikesMidL.setTextureOffset(54, 48);
- KnuckleSpikesMidL.setRotationPoint(0.0F, 0.0F, 0.0F);
- KnuckleSpikesMidL.addBox(3.0F, 1.0F, 0.0F, 5, 13, 0, 0.0F);
- bipedLeftArm.addChild(KnuckleSpikesMidL);
-
- ArmSpikesBackL = new ModelRenderer(this, "Arm Spikes Back Left");
- ArmSpikesBackL.setTextureOffset(56, 32);
- ArmSpikesBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- ArmSpikesBackL.addBox(3.5F, 1.0F, -0.5F, 4, 8, 0, 0.0F);
- setRotateAngle(ArmSpikesBackL, 0.0F, -0.3490658503988659F, 0.0F);
- bipedLeftArm.addChild(ArmSpikesBackL);
-
- ArmSpikesBackR = new ModelRenderer(this, "Arm Spikes Back Right");
- ArmSpikesBackR.setTextureOffset(56, 32);
- ArmSpikesBackR.mirror = true;
- ArmSpikesBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
- ArmSpikesBackR.addBox(-7.5F, 1.0F, -0.5F, 4, 8, 0, 0.0F);
- setRotateAngle(ArmSpikesBackR, 0.0F, 0.3490658503988659F, 0.0F);
- bipedRightArm.addChild(ArmSpikesBackR);
-
- VambraceR = new ModelRenderer(this, "Vambrace Right");
- VambraceR.setTextureOffset(0, 56);
- VambraceR.mirror = true;
- VambraceR.setRotationPoint(0.0F, 0.0F, 0.0F);
- VambraceR.addBox(-3.6F, 2.8F, -2.0F, 3, 4, 4, 0.3F);
- setRotateAngle(VambraceR, 0.0F, 0.0F, -0.08726646259971647F);
- bipedRightArm.addChild(VambraceR);
-
- GemR = new ModelRenderer(this, "Gem Right");
- GemR.setTextureOffset(0, 48);
- GemR.mirror = true;
- GemR.setRotationPoint(0.0F, 0.0F, 0.0F);
- GemR.addBox(-4.2F, 5.0F, -2.0F, 2, 4, 4, -0.3F);
- bipedRightArm.addChild(GemR);
-
- RebraceR = new ModelRenderer(this, "Rebrace Right");
- RebraceR.setTextureOffset(14, 40);
- RebraceR.mirror = true;
- RebraceR.setRotationPoint(0.0F, 0.0F, 0.0F);
- RebraceR.addBox(-1.9F, 3.0F, -2.0F, 3, 5, 4, 0.2F);
- bipedRightArm.addChild(RebraceR);
-
- SettingR = new ModelRenderer(this, "Setting Right");
- SettingR.setTextureOffset(12, 49);
- SettingR.mirror = true;
- SettingR.setRotationPoint(0.0F, 0.0F, 0.0F);
- SettingR.addBox(-3.7F, 5.0F, -2.0F, 1, 4, 4, 0.0F);
- bipedRightArm.addChild(SettingR);
-
- GloveL = new ModelRenderer(this, "Glove Left");
- GloveL.setTextureOffset(0, 32);
- GloveL.setRotationPoint(0.0F, 0.0F, 0.0F);
- GloveL.addBox(-1.0F, 5.0F, -2.0F, 4, 5, 4, 0.1F);
- bipedLeftArm.addChild(GloveL);
-
- GemL = new ModelRenderer(this, "Gem Left");
- GemL.setTextureOffset(0, 48);
- GemL.mirror = true;
- GemL.setRotationPoint(0.0F, 0.0F, 0.0F);
- GemL.addBox(2.4F, 5.0F, -2.0F, 2, 4, 4, -0.3F);
- bipedLeftArm.addChild(GemL);
-
- VambraceL = new ModelRenderer(this, "Vambrace Left");
- VambraceL.setTextureOffset(0, 56);
- VambraceL.setRotationPoint(0.0F, 0.0F, 0.0F);
- VambraceL.addBox(0.8F, 2.8F, -2.0F, 3, 4, 4, 0.3F);
- setRotateAngle(VambraceL, 0.0F, 0.0F, 0.08726646259971647F);
- bipedLeftArm.addChild(VambraceL);
-
- KnuckleSpikesMidR = new ModelRenderer(this, "Knuckle Spikes Mid Right");
- KnuckleSpikesMidR.setTextureOffset(54, 48);
- KnuckleSpikesMidR.mirror = true;
- KnuckleSpikesMidR.setRotationPoint(0.0F, 0.0F, 0.0F);
- KnuckleSpikesMidR.addBox(-8.0F, 1.0F, 0.0F, 5, 13, 0, 0.0F);
- bipedRightArm.addChild(KnuckleSpikesMidR);
-
- SettingL = new ModelRenderer(this, "Setting Left");
- SettingL.setTextureOffset(12, 49);
- SettingL.mirror = true;
- SettingL.setRotationPoint(0.0F, 0.0F, 0.0F);
- SettingL.addBox(2.9F, 5.0F, -2.0F, 1, 4, 4, 0.0F);
- bipedLeftArm.addChild(SettingL);
-
- ArmSpikesL = new ModelRenderer(this, "Arm Spikes Left");
- ArmSpikesL.setTextureOffset(56, 32);
- ArmSpikesL.setRotationPoint(0.0F, 0.0F, 0.0F);
- ArmSpikesL.addBox(3.5F, 1.0F, 0.5F, 4, 8, 0, 0.0F);
- setRotateAngle(ArmSpikesL, 0.0F, 0.3490658503988659F, 0.0F);
- bipedLeftArm.addChild(ArmSpikesL);
-
- ArmSpikesBackL.isHidden = true;
- ArmSpikesBackR.isHidden = true;
- ArmSpikesL.isHidden = true;
- ArmSpikesR.isHidden = true;
- GemL.isHidden = true;
- GemR.isHidden = true;
- KnuckleSpikesBackL.isHidden = true;
- KnuckleSpikesBackR.isHidden = true;
- KnuckleSpikesL.isHidden = true;
- KnuckleSpikesMidL.isHidden = true;
- KnuckleSpikesMidR.isHidden = true;
- KnuckleSpikesR.isHidden = true;
- SettingL.isHidden = true;
- SettingR.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers;
+//
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * ModelTinkersGauntlet - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersGauntlets extends ArmorRenderer
+//{
+// public ModelRenderer GloveR;
+// public ModelRenderer VambraceR;
+// public ModelRenderer RebraceR;
+// public ModelRenderer BoltR;
+// public ModelRenderer KnuckleR;
+// public ModelRenderer SettingR;
+// public ModelRenderer GemR;
+// public ModelRenderer ArmSpikesR;
+// public ModelRenderer ArmSpikesBackR;
+// public ModelRenderer KnuckleSpikesL;
+// public ModelRenderer KnuckleSpikesR;
+// public ModelRenderer KnuckleSpikesMidR;
+// public ModelRenderer GloveL;
+// public ModelRenderer VambraceL;
+// public ModelRenderer RebraceL;
+// public ModelRenderer BoltL;
+// public ModelRenderer ArmSpikesL;
+// public ModelRenderer KnuckleSpikesBackR;
+// public ModelRenderer KnuckleSpikesBackL;
+// public ModelRenderer KnuckleSpikesMidL;
+// public ModelRenderer KnuckleL;
+// public ModelRenderer GemL;
+// public ModelRenderer SettingL;
+// public ModelRenderer ArmSpikesBackL;
+//
+// public ModelTinkersGauntlets()
+// {
+// super(1.0f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// KnuckleSpikesL = new ModelRenderer(this, "Knuckle Spikes Left");
+// KnuckleSpikesL.setTextureOffset(56, 40);
+// KnuckleSpikesL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KnuckleSpikesL.addBox(3.0F, 6.0F, -0.5F, 4, 8, 0, 0.0F);
+// setRotateAngle(KnuckleSpikesL, 0.0F, 0.3490658503988659F, 0.0F);
+// bipedLeftArm.addChild(KnuckleSpikesL);
+//
+// KnuckleSpikesBackL = new ModelRenderer(this, "Knuckle Spikes Back Left");
+// KnuckleSpikesBackL.setTextureOffset(56, 40);
+// KnuckleSpikesBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KnuckleSpikesBackL.addBox(3.0F, 6.0F, 0.5F, 4, 8, 0, 0.0F);
+// setRotateAngle(KnuckleSpikesBackL, 0.0F, -0.3490658503988659F, 0.0F);
+// bipedLeftArm.addChild(KnuckleSpikesBackL);
+//
+// KnuckleL = new ModelRenderer(this, "Knuckle Left");
+// KnuckleL.setTextureOffset(0, 41);
+// KnuckleL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KnuckleL.addBox(0.1F, 6.8F, -2.0F, 3, 3, 4, 0.4F);
+// bipedLeftArm.addChild(KnuckleL);
+//
+// ArmSpikesR = new ModelRenderer(this, "Arm Spikes Right");
+// ArmSpikesR.setTextureOffset(56, 32);
+// ArmSpikesR.mirror = true;
+// ArmSpikesR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ArmSpikesR.addBox(-7.5F, 1.0F, 0.5F, 4, 8, 0, 0.0F);
+// setRotateAngle(ArmSpikesR, 0.0F, -0.3490658503988659F, 0.0F);
+// bipedRightArm.addChild(ArmSpikesR);
+//
+// RebraceL = new ModelRenderer(this, "Rebrace Left");
+// RebraceL.setTextureOffset(14, 40);
+// RebraceL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// RebraceL.addBox(-1.1F, 3.0F, -2.0F, 3, 5, 4, 0.2F);
+// bipedLeftArm.addChild(RebraceL);
+//
+// BoltL = new ModelRenderer(this, "Bolt Left");
+// BoltL.setTextureOffset(16, 32);
+// BoltL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BoltL.addBox(-5.8F, 3.7F, -3.0F, 2, 2, 6, -0.3F);
+// setRotateAngle(BoltL, 0.0F, 0.0F, -0.7853981633974483F);
+// bipedLeftArm.addChild(BoltL);
+//
+// KnuckleSpikesBackR = new ModelRenderer(this,
+// "Knuckle Spikes Back Right");
+// KnuckleSpikesBackR.setTextureOffset(56, 40);
+// KnuckleSpikesBackR.mirror = true;
+// KnuckleSpikesBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KnuckleSpikesBackR.addBox(-7.0F, 6.0F, 0.5F, 4, 8, 0, 0.0F);
+// setRotateAngle(KnuckleSpikesBackR, 0.0F, 0.3490658503988659F, 0.0F);
+// bipedRightArm.addChild(KnuckleSpikesBackR);
+//
+// GloveR = new ModelRenderer(this, "Glove Right");
+// GloveR.setTextureOffset(0, 32);
+// GloveR.mirror = true;
+// GloveR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// GloveR.addBox(-3.0F, 5.0F, -2.0F, 4, 5, 4, 0.1F);
+// bipedRightArm.addChild(GloveR);
+//
+// BoltR = new ModelRenderer(this, "Bolt Right");
+// BoltR.setTextureOffset(16, 32);
+// BoltR.mirror = true;
+// BoltR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BoltR.addBox(3.8F, 3.7F, -3.0F, 2, 2, 6, -0.3F);
+// setRotateAngle(BoltR, 0.0F, 0.0F, 0.7853981633974483F);
+// bipedRightArm.addChild(BoltR);
+//
+// KnuckleR = new ModelRenderer(this, "Knuckle Right");
+// KnuckleR.setTextureOffset(0, 41);
+// KnuckleR.mirror = true;
+// KnuckleR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KnuckleR.addBox(-2.9F, 6.8F, -2.0F, 3, 3, 4, 0.4F);
+// bipedRightArm.addChild(KnuckleR);
+//
+// KnuckleSpikesR = new ModelRenderer(this, "Knuckle Spikes Right");
+// KnuckleSpikesR.setTextureOffset(56, 40);
+// KnuckleSpikesR.mirror = true;
+// KnuckleSpikesR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KnuckleSpikesR.addBox(-7.0F, 6.0F, -0.5F, 4, 8, 0, 0.0F);
+// setRotateAngle(KnuckleSpikesR, 0.0F, -0.3490658503988659F, 0.0F);
+// bipedRightArm.addChild(KnuckleSpikesR);
+//
+// KnuckleSpikesMidL = new ModelRenderer(this, "Knuckle Spikes Mid Left");
+// KnuckleSpikesMidL.setTextureOffset(54, 48);
+// KnuckleSpikesMidL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KnuckleSpikesMidL.addBox(3.0F, 1.0F, 0.0F, 5, 13, 0, 0.0F);
+// bipedLeftArm.addChild(KnuckleSpikesMidL);
+//
+// ArmSpikesBackL = new ModelRenderer(this, "Arm Spikes Back Left");
+// ArmSpikesBackL.setTextureOffset(56, 32);
+// ArmSpikesBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ArmSpikesBackL.addBox(3.5F, 1.0F, -0.5F, 4, 8, 0, 0.0F);
+// setRotateAngle(ArmSpikesBackL, 0.0F, -0.3490658503988659F, 0.0F);
+// bipedLeftArm.addChild(ArmSpikesBackL);
+//
+// ArmSpikesBackR = new ModelRenderer(this, "Arm Spikes Back Right");
+// ArmSpikesBackR.setTextureOffset(56, 32);
+// ArmSpikesBackR.mirror = true;
+// ArmSpikesBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ArmSpikesBackR.addBox(-7.5F, 1.0F, -0.5F, 4, 8, 0, 0.0F);
+// setRotateAngle(ArmSpikesBackR, 0.0F, 0.3490658503988659F, 0.0F);
+// bipedRightArm.addChild(ArmSpikesBackR);
+//
+// VambraceR = new ModelRenderer(this, "Vambrace Right");
+// VambraceR.setTextureOffset(0, 56);
+// VambraceR.mirror = true;
+// VambraceR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// VambraceR.addBox(-3.6F, 2.8F, -2.0F, 3, 4, 4, 0.3F);
+// setRotateAngle(VambraceR, 0.0F, 0.0F, -0.08726646259971647F);
+// bipedRightArm.addChild(VambraceR);
+//
+// GemR = new ModelRenderer(this, "Gem Right");
+// GemR.setTextureOffset(0, 48);
+// GemR.mirror = true;
+// GemR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// GemR.addBox(-4.2F, 5.0F, -2.0F, 2, 4, 4, -0.3F);
+// bipedRightArm.addChild(GemR);
+//
+// RebraceR = new ModelRenderer(this, "Rebrace Right");
+// RebraceR.setTextureOffset(14, 40);
+// RebraceR.mirror = true;
+// RebraceR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// RebraceR.addBox(-1.9F, 3.0F, -2.0F, 3, 5, 4, 0.2F);
+// bipedRightArm.addChild(RebraceR);
+//
+// SettingR = new ModelRenderer(this, "Setting Right");
+// SettingR.setTextureOffset(12, 49);
+// SettingR.mirror = true;
+// SettingR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// SettingR.addBox(-3.7F, 5.0F, -2.0F, 1, 4, 4, 0.0F);
+// bipedRightArm.addChild(SettingR);
+//
+// GloveL = new ModelRenderer(this, "Glove Left");
+// GloveL.setTextureOffset(0, 32);
+// GloveL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// GloveL.addBox(-1.0F, 5.0F, -2.0F, 4, 5, 4, 0.1F);
+// bipedLeftArm.addChild(GloveL);
+//
+// GemL = new ModelRenderer(this, "Gem Left");
+// GemL.setTextureOffset(0, 48);
+// GemL.mirror = true;
+// GemL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// GemL.addBox(2.4F, 5.0F, -2.0F, 2, 4, 4, -0.3F);
+// bipedLeftArm.addChild(GemL);
+//
+// VambraceL = new ModelRenderer(this, "Vambrace Left");
+// VambraceL.setTextureOffset(0, 56);
+// VambraceL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// VambraceL.addBox(0.8F, 2.8F, -2.0F, 3, 4, 4, 0.3F);
+// setRotateAngle(VambraceL, 0.0F, 0.0F, 0.08726646259971647F);
+// bipedLeftArm.addChild(VambraceL);
+//
+// KnuckleSpikesMidR = new ModelRenderer(this, "Knuckle Spikes Mid Right");
+// KnuckleSpikesMidR.setTextureOffset(54, 48);
+// KnuckleSpikesMidR.mirror = true;
+// KnuckleSpikesMidR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KnuckleSpikesMidR.addBox(-8.0F, 1.0F, 0.0F, 5, 13, 0, 0.0F);
+// bipedRightArm.addChild(KnuckleSpikesMidR);
+//
+// SettingL = new ModelRenderer(this, "Setting Left");
+// SettingL.setTextureOffset(12, 49);
+// SettingL.mirror = true;
+// SettingL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// SettingL.addBox(2.9F, 5.0F, -2.0F, 1, 4, 4, 0.0F);
+// bipedLeftArm.addChild(SettingL);
+//
+// ArmSpikesL = new ModelRenderer(this, "Arm Spikes Left");
+// ArmSpikesL.setTextureOffset(56, 32);
+// ArmSpikesL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ArmSpikesL.addBox(3.5F, 1.0F, 0.5F, 4, 8, 0, 0.0F);
+// setRotateAngle(ArmSpikesL, 0.0F, 0.3490658503988659F, 0.0F);
+// bipedLeftArm.addChild(ArmSpikesL);
+//
+// ArmSpikesBackL.isHidden = true;
+// ArmSpikesBackR.isHidden = true;
+// ArmSpikesL.isHidden = true;
+// ArmSpikesR.isHidden = true;
+// GemL.isHidden = true;
+// GemR.isHidden = true;
+// KnuckleSpikesBackL.isHidden = true;
+// KnuckleSpikesBackR.isHidden = true;
+// KnuckleSpikesL.isHidden = true;
+// KnuckleSpikesMidL.isHidden = true;
+// KnuckleSpikesMidR.isHidden = true;
+// KnuckleSpikesR.isHidden = true;
+// SettingL.isHidden = true;
+// SettingR.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersTabard.java b/src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersTabard.java
index 2bce53e..f061b78 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersTabard.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/ModelTinkersTabard.java
@@ -1,72 +1,72 @@
-package lance5057.tDefense.armor.renderers;
-
-import lance5057.tDefense.armor.ArmorCore;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-import org.lwjgl.opengl.GL11;
-
-/**
- * ModelBiped - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersTabard extends ArmorRenderer
-{
- public ModelRenderer Tabard;
- public ModelRenderer TabardBottomF;
- public ModelRenderer TabardBottomB;
-
- public ModelTinkersTabard()
- {
- super(0.5f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- Tabard = new ModelRenderer(this, 0, 32);
- Tabard.setRotationPoint(0.0F, 0.0F, 0.0F);
- Tabard.addBox(-4.0F, 0.0F, -2.5F, 8, 12, 5, 0.1F);
-
- TabardBottomF = new ModelRenderer(this, 26, 32);
- TabardBottomF.setRotationPoint(0.0F, 12.0F, 0.0F);
- TabardBottomF.addBox(-4.0F, 0.2F, -2.5F, 8, 8, 1, 0.1F);
- TabardBottomB = new ModelRenderer(this, 26, 32);
- TabardBottomB.mirror = true;
-
- TabardBottomB.setRotationPoint(0.0F, 12.0F, 0.0F);
- TabardBottomB.addBox(-4.0F, 0.2F, 1.5F, 8, 8, 1, 0.1F);
- }
-
- @Override
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
- {
- GL11.glPushMatrix();
-
- for(int i = 0; i < 10; i++)
- {
- final String texture = ((ArmorCore) stack.getItem()).getTexture(i, stack);
- if(texture != "")
- {
-
- GL11.glPushMatrix();
-
- ((ArmorCore) stack.getItem()).renderArmor(entity, f, f1, f2, f3, f4, f5, colors, stack, i);
- super.render(entity, f, f1, f2, f3, f4, f5);
-
- GL11.glPopMatrix();
- }
- }
-
- GL11.glPopMatrix();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers;
+//
+//import lance5057.tDefense.armor.ArmorCore;
+//import net.minecraft.client.model.ModelRenderer;
+//import net.minecraft.entity.Entity;
+//
+//import org.lwjgl.opengl.GL11;
+//
+///**
+// * ModelBiped - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersTabard extends ArmorRenderer
+//{
+// public ModelRenderer Tabard;
+// public ModelRenderer TabardBottomF;
+// public ModelRenderer TabardBottomB;
+//
+// public ModelTinkersTabard()
+// {
+// super(0.5f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// Tabard = new ModelRenderer(this, 0, 32);
+// Tabard.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Tabard.addBox(-4.0F, 0.0F, -2.5F, 8, 12, 5, 0.1F);
+//
+// TabardBottomF = new ModelRenderer(this, 26, 32);
+// TabardBottomF.setRotationPoint(0.0F, 12.0F, 0.0F);
+// TabardBottomF.addBox(-4.0F, 0.2F, -2.5F, 8, 8, 1, 0.1F);
+// TabardBottomB = new ModelRenderer(this, 26, 32);
+// TabardBottomB.mirror = true;
+//
+// TabardBottomB.setRotationPoint(0.0F, 12.0F, 0.0F);
+// TabardBottomB.addBox(-4.0F, 0.2F, 1.5F, 8, 8, 1, 0.1F);
+// }
+//
+// @Override
+// public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
+// {
+// GL11.glPushMatrix();
+//
+// for(int i = 0; i < 10; i++)
+// {
+// final String texture = ((ArmorCore) stack.getItem()).getTexture(i, stack);
+// if(texture != "")
+// {
+//
+// GL11.glPushMatrix();
+//
+// ((ArmorCore) stack.getItem()).renderArmor(entity, f, f1, f2, f3, f4, f5, colors, stack, i);
+// super.render(entity, f, f1, f2, f3, f4, f5);
+//
+// GL11.glPopMatrix();
+// }
+// }
+//
+// GL11.glPopMatrix();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersHood.java b/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersHood.java
index f97f7ba..ba5db86 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersHood.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersHood.java
@@ -1,169 +1,169 @@
-package lance5057.tDefense.armor.renderers.cloth;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * TinkersHood - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersHood extends ArmorRenderer
-{
- public ModelRenderer Flop;
- public ModelRenderer Flop_1;
- public ModelRenderer Flop_2;
- public ModelRenderer ScarfNeck;
- public ModelRenderer Band;
- public ModelRenderer BandTilted;
- public ModelRenderer Rim;
- public ModelRenderer HatTop;
- public ModelRenderer HatTopTall;
- public ModelRenderer Tip;
- public ModelRenderer Tip_1;
- public ModelRenderer Tip_2;
- public ModelRenderer ScarfExtra;
- public ModelRenderer ScarfExtra_1;
- public ModelRenderer BandExtra;
- public ModelRenderer BandExtra_1;
-
- public ModelTinkersHood()
- {
- super(0.2f, 0, 128, 64);
-
- textureWidth = 128;
- textureHeight = 64;
-
- bipedHeadwear = new ModelRenderer(this, "Headwear");
- bipedHeadwear.setTextureOffset(32, 0);
- bipedHeadwear.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, 0.2f + 0.5F);
- bipedHeadwear.setRotationPoint(0.0F, 0.0F + 0, 0.0F);
-
- Flop = new ModelRenderer(this, "Flop");
- Flop.setTextureOffset(64, 0);
- Flop.setRotationPoint(0.0F, 0.0F, 0.0F);
- Flop.addBox(-3.0F, -7.6F, 1.0F, 6, 6, 3, 0.5F);
- setRotateAngle(Flop, -0.3490658503988659F, 0.0F, 0.0F);
- bipedHead.addChild(Flop);
-
- Flop_1 = new ModelRenderer(this, "Flop 1");
- Flop_1.setTextureOffset(82, 0);
- Flop_1.setRotationPoint(0.0F, 0.0F, 0.0F);
- Flop_1.addBox(-2.0F, -6.8F, -0.1F, 4, 4, 5, 0.5F);
- setRotateAngle(Flop_1, -0.6981317007977318F, 0.0F, 0.0F);
- bipedHead.addChild(Flop_1);
-
- Flop_2 = new ModelRenderer(this, "Flop 2");
- Flop_2.setTextureOffset(64, 25);
- Flop_2.setRotationPoint(0.0F, 0.0F, 0.0F);
- Flop_2.addBox(-1.0F, -6.6F, 2.0F, 2, 2, 4, 0.5F);
- setRotateAngle(Flop_2, -1.0471975511965976F, 0.0F, 0.0F);
- bipedHead.addChild(Flop_2);
-
- ScarfExtra = new ModelRenderer(this, "ScarfExtra");
- ScarfExtra.setTextureOffset(44, 32);
- ScarfExtra.setRotationPoint(0.0F, 0.0F, 0.0F);
- ScarfExtra.addBox(0.0F, 0.0F, 2.0F, 3, 7, 1, 0.0F);
- setRotateAngle(ScarfExtra, 0.0F, 0.0F, -0.17453292519943295F);
- bipedBody.addChild(ScarfExtra);
-
- ScarfExtra_1 = new ModelRenderer(this, "ScarfExtra 1");
- ScarfExtra_1.setTextureOffset(36, 32);
- ScarfExtra_1.setRotationPoint(0.0F, 0.0F, 0.0F);
- ScarfExtra_1.addBox(-3.0F, 0.0F, 2.0F, 3, 11, 1, 0.0F);
- setRotateAngle(ScarfExtra_1, 0.0F, 0.0F, 0.17453292519943295F);
- bipedBody.addChild(ScarfExtra_1);
-
- ScarfNeck = new ModelRenderer(this, "ScarfNeck");
- ScarfNeck.setTextureOffset(0, 32);
- ScarfNeck.setRotationPoint(0.0F, 0.0F, 0.0F);
- ScarfNeck.addBox(-4.5F, -2.0F, -4.5F, 9, 3, 9, 0.3F);
- bipedHead.addChild(ScarfNeck);
-
- HatTop = new ModelRenderer(this, "HatTop");
- HatTop.setTextureOffset(52, 33);
- HatTop.addBox(-4.0F, -8.0F, -4.0F, 8, 3, 8, 0.1f + 0.5F);
- HatTop.setRotationPoint(0.0F, 0.0F + 0, 0.0F);
- bipedHead.addChild(HatTop);
-
- HatTopTall = new ModelRenderer(this, "HatTopTall");
- HatTopTall.setTextureOffset(96, 4);
- HatTopTall.setRotationPoint(0.0F, 0.0F, 0.0F);
- HatTopTall.addBox(-4.0F, -14.0F, -4.0F, 8, 5, 8, 0.5F);
- bipedHead.addChild(HatTopTall);
-
- Rim = new ModelRenderer(this, "Rim");
- Rim.setTextureOffset(65, 20);
- Rim.setRotationPoint(0.0F, 0.0F, 0.0F);
- Rim.addBox(-6.0F, -5.5F, -6.0F, 12, 1, 12, 0.1F);
- bipedHead.addChild(Rim);
-
- BandTilted = new ModelRenderer(this, "BandTilted");
- BandTilted.setTextureOffset(64, 9);
- BandTilted.setRotationPoint(0.0F, 0.0F, 0.0F);
- BandTilted.addBox(-4.5F, -2.7F, -8.5F, 9, 2, 9, 0.0F);
- setRotateAngle(BandTilted, -1.2f, 0.0F, 0.0F);
- bipedHead.addChild(BandTilted);
-
- Band = new ModelRenderer(this, "Band");
- Band.setTextureOffset(64, 9);
- Band.setRotationPoint(0.0F, 0.0F, 0.0F);
- Band.addBox(-4.5F, -7F, -4.5F, 9, 3, 9, -0.3F);
- bipedHead.addChild(Band);
-
- BandExtra = new ModelRenderer(this, "BandExtra");
- BandExtra.setTextureOffset(44, 32);
- BandExtra.setRotationPoint(0.0F, 0.0F, 0.0F);
- BandExtra.addBox(0.2F, -6.0F, 3.4F, 3, 5, 1, -0.3F);
- setRotateAngle(BandExtra, 0.0F, 0.0F, -0.17453292519943295F);
- bipedHead.addChild(BandExtra);
-
- BandExtra_1 = new ModelRenderer(this, "BandExtra 1");
- BandExtra_1.setTextureOffset(36, 32);
- BandExtra_1.setRotationPoint(0.0F, 0.0F, 0.0F);
- BandExtra_1.addBox(-3.2F, -6.0F, 3.4F, 3, 7, 1, -0.3F);
- setRotateAngle(BandExtra_1, 0.0F, 0.0F, 0.17453292519943295F);
- bipedHead.addChild(BandExtra_1);
-
- Tip = new ModelRenderer(this, "Tip");
- Tip.setTextureOffset(0, 44);
- Tip.setRotationPoint(0.0F, 0.0F, 0.0F);
- Tip.addBox(-3.0F, -10.8F, -5.0F, 6, 3, 6, 0.5F);
- setRotateAngle(Tip, -0.2617993877991494F, 0.0F, 0.0F);
- bipedHead.addChild(Tip);
-
- Tip_1 = new ModelRenderer(this, "Tip 1");
- Tip_1.setTextureOffset(0, 53);
- Tip_1.setRotationPoint(0.0F, 0.0F, 0.0F);
- Tip_1.addBox(-2.0F, -12.9F, -6.7F, 4, 3, 4, 0.5F);
- setRotateAngle(Tip_1, -0.5235987755982988F, 0.0F, 0.0F);
- bipedHead.addChild(Tip_1);
-
- Tip_2 = new ModelRenderer(this, "Tip 2");
- Tip_2.setTextureOffset(18, 45);
- Tip_2.setRotationPoint(0.0F, 0.0F, 0.0F);
- Tip_2.addBox(-1.0F, -14.6F, -8.8F, 2, 3, 2, 0.5F);
- setRotateAngle(Tip_2, -0.7853981633974483F, 0.0F, 0.0F);
- bipedHead.addChild(Tip_2);
-
- Rim.isHidden = true;
- Band.isHidden = true;
- HatTop.isHidden = true;
- HatTopTall.isHidden = true;
- BandTilted.isHidden = true;
- Tip.isHidden = true;
- Tip_1.isHidden = true;
- Tip_2.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.cloth;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * TinkersHood - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersHood extends ArmorRenderer
+//{
+// public ModelRenderer Flop;
+// public ModelRenderer Flop_1;
+// public ModelRenderer Flop_2;
+// public ModelRenderer ScarfNeck;
+// public ModelRenderer Band;
+// public ModelRenderer BandTilted;
+// public ModelRenderer Rim;
+// public ModelRenderer HatTop;
+// public ModelRenderer HatTopTall;
+// public ModelRenderer Tip;
+// public ModelRenderer Tip_1;
+// public ModelRenderer Tip_2;
+// public ModelRenderer ScarfExtra;
+// public ModelRenderer ScarfExtra_1;
+// public ModelRenderer BandExtra;
+// public ModelRenderer BandExtra_1;
+//
+// public ModelTinkersHood()
+// {
+// super(0.2f, 0, 128, 64);
+//
+// textureWidth = 128;
+// textureHeight = 64;
+//
+// bipedHeadwear = new ModelRenderer(this, "Headwear");
+// bipedHeadwear.setTextureOffset(32, 0);
+// bipedHeadwear.addBox(-4.0F, -8.0F, -4.0F, 8, 8, 8, 0.2f + 0.5F);
+// bipedHeadwear.setRotationPoint(0.0F, 0.0F + 0, 0.0F);
+//
+// Flop = new ModelRenderer(this, "Flop");
+// Flop.setTextureOffset(64, 0);
+// Flop.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Flop.addBox(-3.0F, -7.6F, 1.0F, 6, 6, 3, 0.5F);
+// setRotateAngle(Flop, -0.3490658503988659F, 0.0F, 0.0F);
+// bipedHead.addChild(Flop);
+//
+// Flop_1 = new ModelRenderer(this, "Flop 1");
+// Flop_1.setTextureOffset(82, 0);
+// Flop_1.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Flop_1.addBox(-2.0F, -6.8F, -0.1F, 4, 4, 5, 0.5F);
+// setRotateAngle(Flop_1, -0.6981317007977318F, 0.0F, 0.0F);
+// bipedHead.addChild(Flop_1);
+//
+// Flop_2 = new ModelRenderer(this, "Flop 2");
+// Flop_2.setTextureOffset(64, 25);
+// Flop_2.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Flop_2.addBox(-1.0F, -6.6F, 2.0F, 2, 2, 4, 0.5F);
+// setRotateAngle(Flop_2, -1.0471975511965976F, 0.0F, 0.0F);
+// bipedHead.addChild(Flop_2);
+//
+// ScarfExtra = new ModelRenderer(this, "ScarfExtra");
+// ScarfExtra.setTextureOffset(44, 32);
+// ScarfExtra.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ScarfExtra.addBox(0.0F, 0.0F, 2.0F, 3, 7, 1, 0.0F);
+// setRotateAngle(ScarfExtra, 0.0F, 0.0F, -0.17453292519943295F);
+// bipedBody.addChild(ScarfExtra);
+//
+// ScarfExtra_1 = new ModelRenderer(this, "ScarfExtra 1");
+// ScarfExtra_1.setTextureOffset(36, 32);
+// ScarfExtra_1.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ScarfExtra_1.addBox(-3.0F, 0.0F, 2.0F, 3, 11, 1, 0.0F);
+// setRotateAngle(ScarfExtra_1, 0.0F, 0.0F, 0.17453292519943295F);
+// bipedBody.addChild(ScarfExtra_1);
+//
+// ScarfNeck = new ModelRenderer(this, "ScarfNeck");
+// ScarfNeck.setTextureOffset(0, 32);
+// ScarfNeck.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ScarfNeck.addBox(-4.5F, -2.0F, -4.5F, 9, 3, 9, 0.3F);
+// bipedHead.addChild(ScarfNeck);
+//
+// HatTop = new ModelRenderer(this, "HatTop");
+// HatTop.setTextureOffset(52, 33);
+// HatTop.addBox(-4.0F, -8.0F, -4.0F, 8, 3, 8, 0.1f + 0.5F);
+// HatTop.setRotationPoint(0.0F, 0.0F + 0, 0.0F);
+// bipedHead.addChild(HatTop);
+//
+// HatTopTall = new ModelRenderer(this, "HatTopTall");
+// HatTopTall.setTextureOffset(96, 4);
+// HatTopTall.setRotationPoint(0.0F, 0.0F, 0.0F);
+// HatTopTall.addBox(-4.0F, -14.0F, -4.0F, 8, 5, 8, 0.5F);
+// bipedHead.addChild(HatTopTall);
+//
+// Rim = new ModelRenderer(this, "Rim");
+// Rim.setTextureOffset(65, 20);
+// Rim.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Rim.addBox(-6.0F, -5.5F, -6.0F, 12, 1, 12, 0.1F);
+// bipedHead.addChild(Rim);
+//
+// BandTilted = new ModelRenderer(this, "BandTilted");
+// BandTilted.setTextureOffset(64, 9);
+// BandTilted.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BandTilted.addBox(-4.5F, -2.7F, -8.5F, 9, 2, 9, 0.0F);
+// setRotateAngle(BandTilted, -1.2f, 0.0F, 0.0F);
+// bipedHead.addChild(BandTilted);
+//
+// Band = new ModelRenderer(this, "Band");
+// Band.setTextureOffset(64, 9);
+// Band.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Band.addBox(-4.5F, -7F, -4.5F, 9, 3, 9, -0.3F);
+// bipedHead.addChild(Band);
+//
+// BandExtra = new ModelRenderer(this, "BandExtra");
+// BandExtra.setTextureOffset(44, 32);
+// BandExtra.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BandExtra.addBox(0.2F, -6.0F, 3.4F, 3, 5, 1, -0.3F);
+// setRotateAngle(BandExtra, 0.0F, 0.0F, -0.17453292519943295F);
+// bipedHead.addChild(BandExtra);
+//
+// BandExtra_1 = new ModelRenderer(this, "BandExtra 1");
+// BandExtra_1.setTextureOffset(36, 32);
+// BandExtra_1.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BandExtra_1.addBox(-3.2F, -6.0F, 3.4F, 3, 7, 1, -0.3F);
+// setRotateAngle(BandExtra_1, 0.0F, 0.0F, 0.17453292519943295F);
+// bipedHead.addChild(BandExtra_1);
+//
+// Tip = new ModelRenderer(this, "Tip");
+// Tip.setTextureOffset(0, 44);
+// Tip.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Tip.addBox(-3.0F, -10.8F, -5.0F, 6, 3, 6, 0.5F);
+// setRotateAngle(Tip, -0.2617993877991494F, 0.0F, 0.0F);
+// bipedHead.addChild(Tip);
+//
+// Tip_1 = new ModelRenderer(this, "Tip 1");
+// Tip_1.setTextureOffset(0, 53);
+// Tip_1.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Tip_1.addBox(-2.0F, -12.9F, -6.7F, 4, 3, 4, 0.5F);
+// setRotateAngle(Tip_1, -0.5235987755982988F, 0.0F, 0.0F);
+// bipedHead.addChild(Tip_1);
+//
+// Tip_2 = new ModelRenderer(this, "Tip 2");
+// Tip_2.setTextureOffset(18, 45);
+// Tip_2.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Tip_2.addBox(-1.0F, -14.6F, -8.8F, 2, 3, 2, 0.5F);
+// setRotateAngle(Tip_2, -0.7853981633974483F, 0.0F, 0.0F);
+// bipedHead.addChild(Tip_2);
+//
+// Rim.isHidden = true;
+// Band.isHidden = true;
+// HatTop.isHidden = true;
+// HatTopTall.isHidden = true;
+// BandTilted.isHidden = true;
+// Tip.isHidden = true;
+// Tip_1.isHidden = true;
+// Tip_2.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersRobe.java b/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersRobe.java
index aae1594..5494518 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersRobe.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersRobe.java
@@ -1,379 +1,379 @@
-package lance5057.tDefense.armor.renderers.cloth;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * ModelBiped - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersRobe extends ArmorRenderer
-{
- public ModelRenderer LeftFrontL;
- public ModelRenderer LeftBackL;
- public ModelRenderer CenterBackL;
- public ModelRenderer RightFronL;
- public ModelRenderer RightBackL;
- public ModelRenderer CenterFrontL;
- public ModelRenderer CenterFrontR;
- public ModelRenderer CenterBackR;
- public ModelRenderer FrontMidL;
- public ModelRenderer FrontRightMid;
- public ModelRenderer BackMidR;
- public ModelRenderer BackRightMid;
- public ModelRenderer FrontLeftMid;
- public ModelRenderer UnderFrontLeftMid;
- public ModelRenderer UnderBackRightMid;
- public ModelRenderer UnderBackLeftMid;
- public ModelRenderer UnderFrontRightMid;
- public ModelRenderer UnderLeftMid;
- public ModelRenderer UnderRightMid;
- public ModelRenderer FrontMidR;
- public ModelRenderer BackLeftMid;
- public ModelRenderer BackMidL;
- public ModelRenderer FrontLHigh;
- public ModelRenderer UnderFrontRightHigh;
- public ModelRenderer UnderBackRightHigh;
- public ModelRenderer BackUnderHigh;
- public ModelRenderer UnderBackLeftHigh;
- public ModelRenderer RightHigh;
- public ModelRenderer LeftHigh;
- public ModelRenderer FrontRightHigh;
- public ModelRenderer BackRightHigh;
- public ModelRenderer UnderFrontHigh;
- public ModelRenderer UnderFrontLeftHigh;
- public ModelRenderer BackLHigh;
- public ModelRenderer BeltLHip;
- public ModelRenderer BeltStraight;
- public ModelRenderer BeltRHip;
-
- //public ModelRenderer BeltStraightSmall;
-
- public ModelTinkersRobe()
- {
- super(0.1f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- //High
-
- LeftHigh = new ModelRenderer(this, "Left Skirt");
- LeftHigh.setTextureOffset(52, 38);
- LeftHigh.mirror = true;
- LeftHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- LeftHigh.addBox(-7.5F, 8.0F, -2.0F, 2, 7, 4, -0.01F);
- setRotateAngle(LeftHigh, 0.0F, 0.0F, -0.9599310885968813F);
- bipedBody.addChild(LeftHigh);
-
- UnderBackLeftHigh = new ModelRenderer(this, "Underside BackLeft Skirt");
- UnderBackLeftHigh.setTextureOffset(8, 57);
- UnderBackLeftHigh.mirror = true;
- UnderBackLeftHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderBackLeftHigh.addBox(-0.2F, 8.5F, -7.5F, 4, 6, 1, 0.0F);
- setRotateAngle(UnderBackLeftHigh, 0.9599310885968813F, 0.7853981633974483F, 0.0F);
- bipedBody.addChild(UnderBackLeftHigh);
-
- FrontRightHigh = new ModelRenderer(this, "Front Right Skirt");
- FrontRightHigh.setTextureOffset(18, 55);
- FrontRightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- FrontRightHigh.addBox(-3.3F, 6.6F, 6.1F, 4, 7, 2, 0.0F);
- setRotateAngle(FrontRightHigh, -0.9599310885968813F, 0.2617993877991494F, 0.0F);
- bipedBody.addChild(FrontRightHigh);
-
- RightHigh = new ModelRenderer(this, "Right Skirt");
- RightHigh.setTextureOffset(52, 38);
- RightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- RightHigh.addBox(5.5F, 8.0F, -2.0F, 2, 7, 4, -0.01F);
- setRotateAngle(RightHigh, 0.0F, 0.0F, 0.9599310885968813F);
- bipedBody.addChild(RightHigh);
-
- BackUnderHigh = new ModelRenderer(this, "Underside Back Skirt");
- BackUnderHigh.setTextureOffset(8, 57);
- BackUnderHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- BackUnderHigh.addBox(-2.0F, 8.0F, -8.0F, 4, 6, 1, 0.0F);
- setRotateAngle(BackUnderHigh, 0.9599310885968813F, 0.0F, 0.0F);
- bipedBody.addChild(BackUnderHigh);
-
- UnderFrontHigh = new ModelRenderer(this, "Underside Front Skirt");
- UnderFrontHigh.setTextureOffset(8, 57);
- UnderFrontHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderFrontHigh.addBox(-2.0F, 8.0F, 7.0F, 4, 6, 1, 0.0F);
- setRotateAngle(UnderFrontHigh, -0.9599310885968813F, 0.0F, 0.0F);
- bipedBody.addChild(UnderFrontHigh);
-
- UnderBackRightHigh = new ModelRenderer(this,
- "Underside BackRight Skirt");
- UnderBackRightHigh.setTextureOffset(8, 57);
- UnderBackRightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderBackRightHigh.addBox(-3.8F, 8.5F, -7.5F, 4, 6, 1, 0.0F);
- setRotateAngle(UnderBackRightHigh, 0.9599310885968813F, -0.7853981633974483F, 0.0F);
- bipedBody.addChild(UnderBackRightHigh);
-
- BackLHigh = new ModelRenderer(this, "Back Left Skirt");
- BackLHigh.setTextureOffset(18, 55);
- BackLHigh.mirror = true;
- BackLHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- BackLHigh.addBox(-0.7F, 6.6F, -8.1F, 4, 7, 2, 0.0F);
- setRotateAngle(BackLHigh, 0.9599310885968813F, 0.2617993877991494F, 0.0F);
- bipedBody.addChild(BackLHigh);
-
- BackRightHigh = new ModelRenderer(this, "Back Right Skirt");
- BackRightHigh.setTextureOffset(18, 55);
- BackRightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- BackRightHigh.addBox(-3.3F, 6.6F, -8.1F, 4, 7, 2, 0.0F);
- setRotateAngle(BackRightHigh, 0.9599310885968813F, -0.2617993877991494F, 0.0F);
- bipedBody.addChild(BackRightHigh);
-
- UnderFrontRightHigh = new ModelRenderer(this,
- "Underside FrontRight Skirt");
- UnderFrontRightHigh.setTextureOffset(8, 57);
- UnderFrontRightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderFrontRightHigh.addBox(-3.8F, 8.5F, 6.5F, 4, 6, 1, 0.0F);
- setRotateAngle(UnderFrontRightHigh, -0.9599310885968813F, 0.7853981633974483F, 0.0F);
- bipedBody.addChild(UnderFrontRightHigh);
-
- FrontLHigh = new ModelRenderer(this, "Front Left Skirt");
- FrontLHigh.setTextureOffset(18, 55);
- FrontLHigh.mirror = true;
- FrontLHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- FrontLHigh.addBox(-0.7F, 6.6F, 6.1F, 4, 7, 2, 0.0F);
- setRotateAngle(FrontLHigh, -0.9599310885968813F, -0.2617993877991494F, 0.0F);
- bipedBody.addChild(FrontLHigh);
-
- UnderFrontLeftHigh = new ModelRenderer(this, "Under FrontLeft Skirt");
- UnderFrontLeftHigh.setTextureOffset(8, 57);
- UnderFrontLeftHigh.mirror = true;
- UnderFrontLeftHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderFrontLeftHigh.addBox(-0.2F, 8.5F, 6.5F, 4, 6, 1, 0.0F);
- setRotateAngle(UnderFrontLeftHigh, -0.9599310885968813F, -0.7853981633974483F, 0.0F);
- bipedBody.addChild(UnderFrontLeftHigh);
-
- //Mid
- FrontMidL = new ModelRenderer(this, "Front Left Dress");
- FrontMidL.setTextureOffset(16, 32);
- FrontMidL.mirror = true;
- FrontMidL.setRotationPoint(0.0F, 0.0F, 0.0F);
- FrontMidL.addBox(-1.9F, -0.6F, -3.2F, 4, 8, 2, 0.0F);
- setRotateAngle(FrontMidL, -0.4363323129985824F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(FrontMidL);
-
- UnderBackRightMid = new ModelRenderer(this, "Underside BackRight Dress");
- UnderBackRightMid.setTextureOffset(34, 42);
- UnderBackRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderBackRightMid.addBox(-3.0F, 3.0F, 0.2F, 6, 8, 2, 0.0F);
- setRotateAngle(UnderBackRightMid, 0.4363323129985824F, -0.3490658503988659F, 0.0F);
- bipedRightLeg.addChild(UnderBackRightMid);
-
- BackMidR = new ModelRenderer(this, "BackRight Dress");
- BackMidR.setTextureOffset(28, 32);
- BackMidR.setRotationPoint(0.0F, 0.0F, 0.0F);
- BackMidR.addBox(-2.1F, -0.7F, 1.1F, 4, 8, 2, 0.0F);
- setRotateAngle(BackMidR, 0.4363323129985824F, 0.0F, 0.0F);
- bipedRightLeg.addChild(BackMidR);
-
- UnderLeftMid = new ModelRenderer(this, "Underside Left Dress");
- UnderLeftMid.setTextureOffset(18, 42);
- UnderLeftMid.mirror = true;
- UnderLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderLeftMid.addBox(0.0F, 3.8F, -3.0F, 2, 7, 6, 0.0F);
- setRotateAngle(UnderLeftMid, 0.0F, 0.0F, -0.4363323129985824F);
- bipedLeftLeg.addChild(UnderLeftMid);
-
- UnderFrontLeftMid = new ModelRenderer(this, "Underside FrontLeft Dress");
- UnderFrontLeftMid.setTextureOffset(40, 32);
- UnderFrontLeftMid.mirror = true;
- UnderFrontLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderFrontLeftMid.addBox(-3.0F, 3.0F, -2.3F, 6, 8, 2, 0.0F);
- setRotateAngle(UnderFrontLeftMid, -0.4363323129985824F, -0.3490658503988659F, 0.0F);
- bipedLeftLeg.addChild(UnderFrontLeftMid);
-
- BackLeftMid = new ModelRenderer(this, "Back Left Dress");
- BackLeftMid.setTextureOffset(8, 47);
- BackLeftMid.mirror = true;
- BackLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- BackLeftMid.addBox(-1.3F, -0.4F, 1.5F, 3, 8, 2, 0.0F);
- setRotateAngle(BackLeftMid, 0.4363323129985824F, 1.0471975511965976F, 0.0F);
- bipedLeftLeg.addChild(BackLeftMid);
-
- UnderBackLeftMid = new ModelRenderer(this, "Underside BackLeft Dress");
- UnderBackLeftMid.setTextureOffset(34, 42);
- UnderBackLeftMid.mirror = true;
- UnderBackLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderBackLeftMid.addBox(-3.0F, 3.0F, 0.2F, 6, 8, 2, 0.0F);
- setRotateAngle(UnderBackLeftMid, 0.4363323129985824F, 0.3490658503988659F, 0.0F);
- bipedLeftLeg.addChild(UnderBackLeftMid);
-
- UnderFrontRightMid = new ModelRenderer(this,
- "Underside FrontRight Dress");
- UnderFrontRightMid.setTextureOffset(40, 32);
- UnderFrontRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderFrontRightMid.addBox(-3.0F, 3.0F, -2.3F, 6, 8, 2, 0.0F);
- setRotateAngle(UnderFrontRightMid, -0.4363323129985824F, 0.3490658503988659F, 0.0F);
- bipedRightLeg.addChild(UnderFrontRightMid);
-
- FrontRightMid = new ModelRenderer(this, "Front Right Dress");
- FrontRightMid.setTextureOffset(8, 47);
- FrontRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- FrontRightMid.addBox(-1.7F, -0.4F, -3.5F, 3, 8, 2, 0.0F);
- setRotateAngle(FrontRightMid, -0.4363323129985824F, 1.0471975511965976F, 0.0F);
- bipedRightLeg.addChild(FrontRightMid);
-
- FrontLeftMid = new ModelRenderer(this, "Front Left Dress");
- FrontLeftMid.setTextureOffset(8, 47);
- FrontLeftMid.mirror = true;
- FrontLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- FrontLeftMid.addBox(-1.3F, -0.4F, -3.5F, 3, 8, 2, 0.0F);
- setRotateAngle(FrontLeftMid, -0.4363323129985824F, -1.0471975511965976F, 0.0F);
- bipedLeftLeg.addChild(FrontLeftMid);
-
- UnderRightMid = new ModelRenderer(this, "Under Right Dress");
- UnderRightMid.setTextureOffset(18, 42);
- UnderRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- UnderRightMid.addBox(-2.0F, 3.8F, -3.0F, 2, 7, 6, 0.0F);
- setRotateAngle(UnderRightMid, 0.0F, 0.0F, 0.4363323129985824F);
- bipedRightLeg.addChild(UnderRightMid);
-
- BackRightMid = new ModelRenderer(this, "Back Right Dress");
- BackRightMid.setTextureOffset(8, 47);
- BackRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
- BackRightMid.addBox(-1.7F, -0.4F, 1.5F, 3, 8, 2, 0.0F);
- setRotateAngle(BackRightMid, 0.4363323129985824F, -1.0471975511965976F, 0.0F);
- bipedRightLeg.addChild(BackRightMid);
-
- FrontMidR = new ModelRenderer(this, "Front Right Dress");
- FrontMidR.setTextureOffset(16, 32);
- FrontMidR.setRotationPoint(0.0F, 0.0F, 0.0F);
- FrontMidR.addBox(-2.1F, -0.6F, -3.2F, 4, 8, 2, 0.0F);
- setRotateAngle(FrontMidR, -0.4363323129985824F, 0.0F, 0.0F);
- bipedRightLeg.addChild(FrontMidR);
-
- BackMidL = new ModelRenderer(this, "BackLeft Dress");
- BackMidL.setTextureOffset(28, 32);
- BackMidL.mirror = true;
- BackMidL.setRotationPoint(0.0F, 0.0F, 0.0F);
- BackMidL.addBox(-1.9F, -0.7F, 1.1F, 4, 8, 2, 0.0F);
- setRotateAngle(BackMidL, 0.4363323129985824F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(BackMidL);
-
- //Low
- CenterBackL = new ModelRenderer(this, "Center BackLeft Robe");
- CenterBackL.setTextureOffset(0, 49);
- CenterBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- CenterBackL.addBox(-2.9F, -0.2F, 0.5F, 2, 11, 2, 0.0F);
- setRotateAngle(CenterBackL, 0.08726646259971647F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(CenterBackL);
-
- CenterFrontR = new ModelRenderer(this, "Center FrontRight Robe");
- CenterFrontR.setTextureOffset(0, 49);
- CenterFrontR.setRotationPoint(0.0F, 0.0F, 0.0F);
- CenterFrontR.addBox(0.9F, -0.2F, -2.5F, 2, 11, 2, 0.0F);
- setRotateAngle(CenterFrontR, -0.08726646259971647F, 0.0F, 0.0F);
- bipedRightLeg.addChild(CenterFrontR);
-
- CenterFrontL = new ModelRenderer(this, "Center FrontLeft Robe");
- CenterFrontL.setTextureOffset(0, 49);
- CenterFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
- CenterFrontL.addBox(-2.9F, -0.2F, -2.5F, 2, 11, 2, 0.0F);
- setRotateAngle(CenterFrontL, -0.08726646259971647F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(CenterFrontL);
-
- RightBackL = new ModelRenderer(this, "Right Back Robe");
- RightBackL.setTextureOffset(0, 32);
- RightBackL.mirror = true;
- RightBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- RightBackL.addBox(-2.2F, -0.3F, -1.5F, 4, 11, 4, 0.0F);
- setRotateAngle(RightBackL, 0.08726646259971647F, 0.0F, 0.08726646259971647F);
- bipedRightLeg.addChild(RightBackL);
-
- CenterBackR = new ModelRenderer(this, "Center BackRight Robe");
- CenterBackR.setTextureOffset(0, 49);
- CenterBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
- CenterBackR.addBox(0.9F, -0.2F, 0.5F, 2, 11, 2, 0.0F);
- setRotateAngle(CenterBackR, 0.08726646259971647F, 0.0F, 0.0F);
- bipedRightLeg.addChild(CenterBackR);
-
- LeftBackL = new ModelRenderer(this, "Left Back Robe");
- LeftBackL.setTextureOffset(0, 32);
- LeftBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- LeftBackL.addBox(-1.8F, -0.3F, -1.5F, 4, 11, 4, 0.0F);
- setRotateAngle(LeftBackL, 0.08726646259971647F, 0.0F, -0.08726646259971647F);
- bipedLeftLeg.addChild(LeftBackL);
-
- RightFronL = new ModelRenderer(this, "Right Front Robe");
- RightFronL.setTextureOffset(0, 32);
- RightFronL.setRotationPoint(0.0F, 0.0F, 0.0F);
- RightFronL.addBox(-2.2F, -0.3F, -2.5F, 4, 11, 4, 0.01F);
- setRotateAngle(RightFronL, -0.08726646259971647F, 0.0F, 0.08726646259971647F);
- bipedRightLeg.addChild(RightFronL);
-
- LeftFrontL = new ModelRenderer(this, "Left Front Robe");
- LeftFrontL.setTextureOffset(0, 32);
- LeftFrontL.mirror = true;
- LeftFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
- LeftFrontL.addBox(-1.8F, -0.3F, -2.5F, 4, 11, 4, 0.01F);
- setRotateAngle(LeftFrontL, -0.08726646259971647F, 0.0F, -0.08726646259971647F);
- bipedLeftLeg.addChild(LeftFrontL);
-
- //Belts
- BeltRHip = new ModelRenderer(this, "Belt Right Hip");
- BeltRHip.setTextureOffset(32, 55);
- BeltRHip.setRotationPoint(0.0F, 0.0F, 0.0F);
- BeltRHip.addBox(-3.3F, 0.0F, -3.0F, 10, 3, 6, -0.11F);
- setRotateAngle(BeltRHip, 0.0F, 0.0F, -0.13962634015954636F);
- bipedRightLeg.addChild(BeltRHip);
-
- BeltLHip = new ModelRenderer(this, "Belt Left Hip");
- BeltLHip.setTextureOffset(32, 55);
- BeltLHip.setRotationPoint(0.0F, 0.0F, 0.0F);
- BeltLHip.addBox(-6.7F, 0.0F, -3.0F, 10, 3, 6, -0.1F);
- setRotateAngle(BeltLHip, 0.0F, 0.0F, 0.13962634015954636F);
- bipedLeftLeg.addChild(BeltLHip);
-
- BeltStraight = new ModelRenderer(this, "Belt Straight");
- BeltStraight.setTextureOffset(34, 55);
- BeltStraight.setRotationPoint(0.0F, 0.0F, 0.0F);
- BeltStraight.addBox(-4.5F, 10.5F, -3.0F, 9, 3, 6, -0.1F);
- bipedBody.addChild(BeltStraight);
-
- BackLHigh.isHidden = true;
- BackRightHigh.isHidden = true;
- BackUnderHigh.isHidden = true;
- FrontLHigh.isHidden = true;
- FrontRightHigh.isHidden = true;
- LeftHigh.isHidden = true;
- RightHigh.isHidden = true;
- UnderBackLeftHigh.isHidden = true;
- UnderBackRightHigh.isHidden = true;
- UnderFrontHigh.isHidden = true;
- UnderFrontLeftHigh.isHidden = true;
- UnderFrontRightHigh.isHidden = true;
-
- BackLeftMid.isHidden = true;
- BackMidL.isHidden = true;
- BackMidR.isHidden = true;
- BackRightMid.isHidden = true;
- FrontLeftMid.isHidden = true;
- FrontMidL.isHidden = true;
- FrontMidR.isHidden = true;
- FrontRightMid.isHidden = true;
- UnderBackLeftMid.isHidden = true;
- UnderBackRightMid.isHidden = true;
- UnderFrontLeftMid.isHidden = true;
- UnderFrontRightMid.isHidden = true;
- UnderLeftMid.isHidden = true;
- UnderRightMid.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.cloth;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * ModelBiped - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersRobe extends ArmorRenderer
+//{
+// public ModelRenderer LeftFrontL;
+// public ModelRenderer LeftBackL;
+// public ModelRenderer CenterBackL;
+// public ModelRenderer RightFronL;
+// public ModelRenderer RightBackL;
+// public ModelRenderer CenterFrontL;
+// public ModelRenderer CenterFrontR;
+// public ModelRenderer CenterBackR;
+// public ModelRenderer FrontMidL;
+// public ModelRenderer FrontRightMid;
+// public ModelRenderer BackMidR;
+// public ModelRenderer BackRightMid;
+// public ModelRenderer FrontLeftMid;
+// public ModelRenderer UnderFrontLeftMid;
+// public ModelRenderer UnderBackRightMid;
+// public ModelRenderer UnderBackLeftMid;
+// public ModelRenderer UnderFrontRightMid;
+// public ModelRenderer UnderLeftMid;
+// public ModelRenderer UnderRightMid;
+// public ModelRenderer FrontMidR;
+// public ModelRenderer BackLeftMid;
+// public ModelRenderer BackMidL;
+// public ModelRenderer FrontLHigh;
+// public ModelRenderer UnderFrontRightHigh;
+// public ModelRenderer UnderBackRightHigh;
+// public ModelRenderer BackUnderHigh;
+// public ModelRenderer UnderBackLeftHigh;
+// public ModelRenderer RightHigh;
+// public ModelRenderer LeftHigh;
+// public ModelRenderer FrontRightHigh;
+// public ModelRenderer BackRightHigh;
+// public ModelRenderer UnderFrontHigh;
+// public ModelRenderer UnderFrontLeftHigh;
+// public ModelRenderer BackLHigh;
+// public ModelRenderer BeltLHip;
+// public ModelRenderer BeltStraight;
+// public ModelRenderer BeltRHip;
+//
+// //public ModelRenderer BeltStraightSmall;
+//
+// public ModelTinkersRobe()
+// {
+// super(0.1f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// //High
+//
+// LeftHigh = new ModelRenderer(this, "Left Skirt");
+// LeftHigh.setTextureOffset(52, 38);
+// LeftHigh.mirror = true;
+// LeftHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LeftHigh.addBox(-7.5F, 8.0F, -2.0F, 2, 7, 4, -0.01F);
+// setRotateAngle(LeftHigh, 0.0F, 0.0F, -0.9599310885968813F);
+// bipedBody.addChild(LeftHigh);
+//
+// UnderBackLeftHigh = new ModelRenderer(this, "Underside BackLeft Skirt");
+// UnderBackLeftHigh.setTextureOffset(8, 57);
+// UnderBackLeftHigh.mirror = true;
+// UnderBackLeftHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderBackLeftHigh.addBox(-0.2F, 8.5F, -7.5F, 4, 6, 1, 0.0F);
+// setRotateAngle(UnderBackLeftHigh, 0.9599310885968813F, 0.7853981633974483F, 0.0F);
+// bipedBody.addChild(UnderBackLeftHigh);
+//
+// FrontRightHigh = new ModelRenderer(this, "Front Right Skirt");
+// FrontRightHigh.setTextureOffset(18, 55);
+// FrontRightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FrontRightHigh.addBox(-3.3F, 6.6F, 6.1F, 4, 7, 2, 0.0F);
+// setRotateAngle(FrontRightHigh, -0.9599310885968813F, 0.2617993877991494F, 0.0F);
+// bipedBody.addChild(FrontRightHigh);
+//
+// RightHigh = new ModelRenderer(this, "Right Skirt");
+// RightHigh.setTextureOffset(52, 38);
+// RightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// RightHigh.addBox(5.5F, 8.0F, -2.0F, 2, 7, 4, -0.01F);
+// setRotateAngle(RightHigh, 0.0F, 0.0F, 0.9599310885968813F);
+// bipedBody.addChild(RightHigh);
+//
+// BackUnderHigh = new ModelRenderer(this, "Underside Back Skirt");
+// BackUnderHigh.setTextureOffset(8, 57);
+// BackUnderHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BackUnderHigh.addBox(-2.0F, 8.0F, -8.0F, 4, 6, 1, 0.0F);
+// setRotateAngle(BackUnderHigh, 0.9599310885968813F, 0.0F, 0.0F);
+// bipedBody.addChild(BackUnderHigh);
+//
+// UnderFrontHigh = new ModelRenderer(this, "Underside Front Skirt");
+// UnderFrontHigh.setTextureOffset(8, 57);
+// UnderFrontHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderFrontHigh.addBox(-2.0F, 8.0F, 7.0F, 4, 6, 1, 0.0F);
+// setRotateAngle(UnderFrontHigh, -0.9599310885968813F, 0.0F, 0.0F);
+// bipedBody.addChild(UnderFrontHigh);
+//
+// UnderBackRightHigh = new ModelRenderer(this,
+// "Underside BackRight Skirt");
+// UnderBackRightHigh.setTextureOffset(8, 57);
+// UnderBackRightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderBackRightHigh.addBox(-3.8F, 8.5F, -7.5F, 4, 6, 1, 0.0F);
+// setRotateAngle(UnderBackRightHigh, 0.9599310885968813F, -0.7853981633974483F, 0.0F);
+// bipedBody.addChild(UnderBackRightHigh);
+//
+// BackLHigh = new ModelRenderer(this, "Back Left Skirt");
+// BackLHigh.setTextureOffset(18, 55);
+// BackLHigh.mirror = true;
+// BackLHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BackLHigh.addBox(-0.7F, 6.6F, -8.1F, 4, 7, 2, 0.0F);
+// setRotateAngle(BackLHigh, 0.9599310885968813F, 0.2617993877991494F, 0.0F);
+// bipedBody.addChild(BackLHigh);
+//
+// BackRightHigh = new ModelRenderer(this, "Back Right Skirt");
+// BackRightHigh.setTextureOffset(18, 55);
+// BackRightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BackRightHigh.addBox(-3.3F, 6.6F, -8.1F, 4, 7, 2, 0.0F);
+// setRotateAngle(BackRightHigh, 0.9599310885968813F, -0.2617993877991494F, 0.0F);
+// bipedBody.addChild(BackRightHigh);
+//
+// UnderFrontRightHigh = new ModelRenderer(this,
+// "Underside FrontRight Skirt");
+// UnderFrontRightHigh.setTextureOffset(8, 57);
+// UnderFrontRightHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderFrontRightHigh.addBox(-3.8F, 8.5F, 6.5F, 4, 6, 1, 0.0F);
+// setRotateAngle(UnderFrontRightHigh, -0.9599310885968813F, 0.7853981633974483F, 0.0F);
+// bipedBody.addChild(UnderFrontRightHigh);
+//
+// FrontLHigh = new ModelRenderer(this, "Front Left Skirt");
+// FrontLHigh.setTextureOffset(18, 55);
+// FrontLHigh.mirror = true;
+// FrontLHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FrontLHigh.addBox(-0.7F, 6.6F, 6.1F, 4, 7, 2, 0.0F);
+// setRotateAngle(FrontLHigh, -0.9599310885968813F, -0.2617993877991494F, 0.0F);
+// bipedBody.addChild(FrontLHigh);
+//
+// UnderFrontLeftHigh = new ModelRenderer(this, "Under FrontLeft Skirt");
+// UnderFrontLeftHigh.setTextureOffset(8, 57);
+// UnderFrontLeftHigh.mirror = true;
+// UnderFrontLeftHigh.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderFrontLeftHigh.addBox(-0.2F, 8.5F, 6.5F, 4, 6, 1, 0.0F);
+// setRotateAngle(UnderFrontLeftHigh, -0.9599310885968813F, -0.7853981633974483F, 0.0F);
+// bipedBody.addChild(UnderFrontLeftHigh);
+//
+// //Mid
+// FrontMidL = new ModelRenderer(this, "Front Left Dress");
+// FrontMidL.setTextureOffset(16, 32);
+// FrontMidL.mirror = true;
+// FrontMidL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FrontMidL.addBox(-1.9F, -0.6F, -3.2F, 4, 8, 2, 0.0F);
+// setRotateAngle(FrontMidL, -0.4363323129985824F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(FrontMidL);
+//
+// UnderBackRightMid = new ModelRenderer(this, "Underside BackRight Dress");
+// UnderBackRightMid.setTextureOffset(34, 42);
+// UnderBackRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderBackRightMid.addBox(-3.0F, 3.0F, 0.2F, 6, 8, 2, 0.0F);
+// setRotateAngle(UnderBackRightMid, 0.4363323129985824F, -0.3490658503988659F, 0.0F);
+// bipedRightLeg.addChild(UnderBackRightMid);
+//
+// BackMidR = new ModelRenderer(this, "BackRight Dress");
+// BackMidR.setTextureOffset(28, 32);
+// BackMidR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BackMidR.addBox(-2.1F, -0.7F, 1.1F, 4, 8, 2, 0.0F);
+// setRotateAngle(BackMidR, 0.4363323129985824F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(BackMidR);
+//
+// UnderLeftMid = new ModelRenderer(this, "Underside Left Dress");
+// UnderLeftMid.setTextureOffset(18, 42);
+// UnderLeftMid.mirror = true;
+// UnderLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderLeftMid.addBox(0.0F, 3.8F, -3.0F, 2, 7, 6, 0.0F);
+// setRotateAngle(UnderLeftMid, 0.0F, 0.0F, -0.4363323129985824F);
+// bipedLeftLeg.addChild(UnderLeftMid);
+//
+// UnderFrontLeftMid = new ModelRenderer(this, "Underside FrontLeft Dress");
+// UnderFrontLeftMid.setTextureOffset(40, 32);
+// UnderFrontLeftMid.mirror = true;
+// UnderFrontLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderFrontLeftMid.addBox(-3.0F, 3.0F, -2.3F, 6, 8, 2, 0.0F);
+// setRotateAngle(UnderFrontLeftMid, -0.4363323129985824F, -0.3490658503988659F, 0.0F);
+// bipedLeftLeg.addChild(UnderFrontLeftMid);
+//
+// BackLeftMid = new ModelRenderer(this, "Back Left Dress");
+// BackLeftMid.setTextureOffset(8, 47);
+// BackLeftMid.mirror = true;
+// BackLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BackLeftMid.addBox(-1.3F, -0.4F, 1.5F, 3, 8, 2, 0.0F);
+// setRotateAngle(BackLeftMid, 0.4363323129985824F, 1.0471975511965976F, 0.0F);
+// bipedLeftLeg.addChild(BackLeftMid);
+//
+// UnderBackLeftMid = new ModelRenderer(this, "Underside BackLeft Dress");
+// UnderBackLeftMid.setTextureOffset(34, 42);
+// UnderBackLeftMid.mirror = true;
+// UnderBackLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderBackLeftMid.addBox(-3.0F, 3.0F, 0.2F, 6, 8, 2, 0.0F);
+// setRotateAngle(UnderBackLeftMid, 0.4363323129985824F, 0.3490658503988659F, 0.0F);
+// bipedLeftLeg.addChild(UnderBackLeftMid);
+//
+// UnderFrontRightMid = new ModelRenderer(this,
+// "Underside FrontRight Dress");
+// UnderFrontRightMid.setTextureOffset(40, 32);
+// UnderFrontRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderFrontRightMid.addBox(-3.0F, 3.0F, -2.3F, 6, 8, 2, 0.0F);
+// setRotateAngle(UnderFrontRightMid, -0.4363323129985824F, 0.3490658503988659F, 0.0F);
+// bipedRightLeg.addChild(UnderFrontRightMid);
+//
+// FrontRightMid = new ModelRenderer(this, "Front Right Dress");
+// FrontRightMid.setTextureOffset(8, 47);
+// FrontRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FrontRightMid.addBox(-1.7F, -0.4F, -3.5F, 3, 8, 2, 0.0F);
+// setRotateAngle(FrontRightMid, -0.4363323129985824F, 1.0471975511965976F, 0.0F);
+// bipedRightLeg.addChild(FrontRightMid);
+//
+// FrontLeftMid = new ModelRenderer(this, "Front Left Dress");
+// FrontLeftMid.setTextureOffset(8, 47);
+// FrontLeftMid.mirror = true;
+// FrontLeftMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FrontLeftMid.addBox(-1.3F, -0.4F, -3.5F, 3, 8, 2, 0.0F);
+// setRotateAngle(FrontLeftMid, -0.4363323129985824F, -1.0471975511965976F, 0.0F);
+// bipedLeftLeg.addChild(FrontLeftMid);
+//
+// UnderRightMid = new ModelRenderer(this, "Under Right Dress");
+// UnderRightMid.setTextureOffset(18, 42);
+// UnderRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// UnderRightMid.addBox(-2.0F, 3.8F, -3.0F, 2, 7, 6, 0.0F);
+// setRotateAngle(UnderRightMid, 0.0F, 0.0F, 0.4363323129985824F);
+// bipedRightLeg.addChild(UnderRightMid);
+//
+// BackRightMid = new ModelRenderer(this, "Back Right Dress");
+// BackRightMid.setTextureOffset(8, 47);
+// BackRightMid.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BackRightMid.addBox(-1.7F, -0.4F, 1.5F, 3, 8, 2, 0.0F);
+// setRotateAngle(BackRightMid, 0.4363323129985824F, -1.0471975511965976F, 0.0F);
+// bipedRightLeg.addChild(BackRightMid);
+//
+// FrontMidR = new ModelRenderer(this, "Front Right Dress");
+// FrontMidR.setTextureOffset(16, 32);
+// FrontMidR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FrontMidR.addBox(-2.1F, -0.6F, -3.2F, 4, 8, 2, 0.0F);
+// setRotateAngle(FrontMidR, -0.4363323129985824F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(FrontMidR);
+//
+// BackMidL = new ModelRenderer(this, "BackLeft Dress");
+// BackMidL.setTextureOffset(28, 32);
+// BackMidL.mirror = true;
+// BackMidL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BackMidL.addBox(-1.9F, -0.7F, 1.1F, 4, 8, 2, 0.0F);
+// setRotateAngle(BackMidL, 0.4363323129985824F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(BackMidL);
+//
+// //Low
+// CenterBackL = new ModelRenderer(this, "Center BackLeft Robe");
+// CenterBackL.setTextureOffset(0, 49);
+// CenterBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CenterBackL.addBox(-2.9F, -0.2F, 0.5F, 2, 11, 2, 0.0F);
+// setRotateAngle(CenterBackL, 0.08726646259971647F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(CenterBackL);
+//
+// CenterFrontR = new ModelRenderer(this, "Center FrontRight Robe");
+// CenterFrontR.setTextureOffset(0, 49);
+// CenterFrontR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CenterFrontR.addBox(0.9F, -0.2F, -2.5F, 2, 11, 2, 0.0F);
+// setRotateAngle(CenterFrontR, -0.08726646259971647F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(CenterFrontR);
+//
+// CenterFrontL = new ModelRenderer(this, "Center FrontLeft Robe");
+// CenterFrontL.setTextureOffset(0, 49);
+// CenterFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CenterFrontL.addBox(-2.9F, -0.2F, -2.5F, 2, 11, 2, 0.0F);
+// setRotateAngle(CenterFrontL, -0.08726646259971647F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(CenterFrontL);
+//
+// RightBackL = new ModelRenderer(this, "Right Back Robe");
+// RightBackL.setTextureOffset(0, 32);
+// RightBackL.mirror = true;
+// RightBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// RightBackL.addBox(-2.2F, -0.3F, -1.5F, 4, 11, 4, 0.0F);
+// setRotateAngle(RightBackL, 0.08726646259971647F, 0.0F, 0.08726646259971647F);
+// bipedRightLeg.addChild(RightBackL);
+//
+// CenterBackR = new ModelRenderer(this, "Center BackRight Robe");
+// CenterBackR.setTextureOffset(0, 49);
+// CenterBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CenterBackR.addBox(0.9F, -0.2F, 0.5F, 2, 11, 2, 0.0F);
+// setRotateAngle(CenterBackR, 0.08726646259971647F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(CenterBackR);
+//
+// LeftBackL = new ModelRenderer(this, "Left Back Robe");
+// LeftBackL.setTextureOffset(0, 32);
+// LeftBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LeftBackL.addBox(-1.8F, -0.3F, -1.5F, 4, 11, 4, 0.0F);
+// setRotateAngle(LeftBackL, 0.08726646259971647F, 0.0F, -0.08726646259971647F);
+// bipedLeftLeg.addChild(LeftBackL);
+//
+// RightFronL = new ModelRenderer(this, "Right Front Robe");
+// RightFronL.setTextureOffset(0, 32);
+// RightFronL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// RightFronL.addBox(-2.2F, -0.3F, -2.5F, 4, 11, 4, 0.01F);
+// setRotateAngle(RightFronL, -0.08726646259971647F, 0.0F, 0.08726646259971647F);
+// bipedRightLeg.addChild(RightFronL);
+//
+// LeftFrontL = new ModelRenderer(this, "Left Front Robe");
+// LeftFrontL.setTextureOffset(0, 32);
+// LeftFrontL.mirror = true;
+// LeftFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LeftFrontL.addBox(-1.8F, -0.3F, -2.5F, 4, 11, 4, 0.01F);
+// setRotateAngle(LeftFrontL, -0.08726646259971647F, 0.0F, -0.08726646259971647F);
+// bipedLeftLeg.addChild(LeftFrontL);
+//
+// //Belts
+// BeltRHip = new ModelRenderer(this, "Belt Right Hip");
+// BeltRHip.setTextureOffset(32, 55);
+// BeltRHip.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BeltRHip.addBox(-3.3F, 0.0F, -3.0F, 10, 3, 6, -0.11F);
+// setRotateAngle(BeltRHip, 0.0F, 0.0F, -0.13962634015954636F);
+// bipedRightLeg.addChild(BeltRHip);
+//
+// BeltLHip = new ModelRenderer(this, "Belt Left Hip");
+// BeltLHip.setTextureOffset(32, 55);
+// BeltLHip.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BeltLHip.addBox(-6.7F, 0.0F, -3.0F, 10, 3, 6, -0.1F);
+// setRotateAngle(BeltLHip, 0.0F, 0.0F, 0.13962634015954636F);
+// bipedLeftLeg.addChild(BeltLHip);
+//
+// BeltStraight = new ModelRenderer(this, "Belt Straight");
+// BeltStraight.setTextureOffset(34, 55);
+// BeltStraight.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BeltStraight.addBox(-4.5F, 10.5F, -3.0F, 9, 3, 6, -0.1F);
+// bipedBody.addChild(BeltStraight);
+//
+// BackLHigh.isHidden = true;
+// BackRightHigh.isHidden = true;
+// BackUnderHigh.isHidden = true;
+// FrontLHigh.isHidden = true;
+// FrontRightHigh.isHidden = true;
+// LeftHigh.isHidden = true;
+// RightHigh.isHidden = true;
+// UnderBackLeftHigh.isHidden = true;
+// UnderBackRightHigh.isHidden = true;
+// UnderFrontHigh.isHidden = true;
+// UnderFrontLeftHigh.isHidden = true;
+// UnderFrontRightHigh.isHidden = true;
+//
+// BackLeftMid.isHidden = true;
+// BackMidL.isHidden = true;
+// BackMidR.isHidden = true;
+// BackRightMid.isHidden = true;
+// FrontLeftMid.isHidden = true;
+// FrontMidL.isHidden = true;
+// FrontMidR.isHidden = true;
+// FrontRightMid.isHidden = true;
+// UnderBackLeftMid.isHidden = true;
+// UnderBackRightMid.isHidden = true;
+// UnderFrontLeftMid.isHidden = true;
+// UnderFrontRightMid.isHidden = true;
+// UnderLeftMid.isHidden = true;
+// UnderRightMid.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShawl.java b/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShawl.java
index 20a6317..888843e 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShawl.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShawl.java
@@ -1,176 +1,176 @@
-package lance5057.tDefense.armor.renderers.cloth;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * ModelTinkersShawl - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersShawl extends ArmorRenderer
-{
- public ModelRenderer Button;
- public ModelRenderer Zipper;
- public ModelRenderer ArmTrimL;
- public ModelRenderer ArmTrimR;
- public ModelRenderer TrimNeck;
- public ModelRenderer ButtonArmL;
- public ModelRenderer ButtonArmR;
- public ModelRenderer ShawlLeftShort;
- public ModelRenderer ShawlRightShort;
- public ModelRenderer ShawlLeftTrim;
- public ModelRenderer TrimShawl;
- public ModelRenderer ShawlRightTrim;
- public ModelRenderer ZipperShort;
- public ModelRenderer ShawlLeftLong;
- public ModelRenderer ShawlLeftTrimLong;
- public ModelRenderer ShawlRightLong;
- public ModelRenderer ShawlRightTrimLong;
-
- public ModelTinkersShawl()
- {
- super(0.1f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- TrimNeck = new ModelRenderer(this, "Collar");
- TrimNeck.setTextureOffset(20, 32);
- TrimNeck.setRotationPoint(0.0F, 0.0F, 0.0F);
- TrimNeck.addBox(-4.5F, -0.5F, -2.5F, 9, 2, 5, -0.3F);
- bipedBody.addChild(TrimNeck);
-
- Button = new ModelRenderer(this, "Collar Button");
- Button.setTextureOffset(15, 32);
- Button.setRotationPoint(0.0F, 0.0F, 0.0F);
- Button.addBox(-1.5F, -0.5F, -2.5F, 2, 2, 1, -0.2F);
- setRotateAngle(Button, 0.0F, 0.0F, -0.7853981633974483F);
- bipedBody.addChild(Button);
-
- ButtonArmL = new ModelRenderer(this, "Button Arm Left");
- ButtonArmL.setTextureOffset(23, 39);
- ButtonArmL.mirror = true;
- ButtonArmL.setRotationPoint(0.0F, 0.0F, 0.0F);
- ButtonArmL.addBox(2.5F, 3.0F, -5.0F, 1, 2, 2, -0.2F);
- setRotateAngle(ButtonArmL, 0.7853981633974483F, 0.0F, 0.0F);
- bipedLeftArm.addChild(ButtonArmL);
-
- ButtonArmR = new ModelRenderer(this, "Button Arm Right");
- ButtonArmR.setTextureOffset(23, 39);
- ButtonArmR.setRotationPoint(0.0F, 0.0F, 0.0F);
- ButtonArmR.addBox(-3.5F, 3.0F, -5.0F, 1, 2, 2, -0.2F);
- setRotateAngle(ButtonArmR, 0.7853981633974483F, 0.0F, 0.0F);
- bipedRightArm.addChild(ButtonArmR);
-
- ArmTrimR = new ModelRenderer(this, "Arm Trim Right");
- ArmTrimR.setTextureOffset(0, 32);
- ArmTrimR.setRotationPoint(0.0F, 0.0F, 0.0F);
- ArmTrimR.addBox(-3.5F, 5.0F, -2.5F, 5, 2, 5, -0.3F);
- bipedRightArm.addChild(ArmTrimR);
-
- ArmTrimL = new ModelRenderer(this, "Arm Trim Left");
- ArmTrimL.setTextureOffset(0, 32);
- ArmTrimL.mirror = true;
- ArmTrimL.setRotationPoint(0.0F, 0.0F, 0.0F);
- ArmTrimL.addBox(-1.5F, 5.0F, -2.5F, 5, 2, 5, -0.3F);
- bipedLeftArm.addChild(ArmTrimL);
-
- ZipperShort = new ModelRenderer(this, "Zipper Bottom");
- ZipperShort.setTextureOffset(30, 53);
- ZipperShort.setRotationPoint(0.0F, 0.0F, 0.0F);
- ZipperShort.addBox(-1.0F, 6.3F, -2.5F, 2, 5, 1, -0.3F);
- bipedBody.addChild(ZipperShort);
-
- Zipper = new ModelRenderer(this, "Zipper Top");
- Zipper.setTextureOffset(30, 52);
- Zipper.setRotationPoint(0.0F, 0.0F, 0.0F);
- Zipper.addBox(-1.0F, 0.2F, -2.5F, 2, 7, 1, -0.3F);
- bipedBody.addChild(Zipper);
-
- ShawlLeftTrim = new ModelRenderer(this, "Shawl Left Trim");
- ShawlLeftTrim.setTextureOffset(28, 39);
- ShawlLeftTrim.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShawlLeftTrim.addBox(-5.1F, 2.45F, -2.5F, 9, 2, 5, -0.29F);
- setRotateAngle(ShawlLeftTrim, 0.0F, 0.0F, -0.2792526803190927F);
- bipedLeftArm.addChild(ShawlLeftTrim);
-
- ShawlRightTrim = new ModelRenderer(this, "Shawl Right Trim Short");
- ShawlRightTrim.setTextureOffset(28, 39);
- ShawlRightTrim.mirror = true;
- ShawlRightTrim.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShawlRightTrim.addBox(-3.95F, 2.45F, -2.5F, 9, 2, 5, -0.29F);
- setRotateAngle(ShawlRightTrim, 0.0F, 0.0F, 0.2792526803190927F);
- bipedRightArm.addChild(ShawlRightTrim);
-
- ShawlRightTrimLong = new ModelRenderer(this, "Shawl Right Trim Long");
- ShawlRightTrimLong.setTextureOffset(0, 39);
- ShawlRightTrimLong.mirror = true;
- ShawlRightTrimLong.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShawlRightTrimLong.addBox(-3.95F, 7.85F, -2.5F, 9, 2, 5, -0.29F);
- setRotateAngle(ShawlRightTrimLong, 0.0F, 0.0F, 0.2792526803190927F);
- bipedRightArm.addChild(ShawlRightTrimLong);
-
- ShawlLeftTrimLong = new ModelRenderer(this, "Shawl Left Trim Long");
- ShawlLeftTrimLong.setTextureOffset(0, 39);
- ShawlLeftTrimLong.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShawlLeftTrimLong.addBox(-5.1F, 7.85F, -2.5F, 9, 2, 5, -0.29F);
- setRotateAngle(ShawlLeftTrimLong, 0.0F, 0.0F, -0.2792526803190927F);
- bipedLeftArm.addChild(ShawlLeftTrimLong);
-
- ShawlLeftLong = new ModelRenderer(this, "Shawl Left Long");
- ShawlLeftLong.setTextureOffset(38, 50);
- ShawlLeftLong.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShawlLeftLong.addBox(-4.55F, -1.05F, -2.0F, 8, 10, 4, 0.11F);
- setRotateAngle(ShawlLeftLong, 0.0F, 0.0F, -0.2792526803190927F);
- bipedLeftArm.addChild(ShawlLeftLong);
-
- ShawlRightLong = new ModelRenderer(this, "Shawl Right Long");
- ShawlRightLong.setTextureOffset(38, 50);
- ShawlRightLong.mirror = true;
- ShawlRightLong.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShawlRightLong.addBox(-3.45F, -1.05F, -2.0F, 8, 10, 4, 0.11F);
- setRotateAngle(ShawlRightLong, 0.0F, 0.0F, 0.2792526803190927F);
- bipedRightArm.addChild(ShawlRightLong);
-
- ShawlLeftShort = new ModelRenderer(this, "Shawl Left Short");
- ShawlLeftShort.setTextureOffset(38, 50);
- ShawlLeftShort.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShawlLeftShort.addBox(-1.55F, -1.05F, -2.0F, 5, 5, 4, 0.01F);
- setRotateAngle(ShawlLeftShort, 0.0F, 0.0F, -0.2792526803190927F);
- bipedLeftArm.addChild(ShawlLeftShort);
-
- ShawlRightShort = new ModelRenderer(this, "Shawl Right Short");
- ShawlRightShort.setTextureOffset(38, 50);
- ShawlRightShort.mirror = true;
- ShawlRightShort.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShawlRightShort.addBox(-3.45F, -1.05F, -2.0F, 5, 5, 4, 0.01F);
- setRotateAngle(ShawlRightShort, 0.0F, 0.0F, 0.2792526803190927F);
- bipedRightArm.addChild(ShawlRightShort);
-
- TrimShawl = new ModelRenderer(this, "Trim Shawl Short");
- TrimShawl.setTextureOffset(20, 32);
- TrimShawl.setRotationPoint(0.0F, 0.0F, 0.0F);
- TrimShawl.addBox(-4.5F, 5.5F, -2.5F, 9, 2, 5, -0.31F);
- bipedBody.addChild(TrimShawl);
-
- ArmTrimL.isHidden = true;
- ArmTrimR.isHidden = true;
- ShawlLeftTrim.isHidden = true;
- ShawlRightTrim.isHidden = true;
- TrimShawl.isHidden = true;
- Zipper.isHidden = true;
- ZipperShort.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.cloth;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * ModelTinkersShawl - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersShawl extends ArmorRenderer
+//{
+// public ModelRenderer Button;
+// public ModelRenderer Zipper;
+// public ModelRenderer ArmTrimL;
+// public ModelRenderer ArmTrimR;
+// public ModelRenderer TrimNeck;
+// public ModelRenderer ButtonArmL;
+// public ModelRenderer ButtonArmR;
+// public ModelRenderer ShawlLeftShort;
+// public ModelRenderer ShawlRightShort;
+// public ModelRenderer ShawlLeftTrim;
+// public ModelRenderer TrimShawl;
+// public ModelRenderer ShawlRightTrim;
+// public ModelRenderer ZipperShort;
+// public ModelRenderer ShawlLeftLong;
+// public ModelRenderer ShawlLeftTrimLong;
+// public ModelRenderer ShawlRightLong;
+// public ModelRenderer ShawlRightTrimLong;
+//
+// public ModelTinkersShawl()
+// {
+// super(0.1f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// TrimNeck = new ModelRenderer(this, "Collar");
+// TrimNeck.setTextureOffset(20, 32);
+// TrimNeck.setRotationPoint(0.0F, 0.0F, 0.0F);
+// TrimNeck.addBox(-4.5F, -0.5F, -2.5F, 9, 2, 5, -0.3F);
+// bipedBody.addChild(TrimNeck);
+//
+// Button = new ModelRenderer(this, "Collar Button");
+// Button.setTextureOffset(15, 32);
+// Button.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Button.addBox(-1.5F, -0.5F, -2.5F, 2, 2, 1, -0.2F);
+// setRotateAngle(Button, 0.0F, 0.0F, -0.7853981633974483F);
+// bipedBody.addChild(Button);
+//
+// ButtonArmL = new ModelRenderer(this, "Button Arm Left");
+// ButtonArmL.setTextureOffset(23, 39);
+// ButtonArmL.mirror = true;
+// ButtonArmL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ButtonArmL.addBox(2.5F, 3.0F, -5.0F, 1, 2, 2, -0.2F);
+// setRotateAngle(ButtonArmL, 0.7853981633974483F, 0.0F, 0.0F);
+// bipedLeftArm.addChild(ButtonArmL);
+//
+// ButtonArmR = new ModelRenderer(this, "Button Arm Right");
+// ButtonArmR.setTextureOffset(23, 39);
+// ButtonArmR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ButtonArmR.addBox(-3.5F, 3.0F, -5.0F, 1, 2, 2, -0.2F);
+// setRotateAngle(ButtonArmR, 0.7853981633974483F, 0.0F, 0.0F);
+// bipedRightArm.addChild(ButtonArmR);
+//
+// ArmTrimR = new ModelRenderer(this, "Arm Trim Right");
+// ArmTrimR.setTextureOffset(0, 32);
+// ArmTrimR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ArmTrimR.addBox(-3.5F, 5.0F, -2.5F, 5, 2, 5, -0.3F);
+// bipedRightArm.addChild(ArmTrimR);
+//
+// ArmTrimL = new ModelRenderer(this, "Arm Trim Left");
+// ArmTrimL.setTextureOffset(0, 32);
+// ArmTrimL.mirror = true;
+// ArmTrimL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ArmTrimL.addBox(-1.5F, 5.0F, -2.5F, 5, 2, 5, -0.3F);
+// bipedLeftArm.addChild(ArmTrimL);
+//
+// ZipperShort = new ModelRenderer(this, "Zipper Bottom");
+// ZipperShort.setTextureOffset(30, 53);
+// ZipperShort.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ZipperShort.addBox(-1.0F, 6.3F, -2.5F, 2, 5, 1, -0.3F);
+// bipedBody.addChild(ZipperShort);
+//
+// Zipper = new ModelRenderer(this, "Zipper Top");
+// Zipper.setTextureOffset(30, 52);
+// Zipper.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Zipper.addBox(-1.0F, 0.2F, -2.5F, 2, 7, 1, -0.3F);
+// bipedBody.addChild(Zipper);
+//
+// ShawlLeftTrim = new ModelRenderer(this, "Shawl Left Trim");
+// ShawlLeftTrim.setTextureOffset(28, 39);
+// ShawlLeftTrim.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShawlLeftTrim.addBox(-5.1F, 2.45F, -2.5F, 9, 2, 5, -0.29F);
+// setRotateAngle(ShawlLeftTrim, 0.0F, 0.0F, -0.2792526803190927F);
+// bipedLeftArm.addChild(ShawlLeftTrim);
+//
+// ShawlRightTrim = new ModelRenderer(this, "Shawl Right Trim Short");
+// ShawlRightTrim.setTextureOffset(28, 39);
+// ShawlRightTrim.mirror = true;
+// ShawlRightTrim.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShawlRightTrim.addBox(-3.95F, 2.45F, -2.5F, 9, 2, 5, -0.29F);
+// setRotateAngle(ShawlRightTrim, 0.0F, 0.0F, 0.2792526803190927F);
+// bipedRightArm.addChild(ShawlRightTrim);
+//
+// ShawlRightTrimLong = new ModelRenderer(this, "Shawl Right Trim Long");
+// ShawlRightTrimLong.setTextureOffset(0, 39);
+// ShawlRightTrimLong.mirror = true;
+// ShawlRightTrimLong.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShawlRightTrimLong.addBox(-3.95F, 7.85F, -2.5F, 9, 2, 5, -0.29F);
+// setRotateAngle(ShawlRightTrimLong, 0.0F, 0.0F, 0.2792526803190927F);
+// bipedRightArm.addChild(ShawlRightTrimLong);
+//
+// ShawlLeftTrimLong = new ModelRenderer(this, "Shawl Left Trim Long");
+// ShawlLeftTrimLong.setTextureOffset(0, 39);
+// ShawlLeftTrimLong.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShawlLeftTrimLong.addBox(-5.1F, 7.85F, -2.5F, 9, 2, 5, -0.29F);
+// setRotateAngle(ShawlLeftTrimLong, 0.0F, 0.0F, -0.2792526803190927F);
+// bipedLeftArm.addChild(ShawlLeftTrimLong);
+//
+// ShawlLeftLong = new ModelRenderer(this, "Shawl Left Long");
+// ShawlLeftLong.setTextureOffset(38, 50);
+// ShawlLeftLong.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShawlLeftLong.addBox(-4.55F, -1.05F, -2.0F, 8, 10, 4, 0.11F);
+// setRotateAngle(ShawlLeftLong, 0.0F, 0.0F, -0.2792526803190927F);
+// bipedLeftArm.addChild(ShawlLeftLong);
+//
+// ShawlRightLong = new ModelRenderer(this, "Shawl Right Long");
+// ShawlRightLong.setTextureOffset(38, 50);
+// ShawlRightLong.mirror = true;
+// ShawlRightLong.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShawlRightLong.addBox(-3.45F, -1.05F, -2.0F, 8, 10, 4, 0.11F);
+// setRotateAngle(ShawlRightLong, 0.0F, 0.0F, 0.2792526803190927F);
+// bipedRightArm.addChild(ShawlRightLong);
+//
+// ShawlLeftShort = new ModelRenderer(this, "Shawl Left Short");
+// ShawlLeftShort.setTextureOffset(38, 50);
+// ShawlLeftShort.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShawlLeftShort.addBox(-1.55F, -1.05F, -2.0F, 5, 5, 4, 0.01F);
+// setRotateAngle(ShawlLeftShort, 0.0F, 0.0F, -0.2792526803190927F);
+// bipedLeftArm.addChild(ShawlLeftShort);
+//
+// ShawlRightShort = new ModelRenderer(this, "Shawl Right Short");
+// ShawlRightShort.setTextureOffset(38, 50);
+// ShawlRightShort.mirror = true;
+// ShawlRightShort.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShawlRightShort.addBox(-3.45F, -1.05F, -2.0F, 5, 5, 4, 0.01F);
+// setRotateAngle(ShawlRightShort, 0.0F, 0.0F, 0.2792526803190927F);
+// bipedRightArm.addChild(ShawlRightShort);
+//
+// TrimShawl = new ModelRenderer(this, "Trim Shawl Short");
+// TrimShawl.setTextureOffset(20, 32);
+// TrimShawl.setRotationPoint(0.0F, 0.0F, 0.0F);
+// TrimShawl.addBox(-4.5F, 5.5F, -2.5F, 9, 2, 5, -0.31F);
+// bipedBody.addChild(TrimShawl);
+//
+// ArmTrimL.isHidden = true;
+// ArmTrimR.isHidden = true;
+// ShawlLeftTrim.isHidden = true;
+// ShawlRightTrim.isHidden = true;
+// TrimShawl.isHidden = true;
+// Zipper.isHidden = true;
+// ZipperShort.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShoes.java b/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShoes.java
index 8bd6dc9..d751ded 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShoes.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/cloth/ModelTinkersShoes.java
@@ -1,79 +1,79 @@
-package lance5057.tDefense.armor.renderers.cloth;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * ModelTinkersShoes - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersShoes extends ArmorRenderer
-{
- public ModelRenderer FootL;
- public ModelRenderer FootR;
- public ModelRenderer OverLegL;
- public ModelRenderer OverLegR;
- public ModelRenderer ShoeL;
- public ModelRenderer ShoeR;
-
- public ModelTinkersShoes()
- {
- super(0.1f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- FootL = new ModelRenderer(this, "Foot Left");
- FootL.setTextureOffset(16, 41);
- FootL.setRotationPoint(0F, 0F, 0F);
- FootL.addBox(-2F, 10.1F, -3.0F, 4, 2, 1, 0.2F);
- bipedLeftLeg.addChild(FootL);
-
- FootR = new ModelRenderer(this, "Foot Right");
- FootR.setTextureOffset(16, 41);
- FootR.setRotationPoint(0F, 0F, 0F);
- FootR.addBox(-2F, 10.1F, -3.0F, 4, 2, 1, 0.2F);
- bipedRightLeg.addChild(FootR);
-
- OverLegL = new ModelRenderer(this, "Over Leg Left");
- OverLegL.setTextureOffset(0, 32);
- OverLegL.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.2F);
- OverLegL.setRotationPoint(0F, 0F, 0F);
- bipedLeftLeg.addChild(OverLegL);
-
- OverLegR = new ModelRenderer(this, "Over Leg Right");
- OverLegR.setTextureOffset(0, 32);
- OverLegR.mirror = true;
- OverLegR.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.2F);
- OverLegR.setRotationPoint(0F, 0F, 0F);
- bipedRightLeg.addChild(OverLegR);
-
- ShoeL = new ModelRenderer(this, "Shoe Left");
- ShoeL.setTextureOffset(16, 32);
- ShoeL.addBox(-2.0F, 7.0F, -2.0F, 4, 5, 4, 0.21F);
- ShoeL.setRotationPoint(0F, 0F, 0F);
- bipedLeftLeg.addChild(ShoeL);
-
- ShoeR = new ModelRenderer(this, "Shoe Right");
- ShoeR.setTextureOffset(16, 32);
- ShoeR.mirror = true;
- ShoeR.addBox(-2.0F, 7.0F, -2.0F, 4, 5, 4, 0.21F);
- ShoeR.setRotationPoint(0F, 0F, 0F);
- bipedRightLeg.addChild(ShoeR);
-
- OverLegL.isHidden = true;
- OverLegR.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.cloth;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * ModelTinkersShoes - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersShoes extends ArmorRenderer
+//{
+// public ModelRenderer FootL;
+// public ModelRenderer FootR;
+// public ModelRenderer OverLegL;
+// public ModelRenderer OverLegR;
+// public ModelRenderer ShoeL;
+// public ModelRenderer ShoeR;
+//
+// public ModelTinkersShoes()
+// {
+// super(0.1f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// FootL = new ModelRenderer(this, "Foot Left");
+// FootL.setTextureOffset(16, 41);
+// FootL.setRotationPoint(0F, 0F, 0F);
+// FootL.addBox(-2F, 10.1F, -3.0F, 4, 2, 1, 0.2F);
+// bipedLeftLeg.addChild(FootL);
+//
+// FootR = new ModelRenderer(this, "Foot Right");
+// FootR.setTextureOffset(16, 41);
+// FootR.setRotationPoint(0F, 0F, 0F);
+// FootR.addBox(-2F, 10.1F, -3.0F, 4, 2, 1, 0.2F);
+// bipedRightLeg.addChild(FootR);
+//
+// OverLegL = new ModelRenderer(this, "Over Leg Left");
+// OverLegL.setTextureOffset(0, 32);
+// OverLegL.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.2F);
+// OverLegL.setRotationPoint(0F, 0F, 0F);
+// bipedLeftLeg.addChild(OverLegL);
+//
+// OverLegR = new ModelRenderer(this, "Over Leg Right");
+// OverLegR.setTextureOffset(0, 32);
+// OverLegR.mirror = true;
+// OverLegR.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.2F);
+// OverLegR.setRotationPoint(0F, 0F, 0F);
+// bipedRightLeg.addChild(OverLegR);
+//
+// ShoeL = new ModelRenderer(this, "Shoe Left");
+// ShoeL.setTextureOffset(16, 32);
+// ShoeL.addBox(-2.0F, 7.0F, -2.0F, 4, 5, 4, 0.21F);
+// ShoeL.setRotationPoint(0F, 0F, 0F);
+// bipedLeftLeg.addChild(ShoeL);
+//
+// ShoeR = new ModelRenderer(this, "Shoe Right");
+// ShoeR.setTextureOffset(16, 32);
+// ShoeR.mirror = true;
+// ShoeR.addBox(-2.0F, 7.0F, -2.0F, 4, 5, 4, 0.21F);
+// ShoeR.setRotationPoint(0F, 0F, 0F);
+// bipedRightLeg.addChild(ShoeR);
+//
+// OverLegL.isHidden = true;
+// OverLegR.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersBreastplate.java b/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersBreastplate.java
index 24ba37a..3ef43ba 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersBreastplate.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersBreastplate.java
@@ -7,7 +7,7 @@ import net.minecraft.client.model.ModelRenderer;
* ModelBiped - Either Mojang or a mod author
* Created using Tabula 4.1.1
*/
-public class ModelTinkersBreastplate extends ArmorRenderer
+public class ModelTinkersBreastplate extends ArmorRenderer
{
public ModelRenderer BackPlate;
public ModelRenderer BreastPlate;
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersGrieves.java b/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersGrieves.java
index 9eccca3..bc76312 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersGrieves.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersGrieves.java
@@ -1,214 +1,214 @@
-package lance5057.tDefense.armor.renderers.heavy;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * TinkersGrieves - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersGrieves extends ArmorRenderer
-{
- public ModelRenderer LegPlateL;
- public ModelRenderer CodPiece;
- public ModelRenderer LegPlateBackL;
- public ModelRenderer LegPlateBackR;
- public ModelRenderer LegPlateR;
- public ModelRenderer Belt;
- public ModelRenderer BeltBuckle;
- public ModelRenderer ThighR;
- public ModelRenderer ThighL;
- public ModelRenderer ThighRB;
- public ModelRenderer ThighLB;
- public ModelRenderer SecBeltR;
- public ModelRenderer SecBeltL;
- public ModelRenderer LeftFrontL;
- public ModelRenderer LeftBackL;
- public ModelRenderer CenterBackL;
- public ModelRenderer CenterBackR;
- public ModelRenderer RightFrontL;
- public ModelRenderer RightBackL;
- public ModelRenderer CenterFrontL;
- public ModelRenderer CenterFrontR;
-
- public ModelTinkersGrieves()
- {
- super(0.1f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- SecBeltL = new ModelRenderer(this, "Hip Belt Left");
- SecBeltL.setTextureOffset(12, 56);
- SecBeltL.setRotationPoint(0.0F, 0.0F, 0.0F);
- SecBeltL.addBox(-1.0F, 11.5F, -2.8F, 9, 2, 6, 0.16F);
- setRotateAngle(SecBeltL, 0.0F, 0.0F, 0.2617993877991494F);
- bipedBody.addChild(SecBeltL);
-
- CodPiece = new ModelRenderer(this, "CodPiece");
- CodPiece.setTextureOffset(0, 49);
- CodPiece.setRotationPoint(0.0F, 0.0F, 0.0F);
- CodPiece.addBox(-2.5F, 11.0F, -3.2F, 5, 5, 3, -0.4F);
- bipedBody.addChild(CodPiece);
-
- ThighL = new ModelRenderer(this, "Thigh Left Front");
- ThighL.setTextureOffset(12, 32);
- ThighL.mirror = true;
- ThighL.setRotationPoint(0.0F, 0.0F, 0.0F);
- ThighL.addBox(-2.0F, 0.0F, -2.5F, 4, 6, 4, 0.2F);
- setRotateAngle(ThighL, 0.08726646259971647F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(ThighL);
-
- ThighLB = new ModelRenderer(this, "Thigh Left Back");
- ThighLB.setTextureOffset(13, 42);
- ThighLB.mirror = true;
- ThighLB.setRotationPoint(0.0F, 0.0F, 0.0F);
- ThighLB.addBox(-2.0F, 0.0F, -1.5F, 4, 6, 4, 0.1F);
- setRotateAngle(ThighLB, -0.08726646259971647F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(ThighLB);
-
- SecBeltR = new ModelRenderer(this, "Hip Belt Right");
- SecBeltR.setTextureOffset(12, 56);
- SecBeltR.setRotationPoint(0.0F, 0.0F, 0.0F);
- SecBeltR.addBox(-8.0F, 11.5F, -2.8F, 9, 2, 6, 0.15F);
- setRotateAngle(SecBeltR, 0.0F, 0.0F, -0.2617993877991494F);
- bipedBody.addChild(SecBeltR);
-
- CenterFrontL = new ModelRenderer(this, "Center Front");
- CenterFrontL.setTextureOffset(29, 43);
- CenterFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
- CenterFrontL.addBox(-2.9F, -0.2F, -2.5F, 2, 11, 2, 0.0F);
- setRotateAngle(CenterFrontL, -0.08726646259971647F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(CenterFrontL);
-
- CenterFrontR = new ModelRenderer(this, "Center Front");
- CenterFrontR.setTextureOffset(29, 43);
- CenterFrontR.setRotationPoint(0.0F, 0.0F, 0.0F);
- CenterFrontR.addBox(0.9F, -0.2F, -2.5F, 2, 11, 2, 0.0F);
- setRotateAngle(CenterFrontR, -0.08726646259971647F, 0.0F, 0.0F);
- bipedRightLeg.addChild(CenterFrontR);
-
- LegPlateBackR = new ModelRenderer(this, "Leg Plate Back Right");
- LegPlateBackR.setTextureOffset(0, 43);
- LegPlateBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
- LegPlateBackR.addBox(-2.0F, 0.1F, 2.1F, 4, 5, 1, 0.0F);
- setRotateAngle(LegPlateBackR, 0.2617993877991494F, 0.0F, 0.0F);
- bipedRightLeg.addChild(LegPlateBackR);
-
- Belt = new ModelRenderer(this, "Belt");
- Belt.setTextureOffset(12, 56);
- Belt.setRotationPoint(0.0F, 0.0F, 0.0F);
- Belt.addBox(-4.5F, 10.0F, -2.8F, 9, 2, 6, 0.25F);
- bipedBody.addChild(Belt);
-
- ThighR = new ModelRenderer(this, "Thigh Right");
- ThighR.setTextureOffset(12, 32);
- ThighR.setRotationPoint(0.0F, 0.0F, 0.0F);
- ThighR.addBox(-2.0F, 0.0F, -2.5F, 4, 6, 4, 0.2F);
- setRotateAngle(ThighR, 0.08726646259971647F, 0.0F, 0.0F);
- bipedRightLeg.addChild(ThighR);
-
- ThighRB = new ModelRenderer(this, "Thigh Right Back");
- ThighRB.setTextureOffset(13, 42);
- ThighRB.setRotationPoint(0.0F, 0.0F, 0.0F);
- ThighRB.addBox(-2.0F, 0.0F, -1.5F, 4, 6, 4, 0.1F);
- setRotateAngle(ThighRB, -0.08726646259971647F, 0.0F, 0.0F);
- bipedRightLeg.addChild(ThighRB);
-
- LegPlateL = new ModelRenderer(this, "Leg Plate Left");
- LegPlateL.setTextureOffset(0, 32);
- LegPlateL.mirror = true;
- LegPlateL.setRotationPoint(0.0F, 0.0F, 0.0F);
- LegPlateL.addBox(1.6F, -0.1F, -2.5F, 1, 5, 5, 0.1F);
- setRotateAngle(LegPlateL, 0.0F, 0.0F, -0.2617993877991494F);
- bipedLeftLeg.addChild(LegPlateL);
-
- RightBackL = new ModelRenderer(this, "Right Back Left");
- RightBackL.setTextureOffset(42, 34);
- RightBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- RightBackL.addBox(-2.2F, -0.3F, -1.5F, 4, 11, 4, 0.0F);
- setRotateAngle(RightBackL, 0.08726646259971647F, 0.0F, 0.08726646259971647F);
- bipedRightLeg.addChild(RightBackL);
-
- LeftBackL = new ModelRenderer(this, "Left Back Left");
- LeftBackL.setTextureOffset(42, 34);
- LeftBackL.mirror = true;
- LeftBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- LeftBackL.addBox(-1.8F, -0.3F, -1.5F, 4, 11, 4, 0.0F);
- setRotateAngle(LeftBackL, 0.08726646259971647F, 0.0F, -0.08726646259971647F);
- bipedLeftLeg.addChild(LeftBackL);
-
- LegPlateR = new ModelRenderer(this, "Leg Plate Right");
- LegPlateR.setTextureOffset(0, 32);
- LegPlateR.setRotationPoint(0.0F, 0.0F, 0.0F);
- LegPlateR.addBox(-2.6F, -0.1F, -2.5F, 1, 5, 5, 0.1F);
- setRotateAngle(LegPlateR, 0.0F, 0.0F, 0.2617993877991494F);
- bipedRightLeg.addChild(LegPlateR);
-
- RightFrontL = new ModelRenderer(this, "Right Front Left");
- RightFrontL.setTextureOffset(42, 49);
- RightFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
- RightFrontL.addBox(-2.2F, -0.3F, -2.5F, 4, 11, 4, 0.0F);
- setRotateAngle(RightFrontL, -0.08726646259971647F, 0.0F, 0.08726646259971647F);
- bipedRightLeg.addChild(RightFrontL);
-
- BeltBuckle = new ModelRenderer(this, "Belt Buckle");
- BeltBuckle.setTextureOffset(0, 58);
- BeltBuckle.setRotationPoint(0.0F, 0.0F, 0.0F);
- BeltBuckle.addBox(-2.0F, 9.0F, -3.5F, 4, 4, 2, -0.3F);
- bipedBody.addChild(BeltBuckle);
-
- LegPlateBackL = new ModelRenderer(this, "Leg Plate Back Left");
- LegPlateBackL.setTextureOffset(0, 43);
- LegPlateBackL.mirror = true;
- LegPlateBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- LegPlateBackL.addBox(-2.0F, 0.1F, 2.1F, 4, 5, 1, 0.0F);
- setRotateAngle(LegPlateBackL, 0.2617993877991494F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(LegPlateBackL);
-
- LeftFrontL = new ModelRenderer(this, "Left Front Left");
- LeftFrontL.setTextureOffset(42, 49);
- LeftFrontL.mirror = true;
- LeftFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
- LeftFrontL.addBox(-1.8F, -0.3F, -2.5F, 4, 11, 4, 0.0F);
- setRotateAngle(LeftFrontL, -0.08726646259971647F, 0.0F, -0.08726646259971647F);
- bipedLeftLeg.addChild(LeftFrontL);
-
- CenterBackL = new ModelRenderer(this, "Center Back Left");
- CenterBackL.setTextureOffset(29, 43);
- CenterBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- CenterBackL.addBox(-2.9F, -0.2F, 0.5F, 2, 11, 2, 0.0F);
- setRotateAngle(CenterBackL, 0.08726646259971647F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(CenterBackL);
-
- CenterBackR = new ModelRenderer(this, "Center Back Right");
- CenterBackR.setTextureOffset(29, 43);
- CenterBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
- CenterBackR.addBox(0.9F, -0.2F, 0.5F, 2, 11, 2, 0.0F);
- setRotateAngle(CenterBackR, 0.08726646259971647F, 0.0F, 0.0F);
- bipedRightLeg.addChild(CenterBackR);
-
- SecBeltL.isHidden = true;
- SecBeltR.isHidden = true;
- CenterBackL.isHidden = true;
- CenterBackR.isHidden = true;
- CenterFrontL.isHidden = true;
- CenterFrontR.isHidden = true;
- LeftBackL.isHidden = true;
- LeftFrontL.isHidden = true;
- RightBackL.isHidden = true;
- RightFrontL.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.heavy;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * TinkersGrieves - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersGrieves extends ArmorRenderer
+//{
+// public ModelRenderer LegPlateL;
+// public ModelRenderer CodPiece;
+// public ModelRenderer LegPlateBackL;
+// public ModelRenderer LegPlateBackR;
+// public ModelRenderer LegPlateR;
+// public ModelRenderer Belt;
+// public ModelRenderer BeltBuckle;
+// public ModelRenderer ThighR;
+// public ModelRenderer ThighL;
+// public ModelRenderer ThighRB;
+// public ModelRenderer ThighLB;
+// public ModelRenderer SecBeltR;
+// public ModelRenderer SecBeltL;
+// public ModelRenderer LeftFrontL;
+// public ModelRenderer LeftBackL;
+// public ModelRenderer CenterBackL;
+// public ModelRenderer CenterBackR;
+// public ModelRenderer RightFrontL;
+// public ModelRenderer RightBackL;
+// public ModelRenderer CenterFrontL;
+// public ModelRenderer CenterFrontR;
+//
+// public ModelTinkersGrieves()
+// {
+// super(0.1f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// SecBeltL = new ModelRenderer(this, "Hip Belt Left");
+// SecBeltL.setTextureOffset(12, 56);
+// SecBeltL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// SecBeltL.addBox(-1.0F, 11.5F, -2.8F, 9, 2, 6, 0.16F);
+// setRotateAngle(SecBeltL, 0.0F, 0.0F, 0.2617993877991494F);
+// bipedBody.addChild(SecBeltL);
+//
+// CodPiece = new ModelRenderer(this, "CodPiece");
+// CodPiece.setTextureOffset(0, 49);
+// CodPiece.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CodPiece.addBox(-2.5F, 11.0F, -3.2F, 5, 5, 3, -0.4F);
+// bipedBody.addChild(CodPiece);
+//
+// ThighL = new ModelRenderer(this, "Thigh Left Front");
+// ThighL.setTextureOffset(12, 32);
+// ThighL.mirror = true;
+// ThighL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ThighL.addBox(-2.0F, 0.0F, -2.5F, 4, 6, 4, 0.2F);
+// setRotateAngle(ThighL, 0.08726646259971647F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(ThighL);
+//
+// ThighLB = new ModelRenderer(this, "Thigh Left Back");
+// ThighLB.setTextureOffset(13, 42);
+// ThighLB.mirror = true;
+// ThighLB.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ThighLB.addBox(-2.0F, 0.0F, -1.5F, 4, 6, 4, 0.1F);
+// setRotateAngle(ThighLB, -0.08726646259971647F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(ThighLB);
+//
+// SecBeltR = new ModelRenderer(this, "Hip Belt Right");
+// SecBeltR.setTextureOffset(12, 56);
+// SecBeltR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// SecBeltR.addBox(-8.0F, 11.5F, -2.8F, 9, 2, 6, 0.15F);
+// setRotateAngle(SecBeltR, 0.0F, 0.0F, -0.2617993877991494F);
+// bipedBody.addChild(SecBeltR);
+//
+// CenterFrontL = new ModelRenderer(this, "Center Front");
+// CenterFrontL.setTextureOffset(29, 43);
+// CenterFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CenterFrontL.addBox(-2.9F, -0.2F, -2.5F, 2, 11, 2, 0.0F);
+// setRotateAngle(CenterFrontL, -0.08726646259971647F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(CenterFrontL);
+//
+// CenterFrontR = new ModelRenderer(this, "Center Front");
+// CenterFrontR.setTextureOffset(29, 43);
+// CenterFrontR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CenterFrontR.addBox(0.9F, -0.2F, -2.5F, 2, 11, 2, 0.0F);
+// setRotateAngle(CenterFrontR, -0.08726646259971647F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(CenterFrontR);
+//
+// LegPlateBackR = new ModelRenderer(this, "Leg Plate Back Right");
+// LegPlateBackR.setTextureOffset(0, 43);
+// LegPlateBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LegPlateBackR.addBox(-2.0F, 0.1F, 2.1F, 4, 5, 1, 0.0F);
+// setRotateAngle(LegPlateBackR, 0.2617993877991494F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(LegPlateBackR);
+//
+// Belt = new ModelRenderer(this, "Belt");
+// Belt.setTextureOffset(12, 56);
+// Belt.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Belt.addBox(-4.5F, 10.0F, -2.8F, 9, 2, 6, 0.25F);
+// bipedBody.addChild(Belt);
+//
+// ThighR = new ModelRenderer(this, "Thigh Right");
+// ThighR.setTextureOffset(12, 32);
+// ThighR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ThighR.addBox(-2.0F, 0.0F, -2.5F, 4, 6, 4, 0.2F);
+// setRotateAngle(ThighR, 0.08726646259971647F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(ThighR);
+//
+// ThighRB = new ModelRenderer(this, "Thigh Right Back");
+// ThighRB.setTextureOffset(13, 42);
+// ThighRB.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ThighRB.addBox(-2.0F, 0.0F, -1.5F, 4, 6, 4, 0.1F);
+// setRotateAngle(ThighRB, -0.08726646259971647F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(ThighRB);
+//
+// LegPlateL = new ModelRenderer(this, "Leg Plate Left");
+// LegPlateL.setTextureOffset(0, 32);
+// LegPlateL.mirror = true;
+// LegPlateL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LegPlateL.addBox(1.6F, -0.1F, -2.5F, 1, 5, 5, 0.1F);
+// setRotateAngle(LegPlateL, 0.0F, 0.0F, -0.2617993877991494F);
+// bipedLeftLeg.addChild(LegPlateL);
+//
+// RightBackL = new ModelRenderer(this, "Right Back Left");
+// RightBackL.setTextureOffset(42, 34);
+// RightBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// RightBackL.addBox(-2.2F, -0.3F, -1.5F, 4, 11, 4, 0.0F);
+// setRotateAngle(RightBackL, 0.08726646259971647F, 0.0F, 0.08726646259971647F);
+// bipedRightLeg.addChild(RightBackL);
+//
+// LeftBackL = new ModelRenderer(this, "Left Back Left");
+// LeftBackL.setTextureOffset(42, 34);
+// LeftBackL.mirror = true;
+// LeftBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LeftBackL.addBox(-1.8F, -0.3F, -1.5F, 4, 11, 4, 0.0F);
+// setRotateAngle(LeftBackL, 0.08726646259971647F, 0.0F, -0.08726646259971647F);
+// bipedLeftLeg.addChild(LeftBackL);
+//
+// LegPlateR = new ModelRenderer(this, "Leg Plate Right");
+// LegPlateR.setTextureOffset(0, 32);
+// LegPlateR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LegPlateR.addBox(-2.6F, -0.1F, -2.5F, 1, 5, 5, 0.1F);
+// setRotateAngle(LegPlateR, 0.0F, 0.0F, 0.2617993877991494F);
+// bipedRightLeg.addChild(LegPlateR);
+//
+// RightFrontL = new ModelRenderer(this, "Right Front Left");
+// RightFrontL.setTextureOffset(42, 49);
+// RightFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// RightFrontL.addBox(-2.2F, -0.3F, -2.5F, 4, 11, 4, 0.0F);
+// setRotateAngle(RightFrontL, -0.08726646259971647F, 0.0F, 0.08726646259971647F);
+// bipedRightLeg.addChild(RightFrontL);
+//
+// BeltBuckle = new ModelRenderer(this, "Belt Buckle");
+// BeltBuckle.setTextureOffset(0, 58);
+// BeltBuckle.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BeltBuckle.addBox(-2.0F, 9.0F, -3.5F, 4, 4, 2, -0.3F);
+// bipedBody.addChild(BeltBuckle);
+//
+// LegPlateBackL = new ModelRenderer(this, "Leg Plate Back Left");
+// LegPlateBackL.setTextureOffset(0, 43);
+// LegPlateBackL.mirror = true;
+// LegPlateBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LegPlateBackL.addBox(-2.0F, 0.1F, 2.1F, 4, 5, 1, 0.0F);
+// setRotateAngle(LegPlateBackL, 0.2617993877991494F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(LegPlateBackL);
+//
+// LeftFrontL = new ModelRenderer(this, "Left Front Left");
+// LeftFrontL.setTextureOffset(42, 49);
+// LeftFrontL.mirror = true;
+// LeftFrontL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LeftFrontL.addBox(-1.8F, -0.3F, -2.5F, 4, 11, 4, 0.0F);
+// setRotateAngle(LeftFrontL, -0.08726646259971647F, 0.0F, -0.08726646259971647F);
+// bipedLeftLeg.addChild(LeftFrontL);
+//
+// CenterBackL = new ModelRenderer(this, "Center Back Left");
+// CenterBackL.setTextureOffset(29, 43);
+// CenterBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CenterBackL.addBox(-2.9F, -0.2F, 0.5F, 2, 11, 2, 0.0F);
+// setRotateAngle(CenterBackL, 0.08726646259971647F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(CenterBackL);
+//
+// CenterBackR = new ModelRenderer(this, "Center Back Right");
+// CenterBackR.setTextureOffset(29, 43);
+// CenterBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// CenterBackR.addBox(0.9F, -0.2F, 0.5F, 2, 11, 2, 0.0F);
+// setRotateAngle(CenterBackR, 0.08726646259971647F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(CenterBackR);
+//
+// SecBeltL.isHidden = true;
+// SecBeltR.isHidden = true;
+// CenterBackL.isHidden = true;
+// CenterBackR.isHidden = true;
+// CenterFrontL.isHidden = true;
+// CenterFrontR.isHidden = true;
+// LeftBackL.isHidden = true;
+// LeftFrontL.isHidden = true;
+// RightBackL.isHidden = true;
+// RightFrontL.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersHelm.java b/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersHelm.java
index 0238b75..5276f2e 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersHelm.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersHelm.java
@@ -1,235 +1,235 @@
-package lance5057.tDefense.armor.renderers.heavy;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * TinkerHelm - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersHelm extends ArmorRenderer
-{
- public ModelRenderer Visor;
- public ModelRenderer Helm2;
- public ModelRenderer WingR;
- public ModelRenderer WingL;
- public ModelRenderer Helm;
- public ModelRenderer Trim;
- public ModelRenderer HornR;
- public ModelRenderer HornL;
- public ModelRenderer HornTipR;
- public ModelRenderer HornTipL;
- public ModelRenderer FeatherRod;
- public ModelRenderer Feathers;
- public ModelRenderer FeatherBase;
- public ModelRenderer HornR_1;
- public ModelRenderer HornL_1;
- public ModelRenderer HornTipR_1;
- public ModelRenderer HornTipL_1;
- public ModelRenderer HornR_2;
- public ModelRenderer HornL_2;
- public ModelRenderer HornTipR_2;
- public ModelRenderer HornTipL_2;
- public ModelRenderer SpikeBase;
- public ModelRenderer Spike2;
- public ModelRenderer Spike1;
-
- public ModelTinkersHelm()
- {
- super(0.1f, 0, 128, 64);
-
- textureWidth = 128;
- textureHeight = 64;
-
- HornR = new ModelRenderer(this, "Horn Right");
- HornR.setTextureOffset(26, 32);
- HornR.setRotationPoint(0.0F, -2.0F, 0.0F);
- HornR.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
- setRotateAngle(HornR, 0.0F, 0.0F, 0.7853981633974483F);
- bipedHead.addChild(HornR);
-
- HornTipR = new ModelRenderer(this, "Horn Tip Right");
- HornTipR.setTextureOffset(26, 32);
- HornTipR.setRotationPoint(0.0F, -10.0F, 0.0F);
- HornTipR.addBox(-0.8F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
- setRotateAngle(HornTipR, 0.0F, 0.0F, 2.007128639793479F);
-
- HornR_1 = new ModelRenderer(this, "Horn Right 2");
- HornR_1.setTextureOffset(26, 32);
- HornR_1.setRotationPoint(2.25F, -6.0F, 2.0F);
- HornR_1.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
- setRotateAngle(HornR_1, 1.3962634015954636F, 0.2617993877991494F, 1.5707963267948966F);
- bipedHead.addChild(HornR_1);
-
- HornTipR_1 = new ModelRenderer(this, "Horn Tip Right 2");
- HornTipR_1.setTextureOffset(26, 32);
- HornTipR_1.setRotationPoint(0.0F, -10.0F, 0.0F);
- HornTipR_1.addBox(-0.8F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
- setRotateAngle(HornTipR_1, 0.0F, 0.0F, 2.007128639793479F);
-
- HornR_2 = new ModelRenderer(this, "Horn Right 3");
- HornR_2.setTextureOffset(26, 32);
- HornR_2.setRotationPoint(1.75F, -3.0F, 4.0F);
- HornR_2.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
- setRotateAngle(HornR_2, 1.3962634015954636F, -0.2617993877991494F, 1.5707963267948966F);
- bipedHead.addChild(HornR_2);
-
- HornTipR_2 = new ModelRenderer(this, "Horn Tip Right 3");
- HornTipR_2.setTextureOffset(26, 32);
- HornTipR_2.setRotationPoint(0.0F, -10.0F, 0.0F);
- HornTipR_2.addBox(-0.8F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
- setRotateAngle(HornTipR_2, 0.0F, 0.0F, 2.007128639793479F);
-
- HornL = new ModelRenderer(this, "Horn Left");
- HornL.setTextureOffset(26, 32);
- HornL.setRotationPoint(0.0F, -2.0F, 0.0F);
- HornL.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
- setRotateAngle(HornL, 0.0F, 0.0F, -0.7853981633974483F);
- bipedHead.addChild(HornL);
-
- HornTipL = new ModelRenderer(this, "Horn Tip Left");
- HornTipL.setTextureOffset(26, 32);
- HornTipL.setRotationPoint(0.0F, -10.0F, 0.0F);
- HornTipL.addBox(-1.2F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
- setRotateAngle(HornTipL, 0.0F, 0.0F, -2.007128639793479F);
-
- HornL_1 = new ModelRenderer(this, "Horn Left 2");
- HornL_1.setTextureOffset(26, 32);
- HornL_1.setRotationPoint(-2.25F, -6.0F, 2.0F);
- HornL_1.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
- setRotateAngle(HornL_1, 1.3962634015954636F, -0.2617993877991494F, -1.5707963267948966F);
- bipedHead.addChild(HornL_1);
-
- HornTipL_1 = new ModelRenderer(this, "Horn Tip Left 2");
- HornTipL_1.setTextureOffset(26, 32);
- HornTipL_1.setRotationPoint(0.0F, -10.0F, 0.0F);
- HornTipL_1.addBox(-1.2F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
- setRotateAngle(HornTipL_1, 0.0F, 0.0F, -2.007128639793479F);
-
- HornL_2 = new ModelRenderer(this, "Horn Left 3");
- HornL_2.setTextureOffset(26, 32);
- HornL_2.setRotationPoint(-1.75F, -3.0F, 4.0F);
- HornL_2.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
- setRotateAngle(HornL_2, 1.3962634015954636F, 0.2617993877991494F, -1.5707963267948966F);
- bipedHead.addChild(HornL_2);
-
- HornTipL_2 = new ModelRenderer(this, "Horn Tip Left 3");
- HornTipL_2.setTextureOffset(26, 32);
- HornTipL_2.setRotationPoint(0.0F, -10.0F, 0.0F);
- HornTipL_2.addBox(-1.2F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
- setRotateAngle(HornTipL_2, 0.0F, 0.0F, -2.007128639793479F);
-
- FeatherBase = new ModelRenderer(this, "Feather Base");
- FeatherBase.setTextureOffset(64, 13);
- FeatherBase.setRotationPoint(0.0F, 0.0F, 0.0F);
- FeatherBase.addBox(-2.0F, -10.0F, -5.3F, 4, 1, 9, 0.0F);
- setRotateAngle(FeatherBase, -0.08726646259971647F, 0.0F, 0.0F);
- bipedHead.addChild(FeatherBase);
-
- WingL = new ModelRenderer(this, "Wing Left");
- WingL.setTextureOffset(0, 44);
- WingL.setRotationPoint(0.0F, 0.0F, 0.0F);
- WingL.addBox(5.7F, -11.0F, -3.5F, 0, 12, 8, 0.0F);
- setRotateAngle(WingL, 0.0F, 0.2617993877991494F, 0.0F);
- bipedHead.addChild(WingL);
-
- Trim = new ModelRenderer(this, "Trim");
- Trim.setTextureOffset(64, 23);
- Trim.setRotationPoint(0.0F, 0.0F, 0.0F);
- Trim.addBox(-1.0F, -8.3F, -4.0F, 2, 9, 8, 0.7F);
- bipedHead.addChild(Trim);
-
- Visor = new ModelRenderer(this, "Visor");
- Visor.setTextureOffset(0, 32);
- Visor.setRotationPoint(0.0F, 0.0F, 0.0F);
- Visor.addBox(-4.5F, -9.5F, -4.7F, 9, 12, 8, 0.1F);
- bipedHead.addChild(Visor);
-
- Feathers = new ModelRenderer(this, "Feathers");
- Feathers.setTextureOffset(64, 0);
- Feathers.setRotationPoint(0.0F, 0.0F, 0.0F);
- Feathers.addBox(-2.0F, -12.7F, -6.1F, 4, 4, 9, -0.3F);
- setRotateAngle(Feathers, -0.17453292519943295F, 0.0F, 0.0F);
- bipedHead.addChild(Feathers);
-
- FeatherRod = new ModelRenderer(this, "Feather Rod");
- FeatherRod.setTextureOffset(0, 32);
- FeatherRod.setRotationPoint(0.0F, 0.0F, 0.0F);
- FeatherRod.addBox(-1.0F, -9.3F, -1.2F, 2, 1, 2, 0.2F);
- bipedHead.addChild(FeatherRod);
-
- Helm2 = new ModelRenderer(this, "Heavy Visor");
- Helm2.setTextureOffset(34, 32);
- Helm2.setRotationPoint(0.0F, 0.0F, 0.0F);
- Helm2.addBox(-4.0F, -9.0F, -4.0F, 8, 10, 8, 0.6F);
- bipedHead.addChild(Helm2);
-
- Spike1 = new ModelRenderer(this, "Spike");
- Spike1.setTextureOffset(16, 52);
- Spike1.setRotationPoint(0.0F, 0.0F, 0.0F);
- Spike1.addBox(-2.5F, -14.0F, 0.0F, 5, 5, 0, 0.0F);
- bipedHead.addChild(Spike1);
-
- SpikeBase = new ModelRenderer(this, "Spike Base");
- SpikeBase.setTextureOffset(66, 40);
- SpikeBase.setRotationPoint(0.0F, 0.0F, 0.0F);
- SpikeBase.addBox(-2.0F, -8.6F, -2.0F, 4, 1, 4, 0.5F);
- bipedHead.addChild(SpikeBase);
-
- Spike2 = new ModelRenderer(this, "Spike");
- Spike2.setTextureOffset(16, 47);
- Spike2.setRotationPoint(0.0F, 0.0F, 0.0F);
- Spike2.addBox(0.0F, -14.0F, -2.5F, 0, 5, 5, 0.0F);
- bipedHead.addChild(Spike2);
-
- Helm = new ModelRenderer(this, "Helm");
- Helm.setTextureOffset(64, 47);
- Helm.setRotationPoint(0.0F, 0.0F, 0.0F);
- Helm.addBox(-4.0F, -8.0F, -4.0F, 8, 9, 8, 0.5F);
- bipedHead.addChild(Helm);
-
- WingR = new ModelRenderer(this, "Wing Right");
- WingR.setTextureOffset(0, 44);
- WingR.setRotationPoint(0.0F, 0.0F, 0.0F);
- WingR.addBox(-5.7F, -11.0F, -3.5F, 0, 12, 8, 0.0F);
- setRotateAngle(WingR, 0.0F, -0.2617993877991494F, 0.0F);
- bipedHead.addChild(WingR);
-
- HornR.addChild(HornTipR);
- HornL.addChild(HornTipL);
-
- HornL_1.addChild(HornTipL_1);
- HornR_1.addChild(HornTipR_1);
-
- HornL_2.addChild(HornTipL_2);
- HornR_2.addChild(HornTipR_2);
-
- HornL.isHidden = true;
- HornR.isHidden = true;
- HornL_1.isHidden = true;
- HornL_2.isHidden = true;
- HornR_1.isHidden = true;
- HornR_2.isHidden = true;
- FeatherBase.isHidden = true;
- FeatherRod.isHidden = true;
- Feathers.isHidden = true;
- Spike1.isHidden = true;
- Spike2.isHidden = true;
- SpikeBase.isHidden = true;
- WingL.isHidden = true;
- WingR.isHidden = true;
- Helm2.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.heavy;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * TinkerHelm - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersHelm extends ArmorRenderer
+//{
+// public ModelRenderer Visor;
+// public ModelRenderer Helm2;
+// public ModelRenderer WingR;
+// public ModelRenderer WingL;
+// public ModelRenderer Helm;
+// public ModelRenderer Trim;
+// public ModelRenderer HornR;
+// public ModelRenderer HornL;
+// public ModelRenderer HornTipR;
+// public ModelRenderer HornTipL;
+// public ModelRenderer FeatherRod;
+// public ModelRenderer Feathers;
+// public ModelRenderer FeatherBase;
+// public ModelRenderer HornR_1;
+// public ModelRenderer HornL_1;
+// public ModelRenderer HornTipR_1;
+// public ModelRenderer HornTipL_1;
+// public ModelRenderer HornR_2;
+// public ModelRenderer HornL_2;
+// public ModelRenderer HornTipR_2;
+// public ModelRenderer HornTipL_2;
+// public ModelRenderer SpikeBase;
+// public ModelRenderer Spike2;
+// public ModelRenderer Spike1;
+//
+// public ModelTinkersHelm()
+// {
+// super(0.1f, 0, 128, 64);
+//
+// textureWidth = 128;
+// textureHeight = 64;
+//
+// HornR = new ModelRenderer(this, "Horn Right");
+// HornR.setTextureOffset(26, 32);
+// HornR.setRotationPoint(0.0F, -2.0F, 0.0F);
+// HornR.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
+// setRotateAngle(HornR, 0.0F, 0.0F, 0.7853981633974483F);
+// bipedHead.addChild(HornR);
+//
+// HornTipR = new ModelRenderer(this, "Horn Tip Right");
+// HornTipR.setTextureOffset(26, 32);
+// HornTipR.setRotationPoint(0.0F, -10.0F, 0.0F);
+// HornTipR.addBox(-0.8F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
+// setRotateAngle(HornTipR, 0.0F, 0.0F, 2.007128639793479F);
+//
+// HornR_1 = new ModelRenderer(this, "Horn Right 2");
+// HornR_1.setTextureOffset(26, 32);
+// HornR_1.setRotationPoint(2.25F, -6.0F, 2.0F);
+// HornR_1.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
+// setRotateAngle(HornR_1, 1.3962634015954636F, 0.2617993877991494F, 1.5707963267948966F);
+// bipedHead.addChild(HornR_1);
+//
+// HornTipR_1 = new ModelRenderer(this, "Horn Tip Right 2");
+// HornTipR_1.setTextureOffset(26, 32);
+// HornTipR_1.setRotationPoint(0.0F, -10.0F, 0.0F);
+// HornTipR_1.addBox(-0.8F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
+// setRotateAngle(HornTipR_1, 0.0F, 0.0F, 2.007128639793479F);
+//
+// HornR_2 = new ModelRenderer(this, "Horn Right 3");
+// HornR_2.setTextureOffset(26, 32);
+// HornR_2.setRotationPoint(1.75F, -3.0F, 4.0F);
+// HornR_2.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
+// setRotateAngle(HornR_2, 1.3962634015954636F, -0.2617993877991494F, 1.5707963267948966F);
+// bipedHead.addChild(HornR_2);
+//
+// HornTipR_2 = new ModelRenderer(this, "Horn Tip Right 3");
+// HornTipR_2.setTextureOffset(26, 32);
+// HornTipR_2.setRotationPoint(0.0F, -10.0F, 0.0F);
+// HornTipR_2.addBox(-0.8F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
+// setRotateAngle(HornTipR_2, 0.0F, 0.0F, 2.007128639793479F);
+//
+// HornL = new ModelRenderer(this, "Horn Left");
+// HornL.setTextureOffset(26, 32);
+// HornL.setRotationPoint(0.0F, -2.0F, 0.0F);
+// HornL.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
+// setRotateAngle(HornL, 0.0F, 0.0F, -0.7853981633974483F);
+// bipedHead.addChild(HornL);
+//
+// HornTipL = new ModelRenderer(this, "Horn Tip Left");
+// HornTipL.setTextureOffset(26, 32);
+// HornTipL.setRotationPoint(0.0F, -10.0F, 0.0F);
+// HornTipL.addBox(-1.2F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
+// setRotateAngle(HornTipL, 0.0F, 0.0F, -2.007128639793479F);
+//
+// HornL_1 = new ModelRenderer(this, "Horn Left 2");
+// HornL_1.setTextureOffset(26, 32);
+// HornL_1.setRotationPoint(-2.25F, -6.0F, 2.0F);
+// HornL_1.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
+// setRotateAngle(HornL_1, 1.3962634015954636F, -0.2617993877991494F, -1.5707963267948966F);
+// bipedHead.addChild(HornL_1);
+//
+// HornTipL_1 = new ModelRenderer(this, "Horn Tip Left 2");
+// HornTipL_1.setTextureOffset(26, 32);
+// HornTipL_1.setRotationPoint(0.0F, -10.0F, 0.0F);
+// HornTipL_1.addBox(-1.2F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
+// setRotateAngle(HornTipL_1, 0.0F, 0.0F, -2.007128639793479F);
+//
+// HornL_2 = new ModelRenderer(this, "Horn Left 3");
+// HornL_2.setTextureOffset(26, 32);
+// HornL_2.setRotationPoint(-1.75F, -3.0F, 4.0F);
+// HornL_2.addBox(-1.0F, -10.0F, -1.0F, 2, 5, 2, 0.25F);
+// setRotateAngle(HornL_2, 1.3962634015954636F, 0.2617993877991494F, -1.5707963267948966F);
+// bipedHead.addChild(HornL_2);
+//
+// HornTipL_2 = new ModelRenderer(this, "Horn Tip Left 3");
+// HornTipL_2.setTextureOffset(26, 32);
+// HornTipL_2.setRotationPoint(0.0F, -10.0F, 0.0F);
+// HornTipL_2.addBox(-1.2F, -1.0F, -1.0F, 2, 6, 2, 0.0F);
+// setRotateAngle(HornTipL_2, 0.0F, 0.0F, -2.007128639793479F);
+//
+// FeatherBase = new ModelRenderer(this, "Feather Base");
+// FeatherBase.setTextureOffset(64, 13);
+// FeatherBase.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FeatherBase.addBox(-2.0F, -10.0F, -5.3F, 4, 1, 9, 0.0F);
+// setRotateAngle(FeatherBase, -0.08726646259971647F, 0.0F, 0.0F);
+// bipedHead.addChild(FeatherBase);
+//
+// WingL = new ModelRenderer(this, "Wing Left");
+// WingL.setTextureOffset(0, 44);
+// WingL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// WingL.addBox(5.7F, -11.0F, -3.5F, 0, 12, 8, 0.0F);
+// setRotateAngle(WingL, 0.0F, 0.2617993877991494F, 0.0F);
+// bipedHead.addChild(WingL);
+//
+// Trim = new ModelRenderer(this, "Trim");
+// Trim.setTextureOffset(64, 23);
+// Trim.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Trim.addBox(-1.0F, -8.3F, -4.0F, 2, 9, 8, 0.7F);
+// bipedHead.addChild(Trim);
+//
+// Visor = new ModelRenderer(this, "Visor");
+// Visor.setTextureOffset(0, 32);
+// Visor.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Visor.addBox(-4.5F, -9.5F, -4.7F, 9, 12, 8, 0.1F);
+// bipedHead.addChild(Visor);
+//
+// Feathers = new ModelRenderer(this, "Feathers");
+// Feathers.setTextureOffset(64, 0);
+// Feathers.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Feathers.addBox(-2.0F, -12.7F, -6.1F, 4, 4, 9, -0.3F);
+// setRotateAngle(Feathers, -0.17453292519943295F, 0.0F, 0.0F);
+// bipedHead.addChild(Feathers);
+//
+// FeatherRod = new ModelRenderer(this, "Feather Rod");
+// FeatherRod.setTextureOffset(0, 32);
+// FeatherRod.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FeatherRod.addBox(-1.0F, -9.3F, -1.2F, 2, 1, 2, 0.2F);
+// bipedHead.addChild(FeatherRod);
+//
+// Helm2 = new ModelRenderer(this, "Heavy Visor");
+// Helm2.setTextureOffset(34, 32);
+// Helm2.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Helm2.addBox(-4.0F, -9.0F, -4.0F, 8, 10, 8, 0.6F);
+// bipedHead.addChild(Helm2);
+//
+// Spike1 = new ModelRenderer(this, "Spike");
+// Spike1.setTextureOffset(16, 52);
+// Spike1.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Spike1.addBox(-2.5F, -14.0F, 0.0F, 5, 5, 0, 0.0F);
+// bipedHead.addChild(Spike1);
+//
+// SpikeBase = new ModelRenderer(this, "Spike Base");
+// SpikeBase.setTextureOffset(66, 40);
+// SpikeBase.setRotationPoint(0.0F, 0.0F, 0.0F);
+// SpikeBase.addBox(-2.0F, -8.6F, -2.0F, 4, 1, 4, 0.5F);
+// bipedHead.addChild(SpikeBase);
+//
+// Spike2 = new ModelRenderer(this, "Spike");
+// Spike2.setTextureOffset(16, 47);
+// Spike2.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Spike2.addBox(0.0F, -14.0F, -2.5F, 0, 5, 5, 0.0F);
+// bipedHead.addChild(Spike2);
+//
+// Helm = new ModelRenderer(this, "Helm");
+// Helm.setTextureOffset(64, 47);
+// Helm.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Helm.addBox(-4.0F, -8.0F, -4.0F, 8, 9, 8, 0.5F);
+// bipedHead.addChild(Helm);
+//
+// WingR = new ModelRenderer(this, "Wing Right");
+// WingR.setTextureOffset(0, 44);
+// WingR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// WingR.addBox(-5.7F, -11.0F, -3.5F, 0, 12, 8, 0.0F);
+// setRotateAngle(WingR, 0.0F, -0.2617993877991494F, 0.0F);
+// bipedHead.addChild(WingR);
+//
+// HornR.addChild(HornTipR);
+// HornL.addChild(HornTipL);
+//
+// HornL_1.addChild(HornTipL_1);
+// HornR_1.addChild(HornTipR_1);
+//
+// HornL_2.addChild(HornTipL_2);
+// HornR_2.addChild(HornTipR_2);
+//
+// HornL.isHidden = true;
+// HornR.isHidden = true;
+// HornL_1.isHidden = true;
+// HornL_2.isHidden = true;
+// HornR_1.isHidden = true;
+// HornR_2.isHidden = true;
+// FeatherBase.isHidden = true;
+// FeatherRod.isHidden = true;
+// Feathers.isHidden = true;
+// Spike1.isHidden = true;
+// Spike2.isHidden = true;
+// SpikeBase.isHidden = true;
+// WingL.isHidden = true;
+// WingR.isHidden = true;
+// Helm2.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersSabatons.java b/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersSabatons.java
index bb88643..702e7d1 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersSabatons.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/heavy/ModelTinkersSabatons.java
@@ -1,188 +1,188 @@
-package lance5057.tDefense.armor.renderers.heavy;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * TinkersSabatons - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersSabatons extends ArmorRenderer
-{
- public ModelRenderer BootL;
- public ModelRenderer FlairBackR;
- public ModelRenderer ShinGuardL;
- public ModelRenderer KneeGuardCapL;
- public ModelRenderer LegBackL;
- public ModelRenderer BootR;
- public ModelRenderer ShinGuardR;
- public ModelRenderer BootCapR;
- public ModelRenderer BootCapL;
- public ModelRenderer LegBackR;
- public ModelRenderer FlairL;
- public ModelRenderer KneeGuardCapR;
- public ModelRenderer BootTipR;
- public ModelRenderer BootTipL;
- public ModelRenderer KneeGuardR;
- public ModelRenderer KneeGuardL;
- public ModelRenderer FlairR;
- public ModelRenderer BackFlairL;
-
- public ModelTinkersSabatons()
- {
- super(0.1f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- BootR = new ModelRenderer(this, "Boot Right");
- BootR.setTextureOffset(0, 56);
- BootR.setRotationPoint(0.0F, 0.0F, 0.0F);
- BootR.addBox(-2.0F, 9.0F, -3.0F, 4, 3, 5, 0.2F);
- bipedRightLeg.addChild(BootR);
-
- BootL = new ModelRenderer(this, "Boot Left");
- BootL.setTextureOffset(0, 56);
- BootL.mirror = true;
- BootL.setRotationPoint(0.0F, 0.0F, 0.0F);
- BootL.addBox(-2.0F, 9.0F, -3.0F, 4, 3, 5, 0.2F);
- bipedLeftLeg.addChild(BootL);
-
- KneeGuardR = new ModelRenderer(this, "Knee Guard Right");
- KneeGuardR.setTextureOffset(0, 32);
- KneeGuardR.setRotationPoint(0.0F, 0.0F, 0.0F);
- KneeGuardR.addBox(-2.0F, 3.1F, -2.5F, 4, 3, 4, 0.3F);
- bipedRightLeg.addChild(KneeGuardR);
-
- KneeGuardL = new ModelRenderer(this, "Knee Guard Left");
- KneeGuardL.setTextureOffset(0, 32);
- KneeGuardL.mirror = true;
- KneeGuardL.setRotationPoint(0.0F, 0.0F, 0.0F);
- KneeGuardL.addBox(-2.0F, 3.1F, -2.5F, 4, 3, 4, 0.3F);
- bipedLeftLeg.addChild(KneeGuardL);
-
- ShinGuardR = new ModelRenderer(this, "Shin Guard Right");
- ShinGuardR.setTextureOffset(0, 48);
- ShinGuardR.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShinGuardR.addBox(-2.0F, 4.0F, -2.5F, 4, 5, 3, 0.11F);
- setRotateAngle(ShinGuardR, 0.05759586531581287F, 0.0F, 0.0F);
- bipedRightLeg.addChild(ShinGuardR);
-
- ShinGuardL = new ModelRenderer(this, "Shin Guard Left");
- ShinGuardL.setTextureOffset(0, 48);
- ShinGuardL.mirror = true;
- ShinGuardL.setRotationPoint(0.0F, 0.0F, 0.0F);
- ShinGuardL.addBox(-2.0F, 4.0F, -2.5F, 4, 5, 3, 0.11F);
- setRotateAngle(ShinGuardL, 0.05759586531581287F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(ShinGuardL);
-
- LegBackL = new ModelRenderer(this, "Leg Back Left");
- LegBackL.setTextureOffset(0, 40);
- LegBackL.mirror = true;
- LegBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
- LegBackL.addBox(-2.0F, 3.0F, 0.6F, 4, 6, 2, 0.1F);
- setRotateAngle(LegBackL, -0.05759586531581287F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(LegBackL);
-
- LegBackR = new ModelRenderer(this, "Leg Back Right");
- LegBackR.setTextureOffset(0, 40);
- LegBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
- LegBackR.addBox(-2.0F, 3.0F, 0.6F, 4, 6, 2, 0.1F);
- setRotateAngle(LegBackR, -0.05759586531581287F, 0.0F, 0.0F);
- bipedRightLeg.addChild(LegBackR);
-
- FlairR = new ModelRenderer(this, "Flair Right");
- FlairR.setTextureOffset(18, 53);
- FlairR.setRotationPoint(0.0F, 0.0F, 0.0F);
- FlairR.addBox(0.9F, 0.2F, -2.5F, 5, 11, 0, 0.0F);
- setRotateAngle(FlairR, 0.0F, -0.6108652381980153F, 0.0F);
- bipedLeftLeg.addChild(FlairR);
-
- FlairL = new ModelRenderer(this, "Flair Left");
- FlairL.setTextureOffset(18, 53);
- FlairL.mirror = true;
- FlairL.setRotationPoint(0.0F, 0.0F, 0.0F);
- FlairL.addBox(-5.9F, 0.2F, -2.5F, 5, 11, 0, 0.0F);
- setRotateAngle(FlairL, 0.0F, 0.6108652381980153F, 0.0F);
- bipedRightLeg.addChild(FlairL);
-
- FlairBackR = new ModelRenderer(this, "Flair Back Right");
- FlairBackR.setTextureOffset(28, 47);
- FlairBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
- FlairBackR.addBox(0.0F, 0.0F, 2.0F, 0, 12, 5, 0.0F);
- bipedRightLeg.addChild(FlairBackR);
-
- BackFlairL = new ModelRenderer(this, "Flair Back Left");
- BackFlairL.setTextureOffset(28, 47);
- BackFlairL.mirror = true;
- BackFlairL.setRotationPoint(0.0F, 0.0F, 0.0F);
- BackFlairL.addBox(0.0F, 0.0F, 2.0F, 0, 12, 5, 0.0F);
- bipedLeftLeg.addChild(BackFlairL);
-
- KneeGuardCapR = new ModelRenderer(this, "Knee Guard Cap Right");
- KneeGuardCapR.setTextureOffset(16, 36);
- KneeGuardCapR.setRotationPoint(0.0F, 0.0F, 0.0F);
- KneeGuardCapR.addBox(-1.5F, 2.4F, -3.8F, 3, 2, 1, 0.2F);
- setRotateAngle(KneeGuardCapR, 0.17453292519943295F, 0.0F, 0.0F);
- bipedRightLeg.addChild(KneeGuardCapR);
-
- KneeGuardCapL = new ModelRenderer(this, "Knee Guard Cap Left");
- KneeGuardCapL.setTextureOffset(16, 36);
- KneeGuardCapL.mirror = true;
- KneeGuardCapL.setRotationPoint(0.0F, 0.0F, 0.0F);
- KneeGuardCapL.addBox(-1.5F, 2.4F, -3.8F, 3, 2, 1, 0.2F);
- setRotateAngle(KneeGuardCapL, 0.17453292519943295F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(KneeGuardCapL);
-
- BootTipR = new ModelRenderer(this, "Boot Tip Right");
- BootTipR.setTextureOffset(22, 32);
- BootTipR.setRotationPoint(0.0F, 0.0F, 0.0F);
- BootTipR.addBox(-1.4F, 10.0F, -2.5F, 3, 2, 2, -0.1F);
- setRotateAngle(BootTipR, -0.3490658503988659F, 0.0F, 0.0F);
- bipedRightLeg.addChild(BootTipR);
-
- BootCapR = new ModelRenderer(this, "Boot Cap Right");
- BootCapR.setTextureOffset(12, 32);
- BootCapR.setRotationPoint(0.0F, 0.0F, 0.0F);
- BootCapR.addBox(-1.5F, 10.0F, -2.5F, 3, 2, 2, 0.3F);
- setRotateAngle(BootCapR, -0.17453292519943295F, 0.0F, 0.0F);
- bipedRightLeg.addChild(BootCapR);
-
- BootTipL = new ModelRenderer(this, "Boot Tip Left");
- BootTipL.setTextureOffset(22, 32);
- BootTipL.mirror = true;
- BootTipL.setRotationPoint(0.0F, 0.0F, 0.0F);
- BootTipL.addBox(-1.5F, 10.0F, -2.6F, 3, 2, 2, -0.1F);
- setRotateAngle(BootTipL, -0.3490658503988659F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(BootTipL);
-
- BootCapL = new ModelRenderer(this, "Boot Cap Left");
- BootCapL.setTextureOffset(12, 32);
- BootCapL.mirror = true;
- BootCapL.setRotationPoint(0.0F, 0.0F, 0.0F);
- BootCapL.addBox(-1.5F, 10.0F, -2.5F, 3, 2, 2, 0.3F);
- setRotateAngle(BootCapL, -0.17453292519943295F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(BootCapL);
-
- BootCapL.isHidden = true;
- BootCapR.isHidden = true;
- BootTipL.isHidden = true;
- BootTipR.isHidden = true;
- FlairBackR.isHidden = true;
- BackFlairL.isHidden = true;
- FlairL.isHidden = true;
- FlairR.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.heavy;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * TinkersSabatons - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersSabatons extends ArmorRenderer
+//{
+// public ModelRenderer BootL;
+// public ModelRenderer FlairBackR;
+// public ModelRenderer ShinGuardL;
+// public ModelRenderer KneeGuardCapL;
+// public ModelRenderer LegBackL;
+// public ModelRenderer BootR;
+// public ModelRenderer ShinGuardR;
+// public ModelRenderer BootCapR;
+// public ModelRenderer BootCapL;
+// public ModelRenderer LegBackR;
+// public ModelRenderer FlairL;
+// public ModelRenderer KneeGuardCapR;
+// public ModelRenderer BootTipR;
+// public ModelRenderer BootTipL;
+// public ModelRenderer KneeGuardR;
+// public ModelRenderer KneeGuardL;
+// public ModelRenderer FlairR;
+// public ModelRenderer BackFlairL;
+//
+// public ModelTinkersSabatons()
+// {
+// super(0.1f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// BootR = new ModelRenderer(this, "Boot Right");
+// BootR.setTextureOffset(0, 56);
+// BootR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BootR.addBox(-2.0F, 9.0F, -3.0F, 4, 3, 5, 0.2F);
+// bipedRightLeg.addChild(BootR);
+//
+// BootL = new ModelRenderer(this, "Boot Left");
+// BootL.setTextureOffset(0, 56);
+// BootL.mirror = true;
+// BootL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BootL.addBox(-2.0F, 9.0F, -3.0F, 4, 3, 5, 0.2F);
+// bipedLeftLeg.addChild(BootL);
+//
+// KneeGuardR = new ModelRenderer(this, "Knee Guard Right");
+// KneeGuardR.setTextureOffset(0, 32);
+// KneeGuardR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KneeGuardR.addBox(-2.0F, 3.1F, -2.5F, 4, 3, 4, 0.3F);
+// bipedRightLeg.addChild(KneeGuardR);
+//
+// KneeGuardL = new ModelRenderer(this, "Knee Guard Left");
+// KneeGuardL.setTextureOffset(0, 32);
+// KneeGuardL.mirror = true;
+// KneeGuardL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KneeGuardL.addBox(-2.0F, 3.1F, -2.5F, 4, 3, 4, 0.3F);
+// bipedLeftLeg.addChild(KneeGuardL);
+//
+// ShinGuardR = new ModelRenderer(this, "Shin Guard Right");
+// ShinGuardR.setTextureOffset(0, 48);
+// ShinGuardR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShinGuardR.addBox(-2.0F, 4.0F, -2.5F, 4, 5, 3, 0.11F);
+// setRotateAngle(ShinGuardR, 0.05759586531581287F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(ShinGuardR);
+//
+// ShinGuardL = new ModelRenderer(this, "Shin Guard Left");
+// ShinGuardL.setTextureOffset(0, 48);
+// ShinGuardL.mirror = true;
+// ShinGuardL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ShinGuardL.addBox(-2.0F, 4.0F, -2.5F, 4, 5, 3, 0.11F);
+// setRotateAngle(ShinGuardL, 0.05759586531581287F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(ShinGuardL);
+//
+// LegBackL = new ModelRenderer(this, "Leg Back Left");
+// LegBackL.setTextureOffset(0, 40);
+// LegBackL.mirror = true;
+// LegBackL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LegBackL.addBox(-2.0F, 3.0F, 0.6F, 4, 6, 2, 0.1F);
+// setRotateAngle(LegBackL, -0.05759586531581287F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(LegBackL);
+//
+// LegBackR = new ModelRenderer(this, "Leg Back Right");
+// LegBackR.setTextureOffset(0, 40);
+// LegBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// LegBackR.addBox(-2.0F, 3.0F, 0.6F, 4, 6, 2, 0.1F);
+// setRotateAngle(LegBackR, -0.05759586531581287F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(LegBackR);
+//
+// FlairR = new ModelRenderer(this, "Flair Right");
+// FlairR.setTextureOffset(18, 53);
+// FlairR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FlairR.addBox(0.9F, 0.2F, -2.5F, 5, 11, 0, 0.0F);
+// setRotateAngle(FlairR, 0.0F, -0.6108652381980153F, 0.0F);
+// bipedLeftLeg.addChild(FlairR);
+//
+// FlairL = new ModelRenderer(this, "Flair Left");
+// FlairL.setTextureOffset(18, 53);
+// FlairL.mirror = true;
+// FlairL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FlairL.addBox(-5.9F, 0.2F, -2.5F, 5, 11, 0, 0.0F);
+// setRotateAngle(FlairL, 0.0F, 0.6108652381980153F, 0.0F);
+// bipedRightLeg.addChild(FlairL);
+//
+// FlairBackR = new ModelRenderer(this, "Flair Back Right");
+// FlairBackR.setTextureOffset(28, 47);
+// FlairBackR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// FlairBackR.addBox(0.0F, 0.0F, 2.0F, 0, 12, 5, 0.0F);
+// bipedRightLeg.addChild(FlairBackR);
+//
+// BackFlairL = new ModelRenderer(this, "Flair Back Left");
+// BackFlairL.setTextureOffset(28, 47);
+// BackFlairL.mirror = true;
+// BackFlairL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BackFlairL.addBox(0.0F, 0.0F, 2.0F, 0, 12, 5, 0.0F);
+// bipedLeftLeg.addChild(BackFlairL);
+//
+// KneeGuardCapR = new ModelRenderer(this, "Knee Guard Cap Right");
+// KneeGuardCapR.setTextureOffset(16, 36);
+// KneeGuardCapR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KneeGuardCapR.addBox(-1.5F, 2.4F, -3.8F, 3, 2, 1, 0.2F);
+// setRotateAngle(KneeGuardCapR, 0.17453292519943295F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(KneeGuardCapR);
+//
+// KneeGuardCapL = new ModelRenderer(this, "Knee Guard Cap Left");
+// KneeGuardCapL.setTextureOffset(16, 36);
+// KneeGuardCapL.mirror = true;
+// KneeGuardCapL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// KneeGuardCapL.addBox(-1.5F, 2.4F, -3.8F, 3, 2, 1, 0.2F);
+// setRotateAngle(KneeGuardCapL, 0.17453292519943295F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(KneeGuardCapL);
+//
+// BootTipR = new ModelRenderer(this, "Boot Tip Right");
+// BootTipR.setTextureOffset(22, 32);
+// BootTipR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BootTipR.addBox(-1.4F, 10.0F, -2.5F, 3, 2, 2, -0.1F);
+// setRotateAngle(BootTipR, -0.3490658503988659F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(BootTipR);
+//
+// BootCapR = new ModelRenderer(this, "Boot Cap Right");
+// BootCapR.setTextureOffset(12, 32);
+// BootCapR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BootCapR.addBox(-1.5F, 10.0F, -2.5F, 3, 2, 2, 0.3F);
+// setRotateAngle(BootCapR, -0.17453292519943295F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(BootCapR);
+//
+// BootTipL = new ModelRenderer(this, "Boot Tip Left");
+// BootTipL.setTextureOffset(22, 32);
+// BootTipL.mirror = true;
+// BootTipL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BootTipL.addBox(-1.5F, 10.0F, -2.6F, 3, 2, 2, -0.1F);
+// setRotateAngle(BootTipL, -0.3490658503988659F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(BootTipL);
+//
+// BootCapL = new ModelRenderer(this, "Boot Cap Left");
+// BootCapL.setTextureOffset(12, 32);
+// BootCapL.mirror = true;
+// BootCapL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BootCapL.addBox(-1.5F, 10.0F, -2.5F, 3, 2, 2, 0.3F);
+// setRotateAngle(BootCapL, -0.17453292519943295F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(BootCapL);
+//
+// BootCapL.isHidden = true;
+// BootCapR.isHidden = true;
+// BootTipL.isHidden = true;
+// BootTipR.isHidden = true;
+// FlairBackR.isHidden = true;
+// BackFlairL.isHidden = true;
+// FlairL.isHidden = true;
+// FlairR.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersBoots.java b/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersBoots.java
index f700e93..bc5dae3 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersBoots.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersBoots.java
@@ -1,111 +1,111 @@
-package lance5057.tDefense.armor.renderers.light;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * ModelTinkersBoots - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersBoots extends ArmorRenderer
-{
- public ModelRenderer BootTopR;
- public ModelRenderer BootTopL;
- public ModelRenderer FootL;
- public ModelRenderer FootR;
- public ModelRenderer LegGuardL;
- public ModelRenderer LegGuardR;
- public ModelRenderer FootTipL;
- public ModelRenderer FootTipR;
-
- public ModelTinkersBoots()
- {
- super(0.1f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- bipedRightLeg = new ModelRenderer(this, "Right Leg");
- bipedRightLeg.setTextureOffset(0, 16);
- bipedRightLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.05f);
- bipedRightLeg.setRotationPoint(-1.9F, 12.0F + 0, 0.0F);
-
- bipedLeftLeg = new ModelRenderer(this, "Left Leg");
- bipedLeftLeg.setTextureOffset(0, 16);
- bipedLeftLeg.mirror = true;
- bipedLeftLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.05f);
- bipedLeftLeg.setRotationPoint(1.9F, 12.0F + 0, 0.0F);
-
- FootR = new ModelRenderer(this, "FootR");
- FootR.setTextureOffset(0, 41);
- FootR.setRotationPoint(0f, 0f, 0f);
- FootR.addBox(-2.0F, 10.0F, -3.0F, 4, 2, 1, 0.1F);
- bipedRightLeg.addChild(FootR);
-
- BootTopR = new ModelRenderer(this, "BootTopR");
- BootTopR.setTextureOffset(0, 32);
- BootTopR.setRotationPoint(0f, 0f, 0f);
- BootTopR.addBox(-2.5F, 3.5F, -2.5F, 5, 4, 5, -0.2F);
- bipedRightLeg.addChild(BootTopR);
-
- BootTopL = new ModelRenderer(this, "BootTopL");
- BootTopL.setTextureOffset(0, 32);
- BootTopL.setRotationPoint(0f, 0f, 0f);
- BootTopL.addBox(-2.5F, 3.5F, -2.5F, 5, 4, 5, -0.2F);
- bipedLeftLeg.addChild(BootTopL);
-
- LegGuardR = new ModelRenderer(this, "LegGuardR");
- LegGuardR.setTextureOffset(0, 44);
- LegGuardR.setRotationPoint(0f, 0f, 0f);
- LegGuardR.addBox(-2.0F, 5.5F, -3.8F, 4, 4, 2, 0.2F);
- setRotateAngle(LegGuardR, 0.17453292519943295F, 0.0F, 0.0F);
- bipedRightLeg.addChild(LegGuardR);
-
- FootTipR = new ModelRenderer(this, "FootTipR");
- FootTipR.setTextureOffset(10, 41);
- FootTipR.setRotationPoint(0f, 0f, 0f);
- FootTipR.addBox(-1.5F, 9.5F, -5.6F, 3, 2, 2, -0.2F);
- setRotateAngle(FootTipR, 0.17453292519943295F, 0.0F, 0.0F);
- bipedRightLeg.addChild(FootTipR);
-
- FootL = new ModelRenderer(this, "FootL");
- FootL.setTextureOffset(0, 41);
- FootL.mirror = true;
- FootL.setRotationPoint(0f, 0f, 0f);
- FootL.addBox(-2.0F, 10.0F, -3.0F, 4, 2, 1, 0.1F);
- bipedLeftLeg.addChild(FootL);
-
- LegGuardL = new ModelRenderer(this, "LegGuardL");
- LegGuardL.setTextureOffset(0, 44);
- LegGuardL.setRotationPoint(0f, 0f, 0f);
- LegGuardL.addBox(-2.0F, 5.5F, -3.8F, 4, 4, 2, 0.2F);
- setRotateAngle(LegGuardL, 0.17453292519943295F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(LegGuardL);
-
- FootTipL = new ModelRenderer(this, "FootTipL");
- FootTipL.setTextureOffset(10, 41);
- FootTipL.setRotationPoint(0f, 0f, 0f);
- FootTipL.addBox(-1.5F, 9.5F, -5.6F, 3, 2, 2, -0.2F);
- setRotateAngle(FootTipL, 0.17453292519943295F, 0.0F, 0.0F);
- bipedLeftLeg.addChild(FootTipL);
-
- BootTopL.isHidden = true;
- BootTopR.isHidden = true;
- FootTipL.isHidden = true;
- FootTipR.isHidden = true;
- LegGuardL.isHidden = true;
- LegGuardR.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.light;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * ModelTinkersBoots - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersBoots extends ArmorRenderer
+//{
+// public ModelRenderer BootTopR;
+// public ModelRenderer BootTopL;
+// public ModelRenderer FootL;
+// public ModelRenderer FootR;
+// public ModelRenderer LegGuardL;
+// public ModelRenderer LegGuardR;
+// public ModelRenderer FootTipL;
+// public ModelRenderer FootTipR;
+//
+// public ModelTinkersBoots()
+// {
+// super(0.1f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// bipedRightLeg = new ModelRenderer(this, "Right Leg");
+// bipedRightLeg.setTextureOffset(0, 16);
+// bipedRightLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.05f);
+// bipedRightLeg.setRotationPoint(-1.9F, 12.0F + 0, 0.0F);
+//
+// bipedLeftLeg = new ModelRenderer(this, "Left Leg");
+// bipedLeftLeg.setTextureOffset(0, 16);
+// bipedLeftLeg.mirror = true;
+// bipedLeftLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.05f);
+// bipedLeftLeg.setRotationPoint(1.9F, 12.0F + 0, 0.0F);
+//
+// FootR = new ModelRenderer(this, "FootR");
+// FootR.setTextureOffset(0, 41);
+// FootR.setRotationPoint(0f, 0f, 0f);
+// FootR.addBox(-2.0F, 10.0F, -3.0F, 4, 2, 1, 0.1F);
+// bipedRightLeg.addChild(FootR);
+//
+// BootTopR = new ModelRenderer(this, "BootTopR");
+// BootTopR.setTextureOffset(0, 32);
+// BootTopR.setRotationPoint(0f, 0f, 0f);
+// BootTopR.addBox(-2.5F, 3.5F, -2.5F, 5, 4, 5, -0.2F);
+// bipedRightLeg.addChild(BootTopR);
+//
+// BootTopL = new ModelRenderer(this, "BootTopL");
+// BootTopL.setTextureOffset(0, 32);
+// BootTopL.setRotationPoint(0f, 0f, 0f);
+// BootTopL.addBox(-2.5F, 3.5F, -2.5F, 5, 4, 5, -0.2F);
+// bipedLeftLeg.addChild(BootTopL);
+//
+// LegGuardR = new ModelRenderer(this, "LegGuardR");
+// LegGuardR.setTextureOffset(0, 44);
+// LegGuardR.setRotationPoint(0f, 0f, 0f);
+// LegGuardR.addBox(-2.0F, 5.5F, -3.8F, 4, 4, 2, 0.2F);
+// setRotateAngle(LegGuardR, 0.17453292519943295F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(LegGuardR);
+//
+// FootTipR = new ModelRenderer(this, "FootTipR");
+// FootTipR.setTextureOffset(10, 41);
+// FootTipR.setRotationPoint(0f, 0f, 0f);
+// FootTipR.addBox(-1.5F, 9.5F, -5.6F, 3, 2, 2, -0.2F);
+// setRotateAngle(FootTipR, 0.17453292519943295F, 0.0F, 0.0F);
+// bipedRightLeg.addChild(FootTipR);
+//
+// FootL = new ModelRenderer(this, "FootL");
+// FootL.setTextureOffset(0, 41);
+// FootL.mirror = true;
+// FootL.setRotationPoint(0f, 0f, 0f);
+// FootL.addBox(-2.0F, 10.0F, -3.0F, 4, 2, 1, 0.1F);
+// bipedLeftLeg.addChild(FootL);
+//
+// LegGuardL = new ModelRenderer(this, "LegGuardL");
+// LegGuardL.setTextureOffset(0, 44);
+// LegGuardL.setRotationPoint(0f, 0f, 0f);
+// LegGuardL.addBox(-2.0F, 5.5F, -3.8F, 4, 4, 2, 0.2F);
+// setRotateAngle(LegGuardL, 0.17453292519943295F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(LegGuardL);
+//
+// FootTipL = new ModelRenderer(this, "FootTipL");
+// FootTipL.setTextureOffset(10, 41);
+// FootTipL.setRotationPoint(0f, 0f, 0f);
+// FootTipL.addBox(-1.5F, 9.5F, -5.6F, 3, 2, 2, -0.2F);
+// setRotateAngle(FootTipL, 0.17453292519943295F, 0.0F, 0.0F);
+// bipedLeftLeg.addChild(FootTipL);
+//
+// BootTopL.isHidden = true;
+// BootTopR.isHidden = true;
+// FootTipL.isHidden = true;
+// FootTipR.isHidden = true;
+// LegGuardL.isHidden = true;
+// LegGuardR.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersChausses.java b/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersChausses.java
index f2eb795..7381d4e 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersChausses.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersChausses.java
@@ -1,138 +1,138 @@
-package lance5057.tDefense.armor.renderers.light;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * ModelTinkersChausses - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersChausses extends ArmorRenderer
-{
- public ModelRenderer FrontL;
- public ModelRenderer FrontR;
- public ModelRenderer HipGuardL;
- public ModelRenderer HipGuardR;
- public ModelRenderer BackL;
- public ModelRenderer BackR;
- public ModelRenderer HipGuardL_1;
- public ModelRenderer HipGuardR_1;
- public ModelRenderer Belt;
- public ModelRenderer BeltR;
- public ModelRenderer BeltL;
-
- public ModelTinkersChausses()
- {
- super(0.1f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- bipedRightLeg = new ModelRenderer(this, "Right Leg");
- bipedRightLeg.setTextureOffset(0, 16);
- bipedRightLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.1f);
- bipedRightLeg.setRotationPoint(-1.9F, 12.0F + 0, 0.0F);
-
- bipedLeftLeg = new ModelRenderer(this, "Left Leg");
- bipedLeftLeg.setTextureOffset(0, 16);
- bipedLeftLeg.mirror = true;
- bipedLeftLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.1f);
- bipedLeftLeg.setRotationPoint(1.9F, 12.0F + 0, 0.0F);
-
- HipGuardR = new ModelRenderer(this, "Hip Guard Right");
- HipGuardR.setTextureOffset(10, 37);
- HipGuardR.setRotationPoint(0f, 0f, 0f);
- HipGuardR.addBox(-2.5F, 0.0F, -2.6F, 4, 6, 5, 0.1F);
- setRotateAngle(HipGuardR, 0.0F, 0.0F, 0.17453292519943295F);
- bipedRightLeg.addChild(HipGuardR);
-
- Belt = new ModelRenderer(this, "Belt");
- Belt.setTextureOffset(18, 48);
- Belt.setRotationPoint(0.0F, 0.0F, 0.0F);
- Belt.addBox(-5.0F, 10.5F, -3.0F, 10, 2, 6, -0.19F);
- bipedBody.addChild(Belt);
-
- FrontR = new ModelRenderer(this, "Front Right");
- FrontR.setTextureOffset(0, 40);
- FrontR.setRotationPoint(1.9f, 0f, -0.1f);
- FrontR.addBox(-2.0F, 0.0F, -2.6F, 4, 7, 1, 0.0F);
- setRotateAngle(FrontR, -0.1F, 0.0F, 0.0f);
- bipedRightLeg.addChild(FrontR);
-
- FrontL = new ModelRenderer(this, "Front Left");
- FrontL.setTextureOffset(0, 40);
- FrontL.setRotationPoint(-1.9f, 0f, -0.1f);
- FrontL.addBox(-2.0F, 0.0F, -2.6F, 4, 7, 1, 0.0F);
- setRotateAngle(FrontL, -0.1F, 0.0F, 0.0f);
- bipedLeftLeg.addChild(FrontL);
-
- HipGuardL_1 = new ModelRenderer(this, "Hip Guard Left 2");
- HipGuardL_1.setTextureOffset(0, 49);
- HipGuardL_1.mirror = true;
- HipGuardL_1.setRotationPoint(0f, 0f, 0f);
- HipGuardL_1.addBox(-1.5F, 0.0F, -2.6F, 4, 10, 5, 0.0F);
- setRotateAngle(HipGuardL_1, 0.0F, 0.0F, -0.08726646259971647F);
- bipedLeftLeg.addChild(HipGuardL_1);
-
- BeltR = new ModelRenderer(this, "Belt Right");
- BeltR.setTextureOffset(18, 56);
- BeltR.mirror = true;
- BeltR.setRotationPoint(0.0F, 0.0F, 0.0F);
- BeltR.addBox(-6F, 1.0F, -3.1F, 12, 2, 6, -0.2F);
- setRotateAngle(BeltR, 0.0F, 0.0F, -0.4363323129985824F);
- bipedRightLeg.addChild(BeltR);
-
- BeltL = new ModelRenderer(this, "Belt Left");
- BeltL.setTextureOffset(18, 56);
- BeltL.setRotationPoint(0.0F, 0.0F, 0.0F);
- BeltL.addBox(-6F, 1.0F, -3.1F, 12, 2, 6, -0.21F);
- setRotateAngle(BeltL, 0.0F, 0.0F, 0.4363323129985824F);
- bipedLeftLeg.addChild(BeltL);
-
- HipGuardR_1 = new ModelRenderer(this, "Hip Guard Right 2");
- HipGuardR_1.setTextureOffset(0, 49);
- HipGuardR_1.setRotationPoint(0f, 0f, 0f);
- HipGuardR_1.addBox(-2.5F, 0.0F, -2.6F, 4, 10, 5, 0.0F);
- setRotateAngle(HipGuardR_1, 0.0F, 0.0F, 0.08726646259971647F);
- bipedRightLeg.addChild(HipGuardR_1);
-
- BackR = new ModelRenderer(this, "Back Right");
- BackR.setTextureOffset(0, 40);
- BackR.setRotationPoint(1.9f, 0f, 0f);
- BackR.addBox(-2.0F, 0.0F, 1.5F, 4, 7, 1, 0.0F);
- setRotateAngle(BackR, 0.1F, 0.0F, 0.0f);
- bipedRightLeg.addChild(BackR);
-
- BackL = new ModelRenderer(this, "Back Light");
- BackL.setTextureOffset(0, 40);
- BackL.setRotationPoint(-1.9f, 0f, 0f);
- BackL.addBox(-2.0F, 0.0F, 1.5F, 4, 7, 1, 0.0F);
- setRotateAngle(BackL, 0.1F, 0.0F, 0.0f);
- bipedLeftLeg.addChild(BackL);
-
- HipGuardL = new ModelRenderer(this, "Hip Guard Left");
- HipGuardL.setTextureOffset(10, 37);
- HipGuardL.mirror = true;
- HipGuardL.setRotationPoint(0f, 0f, 0f);
- HipGuardL.addBox(-1.5F, 0.0F, -2.6F, 4, 6, 5, 0.1F);
- setRotateAngle(HipGuardL, 0.0F, 0.0F, -0.17453292519943295F);
- bipedLeftLeg.addChild(HipGuardL);
-
- BeltL.isHidden = true;
- BeltR.isHidden = true;
- HipGuardL_1.isHidden = true;
- HipGuardR_1.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.light;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * ModelTinkersChausses - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersChausses extends ArmorRenderer
+//{
+// public ModelRenderer FrontL;
+// public ModelRenderer FrontR;
+// public ModelRenderer HipGuardL;
+// public ModelRenderer HipGuardR;
+// public ModelRenderer BackL;
+// public ModelRenderer BackR;
+// public ModelRenderer HipGuardL_1;
+// public ModelRenderer HipGuardR_1;
+// public ModelRenderer Belt;
+// public ModelRenderer BeltR;
+// public ModelRenderer BeltL;
+//
+// public ModelTinkersChausses()
+// {
+// super(0.1f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// bipedRightLeg = new ModelRenderer(this, "Right Leg");
+// bipedRightLeg.setTextureOffset(0, 16);
+// bipedRightLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.1f);
+// bipedRightLeg.setRotationPoint(-1.9F, 12.0F + 0, 0.0F);
+//
+// bipedLeftLeg = new ModelRenderer(this, "Left Leg");
+// bipedLeftLeg.setTextureOffset(0, 16);
+// bipedLeftLeg.mirror = true;
+// bipedLeftLeg.addBox(-2.0F, 0.0F, -2.0F, 4, 12, 4, 0.1f);
+// bipedLeftLeg.setRotationPoint(1.9F, 12.0F + 0, 0.0F);
+//
+// HipGuardR = new ModelRenderer(this, "Hip Guard Right");
+// HipGuardR.setTextureOffset(10, 37);
+// HipGuardR.setRotationPoint(0f, 0f, 0f);
+// HipGuardR.addBox(-2.5F, 0.0F, -2.6F, 4, 6, 5, 0.1F);
+// setRotateAngle(HipGuardR, 0.0F, 0.0F, 0.17453292519943295F);
+// bipedRightLeg.addChild(HipGuardR);
+//
+// Belt = new ModelRenderer(this, "Belt");
+// Belt.setTextureOffset(18, 48);
+// Belt.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Belt.addBox(-5.0F, 10.5F, -3.0F, 10, 2, 6, -0.19F);
+// bipedBody.addChild(Belt);
+//
+// FrontR = new ModelRenderer(this, "Front Right");
+// FrontR.setTextureOffset(0, 40);
+// FrontR.setRotationPoint(1.9f, 0f, -0.1f);
+// FrontR.addBox(-2.0F, 0.0F, -2.6F, 4, 7, 1, 0.0F);
+// setRotateAngle(FrontR, -0.1F, 0.0F, 0.0f);
+// bipedRightLeg.addChild(FrontR);
+//
+// FrontL = new ModelRenderer(this, "Front Left");
+// FrontL.setTextureOffset(0, 40);
+// FrontL.setRotationPoint(-1.9f, 0f, -0.1f);
+// FrontL.addBox(-2.0F, 0.0F, -2.6F, 4, 7, 1, 0.0F);
+// setRotateAngle(FrontL, -0.1F, 0.0F, 0.0f);
+// bipedLeftLeg.addChild(FrontL);
+//
+// HipGuardL_1 = new ModelRenderer(this, "Hip Guard Left 2");
+// HipGuardL_1.setTextureOffset(0, 49);
+// HipGuardL_1.mirror = true;
+// HipGuardL_1.setRotationPoint(0f, 0f, 0f);
+// HipGuardL_1.addBox(-1.5F, 0.0F, -2.6F, 4, 10, 5, 0.0F);
+// setRotateAngle(HipGuardL_1, 0.0F, 0.0F, -0.08726646259971647F);
+// bipedLeftLeg.addChild(HipGuardL_1);
+//
+// BeltR = new ModelRenderer(this, "Belt Right");
+// BeltR.setTextureOffset(18, 56);
+// BeltR.mirror = true;
+// BeltR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BeltR.addBox(-6F, 1.0F, -3.1F, 12, 2, 6, -0.2F);
+// setRotateAngle(BeltR, 0.0F, 0.0F, -0.4363323129985824F);
+// bipedRightLeg.addChild(BeltR);
+//
+// BeltL = new ModelRenderer(this, "Belt Left");
+// BeltL.setTextureOffset(18, 56);
+// BeltL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// BeltL.addBox(-6F, 1.0F, -3.1F, 12, 2, 6, -0.21F);
+// setRotateAngle(BeltL, 0.0F, 0.0F, 0.4363323129985824F);
+// bipedLeftLeg.addChild(BeltL);
+//
+// HipGuardR_1 = new ModelRenderer(this, "Hip Guard Right 2");
+// HipGuardR_1.setTextureOffset(0, 49);
+// HipGuardR_1.setRotationPoint(0f, 0f, 0f);
+// HipGuardR_1.addBox(-2.5F, 0.0F, -2.6F, 4, 10, 5, 0.0F);
+// setRotateAngle(HipGuardR_1, 0.0F, 0.0F, 0.08726646259971647F);
+// bipedRightLeg.addChild(HipGuardR_1);
+//
+// BackR = new ModelRenderer(this, "Back Right");
+// BackR.setTextureOffset(0, 40);
+// BackR.setRotationPoint(1.9f, 0f, 0f);
+// BackR.addBox(-2.0F, 0.0F, 1.5F, 4, 7, 1, 0.0F);
+// setRotateAngle(BackR, 0.1F, 0.0F, 0.0f);
+// bipedRightLeg.addChild(BackR);
+//
+// BackL = new ModelRenderer(this, "Back Light");
+// BackL.setTextureOffset(0, 40);
+// BackL.setRotationPoint(-1.9f, 0f, 0f);
+// BackL.addBox(-2.0F, 0.0F, 1.5F, 4, 7, 1, 0.0F);
+// setRotateAngle(BackL, 0.1F, 0.0F, 0.0f);
+// bipedLeftLeg.addChild(BackL);
+//
+// HipGuardL = new ModelRenderer(this, "Hip Guard Left");
+// HipGuardL.setTextureOffset(10, 37);
+// HipGuardL.mirror = true;
+// HipGuardL.setRotationPoint(0f, 0f, 0f);
+// HipGuardL.addBox(-1.5F, 0.0F, -2.6F, 4, 6, 5, 0.1F);
+// setRotateAngle(HipGuardL, 0.0F, 0.0F, -0.17453292519943295F);
+// bipedLeftLeg.addChild(HipGuardL);
+//
+// BeltL.isHidden = true;
+// BeltR.isHidden = true;
+// HipGuardL_1.isHidden = true;
+// HipGuardR_1.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersCoif.java b/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersCoif.java
index 7496f00..d0af22d 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersCoif.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersCoif.java
@@ -1,100 +1,100 @@
-package lance5057.tDefense.armor.renderers.light;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * ModelBiped - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersCoif extends ArmorRenderer
-{
- public ModelRenderer Coif;
- public ModelRenderer WingR;
- public ModelRenderer Mask;
- public ModelRenderer Overlay;
- public ModelRenderer WingL;
- public ModelRenderer Mohawk;
- public ModelRenderer MohawkR;
- public ModelRenderer MohawkL;
-
- public ModelTinkersCoif()
- {
- super(0.1f, 0, 128, 64);
-
- textureWidth = 128;
- textureHeight = 64;
-
- Overlay = new ModelRenderer(this, "Overlay");
- Overlay.setTextureOffset(32, 32);
- Overlay.setRotationPoint(0.0F, 0.0F, 0.0F);
- Overlay.addBox(-4.0F, -10.0F, -4.0F, 8, 10, 8, 0.7F);
- bipedHead.addChild(Overlay);
-
- WingL = new ModelRenderer(this, "WingL");
- WingL.setTextureOffset(64, 0);
- WingL.setRotationPoint(-0.7F, 0.0F, 0.0F);
- WingL.addBox(2.3F, -13.5F, -6.6F, 8, 18, 0, 0.0F);
- setRotateAngle(WingL, 0.0F, -0.5235987755982988F, 0.0F);
- bipedHead.addChild(WingL);
-
- MohawkR = new ModelRenderer(this, "MohawkR");
- MohawkR.setTextureOffset(80, -14);
- MohawkR.setRotationPoint(0.0F, 0.0F, 0.0F);
- MohawkR.addBox(-3.0F, -14.0F, -3.6F, 0, 18, 14, 0.0F);
- setRotateAngle(MohawkR, 0.0F, -0.4363323129985824F, 0.0F);
- bipedHead.addChild(MohawkR);
-
- Mohawk = new ModelRenderer(this, "Mohawk");
- Mohawk.setTextureOffset(64, 4);
- Mohawk.setRotationPoint(0.0F, 0.0F, 0.0F);
- Mohawk.addBox(0.0F, -14.0F, -4.6F, 0, 18, 14, 0.0F);
- bipedHead.addChild(Mohawk);
-
- Mask = new ModelRenderer(this, "Mask");
- Mask.setTextureOffset(0, 43);
- Mask.setRotationPoint(0.0F, 0.0F, 0.0F);
- Mask.addBox(-4.5F, -8.0F, -5.0F, 9, 10, 4, 0.11F);
- bipedHead.addChild(Mask);
-
- WingR = new ModelRenderer(this, "WingR");
- WingR.setTextureOffset(64, 0);
- WingR.mirror = true;
- WingR.setRotationPoint(-0.5F, 0.0F, 0.0F);
- WingR.addBox(-9.2F, -13.5F, -6.0F, 8, 18, 0, 0.0F);
- setRotateAngle(WingR, 0.0F, 0.5235987755982988F, 0.0F);
- bipedHead.addChild(WingR);
-
- MohawkL = new ModelRenderer(this, "MohawkL");
- MohawkL.setTextureOffset(80, -14);
- MohawkL.setRotationPoint(0.0F, 0.0F, 0.0F);
- MohawkL.addBox(3.0F, -14.0F, -3.6F, 0, 18, 14, 0.0F);
- setRotateAngle(MohawkL, 0.0F, 0.4363323129985824F, 0.0F);
- bipedHead.addChild(MohawkL);
-
- Coif = new ModelRenderer(this, "Coif");
- Coif.setTextureOffset(0, 32);
- Coif.setRotationPoint(0.0F, 0.0F, 0.0F);
- Coif.addBox(-4.0F, 1.0F, -4.0F, 8, 3, 8, 0.6F);
- bipedHead.addChild(Coif);
-
- Mask.isHidden = true;
- Mohawk.isHidden = true;
- MohawkL.isHidden = true;
- MohawkR.isHidden = true;
- WingL.isHidden = true;
- WingR.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.light;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * ModelBiped - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersCoif extends ArmorRenderer
+//{
+// public ModelRenderer Coif;
+// public ModelRenderer WingR;
+// public ModelRenderer Mask;
+// public ModelRenderer Overlay;
+// public ModelRenderer WingL;
+// public ModelRenderer Mohawk;
+// public ModelRenderer MohawkR;
+// public ModelRenderer MohawkL;
+//
+// public ModelTinkersCoif()
+// {
+// super(0.1f, 0, 128, 64);
+//
+// textureWidth = 128;
+// textureHeight = 64;
+//
+// Overlay = new ModelRenderer(this, "Overlay");
+// Overlay.setTextureOffset(32, 32);
+// Overlay.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Overlay.addBox(-4.0F, -10.0F, -4.0F, 8, 10, 8, 0.7F);
+// bipedHead.addChild(Overlay);
+//
+// WingL = new ModelRenderer(this, "WingL");
+// WingL.setTextureOffset(64, 0);
+// WingL.setRotationPoint(-0.7F, 0.0F, 0.0F);
+// WingL.addBox(2.3F, -13.5F, -6.6F, 8, 18, 0, 0.0F);
+// setRotateAngle(WingL, 0.0F, -0.5235987755982988F, 0.0F);
+// bipedHead.addChild(WingL);
+//
+// MohawkR = new ModelRenderer(this, "MohawkR");
+// MohawkR.setTextureOffset(80, -14);
+// MohawkR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// MohawkR.addBox(-3.0F, -14.0F, -3.6F, 0, 18, 14, 0.0F);
+// setRotateAngle(MohawkR, 0.0F, -0.4363323129985824F, 0.0F);
+// bipedHead.addChild(MohawkR);
+//
+// Mohawk = new ModelRenderer(this, "Mohawk");
+// Mohawk.setTextureOffset(64, 4);
+// Mohawk.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Mohawk.addBox(0.0F, -14.0F, -4.6F, 0, 18, 14, 0.0F);
+// bipedHead.addChild(Mohawk);
+//
+// Mask = new ModelRenderer(this, "Mask");
+// Mask.setTextureOffset(0, 43);
+// Mask.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Mask.addBox(-4.5F, -8.0F, -5.0F, 9, 10, 4, 0.11F);
+// bipedHead.addChild(Mask);
+//
+// WingR = new ModelRenderer(this, "WingR");
+// WingR.setTextureOffset(64, 0);
+// WingR.mirror = true;
+// WingR.setRotationPoint(-0.5F, 0.0F, 0.0F);
+// WingR.addBox(-9.2F, -13.5F, -6.0F, 8, 18, 0, 0.0F);
+// setRotateAngle(WingR, 0.0F, 0.5235987755982988F, 0.0F);
+// bipedHead.addChild(WingR);
+//
+// MohawkL = new ModelRenderer(this, "MohawkL");
+// MohawkL.setTextureOffset(80, -14);
+// MohawkL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// MohawkL.addBox(3.0F, -14.0F, -3.6F, 0, 18, 14, 0.0F);
+// setRotateAngle(MohawkL, 0.0F, 0.4363323129985824F, 0.0F);
+// bipedHead.addChild(MohawkL);
+//
+// Coif = new ModelRenderer(this, "Coif");
+// Coif.setTextureOffset(0, 32);
+// Coif.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Coif.addBox(-4.0F, 1.0F, -4.0F, 8, 3, 8, 0.6F);
+// bipedHead.addChild(Coif);
+//
+// Mask.isHidden = true;
+// Mohawk.isHidden = true;
+// MohawkL.isHidden = true;
+// MohawkR.isHidden = true;
+// WingL.isHidden = true;
+// WingR.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersHauberk.java b/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersHauberk.java
index 68e92aa..d30b478 100644
--- a/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersHauberk.java
+++ b/src/main/java/lance5057/tDefense/armor/renderers/light/ModelTinkersHauberk.java
@@ -1,198 +1,198 @@
-package lance5057.tDefense.armor.renderers.light;
-
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import net.minecraft.client.model.ModelRenderer;
-
-/**
- * ModelTinkersHauberk - Either Mojang or a mod author
- * Created using Tabula 4.1.1
- */
-public class ModelTinkersHauberk extends ArmorRenderer
-{
- public ModelRenderer ChestBeltR;
- public ModelRenderer ChestBelt;
- public ModelRenderer ChestBeltR_1;
- public ModelRenderer ChestBelt_1;
- public ModelRenderer ChestBeltL;
- public ModelRenderer ChestBeltL_1;
- public ModelRenderer ChestBelt_2;
- public ModelRenderer Pauldron1;
- public ModelRenderer Pauldron2;
- public ModelRenderer PauldronStudR;
- public ModelRenderer Pauldron3R;
- public ModelRenderer PauldronFlairR;
- public ModelRenderer Pauldron1L;
- public ModelRenderer Pauldron2L;
- public ModelRenderer PauldronStudL;
- public ModelRenderer Pauldron3L;
- public ModelRenderer PauldronFlairL;
-
- public ModelTinkersHauberk()
- {
- super(0.1f, 0, 64, 64);
-
- textureWidth = 64;
- textureHeight = 64;
-
- bipedBody = new ModelRenderer(this, "Body");
- bipedBody.setTextureOffset(16, 16);
- bipedBody.addBox(-4.0F, 0.0F, -2.0F, 8, 12, 4, 0.05f);
- bipedBody.setRotationPoint(0.0F, 0.0F + 0, 0.0F);
-
- bipedRightArm = new ModelRenderer(this, "Right Arm");
- bipedRightArm.setTextureOffset(40, 16);
- bipedRightArm.addBox(-3.0F, -2.0F, -2.0F, 4, 12, 4, 0.05f);
- bipedRightArm.setRotationPoint(-5.0F, 2.0F + 0, 0.0F);
-
- bipedLeftArm = new ModelRenderer(this, "Left Arm");
- bipedLeftArm.setTextureOffset(40, 16);
- bipedLeftArm.mirror = true;
- bipedLeftArm.addBox(-1.0F, -2.0F, -2.0F, 4, 12, 4, 0.05f);
- bipedLeftArm.setRotationPoint(5.0F, 2.0F + 0, 0.0F);
-
- ChestBelt_1 = new ModelRenderer(this, "ChestBelt_1");
- ChestBelt_1.setTextureOffset(0, 57);
- ChestBelt_1.setRotationPoint(0.0F, 0.0F, 0.0F);
- ChestBelt_1.addBox(-4.5F, 9.0F, -2.5F, 9, 2, 5, -0.19F);
- bipedBody.addChild(ChestBelt_1);
-
- ChestBelt_2 = new ModelRenderer(this, "ChestBelt_2");
- ChestBelt_2.setTextureOffset(28, 32);
- ChestBelt_2.setRotationPoint(0.0F, 0.0F, 0.0F);
- ChestBelt_2.addBox(-4.5F, 5.0F, -2.5F, 9, 2, 5, -0.19F);
- bipedBody.addChild(ChestBelt_2);
-
- Pauldron3R = new ModelRenderer(this, "Pauldron3R");
- Pauldron3R.setTextureOffset(0, 32);
- Pauldron3R.setRotationPoint(-0.0F, 0.0F, 0.0F);
- Pauldron3R.addBox(-3.2F, -0.5F, -2.0F, 3, 4, 4, 0.1F);
- setRotateAngle(Pauldron3R, 0.0F, 0.0F, 0.08726646259971647F);
- bipedRightArm.addChild(Pauldron3R);
-
- Pauldron2L = new ModelRenderer(this, "Pauldron2L");
- Pauldron2L.setTextureOffset(0, 49);
- Pauldron2L.mirror = true;
- Pauldron2L.setRotationPoint(0.0F, 0.0F, 0.0F);
- Pauldron2L.addBox(-1.0F, -3.0F, -2.0F, 3, 3, 4, 0.1F);
- setRotateAngle(Pauldron2L, 0.0F, 0.0F, 0.2617993877991494F);
- bipedLeftArm.addChild(Pauldron2L);
-
- Pauldron3L = new ModelRenderer(this, "Pauldron3L");
- Pauldron3L.setTextureOffset(0, 32);
- Pauldron3L.mirror = true;
- Pauldron3L.setRotationPoint(0.0F, 0.0F, 0.0F);
- Pauldron3L.addBox(0.2F, -0.5F, -2.0F, 3, 4, 4, 0.1F);
- setRotateAngle(Pauldron3L, 0.0F, 0.0F, -0.08726646259971647F);
- bipedLeftArm.addChild(Pauldron3L);
-
- ChestBeltR = new ModelRenderer(this, "ChestBeltR");
- ChestBeltR.setTextureOffset(0, 57);
- ChestBeltR.setRotationPoint(0.0F, 0.0F, 0.0F);
- ChestBeltR.addBox(-1.7F, 5.7F, -2.5F, 11, 2, 5, -0.2F);
- setRotateAngle(ChestBeltR, 0.0F, 0.0F, 0.5235987755982988F);
- bipedBody.addChild(ChestBeltR);
-
- ChestBeltL = new ModelRenderer(this, "ChestBeltL");
- ChestBeltL.setTextureOffset(0, 57);
- ChestBeltL.mirror = true;
- ChestBeltL.setRotationPoint(0.0F, 0.0F, 0.0F);
- ChestBeltL.addBox(-7.5F, 2.3F, -2.5F, 11, 2, 5, -0.2F);
- setRotateAngle(ChestBeltL, 0.0F, 0.0F, -0.5235987755982988F);
- bipedBody.addChild(ChestBeltL);
-
- ChestBeltL_1 = new ModelRenderer(this, "ChestBeltL_1");
- ChestBeltL_1.setTextureOffset(0, 57);
- ChestBeltL_1.mirror = true;
- ChestBeltL_1.setRotationPoint(0.0F, 0.0F, 0.0F);
- ChestBeltL_1.addBox(-9.3F, 5.7F, -2.5F, 11, 2, 5, -0.21F);
- setRotateAngle(ChestBeltL_1, 0.0F, 0.0F, -0.5235987755982988F);
- bipedBody.addChild(ChestBeltL_1);
-
- PauldronStudR = new ModelRenderer(this, "PauldronStudR");
- PauldronStudR.setTextureOffset(14, 32);
- PauldronStudR.setRotationPoint(-0.0F, 0.0F, 0.0F);
- PauldronStudR.addBox(-1.0F, -1.5F, -2.5F, 2, 2, 5, 0.1F);
- setRotateAngle(PauldronStudR, 0.0F, 0.0F, -0.2617993877991494F);
- bipedRightArm.addChild(PauldronStudR);
-
- Pauldron1 = new ModelRenderer(this, "Pauldron1");
- Pauldron1.setTextureOffset(0, 40);
- Pauldron1.setRotationPoint(-0.0F, 0.0F, 0.0F);
- Pauldron1.addBox(-3.5F, -1.9F, -2.5F, 4, 4, 5, 0.0F);
- setRotateAngle(Pauldron1, 0.0F, 0.0F, 0.2617993877991494F);
- bipedRightArm.addChild(Pauldron1);
-
- ChestBeltR_1 = new ModelRenderer(this, "ChestBeltR_1");
- ChestBeltR_1.setTextureOffset(0, 57);
- ChestBeltR_1.setRotationPoint(0.0F, 0.0F, 0.0F);
- ChestBeltR_1.addBox(-3.5F, 2.3F, -2.5F, 11, 2, 5, -0.21F);
- setRotateAngle(ChestBeltR_1, 0.0F, 0.0F, 0.5235987755982988F);
- bipedBody.addChild(ChestBeltR_1);
-
- PauldronFlairR = new ModelRenderer(this, "PauldronFlairR");
- PauldronFlairR.setTextureOffset(18, 39);
- PauldronFlairR.mirror = true;
- PauldronFlairR.setRotationPoint(-0.0F, 0.0F, 0.0F);
- PauldronFlairR.addBox(-8.5F, -4.5F, 0.0F, 7, 9, 0, 0.0F);
- setRotateAngle(PauldronFlairR, 0.0F, 0.0F, 0.2617993877991494F);
- bipedRightArm.addChild(PauldronFlairR);
-
- PauldronFlairL = new ModelRenderer(this, "PauldronFlairL");
- PauldronFlairL.setTextureOffset(18, 39);
- PauldronFlairL.setRotationPoint(0.0F, 0.0F, 0.0F);
- PauldronFlairL.addBox(1.5F, -4.5F, 0.0F, 7, 9, 0, 0.0F);
- setRotateAngle(PauldronFlairL, 0.0F, 0.0F, -0.2617993877991494F);
- bipedLeftArm.addChild(PauldronFlairL);
-
- Pauldron2 = new ModelRenderer(this, "Pauldron2");
- Pauldron2.setTextureOffset(0, 49);
- Pauldron2.setRotationPoint(-0.0F, 0.0F, 0.0F);
- Pauldron2.addBox(-2.0F, -3.0F, -2.0F, 3, 3, 4, 0.1F);
- setRotateAngle(Pauldron2, 0.0F, 0.0F, -0.2617993877991494F);
- bipedRightArm.addChild(Pauldron2);
-
- PauldronStudL = new ModelRenderer(this, "PauldronStudL");
- PauldronStudL.setTextureOffset(14, 32);
- PauldronStudL.mirror = true;
- PauldronStudL.setRotationPoint(0.0F, 0.0F, 0.0F);
- PauldronStudL.addBox(-1.0F, -1.5F, -2.5F, 2, 2, 5, 0.1F);
- setRotateAngle(PauldronStudL, 0.0F, 0.0F, 0.2617993877991494F);
- bipedLeftArm.addChild(PauldronStudL);
-
- Pauldron1L = new ModelRenderer(this, "Pauldron1L");
- Pauldron1L.setTextureOffset(0, 40);
- Pauldron1L.mirror = true;
- Pauldron1L.setRotationPoint(0.0F, 0.0F, 0.0F);
- Pauldron1L.addBox(-0.5F, -1.9F, -2.5F, 4, 4, 5, 0.0F);
- setRotateAngle(Pauldron1L, 0.0F, 0.0F, -0.2617993877991494F);
- bipedLeftArm.addChild(Pauldron1L);
-
- ChestBelt = new ModelRenderer(this, "ChestBelt");
- ChestBelt.setTextureOffset(28, 32);
- ChestBelt.setRotationPoint(0.0F, 0.0F, 0.0F);
- ChestBelt.addBox(-4.5F, 3.0F, -2.5F, 9, 2, 5, -0.19F);
- bipedBody.addChild(ChestBelt);
-
- //ChestBelt.isHidden = true;
- ChestBelt_1.isHidden = true;
- ChestBelt_2.isHidden = true;
- ChestBeltL.isHidden = true;
- ChestBeltL_1.isHidden = true;
- ChestBeltR.isHidden = true;
- ChestBeltR_1.isHidden = true;
- PauldronFlairL.isHidden = true;
- PauldronFlairR.isHidden = true;
-
- init();
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
+//package lance5057.tDefense.armor.renderers.light;
+//
+//import lance5057.tDefense.armor.renderers.ArmorRenderer;
+//import net.minecraft.client.model.ModelRenderer;
+//
+///**
+// * ModelTinkersHauberk - Either Mojang or a mod author
+// * Created using Tabula 4.1.1
+// */
+//public class ModelTinkersHauberk extends ArmorRenderer
+//{
+// public ModelRenderer ChestBeltR;
+// public ModelRenderer ChestBelt;
+// public ModelRenderer ChestBeltR_1;
+// public ModelRenderer ChestBelt_1;
+// public ModelRenderer ChestBeltL;
+// public ModelRenderer ChestBeltL_1;
+// public ModelRenderer ChestBelt_2;
+// public ModelRenderer Pauldron1;
+// public ModelRenderer Pauldron2;
+// public ModelRenderer PauldronStudR;
+// public ModelRenderer Pauldron3R;
+// public ModelRenderer PauldronFlairR;
+// public ModelRenderer Pauldron1L;
+// public ModelRenderer Pauldron2L;
+// public ModelRenderer PauldronStudL;
+// public ModelRenderer Pauldron3L;
+// public ModelRenderer PauldronFlairL;
+//
+// public ModelTinkersHauberk()
+// {
+// super(0.1f, 0, 64, 64);
+//
+// textureWidth = 64;
+// textureHeight = 64;
+//
+// bipedBody = new ModelRenderer(this, "Body");
+// bipedBody.setTextureOffset(16, 16);
+// bipedBody.addBox(-4.0F, 0.0F, -2.0F, 8, 12, 4, 0.05f);
+// bipedBody.setRotationPoint(0.0F, 0.0F + 0, 0.0F);
+//
+// bipedRightArm = new ModelRenderer(this, "Right Arm");
+// bipedRightArm.setTextureOffset(40, 16);
+// bipedRightArm.addBox(-3.0F, -2.0F, -2.0F, 4, 12, 4, 0.05f);
+// bipedRightArm.setRotationPoint(-5.0F, 2.0F + 0, 0.0F);
+//
+// bipedLeftArm = new ModelRenderer(this, "Left Arm");
+// bipedLeftArm.setTextureOffset(40, 16);
+// bipedLeftArm.mirror = true;
+// bipedLeftArm.addBox(-1.0F, -2.0F, -2.0F, 4, 12, 4, 0.05f);
+// bipedLeftArm.setRotationPoint(5.0F, 2.0F + 0, 0.0F);
+//
+// ChestBelt_1 = new ModelRenderer(this, "ChestBelt_1");
+// ChestBelt_1.setTextureOffset(0, 57);
+// ChestBelt_1.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ChestBelt_1.addBox(-4.5F, 9.0F, -2.5F, 9, 2, 5, -0.19F);
+// bipedBody.addChild(ChestBelt_1);
+//
+// ChestBelt_2 = new ModelRenderer(this, "ChestBelt_2");
+// ChestBelt_2.setTextureOffset(28, 32);
+// ChestBelt_2.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ChestBelt_2.addBox(-4.5F, 5.0F, -2.5F, 9, 2, 5, -0.19F);
+// bipedBody.addChild(ChestBelt_2);
+//
+// Pauldron3R = new ModelRenderer(this, "Pauldron3R");
+// Pauldron3R.setTextureOffset(0, 32);
+// Pauldron3R.setRotationPoint(-0.0F, 0.0F, 0.0F);
+// Pauldron3R.addBox(-3.2F, -0.5F, -2.0F, 3, 4, 4, 0.1F);
+// setRotateAngle(Pauldron3R, 0.0F, 0.0F, 0.08726646259971647F);
+// bipedRightArm.addChild(Pauldron3R);
+//
+// Pauldron2L = new ModelRenderer(this, "Pauldron2L");
+// Pauldron2L.setTextureOffset(0, 49);
+// Pauldron2L.mirror = true;
+// Pauldron2L.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Pauldron2L.addBox(-1.0F, -3.0F, -2.0F, 3, 3, 4, 0.1F);
+// setRotateAngle(Pauldron2L, 0.0F, 0.0F, 0.2617993877991494F);
+// bipedLeftArm.addChild(Pauldron2L);
+//
+// Pauldron3L = new ModelRenderer(this, "Pauldron3L");
+// Pauldron3L.setTextureOffset(0, 32);
+// Pauldron3L.mirror = true;
+// Pauldron3L.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Pauldron3L.addBox(0.2F, -0.5F, -2.0F, 3, 4, 4, 0.1F);
+// setRotateAngle(Pauldron3L, 0.0F, 0.0F, -0.08726646259971647F);
+// bipedLeftArm.addChild(Pauldron3L);
+//
+// ChestBeltR = new ModelRenderer(this, "ChestBeltR");
+// ChestBeltR.setTextureOffset(0, 57);
+// ChestBeltR.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ChestBeltR.addBox(-1.7F, 5.7F, -2.5F, 11, 2, 5, -0.2F);
+// setRotateAngle(ChestBeltR, 0.0F, 0.0F, 0.5235987755982988F);
+// bipedBody.addChild(ChestBeltR);
+//
+// ChestBeltL = new ModelRenderer(this, "ChestBeltL");
+// ChestBeltL.setTextureOffset(0, 57);
+// ChestBeltL.mirror = true;
+// ChestBeltL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ChestBeltL.addBox(-7.5F, 2.3F, -2.5F, 11, 2, 5, -0.2F);
+// setRotateAngle(ChestBeltL, 0.0F, 0.0F, -0.5235987755982988F);
+// bipedBody.addChild(ChestBeltL);
+//
+// ChestBeltL_1 = new ModelRenderer(this, "ChestBeltL_1");
+// ChestBeltL_1.setTextureOffset(0, 57);
+// ChestBeltL_1.mirror = true;
+// ChestBeltL_1.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ChestBeltL_1.addBox(-9.3F, 5.7F, -2.5F, 11, 2, 5, -0.21F);
+// setRotateAngle(ChestBeltL_1, 0.0F, 0.0F, -0.5235987755982988F);
+// bipedBody.addChild(ChestBeltL_1);
+//
+// PauldronStudR = new ModelRenderer(this, "PauldronStudR");
+// PauldronStudR.setTextureOffset(14, 32);
+// PauldronStudR.setRotationPoint(-0.0F, 0.0F, 0.0F);
+// PauldronStudR.addBox(-1.0F, -1.5F, -2.5F, 2, 2, 5, 0.1F);
+// setRotateAngle(PauldronStudR, 0.0F, 0.0F, -0.2617993877991494F);
+// bipedRightArm.addChild(PauldronStudR);
+//
+// Pauldron1 = new ModelRenderer(this, "Pauldron1");
+// Pauldron1.setTextureOffset(0, 40);
+// Pauldron1.setRotationPoint(-0.0F, 0.0F, 0.0F);
+// Pauldron1.addBox(-3.5F, -1.9F, -2.5F, 4, 4, 5, 0.0F);
+// setRotateAngle(Pauldron1, 0.0F, 0.0F, 0.2617993877991494F);
+// bipedRightArm.addChild(Pauldron1);
+//
+// ChestBeltR_1 = new ModelRenderer(this, "ChestBeltR_1");
+// ChestBeltR_1.setTextureOffset(0, 57);
+// ChestBeltR_1.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ChestBeltR_1.addBox(-3.5F, 2.3F, -2.5F, 11, 2, 5, -0.21F);
+// setRotateAngle(ChestBeltR_1, 0.0F, 0.0F, 0.5235987755982988F);
+// bipedBody.addChild(ChestBeltR_1);
+//
+// PauldronFlairR = new ModelRenderer(this, "PauldronFlairR");
+// PauldronFlairR.setTextureOffset(18, 39);
+// PauldronFlairR.mirror = true;
+// PauldronFlairR.setRotationPoint(-0.0F, 0.0F, 0.0F);
+// PauldronFlairR.addBox(-8.5F, -4.5F, 0.0F, 7, 9, 0, 0.0F);
+// setRotateAngle(PauldronFlairR, 0.0F, 0.0F, 0.2617993877991494F);
+// bipedRightArm.addChild(PauldronFlairR);
+//
+// PauldronFlairL = new ModelRenderer(this, "PauldronFlairL");
+// PauldronFlairL.setTextureOffset(18, 39);
+// PauldronFlairL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// PauldronFlairL.addBox(1.5F, -4.5F, 0.0F, 7, 9, 0, 0.0F);
+// setRotateAngle(PauldronFlairL, 0.0F, 0.0F, -0.2617993877991494F);
+// bipedLeftArm.addChild(PauldronFlairL);
+//
+// Pauldron2 = new ModelRenderer(this, "Pauldron2");
+// Pauldron2.setTextureOffset(0, 49);
+// Pauldron2.setRotationPoint(-0.0F, 0.0F, 0.0F);
+// Pauldron2.addBox(-2.0F, -3.0F, -2.0F, 3, 3, 4, 0.1F);
+// setRotateAngle(Pauldron2, 0.0F, 0.0F, -0.2617993877991494F);
+// bipedRightArm.addChild(Pauldron2);
+//
+// PauldronStudL = new ModelRenderer(this, "PauldronStudL");
+// PauldronStudL.setTextureOffset(14, 32);
+// PauldronStudL.mirror = true;
+// PauldronStudL.setRotationPoint(0.0F, 0.0F, 0.0F);
+// PauldronStudL.addBox(-1.0F, -1.5F, -2.5F, 2, 2, 5, 0.1F);
+// setRotateAngle(PauldronStudL, 0.0F, 0.0F, 0.2617993877991494F);
+// bipedLeftArm.addChild(PauldronStudL);
+//
+// Pauldron1L = new ModelRenderer(this, "Pauldron1L");
+// Pauldron1L.setTextureOffset(0, 40);
+// Pauldron1L.mirror = true;
+// Pauldron1L.setRotationPoint(0.0F, 0.0F, 0.0F);
+// Pauldron1L.addBox(-0.5F, -1.9F, -2.5F, 4, 4, 5, 0.0F);
+// setRotateAngle(Pauldron1L, 0.0F, 0.0F, -0.2617993877991494F);
+// bipedLeftArm.addChild(Pauldron1L);
+//
+// ChestBelt = new ModelRenderer(this, "ChestBelt");
+// ChestBelt.setTextureOffset(28, 32);
+// ChestBelt.setRotationPoint(0.0F, 0.0F, 0.0F);
+// ChestBelt.addBox(-4.5F, 3.0F, -2.5F, 9, 2, 5, -0.19F);
+// bipedBody.addChild(ChestBelt);
+//
+// //ChestBelt.isHidden = true;
+// ChestBelt_1.isHidden = true;
+// ChestBelt_2.isHidden = true;
+// ChestBeltL.isHidden = true;
+// ChestBeltL_1.isHidden = true;
+// ChestBeltR.isHidden = true;
+// ChestBeltR_1.isHidden = true;
+// PauldronFlairL.isHidden = true;
+// PauldronFlairR.isHidden = true;
+//
+// init();
+// }
+//
+// /**
+// * This is a helper function from Tabula to set the rotation of model parts
+// */
+// public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
+// {
+// modelRenderer.rotateAngleX = x;
+// modelRenderer.rotateAngleY = y;
+// modelRenderer.rotateAngleZ = z;
+// }
+//}
diff --git a/src/main/java/lance5057/tDefense/baubles/BaublesBase.java b/src/main/java/lance5057/tDefense/baubles/BaublesBase.java
index 7152104..b2af546 100644
--- a/src/main/java/lance5057/tDefense/baubles/BaublesBase.java
+++ b/src/main/java/lance5057/tDefense/baubles/BaublesBase.java
@@ -1,8 +1,40 @@
package lance5057.tDefense.baubles;
+import lance5057.tDefense.baubles.tools.TDBaubles;
import lance5057.tDefense.util.ModuleBase;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
public class BaublesBase extends ModuleBase
{
+ public static BaublesBase instance = new BaublesBase();
+
+ public static BaublesItems items;
+ public static TDBaubles tools;
+
+ @Override
+ public void preInit(FMLPreInitializationEvent e)
+ {
+ items = new BaublesItems();
+ tools = new TDBaubles();
+
+ items.preInit(e);
+ tools.preInit(e);
+ }
+
+ @Override
+ public void init(FMLInitializationEvent e) {
+ // TODO Auto-generated method stub
+ items.init(e);
+ tools.init(e);
+ }
+
+ @Override
+ public void postInit(FMLPostInitializationEvent e) {
+ // TODO Auto-generated method stub
+ items.postInit(e);
+ tools.postInit(e);
+ }
}
diff --git a/src/main/java/lance5057/tDefense/baubles/BaublesClientProxy.java b/src/main/java/lance5057/tDefense/baubles/BaublesClientProxy.java
new file mode 100644
index 0000000..d5603ff
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/baubles/BaublesClientProxy.java
@@ -0,0 +1,91 @@
+package lance5057.tDefense.baubles;
+
+import java.util.Map;
+
+import lance5057.tDefense.Reference;
+import lance5057.tDefense.baubles.renderers.BaubleRenderer;
+import lance5057.tDefense.baubles.renderers.SheatheModel;
+import lance5057.tDefense.baubles.tools.TDBaubles;
+import lance5057.tDefense.core.tools.TDTools;
+import lance5057.tDefense.util.ModuleBase;
+import net.minecraft.client.Minecraft;
+import net.minecraft.client.model.ModelBiped;
+import net.minecraft.client.renderer.block.model.ModelResourceLocation;
+import net.minecraft.client.renderer.entity.RenderPlayer;
+import net.minecraft.item.Item;
+import net.minecraftforge.client.model.ModelLoader;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
+import slimeknights.tconstruct.common.ModelRegisterUtil;
+import slimeknights.tconstruct.library.TinkerRegistryClient;
+import slimeknights.tconstruct.library.client.ToolBuildGuiInfo;
+
+public class BaublesClientProxy {
+
+ public SheatheModel sheathe;
+
+ ToolBuildGuiInfo sheatheGUI;
+
+ public void preInit() {
+ // TODO Auto-generated method stub
+
+ reloadRenderers();
+ }
+
+ public void init() {
+ // TODO Auto-generated method stub
+ Map<String, RenderPlayer> skinMap = Minecraft.getMinecraft().getRenderManager().getSkinMap();
+ RenderPlayer render;
+ render = skinMap.get("default");
+ render.addLayer(new BaubleRenderer());
+
+ render = skinMap.get("slim");
+ render.addLayer(new BaubleRenderer());
+
+ createToolGuis();
+ setupToolGuis();
+ registerToolGuis();
+ }
+
+ public void postInit()
+ {
+ }
+
+ public void registerToolRenderers()
+ {
+ ModelRegisterUtil.registerToolModel(TDBaubles.sheathe);
+ }
+
+ public void createToolGuis()
+ {
+ sheatheGUI = new ToolBuildGuiInfo(TDBaubles.sheathe);
+ }
+
+ public void setupToolGuis()
+ {
+ sheatheGUI.addSlotPosition(34, 15+8);
+ sheatheGUI.addSlotPosition(34, 33+8);
+ sheatheGUI.addSlotPosition(34, 51+8);
+ }
+
+ public void registerToolGuis()
+ {
+ TinkerRegistryClient.addToolBuilding(sheatheGUI);
+ }
+
+ public void reloadRenderers()
+ {
+ sheathe = new SheatheModel();
+ registerToolRenderers();
+ }
+
+ public void setToolGuis()
+ {
+ sheatheGUI.positions.clear();
+ sheatheGUI.addSlotPosition(34, 15);
+ sheatheGUI.addSlotPosition(34, 33);
+ sheatheGUI.addSlotPosition(34, 51);
+ }
+
+}
diff --git a/src/main/java/lance5057/tDefense/baubles/BaublesItems.java b/src/main/java/lance5057/tDefense/baubles/BaublesItems.java
index 729654a..69323bb 100644
--- a/src/main/java/lance5057/tDefense/baubles/BaublesItems.java
+++ b/src/main/java/lance5057/tDefense/baubles/BaublesItems.java
@@ -1,5 +1,28 @@
package lance5057.tDefense.baubles;
-public class BaublesItems {
+import lance5057.tDefense.util.ItemsBase;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
+public class BaublesItems extends ItemsBase
+{
+
+ @Override
+ public void preInit(FMLPreInitializationEvent e) {
+ // TODO Auto-generated method stub
+
+ }
+
+ @Override
+ public void init(FMLInitializationEvent e) {
+ // TODO Auto-generated method stub
+
+ }
+
+ @Override
+ public void postInit(FMLPostInitializationEvent e) {
+ // TODO Auto-generated method stub
+
+ }
}
diff --git a/src/main/java/lance5057/tDefense/baubles/blocks/JewelersBench.java b/src/main/java/lance5057/tDefense/baubles/blocks/JewelersBench.java
deleted file mode 100644
index e7f54fb..0000000
--- a/src/main/java/lance5057/tDefense/baubles/blocks/JewelersBench.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package lance5057.tDefense.baubles.blocks;
-
-import lance5057.tDefense.baubles.tileentities.TileEntity_JewelersBench;
-import net.minecraft.block.Block;
-import net.minecraft.block.ITileEntityProvider;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class JewelersBench extends Block implements ITileEntityProvider
-{
-
- public JewelersBench()
- {
- super(Material.iron);
- }
-
- //You don't want the normal render type, or it wont render properly.
- @Override
- public int getRenderType()
- {
- return -1;
- }
-
- //It's not an opaque cube, so you need this.
- @Override
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- //It's not a normal block, so you need this too.
- @Override
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- //This is the icon to use for showing the block in your hand.
- @SideOnly(Side.CLIENT)
- @Override
- public void registerBlockIcons(IIconRegister icon)
- {
- blockIcon = icon.registerIcon("tinkersdefense:WIP");
- }
-
- @Override
- public TileEntity createNewTileEntity(World w, int md)
- {
- final TileEntity_JewelersBench te = new TileEntity_JewelersBench();
- return te;
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/baubles/models/ModelJewelersBench.java b/src/main/java/lance5057/tDefense/baubles/models/ModelJewelersBench.java
deleted file mode 100644
index 164c522..0000000
--- a/src/main/java/lance5057/tDefense/baubles/models/ModelJewelersBench.java
+++ /dev/null
@@ -1,104 +0,0 @@
-package lance5057.tDefense.baubles.models;
-
-import net.minecraft.client.model.ModelBase;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-/**
- * JewelersBench - lance5057
- * Created using Tabula 4.1.1
- */
-public class ModelJewelersBench extends ModelBase
-{
- public ModelRenderer TableSide2;
- public ModelRenderer SawBlock1;
- public ModelRenderer SawBlock2;
- public ModelRenderer SawBlock3;
- public ModelRenderer SawBlockClamp;
- public ModelRenderer Leg1;
- public ModelRenderer Leg2;
- public ModelRenderer Leg3;
- public ModelRenderer Leg4;
- public ModelRenderer TableTop;
- public ModelRenderer TableBack;
- public ModelRenderer TableSide1;
- public ModelRenderer Drawer;
- public ModelRenderer Handle;
-
- public ModelJewelersBench()
- {
- textureWidth = 64;
- textureHeight = 64;
- SawBlock1 = new ModelRenderer(this, 0, 0);
- SawBlock1.setRotationPoint(2.0F, 8.2F, -12.0F);
- SawBlock1.addBox(0.0F, 0.0F, 0.0F, 1, 1, 4, 0.0F);
- Leg4 = new ModelRenderer(this, 0, 0);
- Leg4.setRotationPoint(6.0F, 10.0F, 6.0F);
- Leg4.addBox(0.0F, 0.0F, 0.0F, 2, 14, 2, 0.0F);
- Drawer = new ModelRenderer(this, 0, 46);
- Drawer.setRotationPoint(-6.0F, 11.5F, -8.0F);
- Drawer.addBox(0.0F, 0.0F, 0.0F, 12, 2, 16, 0.0F);
- TableSide2 = new ModelRenderer(this, 0, 0);
- TableSide2.setRotationPoint(-8.0F, 7.0F, -7.0F);
- TableSide2.addBox(0.0F, 0.0F, 0.0F, 1, 1, 14, 0.0F);
- Leg2 = new ModelRenderer(this, 0, 0);
- Leg2.setRotationPoint(6.0F, 10.0F, -8.0F);
- Leg2.addBox(0.0F, 0.0F, 0.0F, 2, 14, 2, 0.0F);
- TableSide1 = new ModelRenderer(this, 0, 0);
- TableSide1.setRotationPoint(7.0F, 7.0F, -7.0F);
- TableSide1.addBox(0.0F, 0.0F, 0.0F, 1, 1, 14, 0.0F);
- SawBlock3 = new ModelRenderer(this, 0, 0);
- SawBlock3.setRotationPoint(3.0F, 8.2F, -11.0F);
- SawBlock3.addBox(0.0F, 0.0F, 0.0F, 1, 1, 3, 0.0F);
- Handle = new ModelRenderer(this, 55, 0);
- Handle.setRotationPoint(-2.0F, 12.0F, -9.0F);
- Handle.addBox(0.0F, 0.0F, 0.0F, 4, 1, 1, 0.0F);
- Leg1 = new ModelRenderer(this, 0, 0);
- Leg1.setRotationPoint(-8.0F, 10.0F, -8.0F);
- Leg1.addBox(0.0F, 0.0F, 0.0F, 2, 14, 2, 0.0F);
- TableTop = new ModelRenderer(this, 0, 28);
- TableTop.setRotationPoint(-8.0F, 8.0F, -8.0F);
- TableTop.addBox(0.0F, 0.0F, 0.0F, 16, 2, 16, 0.0F);
- TableBack = new ModelRenderer(this, 0, 0);
- TableBack.setRotationPoint(-8.0F, 7.0F, 7.0F);
- TableBack.addBox(0.0F, 0.0F, 0.0F, 16, 1, 1, 0.0F);
- SawBlockClamp = new ModelRenderer(this, 54, 0);
- SawBlockClamp.setRotationPoint(1.5F, 8.0F, -9.0F);
- SawBlockClamp.addBox(0.0F, 0.0F, 0.0F, 4, 2, 1, 0.0F);
- Leg3 = new ModelRenderer(this, 0, 0);
- Leg3.setRotationPoint(-8.0F, 10.0F, 6.0F);
- Leg3.addBox(0.0F, 0.0F, 0.0F, 2, 14, 2, 0.0F);
- SawBlock2 = new ModelRenderer(this, 0, 0);
- SawBlock2.setRotationPoint(4.0F, 8.2F, -12.0F);
- SawBlock2.addBox(0.0F, 0.0F, 0.0F, 1, 1, 4, 0.0F);
- }
-
- @Override
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
- {
- SawBlock1.render(f5);
- Leg4.render(f5);
- Drawer.render(f5);
- TableSide2.render(f5);
- Leg2.render(f5);
- TableSide1.render(f5);
- SawBlock3.render(f5);
- Handle.render(f5);
- Leg1.render(f5);
- TableTop.render(f5);
- TableBack.render(f5);
- SawBlockClamp.render(f5);
- Leg3.render(f5);
- SawBlock2.render(f5);
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/baubles/models/Renderer_JewelersBench.java b/src/main/java/lance5057/tDefense/baubles/models/Renderer_JewelersBench.java
deleted file mode 100644
index 8f5608c..0000000
--- a/src/main/java/lance5057/tDefense/baubles/models/Renderer_JewelersBench.java
+++ /dev/null
@@ -1,43 +0,0 @@
-package lance5057.tDefense.baubles.models;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
-import net.minecraft.entity.Entity;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ResourceLocation;
-
-import org.lwjgl.opengl.GL11;
-
-public class Renderer_JewelersBench extends TileEntitySpecialRenderer
-{
- private final ModelJewelersBench model;
-
- public Renderer_JewelersBench()
- {
- model = new ModelJewelersBench();
- }
-
- @Override
- public void renderTileEntityAt(TileEntity te, double x, double y, double z, float scale)
- {
- GL11.glPushMatrix();
- GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
-
- final ResourceLocation textures = (new ResourceLocation(
- "tinkersdefense:textures/blocks/jewelersbench.png"));
-
- Minecraft.getMinecraft().renderEngine.bindTexture(textures);
-
- GL11.glPushMatrix();
-
- te.getBlockMetadata();
-
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
-
- model.render((Entity) null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
- GL11.glPopMatrix();
- GL11.glPopMatrix();
-
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/baubles/renderers/BaubleRenderer.java b/src/main/java/lance5057/tDefense/baubles/renderers/BaubleRenderer.java
new file mode 100644
index 0000000..8c6aec3
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/baubles/renderers/BaubleRenderer.java
@@ -0,0 +1,108 @@
+package lance5057.tDefense.baubles.renderers;
+
+import lance5057.tDefense.core.tools.Shield;
+import lance5057.tDefense.core.tools.Zweihander;
+import net.minecraft.client.Minecraft;
+import net.minecraft.client.renderer.GlStateManager;
+import net.minecraft.client.renderer.OpenGlHelper;
+import net.minecraft.client.renderer.block.model.ItemCameraTransforms;
+import net.minecraft.client.renderer.entity.layers.LayerRenderer;
+import net.minecraft.client.renderer.texture.TextureMap;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.inventory.EntityEquipmentSlot;
+import net.minecraft.item.ItemShield;
+import net.minecraft.item.ItemStack;
+import net.minecraft.item.ItemSword;
+import net.minecraft.util.EnumHand;
+import slimeknights.tconstruct.library.tools.ToolCore;
+import slimeknights.tconstruct.tools.melee.item.Cleaver;
+
+public class BaubleRenderer implements LayerRenderer<EntityPlayer> {
+
+ @Override
+ public void doRenderLayer(EntityPlayer entitylivingbaseIn, float limbSwing, float limbSwingAmount,
+ float partialTicks, float ageInTicks, float netHeadYaw, float headPitch, float scale) {
+
+// ItemStack stack = entitylivingbaseIn.inventory.getStackInSlot(0);
+// ItemStack stackShield = entitylivingbaseIn.inventory.getStackInSlot(1);
+//
+// ItemStack stackTest = entitylivingbaseIn.getHeldItem(EnumHand.MAIN_HAND);
+//
+// if (stack != null
+// && (stack.getItem() instanceof ToolCore || stack.getItem() instanceof ItemSword)
+// && !(stack.getItem() instanceof Shield)
+// && stack != stackTest) {
+// GlStateManager.pushMatrix();
+// Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.LOCATION_BLOCKS_TEXTURE);
+//// Helper.rotateIfSneaking(player);
+//// boolean armor = !player.getItemStackFromSlot(EntityEquipmentSlot.LEGS).isEmpty();
+// //GlStateManager.rotate(90, 0, 1, 0);
+// GlStateManager.rotate(20, 0, 0, 1);
+// GlStateManager.translate(-0.125, 0.1, 0.25);
+// //GlStateManager.scale(0.55, 0.55, 0.55);
+//
+//// if (renderedOne)
+//// GlStateManager.translate(0F, 0F, armor ? 0.55F : 0.5F);
+//// else
+//// GlStateManager.translate(0F, 0F, armor ? -0.55F : -0.5F);
+//
+// if(stack.getItem() instanceof Zweihander || stack.getItem() instanceof Cleaver)
+// {
+// GlStateManager.scale(1.5F, 1.5F, 0.75F);
+// GlStateManager.translate(0.1, 0.1, 0);
+// }
+// else
+// GlStateManager.scale(0.75F, 0.75F, 0.75F);
+//
+// GlStateManager.color(1F, 1F, 1F);
+// int light = 15728880;
+// int lightmapX = light % 65536;
+// int lightmapY = light / 65536;
+// OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, lightmapX, lightmapY);
+// Minecraft.getMinecraft().getRenderItem().renderItem(stack, ItemCameraTransforms.TransformType.NONE);
+// GlStateManager.popMatrix();
+// }
+//
+// //Shield
+// if (stackShield != null
+// && (stackShield.getItem() instanceof Shield || stackShield.getItem() instanceof ItemShield)
+// && stackShield != stackTest) {
+// GlStateManager.pushMatrix();
+// Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.LOCATION_BLOCKS_TEXTURE);
+//// Helper.rotateIfSneaking(player);
+//// boolean armor = !player.getItemStackFromSlot(EntityEquipmentSlot.LEGS).isEmpty();
+// //GlStateManager.rotate(90, 0, 1, 0);
+// GlStateManager.rotate(160, 0, 0, 1);
+// GlStateManager.translate(0.125, -0.3, 0.3);
+// //GlStateManager.scale(0.55, 0.55, 0.55);
+//
+//// if (renderedOne)
+//// GlStateManager.translate(0F, 0F, armor ? 0.55F : 0.5F);
+//// else
+//// GlStateManager.translate(0F, 0F, armor ? -0.55F : -0.5F);
+//
+// if(stackShield.getItem() instanceof ItemShield)
+// {
+// //GlStateManager.scale(1.5F, 1.5F, 0.75F);
+// GlStateManager.translate(0.5, 0.5, 0.5);
+// }
+//// else
+// //GlStateManager.scale(0.75F, 0.75F, 0.75F);
+//
+// GlStateManager.color(1F, 1F, 1F);
+// int light = 15728880;
+// int lightmapX = light % 65536;
+// int lightmapY = light / 65536;
+// OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, lightmapX, lightmapY);
+// Minecraft.getMinecraft().getRenderItem().renderItem(stackShield, ItemCameraTransforms.TransformType.NONE);
+// GlStateManager.popMatrix();
+// }
+ }
+
+ @Override
+ public boolean shouldCombineTextures() {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+}
diff --git a/src/main/java/lance5057/tDefense/baubles/renderers/SheatheModel.java b/src/main/java/lance5057/tDefense/baubles/renderers/SheatheModel.java
new file mode 100644
index 0000000..88177ef
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/baubles/renderers/SheatheModel.java
@@ -0,0 +1,128 @@
+package lance5057.tDefense.baubles.renderers;
+
+import lance5057.tDefense.core.tools.Shield;
+import lance5057.tDefense.core.tools.Zweihander;
+import net.minecraft.client.Minecraft;
+import net.minecraft.client.model.ModelBiped;
+import net.minecraft.client.model.ModelRenderer;
+import net.minecraft.client.renderer.GlStateManager;
+import net.minecraft.client.renderer.block.model.ItemCameraTransforms;
+import net.minecraft.client.renderer.texture.TextureMap;
+import net.minecraft.item.ItemShield;
+import net.minecraft.item.ItemStack;
+import slimeknights.tconstruct.tools.melee.item.Cleaver;
+
+/**
+ * Sheathe - Lance5057 Created using Tabula 4.1.1
+ */
+public class SheatheModel extends ModelBiped {
+ public ModelRenderer Sheathe;
+ public ModelRenderer FrontCap;
+ public ModelRenderer WaistBelt;
+ public ModelRenderer BackCap;
+ public ModelRenderer ShoulderBelt;
+
+ public SheatheModel() {
+
+ // rSword = new RenderItem(Minecraft.getMinecraft().getTextureManager(),
+ // null, null);
+
+ this.textureWidth = 64;
+ this.textureHeight = 64;
+
+ this.WaistBelt = new ModelRenderer(this, 0, 32);
+ this.WaistBelt.setRotationPoint(0.0F, 0.0F, 0.0F);
+ this.WaistBelt.addBox(-4.5F, 4.5F, -2.5F, 9, 2, 5, -0.3F);
+ // this.bipedBody.addChild(WaistBelt);
+
+ this.ShoulderBelt = new ModelRenderer(this, 0, 32);
+ this.ShoulderBelt.setRotationPoint(0.0F, 0.0F, 0.0F);
+ this.ShoulderBelt.addBox(-3.0F, 1.0F, -2.5F, 9, 2, 5, -0.3F);
+ this.setRotateAngle(ShoulderBelt, 0.0F, 0.0F, 0.7853981633974483F);
+ // this.bipedBody.addChild(ShoulderBelt);
+
+ this.BackCap = new ModelRenderer(this, 0, 39);
+ this.BackCap.setRotationPoint(0.0F, 0.0F, 0.0F);
+ this.BackCap.addBox(-2.2F, 3.6F, -2.8F, 3, 3, 2, -0.4F);
+ this.setRotateAngle(BackCap, 0.0F, 0.0F, -0.4363323129985824F);
+ // this.bipedBody.addChild(BackCap);
+
+ this.FrontCap = new ModelRenderer(this, 0, 39);
+ this.FrontCap.setRotationPoint(0.0F, 0.0F, 0.0F);
+ this.FrontCap.addBox(-2.2F, 3.6F, 0.7F, 3, 3, 2, -0.4F);
+ this.setRotateAngle(FrontCap, 0.0F, 0.0F, -0.4363323129985824F);
+ // this.bipedBody.addChild(FrontCap);
+
+ this.Sheathe = new ModelRenderer(this, 28, 32);
+ this.Sheathe.setRotationPoint(0.0F, 0.0F, 0.0F);
+ this.Sheathe.addBox(-1.1F, 1.0F, 3.5F, 11, 3, 1, 0.2F);
+ this.setRotateAngle(Sheathe, 0.0F, 0.0F, 1.1344640137963142F);
+ // this.bipedBody.addChild(Sheathe);
+ }
+
+ public void render(float f5, ItemStack weapon, ItemStack shield, ItemStack active, ItemStack offhand) {
+
+ WaistBelt.render(f5);
+ ShoulderBelt.render(f5);
+ BackCap.render(f5);
+ FrontCap.render(f5);
+ Sheathe.render(f5);
+
+
+ Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.LOCATION_BLOCKS_TEXTURE);
+
+ if (weapon != null && active != weapon) {
+ GlStateManager.pushMatrix();
+
+ GlStateManager.rotate(20, 0, 0, 1);
+ float s = 13f;
+ GlStateManager.scale(s, s, s);
+ GlStateManager.translate(-0.1F, 0.175f, 0.3f);
+
+ if(weapon.getItem() instanceof Zweihander || weapon.getItem() instanceof Cleaver)
+ {
+ GlStateManager.scale(2f, 2f, 1f);
+ }
+
+ Minecraft.getMinecraft().getRenderItem().renderItem(weapon, ItemCameraTransforms.TransformType.NONE);
+
+ GlStateManager.popMatrix();
+ }
+
+ if (shield != null && shield != active
+ && (shield.getItem() instanceof ItemShield || shield.getItem() instanceof Shield)) {
+ GlStateManager.pushMatrix();
+
+ GlStateManager.rotate(20, 0, 0, 1);
+ float s = 13f;
+ GlStateManager.scale(s, s, s);
+ GlStateManager.translate(-0.1F, 0.175f, 0.3f);
+
+ if (shield.getItem() instanceof Shield) {
+
+ GlStateManager.rotate(180 - 45, 0, 0, 1);
+ GlStateManager.translate(-0.0F, -0.3f, 0.1f);
+ GlStateManager.scale(1.35, 1.35, 1.35);
+ } else {
+ GlStateManager.rotate(180 - 45, 0, 0, 1);
+ GlStateManager.translate(0.7F, 0.2f, 0.7f);
+ GlStateManager.scale(1.35, 1.35, 1.35);
+ }
+
+ Minecraft.getMinecraft().getRenderItem().renderItem(shield, ItemCameraTransforms.TransformType.NONE);
+
+ GlStateManager.popMatrix();
+ }
+
+
+ }
+
+ /**
+ * This is a helper function from Tabula to set the rotation of model parts
+ */
+ public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z) {
+ modelRenderer.rotateAngleX = x;
+ modelRenderer.rotateAngleY = y;
+ modelRenderer.rotateAngleZ = z;
+ }
+}
diff --git a/src/main/java/lance5057/tDefense/baubles/tools/BaubleTool.java b/src/main/java/lance5057/tDefense/baubles/tools/BaubleTool.java
new file mode 100644
index 0000000..b393100
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/baubles/tools/BaubleTool.java
@@ -0,0 +1,152 @@
+package lance5057.tDefense.baubles.tools;
+
+import java.util.List;
+
+import javax.annotation.Nullable;
+
+import baubles.api.BaubleType;
+import baubles.api.IBauble;
+import baubles.api.render.IRenderBauble;
+import lance5057.tDefense.core.materials.ShieldMaterialStats;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.client.entity.EntityPlayerSP;
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.EntityLivingBase;
+import net.minecraft.entity.IProjectile;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.projectile.EntityArrow;
+import net.minecraft.item.EnumAction;
+import net.minecraft.item.IItemPropertyGetter;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.ActionResult;
+import net.minecraft.util.DamageSource;
+import net.minecraft.util.EnumActionResult;
+import net.minecraft.util.EnumFacing;
+import net.minecraft.util.EnumHand;
+import net.minecraft.util.ResourceLocation;
+import net.minecraft.util.math.BlockPos;
+import net.minecraft.world.World;
+import net.minecraftforge.fml.common.Optional;
+import net.minecraftforge.fml.relauncher.Side;
+import net.minecraftforge.fml.relauncher.SideOnly;
+import slimeknights.tconstruct.library.client.model.ToolModelLoader;
+import slimeknights.tconstruct.library.tinkering.PartMaterialType;
+import slimeknights.tconstruct.library.tools.ToolCore;
+import slimeknights.tconstruct.library.tools.ToolNBT;
+import slimeknights.tconstruct.tools.TinkerTools;
+
+//@Optional.InterfaceList({@Optional.Interface(modid = "battlegear2", iface = "mods.battlegear2.api.ISheathed"), @Optional.Interface(modid = "battlegear2", iface = "mods.battlegear2.api.shield.IArrowCatcher"), @Optional.Interface(modid = "battlegear2", iface = "mods.battlegear2.api.shield.IArrowDisplay"), @Optional.Interface(modid = "battlegear2", iface = "mods.battlegear2.api.shield.IShield")})
+public abstract class BaubleTool extends ToolCore implements IBauble, IRenderBauble
+{
+ //protected static PartMaterialType ShieldMat = new PartMaterialType(TinkerTools.largePlate, ShieldMaterialStats.TYPE);
+
+ public BaubleTool(PartMaterialType... requiredComponents)
+ {
+ super(requiredComponents);
+
+// this.addPropertyOverride(new ResourceLocation("block"), new IItemPropertyGetter()
+// {
+// @SideOnly(Side.CLIENT)
+// public float apply(ItemStack stack, @Nullable World worldIn, @Nullable EntityLivingBase entityIn)
+// {
+// float i = entityIn != null && entityIn.isHandActive() && entityIn.getActiveItemStack() == stack ? 1.0F : 0.0F;
+// return i;
+// }
+// });
+ }
+
+ protected float baseSpeed()
+ {
+ return 1.5f;
+ }
+
+ protected float effectiveSpeed()
+ {
+ return 15f;
+ }
+
+ public float breakSpeedModifier()
+ {
+ return 1.0f;
+ }
+
+// @Override
+// public float getDigSpeed(ItemStack stack, Block block, int meta)
+// {
+// return 0.0f;
+// }
+
+ /**
+ * returns the action that specifies what animation to play when the items
+ * is being used
+ */
+// @Override
+// public EnumAction getItemUseAction(ItemStack par1ItemStack)
+// {
+// return EnumAction.BLOCK;
+// }
+
+// public ActionResult<ItemStack> onItemRightClick(ItemStack itemStackIn, World worldIn, EntityPlayer playerIn, EnumHand hand)
+// {
+// playerIn.setActiveHand(hand);
+// return new ActionResult(EnumActionResult.SUCCESS, itemStackIn);
+// }
+//
+// public EnumActionResult onItemUse(ItemStack stack, EntityPlayer playerIn, World worldIn, BlockPos pos, EnumHand hand, EnumFacing facing, float hitX, float hitY, float hitZ)
+// {
+// return super.onItemUse(stack, playerIn, worldIn, pos, hand, facing, hitX, hitY, hitZ);
+// }
+
+ /**
+ * How long it takes to use or consume an item
+ */
+ @Override
+ public int getMaxItemUseDuration(ItemStack par1ItemStack)
+ {
+ return 72000;
+ }
+
+ @Override
+ @SideOnly(Side.CLIENT)
+ public void onUpdate(ItemStack stack, World world, Entity entity, int par4, boolean par5)
+ {
+// super.onUpdate(stack, world, entity, par4, par5);
+// if(entity instanceof EntityPlayerSP)
+// {
+// final EntityPlayerSP player = (EntityPlayerSP) entity;
+// final ItemStack usingItem = player.getActiveItemStack();
+// if(usingItem != null && usingItem.getItem() == this)
+// {
+// player.movementInput.moveForward *= 2.5F;
+// player.movementInput.moveStrafe *= 2.5F;
+// }
+// }
+ }
+
+ protected String getHarvestType()
+ {
+ return null;
+ }
+
+ @Override
+ public float damagePotential() {
+ // TODO Auto-generated method stub
+ return 0.1f;
+ }
+
+ @Override
+ public double attackSpeed() {
+ // TODO Auto-generated method stub
+ return 4;
+ }
+
+ @Override
+ public NBTTagCompound buildTag(
+ List<slimeknights.tconstruct.library.materials.Material> materials) {
+ ToolNBT data = buildDefaultTag(materials);
+ return data.get();
+ }
+}
diff --git a/src/main/java/lance5057/tDefense/baubles/tools/Sheathe.java b/src/main/java/lance5057/tDefense/baubles/tools/Sheathe.java
new file mode 100644
index 0000000..f9c62cc
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/baubles/tools/Sheathe.java
@@ -0,0 +1,48 @@
+package lance5057.tDefense.baubles.tools;
+
+import baubles.api.BaubleType;
+import lance5057.tDefense.Reference;
+import lance5057.tDefense.TinkersDefense;
+import lance5057.tDefense.baubles.BaublesBase;
+import lance5057.tDefense.proxy.ClientProxy;
+import net.minecraft.client.Minecraft;
+import net.minecraft.client.renderer.GlStateManager;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.ResourceLocation;
+import slimeknights.tconstruct.library.tinkering.PartMaterialType;
+import slimeknights.tconstruct.tools.TinkerTools;
+
+public class Sheathe extends BaubleTool {
+ private static final ResourceLocation texture = new ResourceLocation(Reference.MOD_ID, "textures/model/sheathe.png");
+
+ public Sheathe(PartMaterialType... requiredComponents) {
+ super(PartMaterialType.head(TinkerTools.largePlate), PartMaterialType.handle(TinkerTools.toolRod),
+ PartMaterialType.extra(TinkerTools.bowString));
+
+ }
+
+ @Override
+ public BaubleType getBaubleType(ItemStack itemstack) {
+ // TODO Auto-generated method stub
+ return BaubleType.BODY;
+ }
+
+ @Override
+ public void onPlayerBaubleRender(ItemStack stack, EntityPlayer player, RenderType type, float partialTicks) {
+ // TODO Auto-generated method stub
+
+ if (type == RenderType.BODY) {
+ float s = 1F / 16F;
+ GlStateManager.scale(s, s, s);
+
+ GlStateManager.enableLighting();
+ GlStateManager.enableRescaleNormal();
+
+ Minecraft.getMinecraft().renderEngine.bindTexture(texture);
+
+ ClientProxy.baubles.sheathe.render(1f, player.inventory.getStackInSlot(0), player.inventory.getStackInSlot(1), player.getHeldItemMainhand(), player.getHeldItemOffhand());
+ }
+ }
+
+}
diff --git a/src/main/java/lance5057/tDefense/baubles/tools/TDBaubles.java b/src/main/java/lance5057/tDefense/baubles/tools/TDBaubles.java
new file mode 100644
index 0000000..f06a217
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/baubles/tools/TDBaubles.java
@@ -0,0 +1,99 @@
+package lance5057.tDefense.baubles.tools;
+
+import com.google.common.eventbus.Subscribe;
+
+import lance5057.tDefense.core.tools.HeaterShield;
+import lance5057.tDefense.core.tools.RoundShield;
+import lance5057.tDefense.core.tools.TDToolEvents;
+import lance5057.tDefense.core.tools.Zweihander;
+import net.minecraft.util.ResourceLocation;
+import net.minecraftforge.common.MinecraftForge;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
+import net.minecraftforge.fml.common.registry.GameRegistry;
+import slimeknights.tconstruct.library.TinkerRegistry;
+import slimeknights.tconstruct.library.tools.ToolCore;
+
+public class TDBaubles
+{
+
+ TDToolEvents events = new TDToolEvents();
+
+ // Tools
+ public static ToolCore sheathe = new Sheathe();
+
+ // Tool Parts
+
+ // Modifiers
+
+ // Helper stuff
+// static List<ToolCore> tools = Lists.newLinkedList(); // contains all tools registered in this pulse
+// static List<ToolPart> toolparts = Lists.newLinkedList(); // ^ all toolparts
+// static List<IModifier> modifiers = Lists.newLinkedList(); // ^ all modifiers
+
+ // PRE-INITIALIZATION
+ @Subscribe
+ public void preInit(FMLPreInitializationEvent event) {
+ // register items
+ MinecraftForge.EVENT_BUS.register(events);
+
+ regToolParts();
+ regTools();
+ registerModifiers();
+
+ // register blocks
+
+ // register entities
+
+ //proxy.preInit();
+ }
+
+ private void regToolParts() {
+ // The order the items are registered in represents the order in the stencil table GUI too
+
+ }
+
+ private void regTools() {
+
+ regTool(sheathe, "sheathe");
+
+ TinkerRegistry.registerToolStationCrafting(sheathe);
+ }
+
+ private void regTool(ToolCore tool, String name)
+ {
+ tool.setRegistryName(new ResourceLocation("tinkersdefense:" + name));
+ TinkerRegistry.registerTool(tool);
+ GameRegistry.register(tool);
+ }
+
+ private void registerModifiers() {
+
+ }
+
+ // INITIALIZATION
+ @Subscribe
+ public void init(FMLInitializationEvent event) {
+ regToolBuilding();
+ regRecipies();
+
+ //proxy.init();
+ }
+
+ private void regToolBuilding() {
+ TinkerRegistry.registerToolCrafting(sheathe);
+ }
+
+ private void regRecipies() {
+
+ }
+
+ // POST-INITIALIZATION
+ @Subscribe
+ public void postInit(FMLPostInitializationEvent event) {
+ //proxy.postInit();
+ }
+
+
+} \ No newline at end of file
diff --git a/src/main/java/lance5057/tDefense/core/CoreBase.java b/src/main/java/lance5057/tDefense/core/CoreBase.java
index 480aebd..d04c248 100644
--- a/src/main/java/lance5057/tDefense/core/CoreBase.java
+++ b/src/main/java/lance5057/tDefense/core/CoreBase.java
@@ -1,11 +1,49 @@
package lance5057.tDefense.core;
+import lance5057.tDefense.util.BlocksBase;
+import lance5057.tDefense.util.ItemsBase;
import lance5057.tDefense.util.ModuleBase;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
+import slimeknights.mantle.client.CreativeTab;
public class CoreBase extends ModuleBase
{
+ public static CreativeTabs tab;
+
+ public ItemsBase items;
+ public BlocksBase blocks;
+
public CoreBase()
{
items = new CoreItems();
+ blocks = new CoreBlocks();
+ }
+
+ @Override
+ public void preInit(FMLPreInitializationEvent e) {
+ tab = new CreativeTab("TDefense_Core", new ItemStack(Items.SHIELD));
+
+ // TODO Auto-generated method stub
+ items.preInit(e);
+ blocks.preInit(e);
+ }
+
+ @Override
+ public void init(FMLInitializationEvent e) {
+ // TODO Auto-generated method stub
+ items.init(e);
+ blocks.init(e);
+ }
+
+ @Override
+ public void postInit(FMLPostInitializationEvent e) {
+ // TODO Auto-generated method stub
+ items.postInit(e);
+ blocks.postInit(e);
}
}
diff --git a/src/main/java/lance5057/tDefense/core/CoreBlocks.java b/src/main/java/lance5057/tDefense/core/CoreBlocks.java
new file mode 100644
index 0000000..58d4ed0
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/core/CoreBlocks.java
@@ -0,0 +1,68 @@
+package lance5057.tDefense.core;
+
+import lance5057.tDefense.core.blocks.crestMount.CrestMount;
+import lance5057.tDefense.util.BlocksBase;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemBlock;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
+import net.minecraftforge.fml.common.registry.GameRegistry;
+
+public class CoreBlocks extends BlocksBase
+{
+
+ public static Block aeonsteelBlock;
+ public static Block dogbeariumBlock;
+ public static Block queensgoldBlock;
+ public static Block greencandyBlock;
+ public static Block redcandyBlock;
+
+ public static ItemBlock aeonsteelItemBlock;
+ public static ItemBlock dogbeariumItemBlock;
+ public static ItemBlock queensgoldItemBlock;
+ public static ItemBlock greencandyItemBlock;
+ public static ItemBlock redcandyItemBlock;
+
+ public static CrestMount crestMount;
+
+ @Override
+ public void preInit(FMLPreInitializationEvent e) {
+ aeonsteelBlock = register("aeonsteelblock", CoreBase.tab, 5);
+ dogbeariumBlock = register("dogbeariumblock", CoreBase.tab, 5);
+ queensgoldBlock = register("queensgoldblock", CoreBase.tab, 5);
+ greencandyBlock = register("greencandyblock", CoreBase.tab, 5);
+ redcandyBlock = register("redcandyblock", CoreBase.tab, 5);
+
+ crestMount = new CrestMount();
+ crestMount.setCreativeTab(CoreBase.tab);
+
+ aeonsteelItemBlock = register("aeonsteelblock", 64, CoreBase.tab, aeonsteelBlock);
+ dogbeariumItemBlock = register("dogbeariumblock", 64, CoreBase.tab, dogbeariumBlock);
+ queensgoldItemBlock = register("queensgoldblock", 64, CoreBase.tab, queensgoldBlock);
+ greencandyItemBlock = register("greencandyblock", 64, CoreBase.tab, greencandyBlock);
+ redcandyItemBlock = register("redcandyblock", 64, CoreBase.tab, redcandyBlock);
+
+// GameRegistry.register(aeonsteelBlock);
+// GameRegistry.register(dogbeariumBlock);
+// GameRegistry.register(queensgoldBlock);
+// GameRegistry.register(greencandyBlock);
+// GameRegistry.register(redcandyBlock);
+ }
+
+ @Override
+ public void init(FMLInitializationEvent e) {
+ // TODO Auto-generated method stub
+
+ }
+
+ @Override
+ public void postInit(FMLPostInitializationEvent e) {
+ // TODO Auto-generated method stub
+
+ }
+
+}
diff --git a/src/main/java/lance5057/tDefense/core/CoreClientProxy.java b/src/main/java/lance5057/tDefense/core/CoreClientProxy.java
new file mode 100644
index 0000000..04c5b0c
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/core/CoreClientProxy.java
@@ -0,0 +1,25 @@
+package lance5057.tDefense.core;
+
+import lance5057.tDefense.util.ModuleBase;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
+
+public class CoreClientProxy
+{
+
+ public void preInit() {
+ CoreBlocks.crestMount.initModel();
+ }
+
+ public void init() {
+ // TODO Auto-generated method stub
+
+ }
+
+ public void postInit() {
+ // TODO Auto-generated method stub
+
+ }
+
+}
diff --git a/src/main/java/lance5057/tDefense/core/CoreCommonProxy.java b/src/main/java/lance5057/tDefense/core/CoreCommonProxy.java
new file mode 100644
index 0000000..bdbc5a9
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/core/CoreCommonProxy.java
@@ -0,0 +1,5 @@
+package lance5057.tDefense.core;
+
+public class CoreCommonProxy {
+
+}
diff --git a/src/main/java/lance5057/tDefense/core/CoreItems.java b/src/main/java/lance5057/tDefense/core/CoreItems.java
index c4a5fa6..85da32d 100644
--- a/src/main/java/lance5057/tDefense/core/CoreItems.java
+++ b/src/main/java/lance5057/tDefense/core/CoreItems.java
@@ -1,12 +1,12 @@
package lance5057.tDefense.core;
-import lance5057.tDefense.Reference;
-import lance5057.tDefense.proxy.ClientProxy;
import lance5057.tDefense.util.ItemsBase;
import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
-import net.minecraftforge.fml.common.registry.GameRegistry;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
public class CoreItems extends ItemsBase
{
@@ -21,18 +21,23 @@ public class CoreItems extends ItemsBase
}
- public void preInit()
+ @Override
+ public void preInit(FMLPreInitializationEvent e)
{
- this.setTab("TDefense_Items", new ItemStack(Items.SHIELD));
}
- public void init()
+ @Override
+ public void init(FMLInitializationEvent e)
{
- item_aeonsteelIngot = register("aeonsteelingot", 64);
- item_queensgoldIngot = register("queensgoldingot", 64);
- item_dogbeariumIngot = register("dogbeariumingot", 64);
+ item_aeonsteelIngot = register("aeonsteelingot", 64, CoreBase.tab);
+ item_queensgoldIngot = register("queensgoldingot", 64, CoreBase.tab);
+ item_dogbeariumIngot = register("dogbeariumingot", 64, CoreBase.tab);
+ }
- this.tabName.setDisplayIcon(new ItemStack(item_aeonsteelIngot));
+ @Override
+ public void postInit(FMLPostInitializationEvent e) {
+ // TODO Auto-generated method stub
+
}
}
diff --git a/src/main/java/lance5057/tDefense/core/TD_Patterns.java b/src/main/java/lance5057/tDefense/core/TD_Patterns.java
deleted file mode 100644
index 0f31dc2..0000000
--- a/src/main/java/lance5057/tDefense/core/TD_Patterns.java
+++ /dev/null
@@ -1,60 +0,0 @@
-package lance5057.tDefense.core;
-
-import java.util.List;
-
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import tconstruct.tools.items.Pattern;
-import tconstruct.util.Reference;
-
-public class TD_Patterns extends Pattern
-{
- private static final String[] patternName = new String[] {"rivets", "clasp", "armorplate", "cloth", "chainmaille"};
-
- public TD_Patterns(String patternType, String name)
- {
- super(patternName, getPatternNames(patternName, patternType), "patterns/");
-
- setUnlocalizedName(Reference.prefix(name));
- }
-
- public static String[] getPatternNames(String[] patternName, String partType)
- {
- final String[] names = new String[patternName.length];
- for(int i = 0; i < patternName.length; i++)
- {
- names[i] = partType + patternName[i];
- }
- return names;
- }
-
- @Override
- public void getSubItems(Item b, CreativeTabs tab, List list)
- {
- for(int i = 0; i < patternName.length; i++)
- {
- // if (i != 23)
- list.add(new ItemStack(b, 1, i));
- }
- }
-
- @Override
- public int getPatternCost(ItemStack pattern)
- {
- switch(pattern.getItemDamage())
- {
- case 0:
- return 1; //rivets
- case 1:
- return 2; //clasp
- case 2:
- return 8; //armorplate
- case 3:
- return 6; //cloth
- case 4:
- return 6; //chainmaille
- }
- return 0;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/AeonSteelBlock.java b/src/main/java/lance5057/tDefense/core/blocks/AeonSteelBlock.java
deleted file mode 100644
index d4c59e5..0000000
--- a/src/main/java/lance5057/tDefense/core/blocks/AeonSteelBlock.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package lance5057.tDefense.core.blocks;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-
-public class AeonSteelBlock extends Block
-{
-
- public AeonSteelBlock(Material material)
- {
- super(material);
- setHarvestLevel("pickaxe", 2);
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/DogbeariumBlock.java b/src/main/java/lance5057/tDefense/core/blocks/DogbeariumBlock.java
deleted file mode 100644
index 2285b72..0000000
--- a/src/main/java/lance5057/tDefense/core/blocks/DogbeariumBlock.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package lance5057.tDefense.core.blocks;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-
-public class DogbeariumBlock extends Block
-{
-
- public DogbeariumBlock(Material material)
- {
- super(material);
- setHarvestLevel("pickaxe", 2);
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/GreenMintBlock.java b/src/main/java/lance5057/tDefense/core/blocks/GreenMintBlock.java
deleted file mode 100644
index 2e8ff7a..0000000
--- a/src/main/java/lance5057/tDefense/core/blocks/GreenMintBlock.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package lance5057.tDefense.core.blocks;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-
-public class GreenMintBlock extends Block
-{
-
- public GreenMintBlock(Material material)
- {
- super(material);
- setHarvestLevel("pickaxe", 2);
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/QueensGoldBlock.java b/src/main/java/lance5057/tDefense/core/blocks/QueensGoldBlock.java
deleted file mode 100644
index 0d9e3d0..0000000
--- a/src/main/java/lance5057/tDefense/core/blocks/QueensGoldBlock.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package lance5057.tDefense.core.blocks;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-
-public class QueensGoldBlock extends Block
-{
-
- public QueensGoldBlock(Material material)
- {
- super(material);
- setHarvestLevel("pickaxe", 2);
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/RedMintBlock.java b/src/main/java/lance5057/tDefense/core/blocks/RedMintBlock.java
deleted file mode 100644
index ca80865..0000000
--- a/src/main/java/lance5057/tDefense/core/blocks/RedMintBlock.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package lance5057.tDefense.core.blocks;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-
-public class RedMintBlock extends Block
-{
-
- public RedMintBlock(Material material)
- {
- super(material);
- setHarvestLevel("pickaxe", 2);
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/crestMount/CrestMount.java b/src/main/java/lance5057/tDefense/core/blocks/crestMount/CrestMount.java
index 507bef4..b41f9c0 100644
--- a/src/main/java/lance5057/tDefense/core/blocks/crestMount/CrestMount.java
+++ b/src/main/java/lance5057/tDefense/core/blocks/crestMount/CrestMount.java
@@ -1,85 +1,192 @@
package lance5057.tDefense.core.blocks.crestMount;
-import static net.minecraftforge.common.util.ForgeDirection.EAST;
-import static net.minecraftforge.common.util.ForgeDirection.NORTH;
-import static net.minecraftforge.common.util.ForgeDirection.SOUTH;
-import static net.minecraftforge.common.util.ForgeDirection.WEST;
-
import java.util.Random;
+import javax.annotation.Nullable;
+
+import lance5057.tDefense.Reference;
import lance5057.tDefense.TinkersDefense;
-import net.minecraft.block.Block;
import net.minecraft.block.BlockContainer;
+import net.minecraft.block.BlockHorizontal;
+import net.minecraft.block.ITileEntityProvider;
import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
+import net.minecraft.block.properties.IProperty;
+import net.minecraft.block.properties.PropertyDirection;
+import net.minecraft.block.state.BlockStateContainer;
+import net.minecraft.block.state.IBlockState;
+import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.item.EntityItem;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.inventory.IInventory;
+import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.EnumBlockRenderType;
+import net.minecraft.util.EnumFacing;
+import net.minecraft.util.EnumHand;
+import net.minecraft.util.math.AxisAlignedBB;
+import net.minecraft.util.math.BlockPos;
+import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class CrestMount extends BlockContainer
-{
- public CrestMount()
- {
- super(Material.iron);
- setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
+import net.minecraftforge.fml.client.registry.ClientRegistry;
+import net.minecraftforge.fml.common.registry.GameRegistry;
+import net.minecraftforge.fml.relauncher.Side;
+import net.minecraftforge.fml.relauncher.SideOnly;
+
+public class CrestMount extends BlockContainer implements ITileEntityProvider {
+
+ public static final PropertyDirection FACING = BlockHorizontal.FACING;
+ protected static final AxisAlignedBB EAST_AABB = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 0.1875D, 1.0D, 1.0D);
+ protected static final AxisAlignedBB WEST_AABB = new AxisAlignedBB(0.8125D, 0.0D, 0.0D, 1.0D, 1.0D, 1.0D);
+ protected static final AxisAlignedBB SOUTH_AABB = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 1.0D, 1.0D, 0.1875D);
+ protected static final AxisAlignedBB NORTH_AABB = new AxisAlignedBB(0.0D, 0.0D, 0.8125D, 1.0D, 1.0D, 1.0D);
+
+ public CrestMount() {
+ super(Material.IRON);
+ this.setDefaultState(this.blockState.getBaseState().withProperty(FACING, EnumFacing.NORTH));
+
+ this.setRegistryName("crestmount");
+ this.setUnlocalizedName("crestmount");
+
+ GameRegistry.register(this);
+ GameRegistry.register(new ItemBlock(this), getRegistryName());
+ GameRegistry.registerTileEntity(TileEntity_CrestMount.class, Reference.MOD_ID + "_crestmount");
+ }
+
+ @Override
+ protected BlockStateContainer createBlockState() {
+ return new BlockStateContainer(this, new IProperty[] { FACING });
+ }
+
+ @Override
+ public IBlockState getStateFromMeta(int meta)
+ {
+ EnumFacing enumfacing = EnumFacing.getFront(meta);
+
+ if (enumfacing.getAxis() == EnumFacing.Axis.Y)
+ {
+ enumfacing = EnumFacing.NORTH;
+ }
+
+ return this.getDefaultState().withProperty(FACING, enumfacing);
+ }
+
+ @Override
+ public int getMetaFromState(IBlockState state)
+ {
+ return ((EnumFacing)state.getValue(FACING)).getIndex();
+ }
+
+
+ @Override
+ public AxisAlignedBB getBoundingBox(IBlockState state, IBlockAccess source, BlockPos pos) {
+ switch ((EnumFacing) state.getValue(FACING)) {
+ case NORTH:
+ return NORTH_AABB;
+ case SOUTH:
+ return SOUTH_AABB;
+ case WEST:
+ return WEST_AABB;
+ case EAST:
+ default:
+ return EAST_AABB;
+ }
+ }
+
+ @SideOnly(Side.CLIENT)
+ public void initModel() {
+ ClientRegistry.bindTileEntitySpecialRenderer(TileEntity_CrestMount.class, new Renderer_CrestMount());
+ }
+
+ @Override
+ @SideOnly(Side.CLIENT)
+ public boolean shouldSideBeRendered(IBlockState blockState, IBlockAccess blockAccess, BlockPos pos,
+ EnumFacing side) {
+ return false;
+ }
+
+ @Override
+ public boolean isBlockNormalCube(IBlockState blockState) {
+ return false;
+ }
+
+ @Override
+ public boolean isOpaqueCube(IBlockState blockState) {
+ return false;
+ }
+
+ @Override
+ public EnumBlockRenderType getRenderType(IBlockState state) {
+ return EnumBlockRenderType.INVISIBLE;
+ }
+
+ @Override
+ public boolean canPlaceBlockAt(World worldIn, BlockPos pos) {
+ return worldIn.getBlockState(pos.west()).isSideSolid(worldIn, pos.west(), EnumFacing.EAST)
+ || worldIn.getBlockState(pos.east()).isSideSolid(worldIn, pos.east(), EnumFacing.WEST)
+ || worldIn.getBlockState(pos.north()).isSideSolid(worldIn, pos.north(), EnumFacing.SOUTH)
+ || worldIn.getBlockState(pos.south()).isSideSolid(worldIn, pos.south(), EnumFacing.NORTH);
}
@Override
- public void onBlockAdded(World world, int i, int j, int k)
- {
- super.onBlockAdded(world, i, j, k);
- world.markBlockForUpdate(i, j, k);
+ public IBlockState getStateForPlacement(World worldIn, BlockPos pos, EnumFacing facing, float hitX, float hitY,
+ float hitZ, int meta, EntityLivingBase placer) {
+ if (facing.getAxis().isHorizontal() && this.canBlockStay(worldIn, pos, facing)) {
+ return this.getDefaultState().withProperty(FACING, facing);
+ } else {
+ for (EnumFacing enumfacing : EnumFacing.Plane.HORIZONTAL) {
+ if (this.canBlockStay(worldIn, pos, enumfacing)) {
+ return this.getDefaultState().withProperty(FACING, enumfacing);
+ }
+ }
+
+ return this.getDefaultState();
+ }
+ }
+
+ protected boolean canBlockStay(World worldIn, BlockPos pos, EnumFacing facing) {
+ return worldIn.getBlockState(pos.offset(facing.getOpposite())).isSideSolid(worldIn,
+ pos.offset(facing.getOpposite()), facing);
}
@Override
- public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int metadata, float what, float these, float are)
- {
- final TileEntity tileEntity = world.getTileEntity(x, y, z);
- if(tileEntity == null || player.isSneaking())
+ public boolean onBlockActivated(World worldIn, BlockPos pos, IBlockState state, EntityPlayer playerIn,
+ EnumHand hand, @Nullable ItemStack heldItem, EnumFacing side, float hitX, float hitY, float hitZ) {
+ final TileEntity tileEntity = worldIn.getTileEntity(pos);
+ if (tileEntity == null || playerIn.isSneaking())
return false;
- //code to open gui explained later
- player.openGui(TinkersDefense.instance, TinkersDefense.GUI_CREST_INV, player.worldObj, x, y, z);
+ // code to open gui explained later
+ playerIn.openGui(TinkersDefense.instance, TinkersDefense.GUI_CREST_INV, worldIn, 0, 0, 0);
return true;
}
@Override
- public void breakBlock(World world, int x, int y, int z, Block par5, int par6)
- {
- dropItems(world, x, y, z);
- super.breakBlock(world, x, y, z, par5, par6);
+ public void breakBlock(World worldIn, BlockPos pos, IBlockState state) {
+ dropItems(worldIn, pos);
+ super.breakBlock(worldIn, pos, state);
}
- private void dropItems(World world, int x, int y, int z)
- {
+ private void dropItems(World world, BlockPos pos) {
final Random rand = new Random();
- final TileEntity tileEntity = world.getTileEntity(x, y, z);
- if(!(tileEntity instanceof IInventory))
+ final TileEntity tileEntity = world.getTileEntity(pos);
+ if (!(tileEntity instanceof IInventory))
return;
final IInventory inventory = (IInventory) tileEntity;
- for(int i = 0; i < inventory.getSizeInventory(); i++)
- {
+ for (int i = 0; i < inventory.getSizeInventory(); i++) {
final ItemStack item = inventory.getStackInSlot(i);
- if(item != null && item.stackSize > 0)
- {
+ if (item != null && item.stackSize > 0) {
final float rx = rand.nextFloat() * 0.8F + 0.1F;
final float ry = rand.nextFloat() * 0.8F + 0.1F;
final float rz = rand.nextFloat() * 0.8F + 0.1F;
- final EntityItem entityItem = new EntityItem(world, x + rx,
- y + ry, z + rz, new ItemStack(item.getItem(),
- item.stackSize, item.getItemDamage()));
+ final EntityItem entityItem = new EntityItem(world, pos.getX() + rx, pos.getY() + ry, pos.getZ() + rz,
+ new ItemStack(item.getItem(), item.stackSize, item.getItemDamage()));
- if(item.hasTagCompound())
- {
+ if (item.hasTagCompound()) {
entityItem.getEntityItem().setTagCompound((NBTTagCompound) item.getTagCompound().copy());
}
@@ -87,73 +194,49 @@ public class CrestMount extends BlockContainer
entityItem.motionX = rand.nextGaussian() * factor;
entityItem.motionY = rand.nextGaussian() * factor + 0.2F;
entityItem.motionZ = rand.nextGaussian() * factor;
- world.spawnEntityInWorld(entityItem);
+ world.spawnEntity(entityItem);
item.stackSize = 0;
}
}
}
- //You don't want the normal render type, or it wont render properly.
@Override
- public int getRenderType()
- {
- return -1;
- }
-
- //It's not an opaque cube, so you need this.
- @Override
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- //It's not a normal block, so you need this too.
- @Override
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- //This is the icon to use for showing the block in your hand.
- @SideOnly(Side.CLIENT)
- @Override
- public void registerBlockIcons(IIconRegister icon)
- {
- blockIcon = icon.registerIcon("tinkersdefense:item_crestmount");
- }
-
- @Override
- public TileEntity createNewTileEntity(World w, int md)
- {
+ public TileEntity createNewTileEntity(World w, int md) {
final TileEntity_CrestMount te = new TileEntity_CrestMount();
return te;
}
- @Override
- public int onBlockPlaced(World p_149660_1_, int p_149660_2_, int p_149660_3_, int p_149660_4_, int p_149660_5_, float p_149660_6_, float p_149660_7_, float p_149660_8_, int p_149660_9_)
- {
- int j1 = p_149660_9_;
-
- if((p_149660_9_ == 0 || p_149660_5_ == 2) && p_149660_1_.isSideSolid(p_149660_2_, p_149660_3_, p_149660_4_ + 1, NORTH))
- {
- j1 = 1;
- }
-
- if((j1 == 0 || p_149660_5_ == 3) && p_149660_1_.isSideSolid(p_149660_2_, p_149660_3_, p_149660_4_ - 1, SOUTH))
- {
- j1 = 2;
- }
-
- if((j1 == 0 || p_149660_5_ == 4) && p_149660_1_.isSideSolid(p_149660_2_ + 1, p_149660_3_, p_149660_4_, WEST))
- {
- j1 = 3;
- }
-
- if((j1 == 0 || p_149660_5_ == 5) && p_149660_1_.isSideSolid(p_149660_2_ - 1, p_149660_3_, p_149660_4_, EAST))
- {
- j1 = 4;
- }
-
- return j1;
- }
+ // @Override
+ // public void onBlockPlacedBy(World worldIn, BlockPos pos, IBlockState
+ // state, EntityLivingBase placer, ItemStack stack)
+ // {
+ // int j1 = p_149660_9_;
+ //
+ // if((p_149660_9_ == 0 || p_149660_5_ == 2) &&
+ // p_149660_1_.isSideSolid(p_149660_2_, p_149660_3_, p_149660_4_ + 1,
+ // NORTH))
+ // {
+ // j1 = 1;
+ // }
+ //
+ // if((j1 == 0 || p_149660_5_ == 3) && p_149660_1_.isSideSolid(p_149660_2_,
+ // p_149660_3_, p_149660_4_ - 1, SOUTH))
+ // {
+ // j1 = 2;
+ // }
+ //
+ // if((j1 == 0 || p_149660_5_ == 4) && p_149660_1_.isSideSolid(p_149660_2_ +
+ // 1, p_149660_3_, p_149660_4_, WEST))
+ // {
+ // j1 = 3;
+ // }
+ //
+ // if((j1 == 0 || p_149660_5_ == 5) && p_149660_1_.isSideSolid(p_149660_2_ -
+ // 1, p_149660_3_, p_149660_4_, EAST))
+ // {
+ // j1 = 4;
+ // }
+ //
+ // return j1;
+ // }
}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/crestMount/Gui_CrestMount.java b/src/main/java/lance5057/tDefense/core/blocks/crestMount/Gui_CrestMount.java
index 1cb2a2f..d1c0713 100644
--- a/src/main/java/lance5057/tDefense/core/blocks/crestMount/Gui_CrestMount.java
+++ b/src/main/java/lance5057/tDefense/core/blocks/crestMount/Gui_CrestMount.java
@@ -1,14 +1,13 @@
package lance5057.tDefense.core.blocks.crestMount;
+import org.lwjgl.opengl.GL11;
+
import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.network.Message_CrestMount;
import net.minecraft.client.gui.GuiButton;
import net.minecraft.client.gui.inventory.GuiContainer;
import net.minecraft.entity.player.InventoryPlayer;
import net.minecraft.util.ResourceLocation;
-import org.lwjgl.opengl.GL11;
-
public class Gui_CrestMount extends GuiContainer
{
private static final ResourceLocation iconLocation = new ResourceLocation(
@@ -56,7 +55,7 @@ public class Gui_CrestMount extends GuiContainer
}
TinkersDefense.INSTANCE.sendToServer(new Message_CrestMount(
- inventory.xCoord, inventory.yCoord, inventory.zCoord,
+ inventory.getPos(),
inventory.flip));
}
}
diff --git a/src/main/java/lance5057/tDefense/core/network/Handler_CrestMount.java b/src/main/java/lance5057/tDefense/core/blocks/crestMount/Handler_CrestMount.java
index ac4e5a2..f238121 100644
--- a/src/main/java/lance5057/tDefense/core/network/Handler_CrestMount.java
+++ b/src/main/java/lance5057/tDefense/core/blocks/crestMount/Handler_CrestMount.java
@@ -1,21 +1,20 @@
-package lance5057.tDefense.core.network;
+package lance5057.tDefense.core.blocks.crestMount;
-import lance5057.tDefense.core.blocks.crestMount.TileEntity_CrestMount;
import net.minecraft.tileentity.TileEntity;
-import cpw.mods.fml.common.network.simpleimpl.IMessage;
-import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
-import cpw.mods.fml.common.network.simpleimpl.MessageContext;
+import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
+import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
+import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
public class Handler_CrestMount implements IMessageHandler<Message_CrestMount, IMessage>
{
@Override
public IMessage onMessage(Message_CrestMount message, MessageContext ctx)
{
- final TileEntity te = ctx.getServerHandler().playerEntity.worldObj.getTileEntity(message.x, message.y, message.z);
+ final TileEntity te = ctx.getServerHandler().playerEntity.world.getTileEntity(message.pos);
if(te instanceof TileEntity_CrestMount)
{
((TileEntity_CrestMount) te).flip = message.flip;
}
return null;
}
-}
+} \ No newline at end of file
diff --git a/src/main/java/lance5057/tDefense/core/network/Message_CrestMount.java b/src/main/java/lance5057/tDefense/core/blocks/crestMount/Message_CrestMount.java
index 390e638..12a1706 100644
--- a/src/main/java/lance5057/tDefense/core/network/Message_CrestMount.java
+++ b/src/main/java/lance5057/tDefense/core/blocks/crestMount/Message_CrestMount.java
@@ -1,11 +1,12 @@
-package lance5057.tDefense.core.network;
+package lance5057.tDefense.core.blocks.crestMount;
import io.netty.buffer.ByteBuf;
-import cpw.mods.fml.common.network.simpleimpl.IMessage;
+import net.minecraft.util.math.BlockPos;
+import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
public class Message_CrestMount implements IMessage
{
- public int x, y, z;
+ public BlockPos pos;
public boolean[] flip = new boolean[4];
public Message_CrestMount()
@@ -13,11 +14,9 @@ public class Message_CrestMount implements IMessage
}
- public Message_CrestMount(int x, int y, int z, boolean[] flip)
+ public Message_CrestMount(BlockPos pos, boolean[] flip)
{
- this.x = x;
- this.y = y;
- this.z = z;
+ this.pos = pos;
this.flip = flip;
//System.arraycopy(flip, 0, this.flip, 0, flip.length);
@@ -26,9 +25,8 @@ public class Message_CrestMount implements IMessage
@Override
public void fromBytes(ByteBuf buf)
{
- x = buf.readInt();
- y = buf.readInt();
- z = buf.readInt();
+ pos = new BlockPos(buf.readInt(), buf.readInt(), buf.readInt());
+
for(int i = 0; i < flip.length; i++)
{
flip[i] = buf.readBoolean();
@@ -38,13 +36,13 @@ public class Message_CrestMount implements IMessage
@Override
public void toBytes(ByteBuf buf)
{
- buf.writeInt(x);
- buf.writeInt(y);
- buf.writeInt(z);
+ buf.writeInt(pos.getX());
+ buf.writeInt(pos.getY());
+ buf.writeInt(pos.getZ());
for(final boolean element : flip)
{
buf.writeBoolean(element);
}
}
-}
+} \ No newline at end of file
diff --git a/src/main/java/lance5057/tDefense/core/blocks/crestMount/Renderer_CrestMount.java b/src/main/java/lance5057/tDefense/core/blocks/crestMount/Renderer_CrestMount.java
index 67bbcda..d64fac3 100644
--- a/src/main/java/lance5057/tDefense/core/blocks/crestMount/Renderer_CrestMount.java
+++ b/src/main/java/lance5057/tDefense/core/blocks/crestMount/Renderer_CrestMount.java
@@ -1,17 +1,20 @@
package lance5057.tDefense.core.blocks.crestMount;
+import org.lwjgl.opengl.GL11;
+
import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.entity.RenderItem;
+import net.minecraft.client.renderer.RenderItem;
+import net.minecraft.client.renderer.block.model.ItemCameraTransforms;
import net.minecraft.client.renderer.entity.RenderManager;
+import net.minecraft.client.renderer.texture.TextureMap;
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
import net.minecraft.entity.Entity;
import net.minecraft.entity.item.EntityItem;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ResourceLocation;
-
-import org.lwjgl.opengl.GL11;
-
-import tconstruct.library.tools.ToolCore;
+import slimeknights.tconstruct.library.tools.ToolCore;
public class Renderer_CrestMount extends TileEntitySpecialRenderer
{
@@ -28,7 +31,7 @@ public class Renderer_CrestMount extends TileEntitySpecialRenderer
}
@Override
- public void renderTileEntityAt(TileEntity te, double x, double y, double z, float scale)
+ public void renderTileEntityAt(TileEntity te, double x, double y, double z, float partialTicks, int destroyStage)
{
final TileEntity_CrestMount tileEntity = (TileEntity_CrestMount) te;
@@ -64,16 +67,16 @@ public class Renderer_CrestMount extends TileEntitySpecialRenderer
switch(meta)
{
case 1:
- rotation = 0;
+ rotation = 180;
break;
case 2:
- rotation = 180;
+ rotation = 0;
break;
case 3:
- rotation = 90;
+ rotation = -90;
break;
case 4:
- rotation = -90;
+ rotation = 90;
break;
}
GL11.glRotatef(rotation, 0.0F, 1.0F, 0.0F);
@@ -88,143 +91,48 @@ public class Renderer_CrestMount extends TileEntitySpecialRenderer
//Render Inventory
//right slot
- int slot = 1;
- if(tileEntity.getStackInSlot(slot) != null)
- {
- if((entItem == null) || entItem.getEntityItem().getItem() != tileEntity.getStackInSlot(slot).getItem())
- {
- entItem = new EntityItem(tileEntity.getWorldObj(), 0, 0, 0,
- tileEntity.getStackInSlot(slot));
- }
- GL11.glPushMatrix();
- entItem.hoverStart = 0.0F;
- RenderItem.renderInFrame = true;
- GL11.glScalef(2f, 2f, 2f);
- GL11.glRotatef(90, 0, 0, -1);
- GL11.glRotatef(rotation, -1.0F, 0.0F, 0.0F);
- //GL11.glTranslatef(0.4f/*up - down*/, -0.3f/*left - right*/, 0.22f);
- if(tileEntity.flip[1] == true)
- {
- GL11.glRotatef(180, 0, 0, 1);
- GL11.glTranslatef(-0.8f, 0.2f, 0);
- }
-
- if(tileEntity.getStackInSlot(1).getItem() instanceof ToolCore)
- {
- GL11.glRotatef(90F, 0.0F, 0.0F, 1.0F);
- GL11.glTranslatef(-0.505f, -0.32f, 0);
- }
-
- RenderManager.instance.renderEntityWithPosYaw(entItem, 0.4f/*up - down*/, -0.3f/*left - right*/, 0.23f, 0, 0);
- RenderItem.renderInFrame = false;
- GL11.glPopMatrix();
- }
+ renderSlot(tileEntity, x, y, z, 1, rotation, tileEntity.flip[1]);
//left slot
- slot = 0;
- if(tileEntity.getStackInSlot(slot) != null)
- {
- if((entItem2 == null) || entItem2.getEntityItem().getItem() != tileEntity.getStackInSlot(slot).getItem())
- {
- entItem2 = new EntityItem(tileEntity.getWorldObj(), x, y, z,
- tileEntity.getStackInSlot(slot));
- }
- GL11.glPushMatrix();
- entItem2.hoverStart = 0.0F;
- RenderItem.renderInFrame = true;
- //GL11.glTranslatef((float)te.xCoord + 0.5F, (float)te.yCoord + 1.02F, (float)te.zCoord + 0.3F);
- GL11.glScalef(2f, 2f, 2f);
- GL11.glRotatef(180, 0, 0, 1);
- GL11.glRotatef(rotation, 0.0F, -1.0F, 0.0F);
- if(tileEntity.flip[0] == true)
- {
- GL11.glRotatef(180, 0, 0, 1);
- GL11.glTranslatef(0.2f, -0.8f, 0);
- }
-
- if(tileEntity.getStackInSlot(0).getItem() instanceof ToolCore)
- {
- GL11.glRotatef(90F, 0.0F, 0.0F, 1.0F);
- GL11.glTranslatef(0.5f, -0.325f, 0);
- }
-
- RenderManager.instance.renderEntityWithPosYaw(entItem2, -0.1, 0.2, 0.23, 0, 0);
- RenderItem.renderInFrame = false;
- GL11.glPopMatrix();
- }
+ renderSlot(tileEntity, x, y, z, 0, rotation, tileEntity.flip[0]);
//middle slot
- slot = 2;
- if(tileEntity.getStackInSlot(slot) != null)
- {
- if((entItem3 == null) || entItem3.getEntityItem().getItem() != tileEntity.getStackInSlot(slot).getItem())
- {
- entItem3 = new EntityItem(tileEntity.getWorldObj(), x, y, z,
- tileEntity.getStackInSlot(slot));
- }
- GL11.glPushMatrix();
- entItem3.hoverStart = 0.0F;
- RenderItem.renderInFrame = true;
- GL11.glScalef(2f, 2f, 2f);
- if(rotation == 90)
- {
- GL11.glTranslatef(0.3f, 0, 0.0f);
- }
- if(rotation == -90)
- {
- GL11.glTranslatef(-0.3f, 0, 0.0f);
- }
- GL11.glRotatef(225, 0, 0, 1);
- GL11.glRotatef(rotation, 1F, 1F, 0F);
- if(tileEntity.flip[2] == true)
- {
- GL11.glRotatef(180, 0, 0, 1);
- GL11.glTranslatef(-0.5f, -0.5f, 0);
- }
+ renderSlot(tileEntity, x, y, z, 2, rotation, tileEntity.flip[2]);
- if(tileEntity.getStackInSlot(2).getItem() instanceof ToolCore)
- {
- GL11.glRotatef(90F, 0.0F, 0.0F, 1.0F);
- GL11.glTranslatef(-0.1125f, -0.5125f, 0);
- }
+ //shield slot
+ renderSlot(tileEntity, x, y, z, 3, rotation, tileEntity.flip[3]);
- RenderManager.instance.renderEntityWithPosYaw(entItem3, 0.3, 0.1, 0.16, 0, 0);
- RenderItem.renderInFrame = false;
- GL11.glPopMatrix();
- }
+ GL11.glPopMatrix();
- //shield slot
- slot = 3;
- if(tileEntity.getStackInSlot(slot) != null)
+ entItem = null;
+ entItem2 = null;
+ entItem3 = null;
+ entItem4 = null;
+ }
+
+ private void renderSlot(TileEntity_CrestMount te, double x, double y, double z, int slot, float rotation, boolean flip)
+ {
+ if(te.getStackInSlot(slot) != null)
{
- if((entItem4 == null) || entItem4.getEntityItem().getItem() != tileEntity.getStackInSlot(slot).getItem())
- {
- entItem4 = new EntityItem(tileEntity.getWorldObj(), x, y, z,
- tileEntity.getStackInSlot(slot));
- }
GL11.glPushMatrix();
- entItem4.hoverStart = 0.0F;
- RenderItem.renderInFrame = true;
+
+ Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.LOCATION_BLOCKS_TEXTURE);
+
GL11.glScalef(2f, 2f, 2f);
GL11.glRotatef(180, 0.0F, 1.0F, 0.0F);
GL11.glRotatef(rotation, 0.0F, 1.0F, 0.0F);
- if(tileEntity.flip[3] == true)
+
+ if(te.flip[3] == true)
{
GL11.glRotatef(180, 0, 0, 1);
GL11.glTranslatef(0.0f, 1.0f, 0);
}
- RenderManager.instance.renderEntityWithPosYaw(entItem4, 0, -0.7, -0.01, 0, 0);
- RenderItem.renderInFrame = false;
+ Minecraft.getMinecraft().getRenderItem().renderItem(te.getStackInSlot(slot),
+ ItemCameraTransforms.TransformType.NONE);
+
GL11.glPopMatrix();
}
-
- GL11.glPopMatrix();
-
- entItem = null;
- entItem2 = null;
- entItem3 = null;
- entItem4 = null;
}
}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/crestMount/TileEntity_CrestMount.java b/src/main/java/lance5057/tDefense/core/blocks/crestMount/TileEntity_CrestMount.java
index 33a293d..6f63a66 100644
--- a/src/main/java/lance5057/tDefense/core/blocks/crestMount/TileEntity_CrestMount.java
+++ b/src/main/java/lance5057/tDefense/core/blocks/crestMount/TileEntity_CrestMount.java
@@ -6,8 +6,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
+import net.minecraft.network.play.server.SPacketUpdateTileEntity;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.util.Constants;
@@ -27,30 +26,17 @@ public class TileEntity_CrestMount extends TileEntity implements IInventory
}
@Override
- public void updateEntity()
- {
- super.updateEntity();
- // if (!worldObj.isRemote)
- // {
-
- // getWorldObj().markBlockForUpdate(xCoord, yCoord, zCoord);
- // markDirty();
- //
- // }
- }
-
- @Override
- public Packet getDescriptionPacket()
+ public SPacketUpdateTileEntity getUpdatePacket()
{
final NBTTagCompound tag = new NBTTagCompound();
writeToNBT(tag);
- return new S35PacketUpdateTileEntity(xCoord, yCoord, zCoord, 0, tag);
+ return new SPacketUpdateTileEntity(getPos(), 1, tag);
}
@Override
- public void onDataPacket(NetworkManager net, S35PacketUpdateTileEntity pkt)
+ public void onDataPacket(NetworkManager net, SPacketUpdateTileEntity packet)
{
- readFromNBT(pkt.func_148857_g());
+ readFromNBT(packet.getNbtCompound());
}
@Override
@@ -88,19 +74,20 @@ public class TileEntity_CrestMount extends TileEntity implements IInventory
markDirty();
}
return stack;
+
}
- @Override
- public ItemStack getStackInSlotOnClosing(int slot)
- {
- final ItemStack stack = getStackInSlot(slot);
-
- if(stack != null)
- {
- setInventorySlotContents(slot, stack);
- }
- return stack;
- }
+// @Override
+// public ItemStack getStackInSlotOnClosing(int slot)
+// {
+// final ItemStack stack = getStackInSlot(slot);
+//
+// if(stack != null)
+// {
+// setInventorySlotContents(slot, stack);
+// }
+// return stack;
+// }
@Override
public void setInventorySlotContents(int slot, ItemStack itemstack)
@@ -116,13 +103,13 @@ public class TileEntity_CrestMount extends TileEntity implements IInventory
}
@Override
- public String getInventoryName()
+ public String getName()
{
return name;
}
@Override
- public boolean hasCustomInventoryName()
+ public boolean hasCustomName()
{
return name.length() > 0;
}
@@ -134,19 +121,19 @@ public class TileEntity_CrestMount extends TileEntity implements IInventory
}
@Override
- public boolean isUseableByPlayer(EntityPlayer p_70300_1_)
+ public boolean isUsableByPlayer(EntityPlayer player)
{
return true;
}
@Override
- public void openInventory()
+ public void openInventory(EntityPlayer player)
{
}
@Override
- public void closeInventory()
+ public void closeInventory(EntityPlayer player)
{
}
@@ -158,7 +145,7 @@ public class TileEntity_CrestMount extends TileEntity implements IInventory
}
@Override
- public void writeToNBT(NBTTagCompound compound)
+ public NBTTagCompound writeToNBT(NBTTagCompound compound)
{
super.writeToNBT(compound);
if(flip != null)
@@ -170,6 +157,7 @@ public class TileEntity_CrestMount extends TileEntity implements IInventory
}
writeInventoryToNBT(compound);
+ return compound;
}
@Override
@@ -215,4 +203,34 @@ public class TileEntity_CrestMount extends TileEntity implements IInventory
tags.setTag("Items", nbttaglist);
}
+
+ @Override
+ public ItemStack removeStackFromSlot(int index) {
+ // TODO Auto-generated method stub
+ return this.getStackInSlot(index);
+ }
+
+ @Override
+ public int getField(int id) {
+ // TODO Auto-generated method stub
+ return 0;
+ }
+
+ @Override
+ public void setField(int id, int value) {
+ // TODO Auto-generated method stub
+
+ }
+
+ @Override
+ public int getFieldCount() {
+ // TODO Auto-generated method stub
+ return 0;
+ }
+
+ @Override
+ public void clear() {
+ // TODO Auto-generated method stub
+
+ }
}
diff --git a/src/main/java/lance5057/tDefense/core/blocks/ore/TD_Ore.java b/src/main/java/lance5057/tDefense/core/blocks/ore/TD_Ore.java
deleted file mode 100644
index 0778857..0000000
--- a/src/main/java/lance5057/tDefense/core/blocks/ore/TD_Ore.java
+++ /dev/null
@@ -1,41 +0,0 @@
-package lance5057.tDefense.core.blocks.ore;
-
-import java.util.Random;
-
-import lance5057.tDefense.Reference;
-import lance5057.tDefense.TinkersDefense;
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.item.Item;
-
-public class TD_Ore extends Block
-{
- Item drops;
-
- public TD_Ore(Material mat, String name, Item drop)
- {
- super(mat);
- setBlockName(name + "ore");
- setBlockTextureName(Reference.MOD_ID + ":" + name + "ore");
- setCreativeTab(TinkersDefense.tabName);
- setStepSound(soundTypeStone);
- setHardness(10.0f);
- setResistance(20.0f);
- setHarvestLevel("pickaxe", 2);
-
- drops = drop;
- }
-
- @Override
- public Item getItemDropped(int metadata, Random random, int fortune)
- {
- return drops;
- }
-
- @Override
- public int quantityDropped(int meta, int fortune, Random random)
- {
- final int rand = random.nextInt(fortune + 1) + 1;
- return rand;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/entity/EntityHookshotHook.java b/src/main/java/lance5057/tDefense/core/entity/EntityHookshotHook.java
deleted file mode 100644
index 3c24863..0000000
--- a/src/main/java/lance5057/tDefense/core/entity/EntityHookshotHook.java
+++ /dev/null
@@ -1,162 +0,0 @@
-package lance5057.tDefense.core.entity;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.projectile.EntityThrowable;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.MovingObjectPosition.MovingObjectType;
-import net.minecraft.world.World;
-import tconstruct.library.tools.ToolCore;
-
-public class EntityHookshotHook extends EntityThrowable
-{
- public int maxChain;
-
- public static final int DATA_PLAYER = 22;
- public static final int DATA_TARGET = 23;
- public static final int DATA_ARRIVED = 24;
- public static final int DATA_HOOK = 25;
- public static final int HIT_POS_X = 26, HIT_POS_Y = 27,
- HIT_POS_Z = 28;
- public static final int DATA_ITEM = 29;
-
- boolean playerTouching = false;
-
- public EntityHookshotHook(World world)
- {
- super(world);
- }
-
- public EntityHookshotHook(World world, EntityLivingBase entity)
- {
- super(world, entity);
- }
-
- public EntityHookshotHook(World world, double x, double y, double z)
- {
- super(world, x, y, z);
- }
-
- @Override
- protected void entityInit()
- {
- super.entityInit();
- setSize(0.25F, 0.25F);
- dataWatcher.addObject(DATA_PLAYER, "");
- dataWatcher.addObject(DATA_TARGET, -1);
- dataWatcher.addObject(DATA_ARRIVED, (byte) 0);
- dataWatcher.addObject(DATA_HOOK, "");
- dataWatcher.addObject(HIT_POS_X, 0.0F);
- dataWatcher.addObject(HIT_POS_Y, 0.0F);
- dataWatcher.addObject(HIT_POS_Z, 0.0F);
- dataWatcher.addObject(DATA_ITEM, new ItemStack(Blocks.air, 1, 0));
- }
-
- @Override
- protected void onImpact(MovingObjectPosition Op)
- {
- motionX = motionY = motionZ = 0.0D;
- if(Op.typeOfHit == MovingObjectType.BLOCK)
- {
- final Block block = worldObj.getBlock(Op.blockX, Op.blockY, Op.blockZ);
-
- if(!block.getMaterial().blocksMovement())
- {
- return;
- }
- if(ticksExisted < getChainLength())
- {
- dataWatcher.updateObject(DATA_ARRIVED, (byte) 1);
- posX = Op.blockX + 0.5D;
- posY = Op.blockY + 0.5D;
- posZ = Op.blockZ + 0.5D;
- }
- }
- }
-
- @Override
- public void onUpdate()
- {
- super.onUpdate();
- if(ticksExisted > 0)// getChainLength())
- {
- if(worldObj.isRemote && getThrower() instanceof EntityPlayer && ticksExisted % 4 == 0 && dataWatcher.getWatchableObjectByte(DATA_ARRIVED) == (byte) 1)
- {
- ((EntityPlayer) getThrower()).playSound("tinkersdefense:hookshotChain", 1.0F, 1.0F);
- }
- }
- else
- {
- setDead();
- }
- }
-
- @Override
- public EntityLivingBase getThrower()
- {
- final String name = dataWatcher.getWatchableObjectString(DATA_PLAYER);
- if(name == "")
- {
- return null;
- }
- return worldObj.getPlayerEntityByName(name);
- }
-
- @Override
- protected float func_70182_d()
- {
- return 1.25F;
- }
-
- @Override
- protected float getGravityVelocity()
- {
- return 0.0F;
- }
-
- public void setHook(String type)
- {
- dataWatcher.updateObject(DATA_HOOK, type);
- }
-
- public String getHook()
- {
- return dataWatcher.getWatchableObjectString(DATA_HOOK);
- }
-
- public void setHookshot(ItemStack hookshot)
- {
- dataWatcher.updateObject(DATA_ITEM, hookshot);
- }
-
- public ItemStack getHookshot()
- {
- return dataWatcher.getWatchableObjectItemStack(DATA_ITEM);
- }
-
- public String getPlayer()
- {
- return dataWatcher.getWatchableObjectString(DATA_PLAYER);
- }
-
- public void setPlayer(EntityPlayer player)
- {
- dataWatcher.updateObject(DATA_PLAYER, player.getDisplayName());
- }
-
- public int getChainLength()
- {
- final ItemStack tool = dataWatcher.getWatchableObjectItemStack(DATA_ITEM);
- if(tool != null && tool.getItem() instanceof ToolCore)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
-
- return tags.getInteger("ChainLength");
- }
- return 0;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/events/TDEventHandler.java b/src/main/java/lance5057/tDefense/core/events/TDEventHandler.java
deleted file mode 100644
index fd4875c..0000000
--- a/src/main/java/lance5057/tDefense/core/events/TDEventHandler.java
+++ /dev/null
@@ -1,98 +0,0 @@
-package lance5057.tDefense.core.events;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.parts.ClothMaterial;
-import lance5057.tDefense.core.tools.RoundShield;
-import mods.battlegear2.api.PlayerEventChild.ShieldBlockEvent;
-import net.minecraft.entity.EntityLiving;
-import net.minecraft.item.ItemStack;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraftforge.common.MinecraftForge;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.event.PartBuilderEvent;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "battlegear2", iface = "mods.battlegear2.api.PlayerEventChild.ShieldBlockEvent"),})
-public class TDEventHandler
-{
-
- public TDEventHandler()
- {
- MinecraftForge.EVENT_BUS.register(this);
- }
-
- @SubscribeEvent
- public void craftTDPart(PartBuilderEvent.NormalPart event)
- {
- // Cloth
- if(event.pattern.getItem() == TinkersDefense.woodPattern && event.pattern.getItemDamage() == 3)
- {
- ItemStack result = null;
-
- final ClothMaterial mat = (ClothMaterial) TConstructRegistry.getCustomMaterial(event.material, ClothMaterial.class);
- if(mat != null && event.material.stackSize >= 3)
- {
- result = mat.craftingItem.copy();
- }
-
- if(result != null)
- {
- event.overrideResult(new ItemStack[] {result, null});
- }
- }
- }
-
- @SubscribeEvent
- @Optional.Method(modid = "battlegear2")
- public void TD_ShieldBlock(ShieldBlockEvent event)
- {
- if(event.shield.getItem() instanceof RoundShield)
- {
- final EntityLiving entity = (EntityLiving) event.source.getEntity();
- entity.addPotionEffect(new PotionEffect(Potion.moveSlowdown.id, 5,
- 10));
- }
- }
- // public void TD_LivingHurt(LivingHurtEvent event)
- // {
- // if(event.entityLiving instanceof EntityPlayer)
- // event.entityLiving
- // }
-
- // @SubscribeEvent
- // public void dropEasterEggs(LivingDropsEvent event)
- // {
- // if(!event.entityLiving.worldObj.isRemote)
- // {
- // if(event.entityLiving.getHeldItem() != null)
- // if(event.entityLiving.getHeldItem().getItem() == TinkersDefense.item_RedMintcane)
- // event.drops.add(new EntityItem(event.entityLiving.worldObj, event.entityLiving.posX, event.entityLiving.posY, event.entityLiving.posZ, new ItemStack(TinkersDefense.item_RedMintcane,1,0)));
- // if(event.entityLiving.getHeldItem().getItem() == TinkersDefense.item_GreenMintcane)
- // event.drops.add(new EntityItem(event.entityLiving.worldObj, event.entityLiving.posX, event.entityLiving.posY, event.entityLiving.posZ, new ItemStack(TinkersDefense.item_GreenMintcane,1,0)));
- //
- // }
- // }
-
- // @SubscribeEvent
- // public void giveCandyToUndead(LivingSpawnEvent event)
- // {
- // //if(!Minecraft.getMinecraft().theWorld.isRemote)
- // if(TinkersDefense.month == 12)
- // {
- // if(event.entityLiving.isEntityUndead())
- // {
- // Integer chance = Minecraft.getMinecraft().theWorld.rand.nextInt(100);
- // Boolean candy = Minecraft.getMinecraft().theWorld.rand.nextBoolean();
- // if(chance < 25)
- // {
- // if(candy == true)
- // event.entityLiving.setCurrentItemOrArmor(0, new ItemStack(TinkersDefense.item_RedMintcane, 1, 0));
- // else
- // event.entityLiving.setCurrentItemOrArmor(0, new ItemStack(TinkersDefense.item_GreenMintcane, 1, 0));
- // }
- // }
- // }
- // }
-}
diff --git a/src/main/java/lance5057/tDefense/core/gui/GuiTDGuideBook.java b/src/main/java/lance5057/tDefense/core/gui/GuiTDGuideBook.java
deleted file mode 100644
index 638bebf..0000000
--- a/src/main/java/lance5057/tDefense/core/gui/GuiTDGuideBook.java
+++ /dev/null
@@ -1,590 +0,0 @@
-package lance5057.tDefense.core.gui;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import lance5057.tDefense.TinkersDefense;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.gui.FontRenderer;
-import net.minecraft.client.gui.GuiButton;
-import net.minecraft.client.gui.GuiScreen;
-import net.minecraft.client.renderer.RenderHelper;
-import net.minecraft.client.renderer.entity.RenderItem;
-import net.minecraft.client.renderer.texture.TextureManager;
-import net.minecraft.item.ItemBlock;
-import net.minecraft.item.ItemStack;
-import net.minecraft.item.crafting.CraftingManager;
-import net.minecraft.item.crafting.IRecipe;
-import net.minecraft.item.crafting.ShapedRecipes;
-import net.minecraft.item.crafting.ShapelessRecipes;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.oredict.ShapedOreRecipe;
-import net.minecraftforge.oredict.ShapelessOreRecipe;
-
-import org.lwjgl.opengl.GL11;
-
-import tconstruct.library.crafting.ToolBuilder;
-import tconstruct.library.tools.DynamicToolPart;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class GuiTDGuideBook extends GuiScreen
-{
- static RenderItem itemRender = new RenderItem();
- List<Chapter> chapters = new ArrayList<Chapter>();
-
- private int chapter = 0;
- private int page = 0;
-
- private static final ResourceLocation guiLocation = new ResourceLocation(
- "tinkersdefense",
- "textures/gui/guide.png");
-
- private static final ResourceLocation guiLocation2 = new ResourceLocation(
- "tinkersdefense",
- "textures/gui/guide2.png");
-
- public GuiTDGuideBook()
- {
-
- }
-
- @Override
- public void initGui()
- {
- final List<Page> pages = new ArrayList<Page>();
- Page page;
- chapters.add(new Chapter(0, 1));
-
- page = new Page(1, 0);
- pages.add(page);
-
- page = new Page(1, 1, (DynamicToolPart) TinkersDefense.partArmorplate,
- (DynamicToolPart) TinkerTools.toughRod,
- (DynamicToolPart) TinkersDefense.partArmorplate,
- (DynamicToolPart) TinkersDefense.partRivet);
- pages.add(page);
-
- page = new Page(1, 2, (DynamicToolPart) TinkersDefense.partArmorplate,
- (DynamicToolPart) TinkerTools.toolRod,
- (DynamicToolPart) TinkerTools.frypanHead, null);
- pages.add(page);
-
- chapters.add(new Chapter(1, pages));
-
- buttonList.clear();
-
- buttonList.add(new BookButton(0, ((width - 256) / 2) + 3, 240, false,
- 80, 0, 18, 12));
- buttonList.add(new BookButton(1, ((width + 256) / 2) - 3 - 18, 240,
- true, 80, 0, 18, 12));
- buttonList.add(new BookButton(2, ((width - 14) / 2), 238, true, 120, 0,
- 14, 13));
-
- for(int i = 0; i < chapters.size(); i++)
- {
- buttonList.add(chapters.get(i).getButton(3 + i, width, height));
- }
-
- // this.buttonList.add(new BookButton(3, ((this.width + 256) / 2) - 8, 15 + 64, true, 71, 180, 35, 21));
- // this.buttonList.add(new BookButton(4, ((this.width + 256) / 2) - 8, 35 + 64, true, 71, 200, 35, 21));
- // this.buttonList.add(new BookButton(5, ((this.width + 256) / 2) - 8, 55 + 64, true, 71, 220, 35, 21));
- // this.buttonList.add(new BookButton(6, ((this.width + 256) / 2) - 8, 75 + 64, true, 144, 180, 35, 21));
- // this.buttonList.add(new BookButton(7, ((this.width + 256) / 2) - 8, 95 + 64, true, 144, 200, 35, 21));
- //
- //
- ((GuiButton) buttonList.get(chapter + 3)).enabled = false;
- }
-
- @Override
- public void drawScreen(int p_73863_1_, int p_73863_2_, float p_73863_3_)
- {
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
- mc.getTextureManager().bindTexture(guiLocation);
-
- drawTexturedModalRect((width - 256) / 2, (height - 224) / 2, 0, 0, 256, 179);
-
- //chapters.get(chapter - 1).pages.get(page - 1).drawText(fontRendererObj, this.width, this.height);
- if(chapters.size() > 0 && chapters.get(chapter).pages.size() > 0)
- {
- chapters.get(chapter).pages.get(page).draw(this, fontRendererObj, width, height, itemRender);
- }
-
- mc.getTextureManager().bindTexture(guiLocation2);
-
- super.drawScreen(p_73863_1_, p_73863_2_, p_73863_3_);
- }
-
- @Override
- protected void actionPerformed(GuiButton button)
- {
- switch(button.id)
- {
- case 0:
- if(page > 0)
- {
- page--;
- }
- else if(chapter > 0)
- {
- ((GuiButton) buttonList.get(chapter + 3)).enabled = true;
- chapter--;
- page = 0;
- ((GuiButton) buttonList.get(chapter + 3)).enabled = false;
- }
- break;
- case 1:
- if(page + 1 < chapters.get(chapter).pages.size())
- {
- page++;
- }
- else if(chapter + 1 <= chapters.size() - 1)
- {
- ((GuiButton) buttonList.get(chapter + 3)).enabled = true;
- chapter++;
- page = 0;
- ((GuiButton) buttonList.get(chapter + 3)).enabled = false;
- }
- break;
- case 2:
- ((GuiButton) buttonList.get(chapter + 3)).enabled = true;
- chapter = 0;
- page = 0;
- ((GuiButton) buttonList.get(chapter + 3)).enabled = false;
- break;
- default:
- ((GuiButton) buttonList.get(chapter + 3)).enabled = true;
- chapter = button.id - 3;
- page = 0;
- ((GuiButton) buttonList.get(chapter + 3)).enabled = false;
- break;
- }
- }
-
- @SideOnly(Side.CLIENT)
- static class BookButton extends GuiButton
- {
- private final boolean mirror;
-
- int iconX, iconY, iconW, iconH;
-
- public BookButton(int id, int x, int y, boolean mirror, int iconX, int iconY, int iconW, int iconH)
- {
- super(id, x, y, iconW, iconH, "");
- this.mirror = mirror;
- this.iconX = iconX;
- this.iconY = iconY;
- this.iconW = iconW;
- this.iconH = iconH;
- }
-
- /**
- * Draws this button to the screen.
- */
- @Override
- public void drawButton(Minecraft p_146112_1_, int p_146112_2_, int p_146112_3_)
- {
- if(visible)
- {
- final boolean flag = (p_146112_2_ >= xPosition && p_146112_3_ >= yPosition && p_146112_2_ < xPosition + width && p_146112_3_ < yPosition + height) || !enabled;
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
- //p_146112_1_.getTextureManager().bindTexture(guiLocation2);
- int k = iconX;
- int l = iconY;
-
- if(flag)
- {
- k += iconW;
- }
-
- if(!mirror)
- {
- l += iconH;
- }
-
- drawTexturedModalRect(xPosition, yPosition, k, l, iconW, iconH);
- }
- }
-
- }
-
- @SideOnly(Side.CLIENT)
- static class Chapter
- {
- List<Page> pages;
- int buttonU, buttonV;
- int number;
-
- public Chapter(int number, int pages2)
- {
- this.number = number;
-
- pages = new ArrayList<Page>();
-
- for(int i = 0; i < pages2; i++)
- {
- pages.add(new Page(number, i));
- }
- }
-
- public Chapter(int number, List<Page> pages)
- {
- this.number = number;
- this.pages = pages;
- }
-
- public BookButton getButton(int id, int w, int h)
- {
- return new BookButton(id, ((w + 256) / 2) - 8,
- 64 + 15 + (id - 3) * 22, true, 0, (id - 3) * 22, 35, 22);
- }
- }
-
- @SideOnly(Side.CLIENT)
- static class Page
- {
- /* enum TYPES {TEXT, CRAFTING1, CRAFTING2, FORGE1, FORGE2, FORGE3, ALLOY};
- 0 = TEXT
- 1 = CRAFTING1
- 2 = CRAFTING2
- 3 = FORGE1
- 4 = FORGE2
- 5 = FORGE3
- 6 = ALLOY
-
- because apparently java overcomplicated enums to all hell
- */
-
- int type;
- int chapter;
- int page;
-
- List<DynamicToolPart> TCRecipe;
- int TCCycleTimer = 0;
- List<Integer> TCItemCycle = new ArrayList<Integer>();
-
- ItemStack result1, result2, result3;
-
- //Text
- public Page(int chapter, int number)
- {
- type = 0;
- this.chapter = chapter;
- page = number;
- }
-
- /*Crafting 1 recipe
- * recipe - up to 9 stacks
- *
- * list to grid looks like
- * 1 2 3
- * 4 5 6
- * 7 8 9
- */
- public Page(int chapter, int number, ItemStack result)
- {
- type = 1;
- this.chapter = chapter;
- page = number;
- result1 = result;
- }
-
- /*Crafting 2 recipe
- * recipe1 - up to 9 stacks
- * recipe2 - up to 9 stacks
- *
- * list to grid looks like
- * 1 2 3
- * 4 5 6
- * 7 8 9
- */
- public Page(int chapter, int number, ItemStack result1, ItemStack result2)
- {
- type = 2;
- this.chapter = chapter;
- page = number;
-
- this.result1 = result1;
- this.result2 = result2;
- }
-
- public Page(int chapter, int number, DynamicToolPart item1, DynamicToolPart item2, DynamicToolPart item3, DynamicToolPart item4)
- {
- type = 3;
- this.chapter = chapter;
- page = number;
-
- TCRecipe = new ArrayList<DynamicToolPart>();
- TCRecipe.add(item1);
- TCRecipe.add(item2);
- if(item3 != null)
- {
- TCRecipe.add(item3);
- }
- if(item4 != null)
- {
- TCRecipe.add(item4);
- }
- }
-
- public void draw(GuiScreen gui, FontRenderer fontRendererObj, int w, int h, RenderItem itemRender)
- {
- drawText(fontRendererObj, w, h);
- switch(type)
- {
- case 0:
- drawTextRight(fontRendererObj, w, h);
- break;
- case 1:
- drawCraftPage(gui, 1, w, h, fontRendererObj, itemRender);
- break;
- case 2:
- drawCraftPage(gui, 2, w, h, fontRendererObj, itemRender);
- break;
- case 3:
- drawForgePage(gui, 2, w, h, fontRendererObj, itemRender);
- break;
- }
- }
-
- public void drawText(FontRenderer fontRendererObj, int w, int h)
- {
- final int titleSize = fontRendererObj.getStringWidth(StatCollector.translateToLocal("book.chapter" + chapter + ".page" + page + ".titleL"));
- fontRendererObj.drawString(StatCollector.translateToLocal("book.chapter" + chapter + ".page" + page + ".titleL"), ((w - 256) / 2) + 64 - titleSize, 64 + 14, 0);
-
- drawCenteredSplit(((w - 256) / 2) + 68, 84, StatCollector.translateToLocal("book.chapter" + chapter + ".page" + page + ".ContentL"), fontRendererObj);
- }
-
- public void drawTextRight(FontRenderer fontRendererObj, int w, int h)
- {
- final int titleSize = fontRendererObj.getStringWidth(StatCollector.translateToLocal("book.chapter" + chapter + ".page" + page + ".titleR"));
- fontRendererObj.drawString(StatCollector.translateToLocal("book.chapter" + chapter + ".page" + page + ".titleR"), ((w + 256) / 2) - 72 - titleSize, 64 + 14, 0);
-
- drawCenteredSplit(((w + 256) / 2) - 72, 84, StatCollector.translateToLocal("book.chapter" + chapter + ".page" + page + ".ContentR"), fontRendererObj);
- }
-
- private void drawCraftPage(GuiScreen gui, int numOfCrafts, int w, int h, FontRenderer fontRendererObj, RenderItem itemRender)
- {
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
- gui.mc.getTextureManager().bindTexture(guiLocation2);
- final IRecipe recipe;
- switch(numOfCrafts)
- {
- case 1:
- gui.drawTexturedModalRect(w / 2 + 7, h / 2 - 49, 157, 0, 99, 56);
- recipe = lookUpRecipe(result1);
-
- DrawRecipe(fontRendererObj, gui.mc.getTextureManager(), recipe, 10, -46, w, h);
- break;
- case 2:
- gui.drawTexturedModalRect((w - 256) / 2 + 7, 64 + 33, 157, 0, 99, 56);
-
- recipe = lookUpRecipe(result1);
-
- DrawRecipe(fontRendererObj, gui.mc.getTextureManager(), recipe, 7, 60, w, h);
-
- gui.drawTexturedModalRect((w - 256) / 2 + 7, 64 + 94, 157, 0, 99, 56);
- break;
- default:
- break;
- }
- GL11.glEnable(GL11.GL_BLEND);
- }
-
- private void drawForgePage(GuiScreen gui, int numOfCrafts, int w, int h, FontRenderer fontRendererObj, RenderItem itemRender)
- {
- if(TCCycleTimer == 0)
- {
- TCItemCycle.clear();
- for(int i = 0; i < 4; i++)
- {
- TCItemCycle.add(gui.mc.theWorld.rand.nextInt(18));
- }
- TCCycleTimer = 100;
- }
- else
- {
- TCCycleTimer--;
- }
-
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
- RenderHelper.enableGUIStandardItemLighting();
- gui.mc.getTextureManager().bindTexture(guiLocation2);
- gui.drawTexturedModalRect(w / 2 + 7, h / 2 - 48, 157, 57, 99, 40);
-
- itemRender.renderItemAndEffectIntoGUI(fontRendererObj, gui.mc.getTextureManager(), new ItemStack(
- TCRecipe.get(0), 1, TCItemCycle.get(0)), w / 2 + 45, h / 2 - 37);
- itemRender.renderItemAndEffectIntoGUI(fontRendererObj, gui.mc.getTextureManager(), new ItemStack(
- TCRecipe.get(1), 1, TCItemCycle.get(1)), w / 2 + 27, h / 2 - 45);
- itemRender.renderItemAndEffectIntoGUI(fontRendererObj, gui.mc.getTextureManager(), new ItemStack(
- TCRecipe.get(2), 1, TCItemCycle.get(2)), w / 2 + 28, h / 2 - 27);
-
- if(TCRecipe.size() <= 3)
- {
- itemRender.renderItemAndEffectIntoGUI(fontRendererObj, gui.mc.getTextureManager(), ToolBuilder.instance.buildTool(new ItemStack(
- TCRecipe.get(0), 1, TCItemCycle.get(0)), new ItemStack(
- TCRecipe.get(1), 1, TCItemCycle.get(1)), new ItemStack(
- TCRecipe.get(2), 1, TCItemCycle.get(2)), "Result"), w / 2 + 87, h / 2 - 37);
- }
- else
- {
-
- itemRender.renderItemAndEffectIntoGUI(fontRendererObj, gui.mc.getTextureManager(), new ItemStack(
- TCRecipe.get(3), 1, TCItemCycle.get(3)), w / 2 + 11, h / 2 - 37);
- itemRender.renderItemAndEffectIntoGUI(fontRendererObj, gui.mc.getTextureManager(), ToolBuilder.instance.buildTool(new ItemStack(
- TCRecipe.get(0), 1, TCItemCycle.get(0)), new ItemStack(
- TCRecipe.get(1), 1, TCItemCycle.get(1)), new ItemStack(
- TCRecipe.get(2), 1, TCItemCycle.get(2)), new ItemStack(
- TCRecipe.get(3), 1, TCItemCycle.get(3)), "Result"), w / 2 + 87, h / 2 - 37);
- }
-
- GL11.glEnable(GL11.GL_BLEND);
- }
- }
-
- static void drawCenteredSplit(int x, int y, String str, FontRenderer fontRendererObj)
- {
- int index = 0;
- int h = 0;
- int endIndex = 0;
- int spaceIndex = 0;
- while(str.length() > index)
- {
- endIndex = index + 20;
- if(index + 20 > str.length())
- {
- endIndex = str.length();
- }
-
- String sub = "";
- spaceIndex = endIndex;
-
- for(int i = index; i < endIndex; i++)
- {
- final char test = str.toCharArray()[i];
- if(test == ' ')
- {
- spaceIndex = i;
- }
- if(i == endIndex - 1)
- {
- if(test != ' ' && i != str.length() - 1)
- {
- sub = str.substring(index, spaceIndex);
- index = spaceIndex;
- }
- else
- {
- sub = str.substring(index, endIndex);
- index = endIndex;
- }
- }
- }
-
- h += fontRendererObj.FONT_HEIGHT;
- fontRendererObj.drawString(sub, x - fontRendererObj.getStringWidth(sub) / 2, h + y, 0);
- }
- }
-
- static IRecipe lookUpRecipe(ItemStack stack)
- {
- final List<IRecipe> recipes = CraftingManager.getInstance().getRecipeList();
- final Iterator<IRecipe> recipe = recipes.iterator();
-
- while(recipe.hasNext())
- {
- final ItemStack next = recipe.next().getRecipeOutput();
- if(next != null)
- {
- if(next.getItem() == stack.getItem())
- return recipe.next();
- }
- }
- return null;
- }
-
- static void DrawRecipe(FontRenderer font, TextureManager tex, IRecipe recipe, int x, int y, int w, int h)
- {
- if(recipe instanceof ShapelessRecipes)
- {
- final ShapelessRecipes SRecipe = (ShapelessRecipes) recipe;
- for(int i = 0; i < 9; i++)
- {
- if(SRecipe.recipeItems.get(i) != null)
- {
- if(((ItemStack) SRecipe.recipeItems.get(i)).getItem() instanceof ItemBlock)
- {
- RenderHelper.enableStandardItemLighting();
- }
- else
- {
- RenderHelper.enableGUIStandardItemLighting();
- }
- itemRender.renderItemAndEffectIntoGUI(font, tex, (ItemStack) SRecipe.recipeItems.get(i), w / 2 + x + ((i % 3) * 17), h / 2 + y + (i / 3 * 17));
- }
- }
- }
- else if(recipe instanceof ShapedOreRecipe)
- {
- // final ShapedOreRecipe SRecipe = (ShapedOreRecipe) recipe;
- // for(int i = 0; i < 9; i++)
- // {
- // if(SRecipe.getInput() != null && OreDictionary. SRecipe.getInput()[i] instanceof ItemStack)
- // {
- // if(((ItemStack) SRecipe.getInput()[i]).getItem() instanceof ItemBlock)
- // {
- // RenderHelper.enableStandardItemLighting();
- // }
- // else
- // {
- // RenderHelper.enableGUIStandardItemLighting();
- // }
- // itemRender.renderItemAndEffectIntoGUI(font, tex, (ItemStack) SRecipe.getInput()[i], w / 2 + x + ((i % 3) * 17), h / 2 + y + (i / 3 * 17));
- // }
- // }
- }
- else if(recipe instanceof ShapelessOreRecipe)
- {
- // final ShapelessOreRecipe SRecipe = (ShapelessOreRecipe) recipe;
- // for(int i = 0; i < 9; i++)
- // {
- // if(SRecipe.getInput() != null && SRecipe.getInput().get(i) instanceof ItemStack)
- // {
- // if(((ItemStack) SRecipe.getInput().get(i)).getItem() instanceof ItemBlock)
- // {
- // RenderHelper.enableStandardItemLighting();
- // }
- // else
- // {
- // RenderHelper.enableGUIStandardItemLighting();
- // }
- // itemRender.renderItemAndEffectIntoGUI(font, tex, (ItemStack) SRecipe.getInput().get(i), w / 2 + x + ((i % 3) * 17), h / 2 + y + (i / 3 * 17));
- // }
- // }
- }
- else
- {
- final ShapedRecipes SRecipe = (ShapedRecipes) recipe;
- for(int i = 0; i < 9; i++)
- {
- if(SRecipe.recipeItems[i] != null)
- {
- if(SRecipe.recipeItems[i].getItem() instanceof ItemBlock)
- {
- RenderHelper.enableStandardItemLighting();
- }
- else
- {
- RenderHelper.enableGUIStandardItemLighting();
- }
- itemRender.renderItemAndEffectIntoGUI(font, tex, SRecipe.recipeItems[i], w / 2 + x + ((i % 3) * 17), h / 2 + y + (i / 3 * 17));
- }
- }
- }
- itemRender.renderItemAndEffectIntoGUI(font, tex, recipe.getRecipeOutput(), w / 2 + 87, 64 + 83);
-
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/items/GuideBook.java b/src/main/java/lance5057/tDefense/core/items/GuideBook.java
deleted file mode 100644
index ec591c6..0000000
--- a/src/main/java/lance5057/tDefense/core/items/GuideBook.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package lance5057.tDefense.core.items;
-
-import lance5057.tDefense.Reference;
-import lance5057.tDefense.TinkersDefense;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-
-public class GuideBook extends Item
-{
- public GuideBook()
- {
- setCreativeTab(TinkersDefense.tabName);
- setMaxStackSize(1);
- setUnlocalizedName("guidebook");
- setTextureName(Reference.MOD_ID + ":tdbook");
- }
-
- @Override
- public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
- {
- player.openGui(TinkersDefense.instance, TinkersDefense.GUI_GUIDEBOOK, player.worldObj, (int) player.posX, (int) player.posY, (int) player.posZ);
- return stack;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/items/MetaModifierItem.java b/src/main/java/lance5057/tDefense/core/items/MetaModifierItem.java
deleted file mode 100644
index 7f11e02..0000000
--- a/src/main/java/lance5057/tDefense/core/items/MetaModifierItem.java
+++ /dev/null
@@ -1,63 +0,0 @@
-package lance5057.tDefense.core.items;
-
-import java.util.List;
-
-import lance5057.tDefense.Reference;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-
-public class MetaModifierItem extends Item
-{
- public IIcon[] icons;
- public String[] names;
- int metaAmount;
-
- public MetaModifierItem(String unlocalizedName, int metaAmount, String[] names)
- {
- super();
- setHasSubtypes(true);
- setUnlocalizedName(unlocalizedName);
- setCreativeTab(CreativeTabs.tabMaterials);
- this.metaAmount = metaAmount;
- this.names = names;
- icons = new IIcon[metaAmount];
- }
-
- @Override
- public void registerIcons(IIconRegister reg)
- {
- for(int i = 0; i < metaAmount; i++)
- {
- icons[i] = reg.registerIcon(Reference.MOD_ID + ":item_" + names[i].toLowerCase());
- }
- }
-
- @Override
- public IIcon getIconFromDamage(int meta)
- {
- if(meta > metaAmount - 1)
- {
- meta = 0;
- }
-
- return icons[meta];
- }
-
- @Override
- public void getSubItems(Item item, CreativeTabs tab, List list)
- {
- for(int i = 0; i < metaAmount; i++)
- {
- list.add(new ItemStack(item, 1, i));
- }
- }
-
- @Override
- public String getUnlocalizedName(ItemStack stack)
- {
- return this.getUnlocalizedName() + "_" + names[stack.getItemDamage()];
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/items/RawGem.java b/src/main/java/lance5057/tDefense/core/items/RawGem.java
deleted file mode 100644
index 41565aa..0000000
--- a/src/main/java/lance5057/tDefense/core/items/RawGem.java
+++ /dev/null
@@ -1,16 +0,0 @@
-package lance5057.tDefense.core.items;
-
-import lance5057.tDefense.Reference;
-import lance5057.tDefense.TinkersDefense;
-import net.minecraft.item.Item;
-
-public class RawGem extends Item
-{
- public RawGem(String name)
- {
- setCreativeTab(TinkersDefense.tabName);
- setMaxStackSize(64);
- setUnlocalizedName("raw" + name);
- setTextureName(Reference.MOD_ID + ":raw" + name);
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/liquids/MoltenFluid.java b/src/main/java/lance5057/tDefense/core/liquids/MoltenFluid.java
deleted file mode 100644
index 48ab09f..0000000
--- a/src/main/java/lance5057/tDefense/core/liquids/MoltenFluid.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package lance5057.tDefense.core.liquids;
-
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.util.IIcon;
-import net.minecraftforge.fluids.BlockFluidClassic;
-import net.minecraftforge.fluids.Fluid;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class MoltenFluid extends BlockFluidClassic
-{
- private IIcon stillIcon;
- private IIcon flowingIcon;
- private final String stillIconTexture;
- private final String flowIconTexture;
-
- public MoltenFluid(Fluid fluid, String name)
- {
- super(fluid, Material.lava);
- setLightLevel(100.0F);
- setHardness(1.0F);
- setBlockName("Molten" + name);
-
- stillIconTexture = "tinkersdefense:molten_" + name;
- flowIconTexture = "tinkersdefense:molten_" + name + "_flow";
- }
-
- @SideOnly(Side.CLIENT)
- public void func_149651_a(IIconRegister icon)
- {
- stillIcon = icon.registerIcon(stillIconTexture);
- flowingIcon = icon.registerIcon(flowIconTexture);
-
- getFluid().setIcons(stillIcon, flowingIcon);
- }
-
- public IIcon getStillIcon()
- {
- return stillIcon;
- }
-
- public IIcon getFlowingIcon()
- {
- return flowingIcon;
- }
-
- @SideOnly(Side.CLIENT)
- public IIcon func_149691_a(int side, int meta)
- {
- if(side <= 1)
- {
- return stillIcon;
- }
- return flowingIcon;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/materials/traits/TraitAxeLover.java b/src/main/java/lance5057/tDefense/core/materials/traits/TraitAxeLover.java
index 0b12566..f262aea 100644
--- a/src/main/java/lance5057/tDefense/core/materials/traits/TraitAxeLover.java
+++ b/src/main/java/lance5057/tDefense/core/materials/traits/TraitAxeLover.java
@@ -36,7 +36,7 @@ public class TraitAxeLover extends AbstractTrait {
|| held.getItem() instanceof ItemAxe
|| held.getItem() instanceof Hatchet
|| held.getItem() instanceof Mattock) {
- if (player.worldObj.rand.nextInt(100) < 5) {
+ if (player.world.rand.nextInt(100) < 5) {
liv.entityDropItem(liv.getHeldItemMainhand(), 0f);
liv.setHeldItem(EnumHand.MAIN_HAND, null);
}
diff --git a/src/main/java/lance5057/tDefense/core/materials/traits/TraitFirestarter.java b/src/main/java/lance5057/tDefense/core/materials/traits/TraitFirestarter.java
index 138c410..16b1c2b 100644
--- a/src/main/java/lance5057/tDefense/core/materials/traits/TraitFirestarter.java
+++ b/src/main/java/lance5057/tDefense/core/materials/traits/TraitFirestarter.java
@@ -37,7 +37,7 @@ public class TraitFirestarter extends AbstractTrait {
{
Vec3d vec = player.getLookVec();
BlockPos block = player.getPosition().add(vec.xCoord,-1,vec.zCoord);
- player.worldObj.setBlockState(block, Blocks.FIRE.getDefaultState());
+ player.world.setBlockState(block, Blocks.FIRE.getDefaultState());
}
}
}
diff --git a/src/main/java/lance5057/tDefense/core/network/Handler_FinishingAnvil.java b/src/main/java/lance5057/tDefense/core/network/Handler_FinishingAnvil.java
deleted file mode 100644
index 561f326..0000000
--- a/src/main/java/lance5057/tDefense/core/network/Handler_FinishingAnvil.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package lance5057.tDefense.core.network;
-
-import lance5057.tDefense.finishingAnvil.blocks.finishingAnvil.TileEntity_FinishingAnvil;
-import net.minecraft.tileentity.TileEntity;
-import cpw.mods.fml.common.network.simpleimpl.IMessage;
-import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
-import cpw.mods.fml.common.network.simpleimpl.MessageContext;
-
-public class Handler_FinishingAnvil implements IMessageHandler<Message_FinishingAnvil, IMessage>
-{
- @Override
- public IMessage onMessage(Message_FinishingAnvil message, MessageContext ctx)
- {
- final TileEntity te = ctx.getServerHandler().playerEntity.worldObj.getTileEntity(message.x, message.y, message.z);
- if(te instanceof TileEntity_FinishingAnvil)
- {
- //((TileEntity_FinishingAnvil) te).flip = message.flip;
- ((TileEntity_FinishingAnvil) te).inventory[0] = message.item;
- }
- return null;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/network/Message_FinishingAnvil.java b/src/main/java/lance5057/tDefense/core/network/Message_FinishingAnvil.java
deleted file mode 100644
index c9a6124..0000000
--- a/src/main/java/lance5057/tDefense/core/network/Message_FinishingAnvil.java
+++ /dev/null
@@ -1,49 +0,0 @@
-package lance5057.tDefense.core.network;
-
-import io.netty.buffer.ByteBuf;
-import net.minecraft.item.ItemStack;
-import cpw.mods.fml.common.network.ByteBufUtils;
-import cpw.mods.fml.common.network.simpleimpl.IMessage;
-
-public class Message_FinishingAnvil implements IMessage
-{
- ByteBufUtils bbu = new ByteBufUtils();
-
- public int x, y, z;
- public ItemStack item;
-
- public Message_FinishingAnvil()
- {
-
- }
-
- public Message_FinishingAnvil(int x, int y, int z, ItemStack item)
- {
- this.x = x;
- this.y = y;
- this.z = z;
-
- this.item = item;
- }
-
- @Override
- public void fromBytes(ByteBuf buf)
- {
- x = buf.readInt();
- y = buf.readInt();
- z = buf.readInt();
-
- item = ByteBufUtils.readItemStack(buf);
- }
-
- @Override
- public void toBytes(ByteBuf buf)
- {
- buf.writeInt(x);
- buf.writeInt(y);
- buf.writeInt(z);
-
- ByteBufUtils.writeItemStack(buf, item);
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/core/network/PacketHandler.java b/src/main/java/lance5057/tDefense/core/network/PacketHandler.java
deleted file mode 100644
index f1b1778..0000000
--- a/src/main/java/lance5057/tDefense/core/network/PacketHandler.java
+++ /dev/null
@@ -1,16 +0,0 @@
-package lance5057.tDefense.core.network;
-
-import lance5057.tDefense.TinkersDefense;
-import cpw.mods.fml.relauncher.Side;
-
-public class PacketHandler
-{
- private static int id = 0;
-
- public static void init()
- {
- TinkersDefense.INSTANCE.registerMessage(Handler_CrestMount.class, Message_CrestMount.class, id++, Side.SERVER);
- TinkersDefense.INSTANCE.registerMessage(Handler_FinishingAnvil.class, Message_FinishingAnvil.class, id++, Side.SERVER);
-
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/renderer/HookRenderer.java b/src/main/java/lance5057/tDefense/core/renderer/HookRenderer.java
deleted file mode 100644
index bb25c76..0000000
--- a/src/main/java/lance5057/tDefense/core/renderer/HookRenderer.java
+++ /dev/null
@@ -1,121 +0,0 @@
-package lance5057.tDefense.core.renderer;
-
-import lance5057.tDefense.core.entity.EntityHookshotHook;
-import net.minecraft.client.renderer.RenderHelper;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.client.renderer.entity.Render;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.ResourceLocation;
-
-import org.lwjgl.opengl.GL11;
-import org.lwjgl.opengl.GL12;
-
-public class HookRenderer extends Render
-{
- ResourceLocation head = new ResourceLocation(
- "tinkersdefense:textures/entity/swordhead.png");
- ResourceLocation chain = new ResourceLocation(
- "tinkersdefense:textures/entity/chain.png");
-
- public HookRenderer()
- {
-
- }
-
- @Override
- public void doRender(Entity p_76986_1_, double p_76986_2_, double p_76986_4_, double p_76986_6_, float p_76986_8_, float p_76986_9_)
- {
- drawHook(p_76986_1_, p_76986_2_, p_76986_4_, p_76986_6_, p_76986_8_, p_76986_9_);
- drawChain(p_76986_1_, p_76986_2_, p_76986_4_, p_76986_6_, p_76986_8_, p_76986_9_);
- }
-
- void drawHook(Entity p_76986_1_, double p_76986_2_, double p_76986_4_, double p_76986_6_, float p_76986_8_, float p_76986_9_)
- {
- bindEntityTexture(p_76986_1_);
- GL11.glPushMatrix();
- GL11.glTranslatef((float) p_76986_2_, (float) p_76986_4_, (float) p_76986_6_);
- GL11.glRotatef(p_76986_1_.prevRotationYaw + (p_76986_1_.rotationYaw - p_76986_1_.prevRotationYaw) * p_76986_9_ - 90.0F, 0.0F, 1.0F, 0.0F);
- GL11.glRotatef(p_76986_1_.prevRotationPitch + (p_76986_1_.rotationPitch - p_76986_1_.prevRotationPitch) * p_76986_9_, 0.0F, 0.0F, 1.0F);
- final Tessellator tessellator = Tessellator.instance;
- final float f2 = 0.0F;
- final float f3 = 1.0F;
- final float f10 = 0.5F;
- GL11.glEnable(GL12.GL_RESCALE_NORMAL);
-
- GL11.glRotatef(45.0F, 1.0F, 0.0F, 0.0F);
- GL11.glScalef(f10, f10, f10);
- for(int i = 0; i < 4; ++i)
- {
- GL11.glRotatef(90.0F, 1.0F, 0.0F, 0.0F);
- GL11.glNormal3f(0.0F, 0.0F, f10);
- tessellator.startDrawingQuads();
- tessellator.addVertexWithUV(-1.0D, -1.0D, 0.0D, f2, f2);
- tessellator.addVertexWithUV(1.0D, -1.0D, 0.0D, f2, f3);
- tessellator.addVertexWithUV(1.0D, 1.0D, 0.0D, f3, f3);
- tessellator.addVertexWithUV(-1.0D, 1.0D, 0.0D, f3, f2);
- tessellator.draw();
- }
-
- GL11.glDisable(GL12.GL_RESCALE_NORMAL);
- GL11.glPopMatrix();
- }
-
- void drawChain(Entity p_76986_1_, double p_76986_2_, double p_76986_4_, double p_76986_6_, float p_76986_8_, float p_76986_9_)
- {
- final EntityHookshotHook hook = (EntityHookshotHook) p_76986_1_;
- final EntityPlayer player = hook.worldObj.getPlayerEntityByName(hook.getPlayer());
-
- final float f2 = 0;
- float f3 = MathHelper.sin(f2 * 0.2F) / 2.0F + 0.5F;
- f3 = (f3 * f3 + f3) * 0.2F;
- final float f4 = (float) (player.posX - p_76986_1_.posX - (p_76986_1_.prevPosX - p_76986_1_.posX) * (1.0F - p_76986_9_));
- final float f5 = (float) (f3 + player.posY - 1.0D - p_76986_1_.posY - (p_76986_1_.prevPosY - p_76986_1_.posY) * (1.0F - p_76986_9_));
- final float f6 = (float) (player.posZ - p_76986_1_.posZ - (p_76986_1_.prevPosZ - p_76986_1_.posZ) * (1.0F - p_76986_9_));
- final float f7 = MathHelper.sqrt_float(f4 * f4 + f6 * f6);
- final float f8 = MathHelper.sqrt_float(f4 * f4 + f5 * f5 + f6 * f6);
- GL11.glPushMatrix();
- GL11.glTranslatef((float) p_76986_2_, (float) p_76986_4_, (float) p_76986_6_);
- GL11.glRotatef((float) (-Math.atan2(f6, f4)) * 180.0F / (float) Math.PI - 90.0F, 0.0F, 1.0F, 0.0F);
- GL11.glRotatef((float) (-Math.atan2(f7, f5)) * 180.0F / (float) Math.PI - 90.0F, 1.0F, 0.0F, 0.0F);
- final Tessellator tessellator = Tessellator.instance;
- RenderHelper.disableStandardItemLighting();
- GL11.glDisable(GL11.GL_CULL_FACE);
- bindTexture(chain);
- GL11.glShadeModel(GL11.GL_SMOOTH);
- final float f9 = 0.0F - (f8) * 0.1F;
- MathHelper.sqrt_float(f4 * f4 + f5 * f5 + f6 * f6);
-
- GL11.glScalef(0.5f, 0.5f, 1);
- for(int j = 0; j < 2; j++)
- {
- tessellator.startDrawing(5);
- final byte b0 = 2;
- GL11.glRotatef(90.0F, 0.0F, 0.0F, 1.0F);
- for(int i = 0; i < b0; ++i)
- {
-
- final float f11 = MathHelper.sin(i % b0 * (float) Math.PI * 2.0F / b0) * 0.75F;
- final float f12 = MathHelper.cos(i % b0 * (float) Math.PI * 2.0F / b0) * 0.75F;
- tessellator.addVertexWithUV(f11, f12, 0.0D, 0, 0);
- tessellator.addVertexWithUV(f11, f12, f8, 0, f9);
- tessellator.addVertexWithUV(f11, f12, 0.0D, 1, 0);
- tessellator.addVertexWithUV(f11, f12, f8, 1, f9);
- }
- tessellator.draw();
- }
-
- GL11.glEnable(GL11.GL_CULL_FACE);
- GL11.glShadeModel(GL11.GL_FLAT);
- RenderHelper.enableStandardItemLighting();
- GL11.glPopMatrix();
- }
-
- @Override
- protected ResourceLocation getEntityTexture(Entity p_110775_1_)
- {
- // TODO Auto-generated method stub
- return head;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/renderer/MoreFlexibleToolRenderer.java b/src/main/java/lance5057/tDefense/core/renderer/MoreFlexibleToolRenderer.java
deleted file mode 100644
index 0412731..0000000
--- a/src/main/java/lance5057/tDefense/core/renderer/MoreFlexibleToolRenderer.java
+++ /dev/null
@@ -1,359 +0,0 @@
-package lance5057.tDefense.core.renderer;
-
-//Owned by Tinkers Construct with small edit
-
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-
-import org.lwjgl.opengl.GL11;
-import org.lwjgl.opengl.GL12;
-
-import tconstruct.TConstruct;
-import tconstruct.client.FlexibleToolRenderer;
-import tconstruct.library.tools.ToolCore;
-
-public class MoreFlexibleToolRenderer extends FlexibleToolRenderer
-{
- private float scale = 1f;
- private final float x, y, z;
- public float depth = 1 / 32f;
-
- public MoreFlexibleToolRenderer(float size, float x, float y, float z)
- {
- scale = size;
- this.x = x;
- this.y = y;
- this.z = z;
- }
-
- @Override
- public void setDepth(float d)
- {
- depth = d;
- }
-
- @Override
- public boolean handleRenderType(ItemStack item, ItemRenderType type)
- {
- if(!item.hasTagCompound())
- {
- return false;
- }
-
- switch(type)
- {
- case ENTITY:
- //GL11.glTranslatef(-0.0625F, -0.0625F, 0F);
- return true;
- case EQUIPPED:
- //GL11.glTranslatef(0.03f, 0F, -0.09375F);
- case EQUIPPED_FIRST_PERSON:
- return true;
- case INVENTORY:
- return true;
- default:
- TConstruct.logger.warn("[TCon] Unhandled render case!");
- case FIRST_PERSON_MAP:
- return false;
- }
- }
-
- @Override
- public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper)
- {
- return handleRenderType(item, type) & helper.ordinal() < ItemRendererHelper.EQUIPPED_BLOCK.ordinal();
- }
-
- private static final int toolIcons = 10;
-
- @Override
- protected void specialAnimation(ItemRenderType type, ItemStack item)
- {
- }
-
- @Override
- public void renderItem(ItemRenderType type, ItemStack item, Object... data)
- {
- if(item == null || item.getItem() == null || !(item.getItem() instanceof ToolCore))
- {
- return;
- }
-
- Entity ent = null;
- if(data.length > 1)
- {
- ent = (Entity) data[1];
- }
-
- final IIcon[] parts = new IIcon[toolIcons];
- final int iconParts = getIcons(item, type, ent, parts);
-
- // drawing the inventory is a simple procedure
- if(type == ItemRenderType.INVENTORY)
- {
- renderInventory(iconParts, parts, item);
- return;
- }
-
- final Tessellator tess = Tessellator.instance;
- final float[] xMax = new float[iconParts];
- final float[] yMin = new float[iconParts];
- final float[] xMin = new float[iconParts];
- final float[] yMax = new float[iconParts];
-
- final float[] width = new float[iconParts];
- final float[] height = new float[iconParts];
- final float[] xDiff = new float[iconParts];
- final float[] yDiff = new float[iconParts];
- final float[] xSub = new float[iconParts];
- final float[] ySub = new float[iconParts];
- for(int i = 0; i < iconParts; ++i)
- {
- final IIcon icon = parts[i];
- xMin[i] = icon.getMinU();
- xMax[i] = icon.getMaxU();
- yMin[i] = icon.getMinV();
- yMax[i] = icon.getMaxV();
- width[i] = icon.getIconWidth();
- height[i] = icon.getIconHeight();
- xDiff[i] = xMin[i] - xMax[i];
- yDiff[i] = yMin[i] - yMax[i];
- xSub[i] = 0.5f * (xMax[i] - xMin[i]) / width[i];
- ySub[i] = 0.5f * (yMax[i] - yMin[i]) / height[i];
- }
-
- GL11.glPushMatrix();
- GL11.glEnable(GL12.GL_RESCALE_NORMAL);
- //edit
- //GL11.glScalef(scale, scale, scale);
- GL11.glScalef(scale, scale, scale);
- GL11.glTranslatef(x, y, z);
-
- if(type != ItemRenderType.ENTITY)
- {
- specialAnimation(type, item);
- }
- else
- {
- GL11.glTranslatef(-0.5f, -0.25f, 0); // why? because.. minecraft.
- }
-
- // prepare colors
- final int[] color = new int[iconParts];
- for(int i = 0; i < iconParts; i++)
- {
- color[i] = item.getItem().getColorFromItemStack(item, i);
- }
-
- // one side
- tess.startDrawingQuads();
- tess.setNormal(0, 0, 1);
- for(int i = 0; i < iconParts; ++i)
- {
- tess.setColorOpaque_I(color[i]);
- tess.addVertexWithUV(0, 0, +depth, xMax[i], yMax[i]);
- tess.addVertexWithUV(1, 0, +depth, xMin[i], yMax[i]);
- tess.addVertexWithUV(1, 1, +depth, xMin[i], yMin[i]);
- tess.addVertexWithUV(0, 1, +depth, xMax[i], yMin[i]);
- }
- tess.draw();
-
- // other side
- tess.startDrawingQuads();
- tess.setNormal(0, 0, -1);
- for(int i = 0; i < iconParts; ++i)
- {
- tess.setColorOpaque_I(color[i]);
- tess.addVertexWithUV(0, 1, -depth, xMax[i], yMin[i]);
- tess.addVertexWithUV(1, 1, -depth, xMin[i], yMin[i]);
- tess.addVertexWithUV(1, 0, -depth, xMin[i], yMax[i]);
- tess.addVertexWithUV(0, 0, -depth, xMax[i], yMax[i]);
- }
- tess.draw();
-
- // make it have "depth"
- tess.startDrawingQuads();
- tess.setNormal(-1, 0, 0);
- float pos;
- float iconPos;
-
- for(int i = 0; i < iconParts; ++i)
- {
- tess.setColorOpaque_I(color[i]);
- final float w = width[i], m = xMax[i], d = xDiff[i], s = xSub[i];
- for(int k = 0, e = (int) w; k < e; ++k)
- {
- pos = k / w;
- iconPos = m + d * pos - s;
- tess.addVertexWithUV(pos, 0, -depth, iconPos, yMax[i]);
- tess.addVertexWithUV(pos, 0, +depth, iconPos, yMax[i]);
- tess.addVertexWithUV(pos, 1, +depth, iconPos, yMin[i]);
- tess.addVertexWithUV(pos, 1, -depth, iconPos, yMin[i]);
- }
- }
-
- tess.draw();
- tess.startDrawingQuads();
- tess.setNormal(1, 0, 0);
- float posEnd;
-
- for(int i = 0; i < iconParts; ++i)
- {
- tess.setColorOpaque_I(color[i]);
- final float w = width[i], m = xMax[i], d = xDiff[i], s = xSub[i];
- final float d2 = 1f / w;
- for(int k = 0, e = (int) w; k < e; ++k)
- {
- pos = k / w;
- iconPos = m + d * pos - s;
- posEnd = pos + d2;
- tess.addVertexWithUV(posEnd, 1, -depth, iconPos, yMin[i]);
- tess.addVertexWithUV(posEnd, 1, +depth, iconPos, yMin[i]);
- tess.addVertexWithUV(posEnd, 0, +depth, iconPos, yMax[i]);
- tess.addVertexWithUV(posEnd, 0, -depth, iconPos, yMax[i]);
- }
- }
-
- tess.draw();
- tess.startDrawingQuads();
- tess.setNormal(0, 1, 0);
-
- for(int i = 0; i < iconParts; ++i)
- {
- tess.setColorOpaque_I(color[i]);
- final float h = height[i], m = yMax[i], d = yDiff[i], s = ySub[i];
- final float d2 = 1f / h;
- for(int k = 0, e = (int) h; k < e; ++k)
- {
- pos = k / h;
- iconPos = m + d * pos - s;
- posEnd = pos + d2;
- tess.addVertexWithUV(0, posEnd, +depth, xMax[i], iconPos);
- tess.addVertexWithUV(1, posEnd, +depth, xMin[i], iconPos);
- tess.addVertexWithUV(1, posEnd, -depth, xMin[i], iconPos);
- tess.addVertexWithUV(0, posEnd, -depth, xMax[i], iconPos);
- }
- }
-
- tess.draw();
- tess.startDrawingQuads();
- tess.setNormal(0, -1, 0);
-
- for(int i = 0; i < iconParts; ++i)
- {
- tess.setColorOpaque_I(color[i]);
- final float h = height[i], m = yMax[i], d = yDiff[i], s = ySub[i];
- for(int k = 0, e = (int) h; k < e; ++k)
- {
- pos = k / h;
- iconPos = m + d * pos - s;
- tess.addVertexWithUV(1, pos, +depth, xMin[i], iconPos);
- tess.addVertexWithUV(0, pos, +depth, xMax[i], iconPos);
- tess.addVertexWithUV(0, pos, -depth, xMax[i], iconPos);
- tess.addVertexWithUV(1, pos, -depth, xMin[i], iconPos);
- }
- }
-
- tess.draw();
- GL11.glDisable(GL12.GL_RESCALE_NORMAL);
-
- GL11.glPopMatrix();
- }
-
- @Override
- public void renderInventory(int count, IIcon[] icons, ItemStack item)
- {
- final Tessellator tess = Tessellator.instance;
- GL11.glPushMatrix();
-
- GL11.glDisable(GL11.GL_LIGHTING);
- GL11.glEnable(GL11.GL_ALPHA_TEST);
- GL11.glAlphaFunc(GL11.GL_GREATER, 0.5F);
- //GL11.glDisable(GL11.GL_BLEND);
-
- tess.startDrawingQuads();
-
- // draw a simple rectangle for the inventory icon
- for(int i = 0; i < count; ++i)
- {
- tess.setColorOpaque_I(item.getItem().getColorFromItemStack(item, i));
-
- final IIcon icon = icons[i];
- final float xmin = icon.getMinU();
- final float xmax = icon.getMaxU();
- final float ymin = icon.getMinV();
- final float ymax = icon.getMaxV();
- tess.addVertexWithUV(0, 16, 0, xmin, ymax);
- tess.addVertexWithUV(16, 16, 0, xmax, ymax);
- tess.addVertexWithUV(16, 0, 0, xmax, ymin);
- tess.addVertexWithUV(0, 0, 0, xmin, ymin);
- }
- tess.draw();
-
- //GL11.glEnable(GL11.GL_BLEND);
- GL11.glDisable(GL11.GL_ALPHA_TEST);
- GL11.glAlphaFunc(GL11.GL_GREATER, 0.1F);
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
-
- @Override
- public int getIcons(ItemStack item, ItemRenderType type, Entity ent, IIcon[] parts)
- {
- int iconParts = toolIcons;//tool.getRenderPasses(item.getItemDamage());
- // TODO: have the tools define how many render passes they have
- // (requires more logic rewrite than it sounds like)
-
- final boolean isInventory = type == ItemRenderType.INVENTORY;
- final ToolCore tool = (ToolCore) item.getItem();
-
- final IIcon[] tempParts = new IIcon[iconParts];
- label:
- {
- if(!isInventory && ent instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) ent;
- final ItemStack itemInUse = player.getItemInUse();
- if(itemInUse != null)
- {
- final int useCount = player.getItemInUseCount();
- for(int i = iconParts; i-- > 0;)
- {
- tempParts[i] = tool.getIcon(item, i, player, itemInUse, useCount);
- }
- break label;
- }
- }
- for(int i = iconParts; i-- > 0;)
- {
- tempParts[i] = tool.getIcon(item, i);
- }
- }
-
- int count = 0;
- for(int i = 0; i < iconParts; ++i)
- {
- final IIcon part = tempParts[i];
- if(part == null || part == ToolCore.blankSprite || part == ToolCore.emptyIcon)
- {
- ++count;
- }
- else
- {
- parts[i - count] = part;
- }
- }
- iconParts -= count;
-
- if(iconParts <= 0)
- {
- iconParts = 1;
- parts[0] = ToolCore.blankSprite;
- }
-
- return iconParts;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/renderer/TestSkinChanger.java b/src/main/java/lance5057/tDefense/core/renderer/TestSkinChanger.java
deleted file mode 100644
index 047b305..0000000
--- a/src/main/java/lance5057/tDefense/core/renderer/TestSkinChanger.java
+++ /dev/null
@@ -1,58 +0,0 @@
-//package lance5057.tDefense.core.renderer;
-//
-//import java.util.Map;
-//
-//import com.google.common.collect.Maps;
-//
-//import net.minecraft.client.Minecraft;
-//import net.minecraft.client.model.ModelHorse;
-//import net.minecraft.client.renderer.entity.RenderHorse;
-//import net.minecraft.client.renderer.texture.ITextureObject;
-//import net.minecraft.client.renderer.texture.LayeredTexture;
-//import net.minecraft.entity.Entity;
-//import net.minecraft.entity.passive.EntityHorse;
-//import net.minecraft.util.ResourceLocation;
-//
-//public class TestSkinChanger extends RenderHorse
-//{
-// private static final Map textures = Maps.newHashMap();
-// private static final String[] horseArmorTextures = new String[] {null, "textures/entity/horse/armor/horse_armor_iron.png", "textures/entity/horse/armor/horse_armor_gold.png", "textures/entity/horse/armor/horse_armor_diamond.png"};
-// private String[] combinedHorseTextures = new String[3];
-//
-// public TestSkinChanger()
-// {
-// super(new ModelHorse(), 1);
-// }
-//
-// @Override
-// protected ResourceLocation getEntityTexture(Entity ent)
-// {
-// if(ent instanceof EntityHorse)
-// {
-// EntityHorse entHorse = (EntityHorse) ent;
-//
-// String rc = "tinkersdefense:textures/skin/horse/horse_witherskeleton.png";
-//
-// return renderHorse(entHorse, rc);
-// }
-// return null;
-// }
-//
-// private ResourceLocation renderHorse(EntityHorse ent, String rc)
-// {
-// String s = ent.getHorseTexture();
-// ResourceLocation resourcelocation = (ResourceLocation)textures.get(s);
-//
-// if (resourcelocation == null)
-// {
-// resourcelocation = new ResourceLocation(s);
-// String[] str = ent.getVariantTexturePaths();
-// str[0] = rc;
-// str[1] = null;
-// Minecraft.getMinecraft().getTextureManager().loadTexture(resourcelocation, new LayeredTexture(str));
-// textures.put(s, resourcelocation);
-// }
-//
-// return resourcelocation;
-// }
-//}
diff --git a/src/main/java/lance5057/tDefense/core/tools/ModifierSoul.java b/src/main/java/lance5057/tDefense/core/tools/ModifierSoul.java
deleted file mode 100644
index e561c44..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/ModifierSoul.java
+++ /dev/null
@@ -1,31 +0,0 @@
-package lance5057.tDefense.core.tools;
-
-import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-
-public class ModifierSoul extends ModifierBoolExclusive
-{
- String name;
-
- public ModifierSoul(ItemStack[] items, int effect, String tag, String c, String tip, String[] exclusive, int modsNeeded, String[] excludeMods, String name)
- {
- super(items, effect, tag, c, tip, exclusive, modsNeeded, excludeMods);
- this.name = name;
- }
-
- @Override
- public void modify(ItemStack[] input, ItemStack tool)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
-
- tags.setBoolean(key, true);
- tags.setString("Soul", name);
-
- int modifiers = tags.getInteger("Modifiers");
- modifiers -= modsNeeded;
- tags.setInteger("Modifiers", modifiers);
-
- addToolTip(tool, color + tooltipName, color + key);
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/Shears.java b/src/main/java/lance5057/tDefense/core/tools/Shears.java
deleted file mode 100644
index 9bf9e36..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/Shears.java
+++ /dev/null
@@ -1,193 +0,0 @@
-package lance5057.tDefense.core.tools;
-
-import java.util.ArrayList;
-import java.util.Random;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.enchantment.Enchantment;
-import net.minecraft.enchantment.EnchantmentHelper;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.stats.StatList;
-import net.minecraft.world.World;
-import net.minecraftforge.common.IShearable;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.tools.TinkerTools;
-
-public class Shears extends ToolCore
-{
-
- public Shears()
- {
- super(0);
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "shears";
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_shears_effect";
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkerTools.knifeBlade;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkerTools.knifeBlade;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.binding;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_shears_top";
- case 1:
- return "_shears_top_broken";
- case 2:
- return "_shears_binding";
- case 3:
- return "_shears_bottom";
- default:
- return "";
- }
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"shears"};
- }
-
- @Override
- public boolean onBlockDestroyed(ItemStack p_150894_1_, World p_150894_2_, Block p_150894_3_, int p_150894_4_, int p_150894_5_, int p_150894_6_, EntityLivingBase p_150894_7_)
- {
- if(p_150894_3_.getMaterial() != Material.leaves && p_150894_3_ != Blocks.web && p_150894_3_ != Blocks.tallgrass && p_150894_3_ != Blocks.vine && p_150894_3_ != Blocks.tripwire && !(p_150894_3_ instanceof IShearable))
- {
- return super.onBlockDestroyed(p_150894_1_, p_150894_2_, p_150894_3_, p_150894_4_, p_150894_5_, p_150894_6_, p_150894_7_);
- }
- else
- {
- return true;
- }
- }
-
- @Override
- public boolean func_150897_b(Block p_150897_1_)
- {
- return p_150897_1_ == Blocks.web || p_150897_1_ == Blocks.redstone_wire || p_150897_1_ == Blocks.tripwire;
- }
-
- @Override
- public float func_150893_a(ItemStack p_150893_1_, Block p_150893_2_)
- {
- return p_150893_2_ != Blocks.web && p_150893_2_.getMaterial() != Material.leaves ? (p_150893_2_ == Blocks.wool ? 5.0F : super.func_150893_a(p_150893_1_, p_150893_2_)) : 15.0F;
- }
-
- /**
- * Returns true if the item can be used on the given entity, e.g. shears on sheep.
- */
- @Override
- public boolean itemInteractionForEntity(ItemStack itemstack, EntityPlayer player, EntityLivingBase entity)
- {
- if(entity.worldObj.isRemote)
- {
- return false;
- }
- if(entity instanceof IShearable)
- {
- final IShearable target = (IShearable) entity;
- if(target.isShearable(itemstack, entity.worldObj, (int) entity.posX, (int) entity.posY, (int) entity.posZ))
- {
- final int enchant = EnchantmentHelper.getEnchantmentLevel(Enchantment.fortune.effectId, itemstack);
- final ArrayList<ItemStack> drops = target.onSheared(itemstack, entity.worldObj, (int) entity.posX, (int) entity.posY, (int) entity.posZ, enchant);
-
- if(itemstack.getTagCompound().getCompoundTag("InfiTool").hasKey("Rainbow"))
- {
- for(int i = 0; i < drops.size(); i++)
- {
- if(drops.get(i).getItem() == Blocks.wool.getItem(entity.worldObj, 0, 0, 0))
- {
- drops.get(i).setItemDamage(entity.worldObj.rand.nextInt(16));
- }
- }
- }
-
- final Random rand = new Random();
- for(final ItemStack stack : drops)
- {
- final EntityItem ent = entity.entityDropItem(stack, 1.0F);
- ent.motionY += rand.nextFloat() * 0.05F;
- ent.motionX += (rand.nextFloat() - rand.nextFloat()) * 0.1F;
- ent.motionZ += (rand.nextFloat() - rand.nextFloat()) * 0.1F;
- }
- itemstack.damageItem(1, entity);
- }
- return true;
- }
- return false;
- }
-
- @Override
- public boolean onBlockStartBreak(ItemStack itemstack, int x, int y, int z, EntityPlayer player)
- {
- if(player.worldObj.isRemote)
- {
- return false;
- }
- final Block block = player.worldObj.getBlock(x, y, z);
- if(block instanceof IShearable)
- {
- final IShearable target = (IShearable) block;
- if(target.isShearable(itemstack, player.worldObj, x, y, z))
- {
- final ArrayList<ItemStack> drops = target.onSheared(itemstack, player.worldObj, x, y, z, EnchantmentHelper.getEnchantmentLevel(Enchantment.fortune.effectId, itemstack));
- final Random rand = new Random();
-
- for(final ItemStack stack : drops)
- {
- final float f = 0.7F;
- final double d = rand.nextFloat() * f + (1.0F - f) * 0.5D;
- final double d1 = rand.nextFloat() * f + (1.0F - f) * 0.5D;
- final double d2 = rand.nextFloat() * f + (1.0F - f) * 0.5D;
- final EntityItem entityitem = new EntityItem(
- player.worldObj, x + d, y + d1, z + d2, stack);
- entityitem.delayBeforeCanPickup = 10;
- player.worldObj.spawnEntityInWorld(entityitem);
- }
-
- itemstack.damageItem(1, player);
- player.addStat(StatList.mineBlockStatArray[Block.getIdFromBlock(block)], 1);
- }
- }
- return false;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/TDToolEvents.java b/src/main/java/lance5057/tDefense/core/tools/TDToolEvents.java
index 4688b3e..69f5c04 100644
--- a/src/main/java/lance5057/tDefense/core/tools/TDToolEvents.java
+++ b/src/main/java/lance5057/tDefense/core/tools/TDToolEvents.java
@@ -27,7 +27,8 @@ public class TDToolEvents {
EntityPlayer player = (EntityPlayer) event.getEntityLiving();
if (player.getActiveItemStack() != null
&& player.getActiveItemStack().getItem() != null
- && player.getActiveItemStack().getItem() instanceof Shield) {
+ && player.getActiveItemStack().getItem() instanceof Shield
+ && !ToolHelper.isBroken(player.getActiveItemStack())) {
ItemStack shield = player.getActiveItemStack();
int damage = event.getAmount() < 2f ? 1 : Math.round(event
diff --git a/src/main/java/lance5057/tDefense/core/tools/TDTools.java b/src/main/java/lance5057/tDefense/core/tools/TDTools.java
index 10e25ca..bd3c879 100644
--- a/src/main/java/lance5057/tDefense/core/tools/TDTools.java
+++ b/src/main/java/lance5057/tDefense/core/tools/TDTools.java
@@ -22,6 +22,7 @@ public class TDTools
// Tools
public static ToolCore roundshield = new RoundShield();
public static ToolCore heatershield = new HeaterShield();
+ public static ToolCore zweihander = new Zweihander();
// Tool Parts
@@ -58,9 +59,11 @@ public class TDTools
regTool(roundshield, "roundshield");
regTool(heatershield, "heatershield");
+ regTool(zweihander, "zweihander");
TinkerRegistry.registerToolStationCrafting(roundshield);
TinkerRegistry.registerToolForgeCrafting(heatershield);
+ TinkerRegistry.registerToolForgeCrafting(zweihander);
}
private void regTool(ToolCore tool, String name)
@@ -86,6 +89,7 @@ public class TDTools
private void regToolBuilding() {
TinkerRegistry.registerToolCrafting(roundshield);
TinkerRegistry.registerToolForgeCrafting(heatershield);
+ TinkerRegistry.registerToolForgeCrafting(zweihander);
}
private void regRecipies() {
diff --git a/src/main/java/lance5057/tDefense/core/tools/TinkerWrench.java b/src/main/java/lance5057/tDefense/core/tools/TinkerWrench.java
deleted file mode 100644
index 9fb8589..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/TinkerWrench.java
+++ /dev/null
@@ -1,255 +0,0 @@
-package lance5057.tDefense.core.tools;
-
-import ic2.api.tile.IWrenchable;
-
-import java.util.List;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import tconstruct.library.tools.AbilityHelper;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.tools.TinkerTools;
-import buildcraft.api.tools.IToolWrench;
-import cofh.api.block.IDismantleable;
-import cofh.api.item.IToolHammer;
-import cpw.mods.fml.common.Optional;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "buildcraft", iface = "buildcraft.api.tools.IToolWrench"), @Optional.Interface(modid = "cofh", iface = "cofh.api.item.IToolHammer")})
-public class TinkerWrench extends ToolCore implements IToolWrench, IToolHammer
-{
- int induceDamage = 0;
-
- public TinkerWrench()
- {
- super(0);
- setUnlocalizedName("tinkerwrench");
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkerTools.handGuard;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toolRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkerTools.binding;
- }
-
- @Override
- public int durabilityTypeAccessory()
- {
- return 2;
- }
-
- @Override
- public float getRepairCost()
- {
- return 1.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 0.1f;
- }
-
- @Override
- public float getDamageModifier()
- {
- return 0.4f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_wrench_head";
- case 1:
- return "_wrench_head_broken";
- case 2:
- return "_wrench_handle";
- case 3:
- return "_wrench_binding";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_wrench_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "wrench";
- }
-
- @Override
- @Optional.Method(modid = "buildcraft")
- public boolean canWrench(EntityPlayer player, int x, int y, int z)
- {
- final NBTTagCompound tags = player.inventory.getCurrentItem().getTagCompound().getCompoundTag("InfiTool");
-
- if(!tags.getBoolean("Broken"))
- {
- return true;
- }
- return false;
- }
-
- @Override
- @Optional.Method(modid = "buildcraft")
- public void wrenchUsed(EntityPlayer player, int x, int y, int z)
- {
-
- player.swingItem();
- AbilityHelper.damageTool(player.inventory.getCurrentItem(), 1, player, false);
-
- }
-
- @Override
- @Optional.Method(modid = "cofh")
- public boolean isUsable(ItemStack item, EntityLivingBase user, int x, int y, int z)
- {
- // TODO Auto-generated method stub
- return true;
- }
-
- @Override
- @Optional.Method(modid = "cofh")
- public void toolUsed(ItemStack item, EntityLivingBase user, int x, int y, int z)
- {
- // TODO Auto-generated method stub
-
- }
-
- // //Skin Changer
- // @Override
- // public boolean itemInteractionForEntity(ItemStack itemstack, EntityPlayer player, EntityLivingBase entity)
- // {
- // if(entity.worldObj.isRemote)
- // {
- // return false;
- // }
- // if(entity instanceof EntityAnimal)
- // {
- // EntityAnimal target = (EntityAnimal) entity;
- // player.openGui(TinkersDefense.instance, TinkersDefense.GUI_ANVIL_INV, player.worldObj, (int)player.posX, (int)player.posY, (int)player.posZ);
- // return true;
- // }
- // return false;
- // }
-
- @Override
- public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float hitX, float hitY, float hitZ)
- {
- final Block block = world.getBlock(x, y, z);
- final TileEntity te = world.getTileEntity(x, y, z);
- final int metaData = world.getBlockMetadata(x, y, z);
-
- if(te != null && te instanceof IWrenchable)
- {
- final IWrenchable wte = (IWrenchable) te;
-
- if(!player.isSneaking())
- {
- // for(int step = 1; step < 6; step++)
- // {
- //side = (wte.getFacing() + 6 - step) % 6;
- if(!world.isRemote)
- {
- //side = side % -3;//(wte.getFacing() + step) % 6;
- //
- if(wte.wrenchCanSetFacing(player, side))
- {
- wte.setFacing((short) side);
- return true;
- }
- }
- // }
- }
- else
- {
- if(!world.isRemote)
- {
- final List<ItemStack> drops = block.getDrops(world, x, y, z, metaData, 0);
- if(world.rand.nextFloat() <= wte.getWrenchDropRate())
- {
- final ItemStack drop = wte.getWrenchDrop(player);
- if(drop != null)
- {
- if(drops.isEmpty())
- {
- drops.add(drop);
- }
- else
- {
- drops.set(0, drop);
- }
- }
- }
- for(final ItemStack itemStack : drops)
- {
- final EntityItem ei = new EntityItem(world, x, y, z,
- itemStack.copy());
- world.spawnEntityInWorld(ei);
- }
- world.removeTileEntity(x, y, z);
- world.setBlockToAir(x, y, z);
- return true;
- }
- }
- return false;
- }
- if(world.blockExists(x, y, z))
- {
- if(block != null)
- {
- if(player.isSneaking() && block instanceof IDismantleable && ((IDismantleable) block).canDismantle(player, world, x, y, z))
- {
- if(!world.isRemote)
- {
- ((IDismantleable) block).dismantleBlock(player, world, x, y, z, false);
- player.swingItem();
- return true;
- }
- }
-
- }
- }
- return false;
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"wrench"};
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/TinkerZweihander.java b/src/main/java/lance5057/tDefense/core/tools/TinkerZweihander.java
deleted file mode 100644
index b7f68bc..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/TinkerZweihander.java
+++ /dev/null
@@ -1,164 +0,0 @@
-package lance5057.tDefense.core.tools;
-
-import java.util.List;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.world.World;
-import tconstruct.library.tools.AbilityHelper;
-import tconstruct.library.tools.Weapon;
-import tconstruct.tools.TinkerTools;
-import cpw.mods.fml.common.Optional;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "battlegear2", iface = "mods.battlegear2.api.weapons.IBattlegearWeapon"),})
-public class TinkerZweihander extends Weapon
-{
-
- public TinkerZweihander(int baseDamage)
- {
- super(3);
- setUnlocalizedName("zweihander");
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkerTools.largeSwordBlade;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toughRod;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkerTools.wideGuard;
- }
-
- @Override
- public Item getExtraItem()
- {
- return TinkerTools.swordBlade;
- }
-
- @Override
- public boolean onLeftClickEntity(ItemStack stack, EntityPlayer player, Entity entity)
- {
- if(AbilityHelper.onLeftClickEntity(stack, player, entity, this))
- {
- if(entity.riddenByEntity != null || entity.ridingEntity != null)
- {
- player.attackTargetEntityWithCurrentItem(entity);
- }
- }
- return true;
- }
-
- @Override
- public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
- {
- if(!player.isPotionActive(Potion.moveSlowdown))
- {
- final List entities = player.worldObj.getEntitiesWithinAABBExcludingEntity(player, AxisAlignedBB.getBoundingBox(player.posX - 2, player.posY - 2, player.posZ - 2, player.posX + 2, player.posY + 2, player.posZ + 2));
-
- for(int i = 0; i < entities.size(); i++)
- {
- if(((Entity) entities.get(i)) instanceof EntityLivingBase)
- {
- player.attackTargetEntityWithCurrentItem((Entity) entities.get(i));
- player.worldObj.spawnParticle("largeexplode", ((Entity) entities.get(i)).posX, ((Entity) entities.get(i)).posY + (((Entity) entities.get(i)).height / 2), ((Entity) entities.get(i)).posZ, 0, 0, 0);
- player.worldObj.playSoundAtEntity((Entity) entities.get(i), "mob.zombie.metal", 15f, 1f);
- }
- }
- player.addPotionEffect(new PotionEffect(Potion.moveSlowdown.id, 20,
- 3));
- player.addPotionEffect(new PotionEffect(Potion.weakness.id, 200, 1));
- }
-
- return stack;
- }
-
- @Override
- public float getRepairCost()
- {
- return 4.0f;
- }
-
- @Override
- public float getDurabilityModifier()
- {
- return 2.5f;
- }
-
- @Override
- public int getPartAmount()
- {
- return 4;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_zweihander_blade";
- case 1:
- return "_zweihander_blade_broken";
- case 2:
- return "_zweihander_handle";
- case 3:
- return "_zweihander_guard";
- case 4:
- return "_zweihander_core";
- default:
- return "";
- }
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_zweihander_effect";
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "zweihander";
- }
-
- // @Override
- // @SideOnly(Side.CLIENT)
- // public void onUpdate(ItemStack stack, World world, Entity entity, int par4,
- // boolean par5) {
- // super.onUpdate(stack, world, entity, par4, par5);
- // if (entity instanceof EntityPlayerSP) {
- // EntityPlayerSP player = (EntityPlayerSP) entity;
- // ItemStack usingItem = player.inventory.getCurrentItem();
- // if (usingItem != null && usingItem.getItem() == this) {
- // player.addPotionEffect(new PotionEffect(Potion.resistance.getId(),2,1));
- //
- // }
- // }
- // }
-
- @Override
- @Optional.Method(modid = "battlegear2")
- public boolean allowOffhand(ItemStack mainhand, ItemStack offhand)
- {
- if(offhand == null)
- return true;
- else
- return false;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/TinkersHookshot.java b/src/main/java/lance5057/tDefense/core/tools/TinkersHookshot.java
deleted file mode 100644
index 061aa51..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/TinkersHookshot.java
+++ /dev/null
@@ -1,119 +0,0 @@
-package lance5057.tDefense.core.tools;
-
-import java.util.List;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.entity.EntityHookshotHook;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import tconstruct.library.crafting.ToolBuilder;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.tools.TinkerTools;
-
-public class TinkersHookshot extends ToolCore
-{
-
- public TinkersHookshot()
- {
- super(0);
- // TODO Auto-generated constructor stub
- }
-
- @Override
- public String getDefaultFolder()
- {
- return "hookshot";
- }
-
- @Override
- public String getEffectSuffix()
- {
- return "_hookshot_effect";
- }
-
- @Override
- public int getPartAmount()
- {
- return 3;
- }
-
- @Override
- public Item getHeadItem()
- {
- return TinkersDefense.partArmorplate;
- }
-
- @Override
- public Item getAccessoryItem()
- {
- return TinkersDefense.partChainmaille;
- }
-
- @Override
- public Item getHandleItem()
- {
- return TinkerTools.toughRod;
- }
-
- @Override
- public String getIconSuffix(int partType)
- {
- switch(partType)
- {
- case 0:
- return "_hookshot_chamber";
- case 1:
- return "_hookshot_chamber_broken";
- case 2:
- return "_hookshot_handle";
- case 3:
- return "_hookshot_chain";
- default:
- return "";
- }
- }
-
- @Override
- public String[] getTraits()
- {
- return new String[] {"hookshot"};
- }
-
- @Override
- public void buildTool(int id, String name, List list)
- {
- final Item accessory = getAccessoryItem();
- final ItemStack accessoryStack = accessory != null ? new ItemStack(
- getAccessoryItem(), 1, id) : null;
- final Item extra = getExtraItem();
- final ItemStack extraStack = extra != null ? new ItemStack(extra, 1, id) : null;
- final ItemStack tool = ToolBuilder.instance.buildTool(new ItemStack(
- getHeadItem(), 1, id), new ItemStack(getHandleItem(), 1, id), accessoryStack, extraStack, name);
- if(tool != null)
- {
- tool.getTagCompound().getCompoundTag("InfiTool").setBoolean("Built", true);
- tool.getTagCompound().getCompoundTag("InfiTool").setInteger("ChainLength", 10);
- list.add(tool);
- }
- }
-
- @Override
- public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
- {
- world.playSoundAtEntity(player, "random.bow", 0.5F, 0.4F / (itemRand.nextFloat() * 0.4F + 0.8F));
-
- player.setItemInUse(stack, getMaxItemUseDuration(stack));
- final EntityHookshotHook hook = new EntityHookshotHook(player.worldObj,
- player);
- hook.setPlayer(player);
- hook.setHook("test");
- hook.setHookshot(stack);
- if(!player.worldObj.isRemote)
- {
- player.worldObj.spawnEntityInWorld(hook);
- }
- return stack;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/Zweihander.java b/src/main/java/lance5057/tDefense/core/tools/Zweihander.java
new file mode 100644
index 0000000..9446bac
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/core/tools/Zweihander.java
@@ -0,0 +1,90 @@
+package lance5057.tDefense.core.tools;
+
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.EntityLivingBase;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.MobEffects;
+import net.minecraft.init.SoundEvents;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.math.MathHelper;
+
+import java.util.List;
+
+import slimeknights.tconstruct.library.materials.Material;
+import slimeknights.tconstruct.library.tinkering.Category;
+import slimeknights.tconstruct.library.tinkering.PartMaterialType;
+import slimeknights.tconstruct.library.tools.SwordCore;
+import slimeknights.tconstruct.library.tools.ToolNBT;
+import slimeknights.tconstruct.library.utils.ToolHelper;
+import slimeknights.tconstruct.tools.TinkerTools;
+
+public class Zweihander extends SwordCore {
+
+ public static final float DURABILITY_MODIFIER = 1.1f;
+
+ public Zweihander() {
+ super(PartMaterialType.head(TinkerTools.largeSwordBlade),
+ PartMaterialType.head(TinkerTools.swordBlade),
+ PartMaterialType.handle(TinkerTools.toughToolRod),
+ PartMaterialType.extra(TinkerTools.toughBinding));
+
+ addCategory(Category.WEAPON);
+ }
+
+ @Override
+ public float damagePotential() {
+ return 1.0f;
+ }
+
+ @Override
+ public double attackSpeed() {
+ return 1.0d;
+ }
+
+// // sword sweep attack
+// @Override
+// public boolean dealDamage(ItemStack stack, EntityLivingBase player, Entity entity, float damage) {
+// // deal damage first
+// boolean hit = super.dealDamage(stack, player, entity, damage);
+// // and then sweep
+// if(hit && !ToolHelper.isBroken(stack)) {
+// // sweep code from EntityPlayer#attackTargetEntityWithCurrentItem()
+// // basically: no crit, no sprinting and has to stand on the ground for sweep. Also has to move regularly slowly
+// double d0 = (double) (player.field_70140_Q - player.field_70141_P);
+// boolean flag = true;
+// if(player instanceof EntityPlayer) {
+// flag = ((EntityPlayer) player).func_184825_o(0.5F) > 0.9f;
+// }
+// boolean flag2 = player.field_70143_R > 0.0F && !player.field_70122_E && !player.func_70617_f_() && !player.func_70090_H() && !player.func_70644_a(MobEffects.field_76440_q) && !player.func_184218_aH();
+// if(flag && !player.func_70051_ag() && !flag2 && player.field_70122_E && d0 < (double) player.func_70689_ay()) {
+// for(EntityLivingBase entitylivingbase : player.func_130014_f_().func_72872_a(EntityLivingBase.class, entity.func_174813_aQ().func_72314_b(1.0D, 0.25D, 1.0D))) {
+// if(entitylivingbase != player && entitylivingbase != entity && !player.func_184191_r(entitylivingbase) && player.func_70068_e(entitylivingbase) < 9.0D) {
+// entitylivingbase.func_70653_a(player, 0.4F, (double) MathHelper.func_76126_a(player.field_70177_z * 0.017453292F), (double) (-MathHelper.func_76134_b(player.field_70177_z * 0.017453292F)));
+// super.dealDamage(stack, player, entitylivingbase, 1f);
+// }
+// }
+//
+// player.func_130014_f_().func_184148_a(null, player.field_70165_t, player.field_70163_u, player.field_70161_v, SoundEvents.field_187730_dW, player.func_184176_by(), 1.0F, 1.0F);
+// if(player instanceof EntityPlayer) {
+// ((EntityPlayer) player).func_184810_cG();
+// }
+// }
+// }
+//
+// return hit;
+// }
+
+ @Override
+ public float getRepairModifierForPart(int index) {
+ return DURABILITY_MODIFIER;
+ }
+
+ @Override
+ public ToolNBT buildTagData(List<Material> materials) {
+ ToolNBT data = buildDefaultTag(materials);
+ // 2 base damage, like vanilla swords
+ data.attack += 1f;
+ data.durability *= DURABILITY_MODIFIER;
+ return data;
+ }
+}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/ActiveToolMods/TDefenseActiveToolMod.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/ActiveToolMods/TDefenseActiveToolMod.java
deleted file mode 100644
index 52663ce..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/ActiveToolMods/TDefenseActiveToolMod.java
+++ /dev/null
@@ -1,31 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers.ActiveToolMods;
-
-import lance5057.tDefense.core.tools.modifiers.Modifiers;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.world.World;
-import tconstruct.library.ActiveToolMod;
-import tconstruct.library.tools.ToolCore;
-
-public class TDefenseActiveToolMod extends ActiveToolMod
-{
- Modifiers mods = new Modifiers();
-
- // BotaniaToolMods FlowerMods = new BotaniaToolMods();
-
- @Override
- public void updateTool(ToolCore tool, ItemStack stack, World world, Entity entity)
- {
- if(stack.hasTagCompound() && stack.getTagCompound().hasKey("InfiTool"))
- {
- final NBTTagCompound tags = stack.getTagCompound().getCompoundTag("InfiTool");
-
- if(!tags.getBoolean("Broken"))
- {
- // TDefense
- mods.UpdateAll(tool, stack, world, entity, tags);
- }
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/BloodMagic/BloodMagicMods.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/BloodMagic/BloodMagicMods.java
deleted file mode 100644
index 25bc332..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/BloodMagic/BloodMagicMods.java
+++ /dev/null
@@ -1,133 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers.BloodMagic;
-
-import lance5057.tDefense.TDIntegration;
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.world.World;
-import net.minecraftforge.event.entity.living.LivingAttackEvent;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.client.TConstructClientRegistry;
-import tconstruct.library.crafting.ModifyBuilder;
-import tconstruct.library.tools.ToolCore;
-import WayofTime.alchemicalWizardry.ModItems;
-import WayofTime.alchemicalWizardry.api.altarRecipeRegistry.AltarRecipeRegistry;
-import WayofTime.alchemicalWizardry.api.items.ShapedBloodOrbRecipe;
-import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
-import WayofTime.alchemicalWizardry.common.items.EnergyItems;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-
-public class BloodMagicMods extends ModifiersBase
-{
-
- public BloodMagicMods()
- {
- super(new String[] {"bindingwrap", "bloodybandages"}, "modItemsBloodMagic");
- }
-
- @Override
- public void RegisterRecipes()
- {
- GameRegistry.addRecipe(new ShapedBloodOrbRecipe(new ItemStack(modItems,
- 1, 0), new Object[] {"sts", "cbc", "sos", 's', new ItemStack(
- ModItems.weakBloodShard, 1, 0), 't', new ItemStack(
- TinkersDefense.partChainmaille, 1, 2), 'c', new ItemStack(
- ModItems.standardBindingAgent, 1, 0), 'b', new ItemStack(
- ModItems.energySword, 1, 0), 'o', new ItemStack(
- ModItems.magicianBloodOrb, 1, 0)}));
-
- AltarRecipeRegistry.registerAltarRecipe(new ItemStack(modItems, 1, 1), new ItemStack(
- TinkersDefense.partCloth, 1, -1), 2, 12000, 10, 10, false);
-
- }
-
- @Override
- public void RegisterModifiers()
- {
- // TODO Auto-generated method stub
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 0)},
- TinkersDefense.config.BloodOathModID, "BloodOath",
- EnumChatFormatting.RED.toString(), "Blood Oath",
- new String[] {"weapon"}, 1, null));
-
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 1)},
- TinkersDefense.config.ScabbingModID, "Scabbing",
- EnumChatFormatting.DARK_RED.toString(), "Scabbing",
- new String[] {}, 1, new String[] {"Supping"}));
-
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(ModItems.apprenticeBloodOrb, 1), new ItemStack(
- ModItems.sacrificialDagger, 1)},
- TinkersDefense.config.SuppingModID, "Supping",
- EnumChatFormatting.DARK_RED.toString(), "Supping",
- new String[] {"weapon"}, 1, new String[] {"Scabbing"}));
-
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.BloodOathModID, "tinker", "bloodoath", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ScabbingModID, "tinker", "scabbing", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.SuppingModID, "tinker", "supping", true);
- }
- }
-
- @Override
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(!world.isRemote)
- {
- if(tags.hasKey("Scabbing"))
- {
- SoulNetworkHandler.checkAndSetItemOwner(stack, (EntityPlayer) entity);
- UpdateScabbing(tool, stack, world, entity, tags);
- }
- }
- }
-
- public void UpdateScabbing(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(tags.getInteger("Damage") > 0 && EnergyItems.syphonBatteries(stack, (EntityPlayer) entity, 50))
- {
- tags.setInteger("Damage", tags.getInteger("Damage") - 1);
- }
- }
-
- @SubscribeEvent
- public void BloodOathInteractEvent(LivingAttackEvent event)
- {
- if(TDIntegration.bloodMagic && !event.entity.worldObj.isRemote)
- {
- if(event.source.getEntity() instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) event.source.getEntity();
- final ItemStack heldItem = player.getHeldItem();
-
- if(heldItem != null && heldItem.getItem() != null && heldItem.getItem() instanceof ToolCore)
- {
- SoulNetworkHandler.checkAndSetItemOwner(heldItem, player);
- final NBTTagCompound tags = heldItem.getTagCompound().getCompoundTag("InfiTool");
-
- if(tags.hasKey("BloodOath") && EnergyItems.syphonBatteries(heldItem, player, 50))
- {
- event.entityLiving.addPotionEffect(new PotionEffect(
- Potion.weakness.id, 30, 2));
- }
-
- if(tags.hasKey("Supping"))
- {
- SoulNetworkHandler.addCurrentEssenceToMaximum(SoulNetworkHandler.getOwnerName(heldItem), 10, SoulNetworkHandler.getMaximumForOrbTier(SoulNetworkHandler.getCurrentMaxOrb(SoulNetworkHandler.getOwnerName(heldItem))));
- }
- }
- }
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/Botania/BotaniaMods.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/Botania/BotaniaMods.java
deleted file mode 100644
index c0f1bfc..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/Botania/BotaniaMods.java
+++ /dev/null
@@ -1,193 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers.Botania;
-
-import lance5057.tDefense.TDIntegration;
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.item.crafting.CraftingManager;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.world.World;
-import net.minecraftforge.event.entity.living.LivingAttackEvent;
-import net.minecraftforge.oredict.ShapedOreRecipe;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.client.TConstructClientRegistry;
-import tconstruct.library.crafting.ModifyBuilder;
-import tconstruct.library.tools.AbilityHelper;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.tools.TinkerTools;
-import vazkii.botania.api.BotaniaAPI;
-import vazkii.botania.api.mana.ManaItemHandler;
-import vazkii.botania.common.entity.EntityManaBurst;
-import vazkii.botania.common.item.ModItems;
-import vazkii.botania.common.item.block.ItemBlockSpecialFlower;
-import vazkii.botania.common.item.equipment.tool.terrasteel.ItemTerraSword;
-import vazkii.botania.common.lib.LibBlockNames;
-import vazkii.botania.common.lib.LibOreDict;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-
-@Optional.InterfaceList({@Optional.Interface(modid = "botania", iface = "vazkii.botania.common.entity.EntityManaBurst"), @Optional.Interface(modid = "botania", iface = "vazkii.botania.common.item.ModItems"), @Optional.Interface(modid = "botania", iface = "vazkii.botania.common.item.equipment.tool.ToolCommons"), @Optional.Interface(modid = "botania", iface = "vazkii.botania.common.item.equipment.tool.terrasteel.ItemTerraSword"),})
-public class BotaniaMods extends ModifiersBase
-{
- public BotaniaMods()
- {
- super(new String[] {"corpseIvyGraft", "corpseIvy", "terraCore", "manaCore"}, "modItemsBotania");
- }
-
- @Override
- public void RegisterRecipes()
- {
- CraftingManager.getInstance().getRecipeList().add(new ShapedOreRecipe(
- new ItemStack(modItems, 1, 0),
- new Object[] {"fsf", "oio", "fgf", 'f', ItemBlockSpecialFlower.ofType(LibBlockNames.SUBTILE_BELLETHORN), 'i', new ItemStack(
- ModItems.keepIvy, 1, 0), 's', LibOreDict.MANA_STRING, 'g', new ItemStack(
- TinkerTools.craftedSoil, 1, 3), 'o', new ItemStack(
- ModItems.fertilizer, 1, 1)}));
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 2), new Object[] {"sis", "idi", "sis", 'i', new ItemStack(
- ModItems.manaResource, 1, 4), 's', new ItemStack(
- ModItems.manaResource, 1, 12), 'd', new ItemStack(
- ModItems.manaResource, 1, 2)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 2), new Object[] {"sis", "idi", "sis", 'i', new ItemStack(
- ModItems.manaResource, 1, 4), 's', new ItemStack(
- ModItems.manaResource, 1, 12), 'd', new ItemStack(
- ModItems.manaResource, 1, 1)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 3), new Object[] {"sis", "idi", "sis", 'i', new ItemStack(
- ModItems.manaResource, 1, 0), 's', new ItemStack(
- ModItems.manaResource, 1, 12), 'd', new ItemStack(
- ModItems.manaTablet)});
-
- BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(modItems, 1, 1), new ItemStack(
- modItems, 1, 0), 100000);
-
- }
-
- @Override
- public void RegisterModifiers()
- {
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 1)},
- TinkersDefense.config.CorpseIvyModID, "CorpseIvy",
- EnumChatFormatting.DARK_GREEN.toString(), "Corpse Ivy",
- new String[] {"weapon"}, 1, new String[] {"ManaCore"}));
-
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 2)},
- TinkersDefense.config.TerraCoreModID, "TerraCore",
- EnumChatFormatting.GREEN.toString(), "TerraCore",
- new String[] {"weapon"}, 1, null));
-
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 3)},
- TinkersDefense.config.ManaRepairModID, "ManaCore",
- EnumChatFormatting.AQUA.toString(), "ManaCore",
- new String[] {}, 1, new String[] {"CorpseIvy"}));
-
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CorpseIvyModID, "tinker", "corpseivy", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.TerraCoreModID, "tinker", "terracore", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ManaRepairModID, "tinker", "manacore", true);
-
- }
- }
-
- @Override
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(!world.isRemote)
- {
- if(tags.hasKey("TerraCore"))
- {
- UpdateTerraCore(tool, stack, world, entity, tags);
- }
- // if(tags.hasKey("CorpseIvy"))
- // {
- // UpdateCorpseIvy(tool, stack, world, entity, tags);
- // }
- if(tags.hasKey("ManaCore"))
- {
- UpdateManaRepair(tool, stack, world, entity, tags);
- }
- }
- }
-
- public void UpdateTerraCore(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(entity instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) entity;
- final PotionEffect haste = player.getActivePotionEffect(Potion.digSpeed);
- final float check = haste == null ? 0.16666667F : haste.getAmplifier() == 1 ? 0.5F : 0.4F;
-
- if(player.getCurrentEquippedItem() == stack && player.swingProgress == check && !world.isRemote && world.rand.nextInt(2) == 0)
- {
- final int color = TConstructRegistry.getMaterial(tags.getInteger("Head")).primaryColor();
- final EntityManaBurst burst = ((ItemTerraSword) ModItems.terraSword).getBurst(player, new ItemStack(
- ModItems.terraSword));
- burst.setColor(color);
- world.spawnEntityInWorld(burst);
- //ToolCommonSoundAtEntity(player, "botania:terraBlade", 0.4F, 1.4F);
- AbilityHelper.damageTool(stack, 1, player, false);
- }
- }
- }
-
- // public void UpdateCorpseIvy(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- // {
- // if(entity instanceof EntityPlayer)
- // {
- // final int mana = stack.getTagCompound().getCompoundTag("InfiTool").getInteger("CorpseIvyMana");
- // final int returned = ManaItemHandler.dispatchMana(stack, (EntityPlayer) entity, mana, true);
- // stack.getTagCompound().getCompoundTag("InfiTool").setInteger("CorpseIvyMana", mana - returned);
- // }
- // }
-
- @SubscribeEvent
- public void BotaniaAttackEvent(LivingAttackEvent event)
- {
- if(TDIntegration.botania)
- {
- if(event.source.getEntity() instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) event.source.getEntity();
- final ItemStack heldItem = player.getHeldItem();
-
- if(heldItem != null && heldItem.getItem() != null && heldItem.getItem() instanceof ToolCore)
- {
- final NBTTagCompound tags = heldItem.getTagCompound().getCompoundTag("InfiTool");
-
- if(tags.hasKey("CorpseIvy"))
- {
- ManaItemHandler.dispatchMana(heldItem, player, 100, true);
- }
- }
- }
- }
- }
-
- public void UpdateManaRepair(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(entity instanceof EntityPlayer)
- {
- if(tags.getInteger("Damage") > 0)
- {
-
- if(ManaItemHandler.requestManaExact(stack, (EntityPlayer) entity, 100, true))
- {
- tags.setInteger("Damage", tags.getInteger("Damage") - 1);
- }
-
- }
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierBoolExclusive.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierBoolExclusive.java
deleted file mode 100644
index 62a63ce..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierBoolExclusive.java
+++ /dev/null
@@ -1,83 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers;
-
-import java.util.Arrays;
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.modifiers.tools.ModBoolean;
-
-public class ModifierBoolExclusive extends ModBoolean
-{
- String[] exclusive;
- protected int modsNeeded = 0;
- protected String color;
- protected String tooltipName;
- String[] modExclusions;
-
- /*
- * excludeMods: If these modifier keys are present this modifier wont take.
- */
- public ModifierBoolExclusive(ItemStack[] items, int effect, String tag, String c, String tip, String[] exclusive, int modsNeeded, String[] excludeMods)
- {
- super(items, effect, tag, c, tip);
- this.exclusive = exclusive;
- this.modsNeeded = modsNeeded;
- color = c;
- tooltipName = tip;
- modExclusions = excludeMods;
- }
-
- @Override
- protected boolean canModify(ItemStack tool, ItemStack[] input)
- {
- final List list = Arrays.asList(((ToolCore) tool.getItem()).getTraits());
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
-
- boolean isExclusive = false;
- boolean hasModRejection = false;
-
- if(exclusive.length > 0)
- {
- for(final String element : exclusive)
- {
- if(list.contains(element))
- {
- isExclusive = true;
- }
- }
- }
- else
- {
- isExclusive = true;
- }
-
- if(modExclusions != null)
- {
- for(final String modExclusion : modExclusions)
- {
- if(tags.hasKey(modExclusion))
- {
- hasModRejection = true;
- }
- }
- }
-
- return isExclusive && !hasModRejection && !tags.hasKey(key);
- }
-
- @Override
- public void modify(ItemStack[] input, ItemStack tool)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
-
- tags.setBoolean(key, true);
-
- int modifiers = tags.getInteger("Modifiers");
- modifiers -= modsNeeded;
- tags.setInteger("Modifiers", modifiers);
-
- addToolTip(tool, color + tooltipName, color + key);
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierIntExclusive.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierIntExclusive.java
deleted file mode 100644
index 4b9b9a3..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierIntExclusive.java
+++ /dev/null
@@ -1,91 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers;
-
-import java.util.Arrays;
-import java.util.List;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.modifiers.tools.ModInteger;
-
-public class ModifierIntExclusive extends ModInteger
-{
- String[] exclusive;
- int modsNeeded = 0;
- String color;
- String tooltipName;
- int initialIncrease;
- int secondaryIncrease;
- int max = 5;
- String[] modExclusions;
-
- public ModifierIntExclusive(ItemStack[] items, int effect, String dataKey, int increase, String c, String tip, String[] exclusive, int modsNeeded, String[] excludeMods)
- {
- super(items, effect, dataKey, increase, c, tip);
- this.exclusive = exclusive;
- this.modsNeeded = modsNeeded;
- initialIncrease = secondaryIncrease = increase;
- color = c;
- tooltipName = tip;
- modExclusions = excludeMods;
- }
-
- public ModifierIntExclusive(ItemStack[] items, int effect, String dataKey, int increase, String c, String tip, String[] exclusive, int modsNeeded, int max)
- {
- super(items, effect, dataKey, increase, c, tip);
- this.exclusive = exclusive;
- this.modsNeeded = modsNeeded;
- initialIncrease = secondaryIncrease = increase;
- color = c;
- tooltipName = tip;
- this.max = max;
- }
-
- @Override
- protected boolean canModify(ItemStack tool, ItemStack[] input)
- {
- final List list = Arrays.asList(((ToolCore) tool.getItem()).getTraits());
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
-
- for(final String element : exclusive)
- {
- if(list.contains(element))
- {
- }
- }
-
- if(modExclusions != null)
- {
- for(final String modExclusion : modExclusions)
- {
- if(tags.hasKey(modExclusion))
- {
- }
- }
- }
-
- return tags.getInteger(tooltipName) < max;
- }
-
- @Override
- public void modify(ItemStack[] input, ItemStack tool)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
- if(tags.hasKey(key))
- {
- int increase = tags.getInteger(key);
- increase += secondaryIncrease;
- tags.setInteger(key, increase);
- }
- else
- {
- tags.setInteger(key, initialIncrease);
- }
-
- int modifiers = tags.getInteger("Modifiers");
- modifiers -= modsNeeded;
- tags.setInteger("Modifiers", modifiers);
-
- addToolTip(tool, color + tooltipName, color + key);
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierSoulHandler.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierSoulHandler.java
deleted file mode 100644
index eda54f1..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifierSoulHandler.java
+++ /dev/null
@@ -1,393 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers;
-
-import java.util.List;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.multiplayer.WorldClient;
-import net.minecraft.entity.EntityCreature;
-import net.minecraft.entity.EntityFlying;
-import net.minecraft.entity.EntityLiving;
-import net.minecraft.entity.monster.EntitySlime;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.event.entity.living.LivingHurtEvent;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.event.ModifyEvent;
-import tconstruct.library.tools.ToolCore;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-
-public class ModifierSoulHandler
-{
- String name;
- int time = 160;
- boolean broken = false;
- boolean newlymade = false;
- boolean newlymodified = false;
- boolean onFire = false;
- boolean playerharmed = false;
- boolean playerattacked = false;
- float dmg = 0;
- //boolean playerdead = false;
- boolean storymode = false;
- int story = 0;
- int storyline = 0;
- int numofstories = 0;
-
- public ModifierSoulHandler(int stories, String name)
- {
- MinecraftForge.EVENT_BUS.register(this);
- numofstories = stories;
- this.name = name;
- }
-
- public void Update(ItemStack tool)
- {
- final WorldClient world = Minecraft.getMinecraft().theWorld;
- final EntityPlayer player = Minecraft.getMinecraft().thePlayer;
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
-
- String output = "";
-
- if(time <= 0)
- {
- if(!tags.getBoolean("Broken"))
- {
- //player.addChatMessage(new ChatComponentText("Test"));
- final List entities = world.getEntitiesWithinAABB(EntityLiving.class, AxisAlignedBB.getBoundingBox(player.posX - 20, player.posY - 20, player.posZ - 20, player.posX + 20, player.posY + 20, player.posZ + 20));
- int choice = world.rand.nextInt(3);
- final float dmg = tags.getInteger("Damage");
- final float dur = tags.getInteger("TotalDurability");
- // if(playerdead)
- // {
- // output += "§4(Player Death)§f ";
- // output += talk(output, world, (ToolCore) tool.getItem(), "death");
- // playerdead = false;
- // }
-
- if(playerattacked)
- {
- output += "§7(Attacking)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "offense");
- playerattacked = false;
- }
-
- else if(playerharmed)
- {
- output += "§4(Player Hurt)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "defense");
- playerattacked = false;
- }
-
- else if(newlymade)
- {
- output += "§7(Greetings)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "creation");
- newlymade = false;
- }
-
- else if(newlymodified)
- {
- output += "§7(Modified)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "modified");
- newlymodified = false;
- }
-
- else if(onFire)
- {
- output += "§4(Player on Fire)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "onfire");
- }
-
- else if(player.getHealth() <= 6)
- {
- output += "§4(Player Low Health)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "lowhp");
- }
-
- else if(player.getFoodStats().getFoodLevel() <= 6)
- {
- output += "§4(Player Hungry)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "lowhunger");
- }
-
- else if((dur - dmg) / dur <= 0.1f)
- {
- output += "§4(Nearly Broken)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "lowdurability");
- }
-
- else if(broken)
- {
- output += "§7(Repaired)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "repaired");
- }
-
- //react entity
- else if(choice == 0)
- {
- if(entities.size() > 0)
- {
- final EntityLiving ent = (EntityLiving) entities.get(world.rand.nextInt(entities.size()));
-
- if(ent instanceof EntityCreature || ent instanceof EntityFlying || ent instanceof EntitySlime)
- {
- final boolean doGeneral = world.rand.nextBoolean();
- final boolean doInsult = world.rand.nextBoolean();
- if(!doInsult)
- {
- if(!doGeneral)
- {
- output += "§7(" + ent.getClass().getName().substring(ent.getClass().getName().lastIndexOf("Entity") + 6).toLowerCase() + " Nearby)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), ent.getClass().getName().substring(ent.getClass().getName().lastIndexOf("Entity") + 6).toLowerCase() + "near");
- }
- else
- {
- output += "§7(Creature Nearby)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "creaturenear");
- }
- }
- else
- {
- if(!doGeneral)
- {
- output += "§7(insult" + ent.getClass().getName().substring(ent.getClass().getName().lastIndexOf("Entity") + 6).toLowerCase() + ")§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "insult" + ent.getClass().getName().substring(ent.getClass().getName().lastIndexOf("Entity") + 6).toLowerCase());
- }
- else
- {
- output += "§7(Generic Insult)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "insultother");
- }
- }
- }
-
- if(output.contains("~other~"))
- {
- output = output.replace("~other~", ent.getClass().getName().substring(ent.getClass().getName().lastIndexOf("Entity") + 6));
- }
- }
- }
- //Story
- else if(choice == 1)
- {
- story = world.rand.nextInt(numofstories);
- output += story(output, world);
- storymode = true;
- }
- //General Chat
- else
- {
- choice = world.rand.nextInt(4);
- if(choice == 0)
- {
- if(tool.getItem() instanceof ArmorCore)
- {
- output += talk(output, world, (ToolCore) tool.getItem(), "armor");
-
- }
- else
- {
- output += talk(output, world, (ToolCore) tool.getItem(), "weapon");
- }
- }
- else
- {
- output += talk(output, world, (ToolCore) tool.getItem(), "other");
- }
- }
-
- if(storymode == true)
- {
- time = world.rand.nextInt(160) + 80;
- }
- else
- {
- time = world.rand.nextInt(1600) + 800;
- if(TinkersDefense.config.debug)
- {
- time = world.rand.nextInt(160) + 80;
- }
- }
-
- }
- else
- {
- if(broken == false)
- {
- output += "§4(Broken)§f ";
- output += talk(output, world, (ToolCore) tool.getItem(), "broken");
- broken = true;
- }
- }
-
- formatOutput(output, player, tool);
- }
- else
- {
- time--;
- }
-
- }
-
- String story(String output, WorldClient world)
- {
- final String line = StatCollector.translateToLocal("soul." + name + ".story." + story + "." + storyline);
- if(!line.equals("soul." + name + ".story." + story + "." + storyline))
- {
- storyline++;
- return line;
- }
- else
- {
- storymode = false;
- story = 0;
- storyline = 0;
- return "";
- }
-
- }
-
- String talk(String output, WorldClient world, ToolCore tool, String type)
- {
- final int lines = getAmountOfLines("soul." + name + "." + type + ".");
- if(lines > 0)
- {
- return StatCollector.translateToLocal("soul." + name + "." + type + "." + world.rand.nextInt(lines));
- }
- if(TinkersDefense.config.debug)
- {
- return "Error: No lines (" + type + " chat)";
- }
- return "";
- }
-
- int getAmountOfLines(String type)
- {
- String nextLine = "";
- int i = -1;
- do
- {
- i++;
- nextLine = StatCollector.translateToLocal(type + i);
- }
- while(!nextLine.contains(type));
- return i;
- }
-
- void formatOutput(String output, EntityPlayer player, ItemStack tool)
- {
- if(tool != null && output.contains("~tool~"))
- {
- output = output.replace("~tool~", ((ToolCore) tool.getItem()).getLocalizedToolName());
- }
- if(output.contains("~player~"))
- {
- output = output.replace("~player~", player.getDisplayName());
- }
- if(output.contains("~material~"))
- {
- output = output.replace("~material~", TConstructRegistry.toolMaterials.get(tool.getTagCompound().getCompoundTag("InfiTool").getInteger("Head")).localizedName());
- }
-
- if(output.contains("~damage~"))
- {
- output = output.replace("~damage~", Float.toString(dmg));
- }
-
- if(!output.isEmpty())
- {
- player.addChatMessage(new ChatComponentText(
- "[" + name + " the " + ((ToolCore) tool.getItem()).getLocalizedToolName() + "] " + output));
- }
- else
- {
- if(TinkersDefense.config.debug)
- {
- player.addChatMessage(new ChatComponentText(
- "Error: Soul missing line"));
- }
- }
- }
-
- @SubscribeEvent
- public void ModifySoulEvent(ModifyEvent event)
- {
- if(event.modifier.stacks != null && !event.modifier.stacks.isEmpty() && event.modifier.stacks.get(0) != null && ItemStack.areItemStacksEqual((ItemStack) event.modifier.stacks.get(0), new ItemStack(
- Modifiers.TMod.modItems, 1, 3)))
- {
- newlymade = true;
-
- }
- else if(event.itemStack.getTagCompound().getCompoundTag("InfiTool").hasKey("Ensouled"))
- {
- newlymodified = true;
- }
-
- time = 0;
- }
-
- @SubscribeEvent
- public void HarmedEvent(LivingHurtEvent event)
- {
- if(event.entityLiving instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) event.entityLiving;
- if(player.getUniqueID() == Minecraft.getMinecraft().thePlayer.getUniqueID())
- {
- if(event.source.isFireDamage())
- {
- onFire = true;
- }
- else
- {
- playerharmed = true;
- dmg = event.ammount;
- }
- time = 0;
- }
- }
- else if(event.source.getEntity() instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) event.source.getEntity();
- final String p = player.getDisplayName();
- final String s = Minecraft.getMinecraft().thePlayer.getDisplayName();
- if(p == s)
- {
- playerattacked = true;
- dmg = event.ammount;
- time = 0;
- }
- }
- }
- // @SubscribeEvent
- // public void PlayerDeathEvent(LivingDeathEvent event)
- // {
- // if(event.entityLiving.worldObj.isRemote)
- // if(event.entityLiving.isEntityEqual(Minecraft.getMinecraft().thePlayer))
- // {
- // String output = "";
- // final int lines = getAmountOfLines("soul." + name + "." + "death" + ".");
- // if(lines > 0)
- // {
- // output += StatCollector.translateToLocal("soul." + name + "." + "death" + "." + event.entityLiving.worldObj.rand.nextInt(lines));
- // }
- // else if(TinkersDefense.config.debug)
- // {
- // output += "Error: No lines (" + "death" + " chat)";
- // }
- // else
- // {
- // output += "";
- // }
- //
- // formatOutput(output, (EntityPlayer) event.entityLiving, null);
- // }
- // }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/Modifiers.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/Modifiers.java
deleted file mode 100644
index f10fa68..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/Modifiers.java
+++ /dev/null
@@ -1,86 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers;
-
-import lance5057.tDefense.TDIntegration;
-import lance5057.tDefense.armor.modifiers.ArmorMods;
-import lance5057.tDefense.core.tools.modifiers.BloodMagic.BloodMagicMods;
-import lance5057.tDefense.core.tools.modifiers.Botania.BotaniaMods;
-import lance5057.tDefense.core.tools.modifiers.TDefense.TDMods;
-import lance5057.tDefense.core.tools.modifiers.Thaumcraft.ThaumcraftMods;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.world.World;
-import tconstruct.library.tools.ToolCore;
-
-public class Modifiers
-{
- public static TDMods TMod;
- public static ArmorMods AMod;
- public static BotaniaMods BotMod;
- public static ThaumcraftMods ThaumMod;
- public static BloodMagicMods BloodMod;
-
- public void preInit()
- {
- TMod = new TDMods();
- AMod = new ArmorMods();
-
- if(TDIntegration.botania)
- {
- BotMod = new BotaniaMods();
- }
-
- if(TDIntegration.thaumcraft)
- {
- ThaumMod = new ThaumcraftMods();
- }
- if(TDIntegration.bloodMagic)
- {
- BloodMod = new BloodMagicMods();
- }
- }
-
- public void Init()
- {
- TMod.RegisterRecipes();
- TMod.RegisterModifiers();
-
- AMod.RegisterRecipes();
- AMod.RegisterModifiers();
-
- if(BotMod != null)
- {
- BotMod.RegisterRecipes();
- BotMod.RegisterModifiers();
- }
-
- if(ThaumMod != null)
- {
- ThaumMod.RegisterRecipes();
- ThaumMod.RegisterModifiers();
- }
- if(BloodMod != null)
- {
- BloodMod.RegisterRecipes();
- BloodMod.RegisterModifiers();
- }
- }
-
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- TMod.UpdateAll(tool, stack, world, entity, tags);
- //AMod.UpdateAll(tool, stack, world, entity, tags);
- if(BotMod != null)
- {
- BotMod.UpdateAll(tool, stack, world, entity, tags);
- }
- if(ThaumMod != null)
- {
- ThaumMod.UpdateAll(tool, stack, world, entity, tags);
- }
- if(BloodMod != null)
- {
- BloodMod.UpdateAll(tool, stack, world, entity, tags);
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifiersBase.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifiersBase.java
deleted file mode 100644
index 94f555d..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/ModifiersBase.java
+++ /dev/null
@@ -1,42 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers;
-
-import lance5057.tDefense.core.items.MetaModifierItem;
-import net.minecraft.entity.Entity;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.world.World;
-import net.minecraftforge.common.MinecraftForge;
-import tconstruct.library.tools.ToolCore;
-import cpw.mods.fml.common.registry.GameRegistry;
-
-public abstract class ModifiersBase
-{
- public MetaModifierItem modItems;
- public String[] itemStrings;
- public String name;
-
- public ModifiersBase(String[] strings, String name)
- {
- itemStrings = strings;
- this.name = name;
-
- MinecraftForge.EVENT_BUS.register(this);
- LoadItems();
- }
-
- public void LoadItems()
- {
- if(itemStrings != null && name != null)
- {
- modItems = new MetaModifierItem(name, itemStrings.length,
- itemStrings);
- GameRegistry.registerItem(modItems, name);
- }
- }
-
- public abstract void RegisterRecipes();
-
- public abstract void RegisterModifiers();
-
- public abstract void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags);
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/TDefense/TDMods.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/TDefense/TDMods.java
deleted file mode 100644
index eb23077..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/TDefense/TDMods.java
+++ /dev/null
@@ -1,470 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers.TDefense;
-
-import java.util.ArrayList;
-import java.util.Random;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.tools.ModifierSoul;
-import lance5057.tDefense.core.tools.Shield;
-import lance5057.tDefense.core.tools.modifiers.ModifierBoolExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifierIntExclusive;
-import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
-import lance5057.tDefense.core.tools.modifiers.modLapisShears;
-import lance5057.tDefense.core.tools.modifiers.ActiveToolMods.TDefenseActiveToolMod;
-import lance5057.tDefense.proxy.CommonProxy;
-import mods.battlegear2.api.PlayerEventChild.ShieldBlockEvent;
-import mods.battlegear2.api.core.IBattlePlayer;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLiving;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.EnumCreatureAttribute;
-import net.minecraft.entity.item.EntityXPOrb;
-import net.minecraft.entity.monster.EntityMob;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.projectile.EntityFireball;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.util.DamageSource;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.Vec3;
-import net.minecraft.util.WeightedRandomChestContent;
-import net.minecraft.world.World;
-import net.minecraftforge.common.ChestGenHooks;
-import net.minecraftforge.event.entity.living.LivingAttackEvent;
-import net.minecraftforge.event.entity.living.LivingDeathEvent;
-import net.minecraftforge.oredict.OreDictionary;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.client.TConstructClientRegistry;
-import tconstruct.library.crafting.ModifyBuilder;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.tools.TinkerTools;
-import tconstruct.weaponry.TinkerWeaponry;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-
-public class TDMods extends ModifiersBase
-{
- public TDMods()
- {
- super(new String[] {"AncientRelic", "RainbowGem", "Textbook", "SoulStone", "CrestFeathers", "CrestMirrors", "CrestLegends", "CrestGluttony", "CrestThorns", "CrestSanguisuga", "CrestWinds", "CrestLight", "CrestPaper"}, "modItemsCore");
- }
-
- @Override
- public void RegisterRecipes()
- {
- ChestGenHooks.getInfo(ChestGenHooks.DUNGEON_CHEST).addItem(new WeightedRandomChestContent(
- new ItemStack(modItems, 1, 0), 1, 1, 1));
- ChestGenHooks.getInfo(ChestGenHooks.DUNGEON_CHEST).addItem(new WeightedRandomChestContent(
- new ItemStack(modItems, 1, 3), 1, 1, 1));
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 1), new Object[] {"111", "1d1", "111", 'd', new ItemStack(
- Items.diamond, 1, 0), '1', new ItemStack(Items.dye, 1,
- OreDictionary.WILDCARD_VALUE)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 2), new Object[] {"-1-", "1d1", "-1-", 'd', new ItemStack(
- Items.enchanted_book, 1, OreDictionary.WILDCARD_VALUE), '1', new ItemStack(
- Items.experience_bottle, 1, 0)});
-
- GameRegistry.addShapelessRecipe(new ItemStack(modItems, 1, 12), new ItemStack(
- Items.enchanted_book, 1, OreDictionary.WILDCARD_VALUE));
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 4), new Object[] {"fcf", "sps", "fcf", 'f', new ItemStack(
- Items.feather, 1, -1), 'c', new ItemStack(
- TinkersDefense.partCloth, 1, OreDictionary.WILDCARD_VALUE), 's', new ItemStack(
- Items.string, 1, -1), 'p', new ItemStack(modItems, 1, 12)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 5), new Object[] {"gng", "spc", "gbg", 'g', new ItemStack(
- Blocks.glass_pane, 1, -1), 'c', new ItemStack(
- TinkersDefense.partCloth, 1, OreDictionary.WILDCARD_VALUE), 's', new ItemStack(
- Blocks.sand, 1, OreDictionary.WILDCARD_VALUE), 'p', new ItemStack(
- modItems, 1, 12), 'n', new ItemStack(Items.nether_star, 1, 0), 'b', new ItemStack(
- Blocks.gold_block, 1, 12)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 6), new Object[] {"-r-", "-p-", "---", 'r', new ItemStack(
- modItems, 1, 0), 'p', new ItemStack(modItems, 1, 12)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 7), new Object[] {"aaa", "ipi", "aaa", 'i', TConstructRegistry.getItemStack("ingotPigIron"), 'p', new ItemStack(
- modItems, 1, 12), 'a', new ItemStack(TinkerWeaponry.arrowhead,
- 1, 5)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 8), new Object[] {"aia", "ipi", "aia", 'i', new ItemStack(
- Items.iron_ingot, 1, 0), 'p', new ItemStack(modItems, 1, 12), 'a', new ItemStack(
- TinkersDefense.partRivet, 1, 4)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 9), new Object[] {"brb", "apa", "ara", 'b', TConstructRegistry.getItemStack("necroticBone"), 'r', new ItemStack(
- TinkerTools.toughRod, 1, 7), 'a', new ItemStack(
- TinkerWeaponry.arrowhead, 1, 11), 'p', new ItemStack(modItems,
- 1, 12)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 10), new Object[] {"PfP", "tpt", "PfP", 'P', new ItemStack(
- Blocks.piston, 1, 0), 'p', new ItemStack(modItems, 1, 12), 'f', new ItemStack(
- Items.feather, 1, 0), 't', new ItemStack(Items.ghast_tear, 1, 0)});
-
- GameRegistry.addShapedRecipe(new ItemStack(modItems, 1, 11), new Object[] {"gbg", "tpt", "gbg", 'g', new ItemStack(
- Blocks.glowstone, 1, 0), 'p', new ItemStack(modItems, 1, 12), 'b', new ItemStack(
- Items.blaze_rod, 1, 0), 't', new ItemStack(Blocks.torch, 1, 0)});
- }
-
- @Override
- public void RegisterModifiers()
- {
- //All
- ModifyBuilder.registerModifier(new ModifierSoul(
- new ItemStack[] {new ItemStack(modItems, 1, 3)},
- TinkersDefense.config.SoulSteveID, "Ensouled",
- EnumChatFormatting.WHITE.toString(), "Ensouled (Steve)",
- new String[] {}, 0, null, "Steve"));
-
- //Weapons
- //TO-DO
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {new ItemStack(
- Blocks.heavy_weighted_pressure_plate, 1, 0)},
- TinkersDefense.config.DazeID, "Daze", 1,
- EnumChatFormatting.GRAY.toString(), "Daze",
- new String[] {"weapon"}, 1, null));
- ModifyBuilder.registerModifier(new ModifierIntExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 2)},
- TinkersDefense.config.XPBoostID, "XPBoost", 1,
- EnumChatFormatting.GREEN.toString(), "XP Boost",
- new String[] {"weapon"}, 1, null));
-
- //Shears
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(
- new ItemStack[] {new ItemStack(modItems, 1, 1)},
- TinkersDefense.config.RainbowID, "Rainbow",
- EnumChatFormatting.WHITE.toString(), "Rainbow",
- new String[] {"shears"}, 1, null));
-
- ModifyBuilder.registerModifier(new modLapisShears(
- TinkersDefense.config.ShearFortuneID,
- new ItemStack[] {new ItemStack(Items.dye, 1, 4), new ItemStack(
- Blocks.lapis_block, 1, 0)}, new int[] {1, 9}));
-
- //Shields
- RegisterCrestModifier(TinkersDefense.config.CrestFeathersID, "Feathers", 1, EnumChatFormatting.WHITE.toString(), new ItemStack(
- modItems, 1, 4), 1);
- RegisterCrestModifier(TinkersDefense.config.CrestMirrorsID, "Mirrors", EnumChatFormatting.DARK_AQUA.toString(), new ItemStack(
- modItems, 1, 5), 1);
- RegisterLegendModifier(TinkersDefense.config.CrestLegendsID, "Legends", EnumChatFormatting.GOLD.toString(), new ItemStack(
- modItems, 1, 6), 1);
- // RegisterCrestModifier(TinkersDefense.config.CrestBladesID, "Blades", 1, EnumChatFormatting.GRAY.toString(), new ItemStack(
- // modItems, 1, 7), 1);
- RegisterCrestModifier(TinkersDefense.config.CrestGluttonyID, "Gluttony", 1, EnumChatFormatting.DARK_GREEN.toString(), new ItemStack(
- modItems, 1, 7), 1);
- // RegisterCrestModifier(TinkersDefense.config.CrestPitchID, "Pitch", 1, EnumChatFormatting.DARK_GRAY.toString(), new ItemStack(
- // modItems, 1, 8), 1);
- RegisterCrestModifier(TinkersDefense.config.CrestThornsID, "Thorns", 1, EnumChatFormatting.GREEN.toString(), new ItemStack(
- modItems, 1, 8), 1);
- RegisterCrestModifier(TinkersDefense.config.CrestSanguisugaID, "Sanguisuga", 1, EnumChatFormatting.DARK_RED.toString(), new ItemStack(
- modItems, 1, 9), 1);
- RegisterCrestModifier(TinkersDefense.config.CrestWindsID, "Wind", 1, EnumChatFormatting.AQUA.toString(), new ItemStack(
- modItems, 1, 10), 1);
- // RegisterCrestModifier(TinkersDefense.config.CrestRetributionID, "Retribution", 1, EnumChatFormatting.LIGHT_PURPLE.toString(), new ItemStack(
- // modItems, 1, 13), 1);
- RegisterCrestModifier(TinkersDefense.config.CrestLightID, "Light", 1, EnumChatFormatting.YELLOW.toString(), new ItemStack(
- modItems, 1, 11), 1);
-
- //Jokes
- // ModifyBuilder.registerModifier(new ModifierBoolExclusive(new ItemStack[] {new ItemStack(Blocks.glass_pane)}, TinkersDefense.config.JokeInsultID, "Insulting", EnumChatFormatting.AQUA.toString(), "Joke: Insulting", null, 0, null));
- // ModifyBuilder.registerModifier(new ModifierBoolExclusive(new ItemStack[] {new ItemStack(Blocks.glass_pane)}, TinkersDefense.config.JokePyrotechID, "Pyrotech", EnumChatFormatting.AQUA.toString(), "Joke: Pyrotech", null, 0, null));
- //ModifyBuilder.registerModifier(new modifierIntExclusive(new ItemStack[] {new ItemStack(Items.slime_ball)}, TinkersDefense.config.JokeCompensateID, "Compensate", 1, EnumChatFormatting.DARK_GRAY.toString(), "Joke: Compensating", new String[] {"shield"}, 1, null));
-
- TConstructRegistry.registerActiveToolMod(new TDefenseActiveToolMod());
-
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.DazeID, "tinker", "daze", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.ShearFortuneID, "tinker", "lapis", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.RainbowID, "rainbow", "daze", true);
-
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestFeathersID, "tinker", "feathers", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestMirrorsID, "tinker", "mirrors", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestLegendsID, "tinker", "legends", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestBladesID, "tinker", "blades", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestGluttonyID, "tinker", "gluttony", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestPitchID, "tinker", "pitch", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestSanguisugaID, "tinker", "sanguisuga", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestWindsID, "tinker", "wind", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestRetributionID, "tinker", "retribution", true);
- // TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CrestLightID, "tinker", "light", true);
-
- //TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.JokeInsultID, "tinker", "insult", true);
- //TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.JokePyrotechID, "tinker", "pyrotech", true);
- //TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.JokeCompensateID, "tinker", "compensate", true);
-
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.SoulBoundID, "tinker", "soulbound", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.RainbowID, "tinker", "rainbow", true);
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.XPBoostID, "tinker", "textbook", true);
-
- }
- }
-
- public void RegisterCrestModifier(int[] effect, String tag, int increase, String color, ItemStack item, int mods)
- {
- for(int i = 0; i < TinkersDefense.colors.length; i++)
- {
- final ItemStack[] items = {item, new ItemStack(Items.dye, 1, i)};
- ModifyBuilder.registerModifier(new ModifierIntExclusive(items,
- effect[i], tag.toLowerCase(), increase, color,
- "Crest of " + tag, new String[] {"shield"}, mods, null));
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, effect[i], "tinker", TinkersDefense.colors[i] + "_" + tag.toLowerCase(), true);
- }
- }
- }
-
- public void RegisterCrestModifier(int[] effect, String tag, String color, ItemStack item, int mods)
- {
-
- for(int i = 0; i < TinkersDefense.colors.length; i++)
- {
- final ItemStack[] items = {item, new ItemStack(Items.dye, 1, i)};
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(items,
- effect[i], tag.toLowerCase(), color, "Crest of " + tag,
- new String[] {"shield"}, mods, null));
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, effect[i], "tinker", TinkersDefense.colors[i] + "_" + tag.toLowerCase(), true);
- }
- }
- }
-
- public void RegisterLegendModifier(int[] effect, String tag, String color, ItemStack item, int mods)
- {
-
- for(int i = 0; i < TinkersDefense.colors.length; i++)
- {
- final ItemStack[] items = {item, new ItemStack(Items.dye, 1, i)};
- ModifyBuilder.registerModifier(new ModifierBoolExclusive(items,
- effect[i], tag.toLowerCase(), color, "Crest of " + tag,
- new String[] {"heatershield"}, mods, null));
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, effect[i], "tinker", TinkersDefense.colors[i] + "_" + tag.toLowerCase(), true);
- }
- }
- }
-
- @Override
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(tags.hasKey("mirrors"))
- {
- UpdateMirrors(tool, stack, world, entity);
- }
- if(tags.hasKey("gluttony"))
- {
- UpdateGluttony(tool, stack, world, entity, tags);
- }
- if(world.isRemote && tags.hasKey("Ensouled") && tags.hasKey("Soul"))
- {
- if(CommonProxy.SoulHandler != null)
- {
- CommonProxy.SoulHandler.Update(stack);
- }
- }
- }
-
- public void UpdateMirrors(ToolCore tool, ItemStack stack, World world, Entity entity)
- {
- if(((IBattlePlayer) entity).isBlockingWithShield())
- {
- final AxisAlignedBB boundingBox = AxisAlignedBB.getBoundingBox(((EntityLivingBase) entity).posX - 3, ((EntityLivingBase) entity).posY - 3, ((EntityLivingBase) entity).posZ - 3, ((EntityLivingBase) entity).posX + 3, ((EntityLivingBase) entity).posY + 3, ((EntityLivingBase) entity).posZ + 3);
-
- final ArrayList<EntityFireball> fireballs = (ArrayList<EntityFireball>) world.getEntitiesWithinAABB(EntityFireball.class, boundingBox);
- for(final EntityFireball fireball : fireballs)
- {
- if(fireball.getDistanceSqToEntity((entity)) <= 25)
- {
- final Vec3 playerlook = ((EntityLivingBase) entity).getLookVec();
-
- fireball.motionX = playerlook.xCoord;
- fireball.motionY = playerlook.yCoord;
- fireball.motionZ = playerlook.zCoord;
- fireball.accelerationX = fireball.motionX * 0.1D;
- fireball.accelerationY = fireball.motionY * 0.1D;
- fireball.accelerationZ = fireball.motionZ * 0.1D;
-
- fireball.shootingEntity = ((EntityLivingBase) entity);
-
- ((EntityLivingBase) entity).worldObj.playSoundAtEntity((entity), "battlegear2:shield", 1, 1);
- }
- }
- }
- }
-
- public void UpdateGluttony(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- final Shield shield = (Shield) tool;
-
- if(tags.getInteger("Damage") > 0 && shield.getArrowCount(stack) > 0)
- {
- tags.setInteger("Damage", tags.getInteger("Damage") - 2);
- shield.setArrowCount(stack, shield.getArrowCount(stack) - 1);
-
- if(world.isRemote)
- {
- world.playSoundEffect(entity.lastTickPosX, entity.lastTickPosY, entity.lastTickPosZ, "minecraft:random.eat", 1, 1);
- }
- }
- }
-
- //Events
- @SubscribeEvent
- public void XPBoost(LivingDeathEvent event)
- {
- if(!(event.entityLiving instanceof EntityPlayer) && event.source.getSourceOfDamage() instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) event.source.getSourceOfDamage();
- final ItemStack itemstack = player.getCurrentEquippedItem();
- if(itemstack != null && itemstack.getItem() instanceof ToolCore)
- {
- final NBTTagCompound tags = itemstack.getTagCompound().getCompoundTag("InfiTool");
-
- if(tags != null && tags.hasKey("XPBoost"))
- {
- player.worldObj.spawnEntityInWorld(new EntityXPOrb(
- player.worldObj, event.entityLiving.posX,
- event.entityLiving.posY, event.entityLiving.posZ,
- (int) Math.pow(tags.getInteger("XPBoost"), 2)));
-
- }
- }
- }
- }
-
- @SubscribeEvent
- public void UpdateDaze(LivingAttackEvent event)
- {
- if(event.source.getEntity() instanceof EntityPlayer)
- {
- final EntityPlayer player = (EntityPlayer) event.source.getEntity();
- final ItemStack heldItem = player.getHeldItem();
- final EntityLivingBase attacked = event.entityLiving;
-
- if(heldItem != null && heldItem.getItem() != null && heldItem.getItem() instanceof ToolCore)
- {
- final NBTTagCompound tags = heldItem.getTagCompound().getCompoundTag("InfiTool");
-
- if(tags.hasKey("Daze"))
- {
- final int daze = tags.getInteger("Daze");
- final int chance = daze * 5;
-
- final Random roll = new Random();
- final int num = roll.nextInt(100) + 1;
-
- if(num <= chance)
- {
- attacked.addPotionEffect(new PotionEffect(2, 3 * 20,
- 100));
- attacked.addPotionEffect(new PotionEffect(9, 3 * 20,
- 100));
- attacked.addPotionEffect(new PotionEffect(15, 3 * 20,
- 100));
- attacked.addPotionEffect(new PotionEffect(18, 3 * 20,
- 100));
- }
-
- }
- }
- }
- }
-
- @SubscribeEvent
- @Optional.Method(modid = "battlegear2")
- public void TD_ShieldBlock(ShieldBlockEvent event)
- {
- if(event.shield.getItem() instanceof ToolCore)
- {
- final NBTTagCompound tags = event.shield.getTagCompound().getCompoundTag("InfiTool");
-
- if(!tags.getBoolean("Broken"))
- {
- if(tags.hasKey("mirrors"))
- {
- UpdateMirrors((ToolCore) event.shield.getItem(), event.shield, event.entityPlayer.worldObj, event.entityPlayer);
- }
-
- if(tags.hasKey("legends"))
- {
- event.getPlayer().addPotionEffect(new PotionEffect(
- Potion.fireResistance.getId(), 200, 2));
- event.getPlayer().addPotionEffect(new PotionEffect(
- Potion.moveSpeed.getId(), 200, 2));
- event.getPlayer().addPotionEffect(new PotionEffect(
- Potion.resistance.getId(), 200, 2));
- }
-
- if(tags.hasKey("thorns"))
- {
- event.source.getEntity().attackEntityFrom(DamageSource.generic, tags.getInteger("thorns") * 2);
- }
-
- if(tags.hasKey("sanguisuga"))
- {
- event.source.getEntity().attackEntityFrom(DamageSource.generic, tags.getInteger("sanguisuga"));
- event.entityPlayer.heal(tags.getInteger("sanguisuga"));
- }
-
- if(tags.hasKey("light"))
- {
- if(event.source.getEntity() instanceof EntityMob)
- {
- final EntityMob entity = (EntityMob) event.source.getEntity();
- if(entity.getCreatureAttribute() == EnumCreatureAttribute.UNDEAD)
- {
- event.source.getEntity().setFire(tags.getInteger("light"));
- }
- }
- }
-
- // if(tags.hasKey("pitch"))
- // {
- // if(!event.entityPlayer.worldObj.isRemote && event.source.getEntity() instanceof EntityPlayer)
- // {
- // final EntityPlayer entity = (EntityPlayer) event.source.getEntity();
- // if(entity.getEquipmentInSlot(0) != null)
- // {
- // entity.entityDropItem(entity.getEquipmentInSlot(0), 5);
- // entity.setCurrentItemOrArmor(0, null);
- // //entity.setCanPickUpLoot(true);
- // }
- // }
- // }
-
- if(tags.hasKey("wind"))
- {
- if(!event.entityPlayer.worldObj.isRemote && event.source.getEntity() instanceof EntityLiving)
- {
- final EntityLiving entity = (EntityLiving) event.source.getEntity();
-
- final double x = event.entityLiving.posX - entity.posX;
- final double z = event.entityLiving.posZ - entity.posZ;
- //entity.knockBack(entity, tags.getInteger("winds") * 10, x, z);
-
- entity.isAirBorne = true;
- final float f1 = MathHelper.sqrt_double(x * x + z * z);
- final float f2 = 0.4F;
- entity.motionX /= 2.0D;
- entity.motionY /= 2.0D;
- entity.motionZ /= 2.0D;
- entity.motionX -= x / f1 * f2 * tags.getInteger("wind");
- entity.motionY += f2;
- entity.motionZ -= z / f1 * f2 * tags.getInteger("wind");
-
- }
- }
- }
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/Thaumcraft/ThaumcraftMods.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/Thaumcraft/ThaumcraftMods.java
deleted file mode 100644
index 75b477c..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/Thaumcraft/ThaumcraftMods.java
+++ /dev/null
@@ -1,110 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers.Thaumcraft;
-
-import java.lang.reflect.Method;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.core.tools.modifiers.ModifiersBase;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.world.World;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.client.TConstructClientRegistry;
-import tconstruct.library.crafting.ModifyBuilder;
-import tconstruct.library.tools.ToolCore;
-import thaumcraft.api.ItemApi;
-import thaumcraft.api.aspects.Aspect;
-import thaumcraft.api.aspects.AspectList;
-import cpw.mods.fml.common.FMLLog;
-
-public class ThaumcraftMods extends ModifiersBase
-{
-
- public ThaumcraftMods()
- {
- super(null, null);
- }
-
- @Override
- public void LoadItems()
- {
-
- }
-
- @Override
- public void RegisterRecipes()
- {
- }
-
- @Override
- public void RegisterModifiers()
- {
- ModifyBuilder.registerModifier(new modifierRepairVis(
- new ItemStack[] {ItemApi.getItem("itemWandCap", 0)},
- TinkersDefense.config.CapsModID, "Caps",
- EnumChatFormatting.GOLD.toString(), "Caps"));
-
- for(final ToolCore tool : TConstructRegistry.getToolMapping())
- {
- TConstructClientRegistry.addEffectRenderMapping(tool, TinkersDefense.config.CapsModID, "tinker", "cap", true);
- }
- }
-
- @Override
- public void UpdateAll(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(!world.isRemote)
- {
- if(tags.hasKey("Caps"))
- {
- UpdateRepairVis(tool, stack, world, entity, tags);
- }
- }
- }
-
- static Method consumeVisFromInventory;
-
- public void UpdateRepairVis(ToolCore tool, ItemStack stack, World world, Entity entity, NBTTagCompound tags)
- {
- if(tags.getInteger("Damage") > 0)
- {
- final AspectList cost = new AspectList();
- cost.add(Aspect.AIR, (int) (10 * tags.getFloat("Caps")));
- cost.add(Aspect.WATER, (int) (30 * tags.getFloat("Caps")));
- cost.add(Aspect.FIRE, (int) (10 * tags.getFloat("Caps")));
- cost.add(Aspect.ORDER, (int) (20 * tags.getFloat("Caps")));
- cost.add(Aspect.ENTROPY, (int) (10 * tags.getFloat("Caps")));
- cost.add(Aspect.EARTH, (int) (30 * tags.getFloat("Caps")));
-
- boolean success = false;
- try
- {
- if(consumeVisFromInventory == null)
- {
- consumeVisFromInventory = Class.forName("thaumcraft.common.items.wands.WandManager").getMethod("consumeVisFromInventory", EntityPlayer.class, AspectList.class);
- }
- success = (Boolean) consumeVisFromInventory.invoke(null, entity, cost);
- }
- catch(final Exception ex)
- {
- FMLLog.warning("Thaumcraft is missing, you shouldn't see this, please report");
- }
- finally
- {
- if(success)
- {
- if(tags.getInteger("Damage") >= 4)
- {
- tags.setInteger("Damage", tags.getInteger("Damage") - 4);
- }
- else
- {
- tags.setInteger("Damage", 0);
- }
- }
- }
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/Thaumcraft/modifierRepairVis.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/Thaumcraft/modifierRepairVis.java
deleted file mode 100644
index 2c20476..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/Thaumcraft/modifierRepairVis.java
+++ /dev/null
@@ -1,69 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers.Thaumcraft;
-
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import tconstruct.modifiers.tools.ModBoolean;
-import thaumcraft.api.wands.WandCap;
-
-public class modifierRepairVis extends ModBoolean
-{
- WandCap cap;
- String color;
- String tooltipName;
-
- public modifierRepairVis(ItemStack[] items, int effect, String tag, String c, String tip)
- {
- super(items, effect, tag, c, tip);
- color = c;
- tooltipName = tip;
- }
-
- @Override
- public boolean matches(ItemStack[] recipe, ItemStack input)
- {
- cap = null;
- for(final ItemStack element : recipe)
- {
- if(element != null)
- {
- for(final WandCap cp : WandCap.caps.values())
- {
- final ItemStack test = cp.getItem();
- if(test != null && element.getItem() == test.getItem() && element.getItemDamage() == test.getItemDamage())
- {
- cap = cp;
- break;
- }
- }
- }
- }
-
- if(!canModify(input, recipe))
- return false;
- if(cap == null)
- return false;
- return true;
- }
-
- @Override
- protected boolean canModify(ItemStack tool, ItemStack[] input)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
- return tags.getInteger("Modifiers") > 0 && !tags.getBoolean(key) && cap != null; //Will fail if the modifier is false or the tag doesn't exist
- }
-
- @Override
- public void modify(ItemStack[] input, ItemStack tool)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
-
- tags.setFloat(key, cap.getBaseCostModifier());
-
- int modifiers = tags.getInteger("Modifiers");
- modifiers -= 1;
- tags.setInteger("Modifiers", modifiers);
-
- final String mat = cap.getTag().substring(0, 1).toUpperCase() + cap.getTag().substring(1) + " ";
- addToolTip(tool, color + mat + tooltipName, color + mat + tooltipName + " (" + (int) (cap.getBaseCostModifier() * 100) + "%)");
- }
-}
diff --git a/src/main/java/lance5057/tDefense/core/tools/modifiers/modLapisShears.java b/src/main/java/lance5057/tDefense/core/tools/modifiers/modLapisShears.java
deleted file mode 100644
index 8261b4c..0000000
--- a/src/main/java/lance5057/tDefense/core/tools/modifiers/modLapisShears.java
+++ /dev/null
@@ -1,85 +0,0 @@
-package lance5057.tDefense.core.tools.modifiers;
-
-import java.util.Arrays;
-import java.util.List;
-
-import net.minecraft.enchantment.Enchantment;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import tconstruct.library.tools.ToolCore;
-import tconstruct.modifiers.tools.ModLapis;
-
-public class modLapisShears extends ModLapis
-{
-
- public modLapisShears(int effect, ItemStack[] items, int[] values)
- {
- super(effect, items, values);
- }
-
- @Override
- public void modify(ItemStack[] input, ItemStack tool)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
- if(!tags.hasKey(key))
- {
- tags.setBoolean(key, true);
-
- final String modName = "\u00a79Lapis (0/450)";
- final int tooltipIndex = addToolTip(tool, "\u00a79Luck", modName);
- final int[] keyPair = new int[] {0, tooltipIndex};
- tags.setIntArray(key, keyPair);
-
- int modifiers = tags.getInteger("Modifiers");
- modifiers -= 1;
- tags.setInteger("Modifiers", modifiers);
- }
-
- final int increase = matchingAmount(input);
- final int keyPair[] = tags.getIntArray(key);
- keyPair[0] += increase;
- tags.setIntArray(key, keyPair);
- final ToolCore toolcore = (ToolCore) tool.getItem();
- final String[] types = toolcore.getTraits();
- boolean harvest = false;
- for(final String s : types)
- {
- if(s.equals("shears"))
- {
- harvest = true;
- }
- }
- if(harvest)
- {
- if(keyPair[0] >= 450)
- {
- addEnchantment(tool, Enchantment.fortune, 3);
- }
- else if(keyPair[0] >= 300)
- {
- addEnchantment(tool, Enchantment.fortune, 2);
- }
- else if(keyPair[0] >= 100)
- {
- addEnchantment(tool, Enchantment.fortune, 1);
- }
- }
-
- updateModTag2(tool, keyPair);
- }
-
- void updateModTag2(ItemStack tool, int[] keys)
- {
- final NBTTagCompound tags = tool.getTagCompound().getCompoundTag("InfiTool");
- final String tip = "ModifierTip" + keys[1];
- final String modName = "\u00a79Lapis (" + keys[0] + "/" + "450" + ")";
- tags.setString(tip, modName);
- }
-
- @Override
- public boolean validType(ToolCore tool)
- {
- final List list = Arrays.asList(tool.getTraits());
- return list.contains("shears");
- }
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Container_FinishingAnvil.java b/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Container_FinishingAnvil.java
deleted file mode 100644
index c10f3b2..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Container_FinishingAnvil.java
+++ /dev/null
@@ -1,41 +0,0 @@
-package lance5057.tDefense.finishingAnvil.blocks.finishingAnvil;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.InventoryPlayer;
-import net.minecraft.inventory.Container;
-import net.minecraft.inventory.Slot;
-import net.minecraft.item.ItemStack;
-
-public class Container_FinishingAnvil extends Container
-{
- public Container_FinishingAnvil(InventoryPlayer inventoryPlayer, TileEntity_FinishingAnvil te)
- {
- addSlotToContainer(new Slot(te, 0, 39, 32));
-
- for(int x = 0; x < 9; x++)
- {
- addSlotToContainer(new Slot(inventoryPlayer, x, 8 + 18 * x, 142));
- }
-
- for(int y = 0; y < 3; y++)
- {
- for(int x = 0; x < 9; x++)
- {
- addSlotToContainer(new Slot(inventoryPlayer, x + y * 9 + 9,
- 8 + 18 * x, 84 + y * 18));
- }
- }
- }
-
- @Override
- public boolean canInteractWith(EntityPlayer p_75145_1_)
- {
- return true;
- }
-
- @Override
- public ItemStack transferStackInSlot(EntityPlayer par1EntityPlayer, int par2)
- {
- return null;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/FinishingAnvil.java b/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/FinishingAnvil.java
deleted file mode 100644
index c94648b..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/FinishingAnvil.java
+++ /dev/null
@@ -1,159 +0,0 @@
-package lance5057.tDefense.finishingAnvil.blocks.finishingAnvil;
-
-import static net.minecraftforge.common.util.ForgeDirection.EAST;
-import static net.minecraftforge.common.util.ForgeDirection.NORTH;
-import static net.minecraftforge.common.util.ForgeDirection.SOUTH;
-import static net.minecraftforge.common.util.ForgeDirection.WEST;
-
-import java.util.Random;
-
-import lance5057.tDefense.TinkersDefense;
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockContainer;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class FinishingAnvil extends BlockContainer
-{
- public FinishingAnvil()
- {
- super(Material.iron);
- setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
- }
-
- @Override
- public void onBlockAdded(World world, int i, int j, int k)
- {
- super.onBlockAdded(world, i, j, k);
- world.markBlockForUpdate(i, j, k);
- }
-
- @Override
- public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int metadata, float what, float these, float are)
- {
- final TileEntity tileEntity = world.getTileEntity(x, y, z);
- if(tileEntity == null || player.isSneaking())
- return false;
- //code to open gui explained later
- player.openGui(TinkersDefense.instance, TinkersDefense.GUI_ANVIL_INV, player.worldObj, x, y, z);
- return true;
- }
-
- @Override
- public void breakBlock(World world, int x, int y, int z, Block par5, int par6)
- {
- dropItems(world, x, y, z);
- super.breakBlock(world, x, y, z, par5, par6);
- }
-
- private void dropItems(World world, int x, int y, int z)
- {
- final Random rand = new Random();
-
- final TileEntity tileEntity = world.getTileEntity(x, y, z);
- if(!(tileEntity instanceof IInventory))
- return;
- final IInventory inventory = (IInventory) tileEntity;
-
- for(int i = 0; i < inventory.getSizeInventory(); i++)
- {
- final ItemStack item = inventory.getStackInSlot(i);
-
- if(item != null && item.stackSize > 0)
- {
- final float rx = rand.nextFloat() * 0.8F + 0.1F;
- final float ry = rand.nextFloat() * 0.8F + 0.1F;
- final float rz = rand.nextFloat() * 0.8F + 0.1F;
-
- final EntityItem entityItem = new EntityItem(world, x + rx,
- y + ry, z + rz, new ItemStack(item.getItem(),
- item.stackSize, item.getItemDamage()));
-
- if(item.hasTagCompound())
- {
- entityItem.getEntityItem().setTagCompound((NBTTagCompound) item.getTagCompound().copy());
- }
-
- final float factor = 0.05F;
- entityItem.motionX = rand.nextGaussian() * factor;
- entityItem.motionY = rand.nextGaussian() * factor + 0.2F;
- entityItem.motionZ = rand.nextGaussian() * factor;
- world.spawnEntityInWorld(entityItem);
- item.stackSize = 0;
- }
- }
- }
-
- //You don't want the normal render type, or it wont render properly.
- @Override
- public int getRenderType()
- {
- return -1;
- }
-
- //It's not an opaque cube, so you need this.
- @Override
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- //It's not a normal block, so you need this too.
- @Override
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- //This is the icon to use for showing the block in your hand.
- @SideOnly(Side.CLIENT)
- @Override
- public void registerBlockIcons(IIconRegister icon)
- {
- blockIcon = icon.registerIcon("tinkersdefense:item_armoranvil");
- }
-
- @Override
- public TileEntity createNewTileEntity(World w, int md)
- {
- final TileEntity_FinishingAnvil te = new TileEntity_FinishingAnvil();
- return te;
- }
-
- @Override
- public int onBlockPlaced(World p_149660_1_, int p_149660_2_, int p_149660_3_, int p_149660_4_, int p_149660_5_, float p_149660_6_, float p_149660_7_, float p_149660_8_, int p_149660_9_)
- {
- int j1 = p_149660_9_;
-
- if((p_149660_9_ == 0 || p_149660_5_ == 2) && p_149660_1_.isSideSolid(p_149660_2_, p_149660_3_, p_149660_4_ + 1, NORTH))
- {
- j1 = 1;
- }
-
- if((j1 == 0 || p_149660_5_ == 3) && p_149660_1_.isSideSolid(p_149660_2_, p_149660_3_, p_149660_4_ - 1, SOUTH))
- {
- j1 = 2;
- }
-
- if((j1 == 0 || p_149660_5_ == 4) && p_149660_1_.isSideSolid(p_149660_2_ + 1, p_149660_3_, p_149660_4_, WEST))
- {
- j1 = 3;
- }
-
- if((j1 == 0 || p_149660_5_ == 5) && p_149660_1_.isSideSolid(p_149660_2_ - 1, p_149660_3_, p_149660_4_, EAST))
- {
- j1 = 4;
- }
-
- return j1;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Gui_FinishingAnvil.java b/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Gui_FinishingAnvil.java
deleted file mode 100644
index 3636b09..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Gui_FinishingAnvil.java
+++ /dev/null
@@ -1,609 +0,0 @@
-package lance5057.tDefense.finishingAnvil.blocks.finishingAnvil;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import lance5057.tDefense.TinkersDefense;
-import lance5057.tDefense.armor.ArmorCore;
-import lance5057.tDefense.armor.renderers.ArmorRenderer;
-import lance5057.tDefense.core.network.Message_FinishingAnvil;
-import lance5057.tDefense.finishingAnvil.utilities.Injector;
-import lance5057.tDefense.finishingAnvil.utilities.ToolCoreTip;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.gui.GuiButton;
-import net.minecraft.client.gui.ScaledResolution;
-import net.minecraft.client.gui.inventory.GuiContainer;
-import net.minecraft.client.model.ModelBiped;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.client.renderer.RenderHelper;
-import net.minecraft.client.renderer.entity.RenderItem;
-import net.minecraft.entity.player.InventoryPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.ResourceLocation;
-
-import org.lwjgl.opengl.GL11;
-import org.lwjgl.opengl.GL12;
-import org.lwjgl.util.glu.Project;
-
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.tools.ToolCore;
-import cpw.mods.fml.client.FMLClientHandler;
-import cpw.mods.fml.client.config.GuiButtonExt;
-
-public class Gui_FinishingAnvil extends GuiContainer
-{
- private ItemStack bigCopy;
- NBTTagCompound bigCopyTags;
- private final RenderItem bigRender = new RenderItem_FinishingAnvil(
- this,
- 3.5f,
- 3.5f, 1.0f);
-
- private ItemStack rightCopy1, rightCopy2, rightCopy3;
- NBTTagCompound rightCopyTags1, rightCopyTags2,
- rightCopyTags3;
- private final RenderItem normalRender = new RenderItem_FinishingAnvil(
- this, 1.0f,
- 1.0f, 1.0f);
-
- //private Boolean isNull = true;
- private ItemStack editItem;
-
- public final TileEntity_FinishingAnvil inventory;
- private ResourceLocation forGui;
-
- private int leftButtonPosX = 0;
- private int leftSelect = 0;
-
- private int rightButtonPos = 0;
- private final int rightSelect = 0;
-
- String[] renders;
-
- boolean renderFlat = true;
- boolean renderBiped = true;
- int rotation = 0;
-
- InventoryPlayer player;
-
- private static final ResourceLocation iconLocation = new ResourceLocation(
- "tinkersdefense",
- "textures/gui/finishinganvil.png");
-
- public Gui_FinishingAnvil(InventoryPlayer invPlayer, TileEntity_FinishingAnvil te)
- {
- super(new Container_FinishingAnvil(invPlayer, te));
- inventory = te;
-
- renders = new String[4];
- renders[0] = "Head";
- renders[1] = "Accessory";
- renders[2] = "Handle";
- renders[3] = "Extra";
-
- player = invPlayer;
- }
-
- @Override
- public void initGui()
- {
- super.initGui();
- buttonList.add(new GuiButtonExt(1, guiLeft + 25, guiTop + 11, 10, 10,
- ""));
- buttonList.add(new GuiButtonExt(2, guiLeft + 25, guiTop + 61, 10, 10,
- ""));
- buttonList.add(new GuiButtonExt(3, guiLeft + 38, guiTop + 53, 18, 18,
- ""));
-
- buttonList.add(new GuiButtonExt(4, guiLeft + 5, guiTop + 11, 20, 20, ""));
- buttonList.add(new GuiButtonExt(5, guiLeft + 5, guiTop + 31, 20, 20, ""));
- buttonList.add(new GuiButtonExt(6, guiLeft + 5, guiTop + 51, 20, 20, ""));
-
- buttonList.add(new GuiButtonExt(7, guiLeft + 141, guiTop + 11, 10, 10,
- ""));
- buttonList.add(new GuiButtonExt(8, guiLeft + 141, guiTop + 61, 10, 10,
- ""));
-
- buttonList.add(new GuiButtonExt(9, guiLeft + 151, guiTop + 11, 20, 20,
- ""));
- buttonList.add(new GuiButtonExt(10, guiLeft + 151, guiTop + 31, 20, 20,
- ""));
- buttonList.add(new GuiButtonExt(11, guiLeft + 151, guiTop + 51, 20, 20,
- ""));
-
- buttonList.add(new GuiButtonExt(12, guiLeft + 38, guiTop + 11, 18, 18,
- ""));
- buttonList.add(new GuiButtonExt(13, guiLeft + 120, guiTop + 11, 18, 18,
- "3D"));
- buttonList.add(new GuiButtonExt(14, guiLeft + 120, guiTop + 53, 18, 18,
- ""));
-
- buttonList.add(new GuiButtonExt(15, guiLeft + 59, guiTop + 60, 10, 10,
- "<"));
- buttonList.add(new GuiButtonExt(16, guiLeft + 107, guiTop + 60, 10, 10,
- ">"));
- }
-
- @Override
- protected void actionPerformed(GuiButton button)
- {
- if(bigCopy != null && bigCopyTags != null)
- {
- switch(button.id)
- {
- case 1:
- if(leftButtonPosX > 0)
- {
- leftButtonPosX--;
- }
- break;
- case 2:
- if(leftButtonPosX + 3 < ((ToolCore) bigCopy.getItem()).getPartAmount())
- {
- leftButtonPosX++;
- }
- break;
-
- case 3:
- TinkersDefense.INSTANCE.sendToServer(new Message_FinishingAnvil(
- inventory.xCoord, inventory.yCoord,
- inventory.zCoord, bigCopy));
- break;
-
- case 4:
- leftSelect = 0 + leftButtonPosX;
- rightButtonPos = 0;
- setRenders();
- break;
- case 5:
- leftSelect = 1 + leftButtonPosX;
- rightButtonPos = 0;
- setRenders();
- break;
- case 6:
- leftSelect = 2 + leftButtonPosX;
- rightButtonPos = 0;
- setRenders();
- break;
-
- case 7:
- if(rightButtonPos > 0)
- {
- rightButtonPos--;
- }
- setRenders();
- break;
-
- case 13:
- renderFlat = !renderFlat;
- break;
-
- case 14:
- renderBiped = !renderBiped;
- break;
-
- case 15:
- if(rotation <= 0)
- {
- rotation += 360;
- }
- rotation -= 8;
- break;
-
- case 16:
- if(rotation >= 360)
- {
- rotation -= 360;
- }
- rotation += 8;
- break;
-
- default:
- if(bigCopy.getItem() instanceof ArmorCore)
- {
- doArmorEdit(button.id);
- }
- else
- {
- doToolEdit(button.id);
- }
- }
- }
- }
-
- public void doToolEdit(int id)
- {
- switch(id)
- {
- case 9:
- if(bigCopyTags.hasKey("Render" + renders[leftSelect]))
- {
- bigCopyTags.setInteger("Render" + renders[leftSelect], bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[leftSelect]) + (rightButtonPos * TinkersDefense.config.MaterialIndex));
- if(rightButtonPos > 0)
- {
- bigCopyTags.setInteger(renders[leftSelect] + "Color", TConstructRegistry.getMaterial(bigCopyTags.getInteger(renders[leftSelect])).primaryColor());
- }
- else
- {
- bigCopyTags.removeTag(renders[leftSelect] + "Color");
- }
- }
- break;
-
- case 10:
- if(bigCopyTags.hasKey("Render" + renders[leftSelect]))
- {
- bigCopyTags.setInteger("Render" + renders[leftSelect], bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[leftSelect]) + ((rightButtonPos + 1) * TinkersDefense.config.MaterialIndex));
- bigCopyTags.setInteger(renders[leftSelect] + "Color", TConstructRegistry.getMaterial(bigCopyTags.getInteger(renders[leftSelect])).primaryColor());
- }
- break;
-
- case 11:
- if(bigCopyTags.hasKey("Render" + renders[leftSelect]))
- {
- bigCopyTags.setInteger("Render" + renders[leftSelect], bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[leftSelect]) + ((rightButtonPos + 2) * TinkersDefense.config.MaterialIndex));
- bigCopyTags.setInteger(renders[leftSelect] + "Color", TConstructRegistry.getMaterial(bigCopyTags.getInteger(renders[leftSelect])).primaryColor());
- }
- break;
-
- case 12:
- bigCopyTags.setInteger("RenderHead", bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[0]));
- bigCopyTags.setInteger("RenderAccessory", bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[1]));
- bigCopyTags.setInteger("RenderHandle", bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[2]));
- bigCopyTags.setInteger("RenderExtra", bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[3]));
-
- bigCopyTags.removeTag(renders[0] + "Color");
- bigCopyTags.removeTag(renders[1] + "Color");
- bigCopyTags.removeTag(renders[2] + "Color");
- bigCopyTags.removeTag(renders[3] + "Color");
-
- setRenders();
- break;
-
- case 8:
- rightButtonPos++;
- setRenders();
- break;
-
- }
- }
-
- public void doArmorEdit(int id)
- {
- NBTTagCompound aTags = bigCopy.getTagCompound().getCompoundTag("ArmorRenderer");
- final ArmorCore armor = (ArmorCore) bigCopy.getItem();
- final List<ModelRenderer> boxes = armor.getRenderer().boxList;
-
- switch(id)
- {
- case 9:
- aTags.setBoolean(boxes.get(rightButtonPos + 9).boxName, !aTags.getBoolean(boxes.get(rightButtonPos + 9).boxName));
- break;
-
- case 10:
- aTags.setBoolean(boxes.get(rightButtonPos + 1 + 9).boxName, !aTags.getBoolean(boxes.get(rightButtonPos + 1 + 9).boxName));
- break;
-
- case 11:
- aTags.setBoolean(boxes.get(rightButtonPos + 2 + 9).boxName, !aTags.getBoolean(boxes.get(rightButtonPos + 2 + 9).boxName));
- break;
-
- case 12:
- aTags = armor.getRenderer().defaultTags;
- break;
-
- case 8:
- if(rightButtonPos < boxes.size() - 12)
- {
- rightButtonPos++;
- }
- break;
-
- }
- }
-
- @Override
- public void drawScreen(int x, int y, float par3)
- {
-
- if(inventory.getStackInSlot(0) != null && inventory.getStackInSlot(0).getItem() instanceof ToolCore)
- {
- if(bigCopy == null)
- {
- rightButtonPos = 0;
- leftButtonPosX = 0;
- bigCopy = inventory.getStackInSlot(0).copy();
- if(bigCopy.hasTagCompound() && bigCopy.getTagCompound().hasKey("InfiTool"))
- {
- bigCopyTags = bigCopy.getTagCompound().getCompoundTag("InfiTool");
- }
- setRenders();
- }
- else if(bigCopy != null && inventory.getStackInSlot(0).getItem() != bigCopy.getItem() || inventory.getStackInSlot(0).getItemDamage() != bigCopy.getItemDamage())
- {
- bigCopy = null;
- }
- }
- else if(inventory.getStackInSlot(0) == null)
- {
- bigCopy = null;
- }
-
- super.drawScreen(x, y, par3);
- drawTooltip(x, y);
- }
-
- @Override
- protected void drawGuiContainerForegroundLayer(int par1, int par2)
- {
-
- mc.getTextureManager().bindTexture(iconLocation);
-
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
-
- drawTexturedModalRect(144, 14, 5, 167, 5, 3);
- drawTexturedModalRect(144, 64, 0, 167, 5, 3);
- drawTexturedModalRect(39, 54, 32, 176, 16, 16);
- drawTexturedModalRect(39, 12, 48, 176, 16, 16);
- drawTexturedModalRect(28, 14, 5, 167, 5, 3);
- drawTexturedModalRect(28, 64, 0, 167, 5, 3);
- drawTexturedModalRect(121, 54, 16, 176, 16, 16);
-
- if(bigCopy != null)
- {
-
- if(!(bigCopy.getItem() instanceof ArmorCore))
- {
- if(renderFlat)
- {
- if(leftSelect > 2)
- {
- drawTexturedModalRect(7, 13, 16, 192, 16, 16);
- drawTexturedModalRect(7, 33, 32, 192, 16, 16);
- drawTexturedModalRect(7, 53, 48, 192, 16, 16);
- }
- else
- {
- drawTexturedModalRect(7, 13, 0, 192, 16, 16);
- drawTexturedModalRect(7, 33, 16, 192, 16, 16);
- drawTexturedModalRect(7, 53, 32, 192, 16, 16);
- }
-
- ((GuiButtonExt) buttonList.get(14)).enabled = false;
- ((GuiButtonExt) buttonList.get(15)).enabled = false;
- ((GuiButtonExt) buttonList.get(12)).displayString = "3D";
-
- normalRender.renderItemAndEffectIntoGUI(fontRendererObj, mc.getTextureManager(), rightCopy1, 153, 13);
- normalRender.renderItemAndEffectIntoGUI(fontRendererObj, mc.getTextureManager(), rightCopy2, 153, 33);
- normalRender.renderItemAndEffectIntoGUI(fontRendererObj, mc.getTextureManager(), rightCopy3, 153, 53);
-
- }
- }
- else
- {
- final NBTTagCompound aTags = bigCopy.getTagCompound().getCompoundTag("ArmorRenderer");
- final ArmorCore armor = (ArmorCore) bigCopy.getItem();
- final List<ModelRenderer> boxes = armor.getRenderer().boxList;
-
- drawTexturedModalRect(7, 13, 0, 176, 16, 16);
- drawTexturedModalRect(7, 33, 0, 176, 16, 16);
- drawTexturedModalRect(7, 53, 0, 176, 16, 16);
-
- //drawTexturedModalRect(153, 13, xRIcon_one + (rightButtonPos * 16), yRIcon_one + (rightButtonPosY * 16), 16, 16);
-
- drawTexturedModalRect(153, 13, 64 + ((aTags.getBoolean(boxes.get(rightButtonPos + 9).boxName) ? 0 : 1) * 16), 176, 16, 16);
- drawTexturedModalRect(153, 33, 64 + ((aTags.getBoolean(boxes.get(rightButtonPos + 1 + 9).boxName) ? 0 : 1) * 16), 176, 16, 16);
- drawTexturedModalRect(153, 53, 64 + ((aTags.getBoolean(boxes.get(rightButtonPos + 2 + 9).boxName) ? 0 : 1) * 16), 176, 16, 16);
-
- }
-
- if(renderFlat)
- {
- bigRender.renderItemAndEffectIntoGUI(fontRendererObj, mc.getTextureManager(), bigCopy, 17, 4);
- }
-
- }
-
- }
-
- @Override
- protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3)
- {
- mc.getTextureManager().bindTexture(iconLocation);
- final int k = ((width - xSize) / 2);
- final int l = (height - ySize) / 2;
- drawTexturedModalRect(k, l, 0, 0, xSize + 80, ySize);
-
- if(!renderFlat)
- {
- if(bigCopy != null && bigCopy.getItem() instanceof ArmorCore)
- {
- ((GuiButtonExt) buttonList.get(14)).enabled = true;
- ((GuiButtonExt) buttonList.get(15)).enabled = true;
-
- ((GuiButtonExt) buttonList.get(12)).displayString = "2D";
-
- final ArmorCore armor = (ArmorCore) bigCopy.getItem();
-
- final ArmorRenderer renderer = (ArmorRenderer) armor.getArmorModel(null, bigCopy, 0);
- renderer.isChild = false;
-
- final float limbs = player.player.prevLimbSwingAmount + (player.player.limbSwingAmount - player.player.prevLimbSwingAmount);
- final float limbSwing = player.player.limbSwing - player.player.limbSwingAmount * (1.0F);
-
- GL11.glPushMatrix();
- GL11.glMatrixMode(GL11.GL_PROJECTION);
- GL11.glPushMatrix();
- GL11.glLoadIdentity();
-
- final ScaledResolution scaledresolution = new ScaledResolution(
- mc, mc.displayWidth, mc.displayHeight);
- //GL11.glViewport(this.guiLeft, this.guiTop, this.width, this.height);
- GL11.glViewport((scaledresolution.getScaledWidth() - 213) / 2 * scaledresolution.getScaleFactor(), (scaledresolution.getScaledHeight() - 240) / 2 * scaledresolution.getScaleFactor(), 320 * scaledresolution.getScaleFactor(), 240 * scaledresolution.getScaleFactor());
- GL11.glTranslatef(-0.34F, 0.23F, -0.1F);
- Project.gluPerspective(90.0F, 1.3333334F, 9.0F, 80.0F);
- final float f1 = 1.0F;
- GL11.glMatrixMode(GL11.GL_MODELVIEW);
- GL11.glLoadIdentity();
- GL11.glColor3d(1f, 1f, 1f);
- RenderHelper.enableStandardItemLighting();
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
- GL11.glTranslatef(0.0F, 3.3F, -16.0F);
- GL11.glScalef(f1, f1, f1);
- final float f2 = 3.0F;
- GL11.glScalef(f2, f2, f2);
- GL11.glRotatef(rotation, 0.0F, 1.0F, 0.0F);
- GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F);
-
- GL11.glEnable(GL12.GL_RESCALE_NORMAL);
- //renderer.setRotationAngles(limbSwing, limbs, player.player.ticksExisted, 0, player.player.rotationPitch, 0.0625f, player.player);
- renderer.render(player.player, limbSwing, limbs, player.player.ticksExisted, 0, 0, 0.1f);
-
- if(renderBiped)
- {
- final ModelBiped biped = new ModelBiped(0f);
- //biped.bipedHeadwear.isHidden = true;
- //biped.bipedHead.isHidden = true;
- final ResourceLocation rc = new ResourceLocation(
- Minecraft.getMinecraft().thePlayer.getLocationSkin().toString());
-
- FMLClientHandler.instance().getClient().renderEngine.bindTexture(rc);
- // final ITextureObject tex = FMLClientHandler.instance().getClient().getTextureManager().getTexture(rc);
- // if(tex.getGlTextureId() == 1)
- // {
- // rc = new ResourceLocation(
- // "minecraft:textures/entity/steve.png");
- // FMLClientHandler.instance().getClient().renderEngine.bindTexture(rc);
- // }
-
- biped.isChild = false;
- biped.render(player.player, limbSwing, limbs, player.player.ticksExisted, 0, 0, 0.0625f);
- }
-
- GL11.glDisable(GL12.GL_RESCALE_NORMAL);
- RenderHelper.disableStandardItemLighting();
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
- GL11.glMatrixMode(GL11.GL_PROJECTION);
- GL11.glViewport(0, 0, mc.displayWidth, mc.displayHeight);
- GL11.glPopMatrix();
- GL11.glMatrixMode(GL11.GL_MODELVIEW);
- GL11.glPopMatrix();
- //RenderHelper.disableStandardItemLighting();
- GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
- }
- else
- {
- renderFlat = true;
- }
- }
-
- }
-
- protected void drawTooltip(int x, int y)
- {
- final int buttons[] = {4, 5, 6, 9, 10, 11};
-
- for(int i = 0; i < buttons.length; i++)
- {
- final GuiButtonExt button = ((GuiButtonExt) buttonList.get(buttons[i] - 1));
- final boolean mousehover = x >= button.xPosition && y >= button.yPosition && x < button.xPosition + button.width && y < button.yPosition + button.height;
- final int test = button.getHoverState(mousehover);
- if(test == 2)
- {
- final List<String> list = new ArrayList();
-
- if(bigCopy.getItem() instanceof ArmorCore)
- {
- bigCopy.getTagCompound().getCompoundTag("ArmorRenderer");
- final ArmorCore armor = (ArmorCore) bigCopy.getItem();
- final List<ModelRenderer> boxes = armor.getRenderer().boxList;
-
- switch(i)
- {
- case 0:
- case 1:
- case 2:
- break;
-
- case 3:
- list.add(boxes.get(rightButtonPos + 9).boxName);
- break;
- case 4:
- list.add(boxes.get(rightButtonPos + 1 + 9).boxName);
- break;
- case 5:
- list.add(boxes.get(rightButtonPos + 2 + 9).boxName);
- break;
- }
- func_146283_a(list, x, y);
- }
- else if(bigCopy != null && bigCopy.getItem() instanceof ToolCore)
- {
- final ToolCore tool = (ToolCore) bigCopy.getItem();
- final String toolName = tool.getUnlocalizedName().toLowerCase().substring(tool.getUnlocalizedName().lastIndexOf('.') + 1, tool.getUnlocalizedName().length());
- final ToolCoreTip tt = ((Injector) TinkersDefense.tcInject).tools.get(toolName);
-
- if(tt != null)
- {
- switch(i)
- {
- case 0:
- list.add(tt.getPart(1 + leftButtonPosX));
- break;
- case 2:
- list.add(tt.getPart(3 + leftButtonPosX));
- break;
- case 1:
- list.add(tt.getPart(2 + leftButtonPosX));
- break;
-
- case 3:
- list.add(tt.getPartName(leftSelect + 1, (rightButtonPos)));
- break;
- case 4:
- list.add(tt.getPartName(leftSelect + 1, (rightButtonPos + 1)));
- break;
- case 5:
- list.add(tt.getPartName(leftSelect + 1, (rightButtonPos + 2)));
- break;
- }
-
- if(list.get(0).contains("m5"))
- {
- list.add(" -by Shadowclaimer");
- }
- func_146283_a(list, x, y);
- }
-
- else
- {
- list.add("Error - No name/desc!");
- func_146283_a(list, x, y);
- }
- }
- }
- }
- }
-
- void setRenders()
- {
- rightCopy1 = bigCopy.copy();
- rightCopyTags1 = (NBTTagCompound) bigCopyTags.copy();
- rightCopyTags1.setInteger("Render" + renders[leftSelect], bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[leftSelect]) + ((rightButtonPos) * TinkersDefense.config.MaterialIndex));
- rightCopyTags1.setInteger(renders[leftSelect] + "Color", TConstructRegistry.getMaterial(bigCopyTags.getInteger(renders[leftSelect])).primaryColor());
- rightCopy1.getTagCompound().setTag("InfiTool", rightCopyTags1);
-
- rightCopy2 = bigCopy.copy();
- rightCopyTags2 = (NBTTagCompound) bigCopyTags.copy();
- rightCopyTags2.setInteger("Render" + renders[leftSelect], bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[leftSelect]) + ((rightButtonPos + 1) * TinkersDefense.config.MaterialIndex));
- rightCopyTags2.setInteger(renders[leftSelect] + "Color", TConstructRegistry.getMaterial(bigCopyTags.getInteger(renders[leftSelect])).primaryColor());
- rightCopy2.getTagCompound().setTag("InfiTool", rightCopyTags2);
-
- rightCopy3 = bigCopy.copy();
- rightCopyTags3 = (NBTTagCompound) bigCopyTags.copy();
- rightCopyTags3.setInteger("Render" + renders[leftSelect], bigCopy.getTagCompound().getCompoundTag("InfiTool").getInteger(renders[leftSelect]) + ((rightButtonPos + 2) * TinkersDefense.config.MaterialIndex));
- rightCopyTags3.setInteger(renders[leftSelect] + "Color", TConstructRegistry.getMaterial(bigCopyTags.getInteger(renders[leftSelect])).primaryColor());
- rightCopy3.getTagCompound().setTag("InfiTool", rightCopyTags3);
- }
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/ModelFinishingAnvil.java b/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/ModelFinishingAnvil.java
deleted file mode 100644
index 843b6c9..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/ModelFinishingAnvil.java
+++ /dev/null
@@ -1,65 +0,0 @@
-package lance5057.tDefense.finishingAnvil.blocks.finishingAnvil;
-
-import net.minecraft.client.model.ModelBase;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-/**
- * Armor Anvil - lance5057
- * Created using Tabula 4.1.1
- */
-public class ModelFinishingAnvil extends ModelBase
-{
- public ModelRenderer Log;
- public ModelRenderer HammerHead;
- public ModelRenderer HammerHandle;
- public ModelRenderer AnvilBase;
- public ModelRenderer AnvilStem;
- public ModelRenderer AnvilTop;
-
- public ModelFinishingAnvil()
- {
- textureWidth = 64;
- textureHeight = 64;
- AnvilTop = new ModelRenderer(this, 0, 22);
- AnvilTop.setRotationPoint(-4.0F, 6.0F, -6.0F);
- AnvilTop.addBox(0.0F, 0.0F, 0.0F, 8, 6, 12, 0.0F);
- HammerHead = new ModelRenderer(this, 15, 21);
- HammerHead.setRotationPoint(-1.3F, 4.0F, 0.0F);
- HammerHead.addBox(0.0F, 0.0F, 0.0F, 3, 2, 2, 0.0F);
- setRotateAngle(HammerHead, 0.091106186954104F, -0.5462880558742251F, 0.0F);
- AnvilStem = new ModelRenderer(this, 10, 32);
- AnvilStem.setRotationPoint(-2.0F, 12.0F, -3.0F);
- AnvilStem.addBox(0.0F, 0.0F, 0.0F, 4, 2, 6, 0.0F);
- HammerHandle = new ModelRenderer(this, 17, 47);
- HammerHandle.setRotationPoint(1.0F, 0.5F, -6.0F);
- HammerHandle.addBox(0.0F, 0.0F, 0.0F, 1, 1, 6, 0.0F);
- AnvilBase = new ModelRenderer(this, 2, 28);
- AnvilBase.setRotationPoint(-4.0F, 14.0F, -5.0F);
- AnvilBase.addBox(0.0F, 0.0F, 0.0F, 8, 2, 10, 0.0F);
- Log = new ModelRenderer(this, 0, 40);
- Log.setRotationPoint(-8.0F, 16.0F, -8.0F);
- Log.addBox(0.0F, 0.0F, 0.0F, 16, 8, 16, 0.0F);
- HammerHead.addChild(HammerHandle);
- }
-
- @Override
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
- {
- AnvilTop.render(f5);
- HammerHead.render(f5);
- AnvilStem.render(f5);
- AnvilBase.render(f5);
- Log.render(f5);
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z)
- {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/RenderItem_FinishingAnvil.java b/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/RenderItem_FinishingAnvil.java
deleted file mode 100644
index 834b583..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/RenderItem_FinishingAnvil.java
+++ /dev/null
@@ -1,48 +0,0 @@
-package lance5057.tDefense.finishingAnvil.blocks.finishingAnvil;
-
-import net.minecraft.client.gui.FontRenderer;
-import net.minecraft.client.renderer.RenderHelper;
-import net.minecraft.client.renderer.entity.RenderItem;
-import net.minecraft.client.renderer.texture.TextureManager;
-import net.minecraft.inventory.Slot;
-import net.minecraft.item.ItemStack;
-
-import org.lwjgl.opengl.GL11;
-
-public class RenderItem_FinishingAnvil extends RenderItem
-{
- private final Gui_FinishingAnvil anvilGui;
- float sx;
- float sy;
- float sz;
-
- RenderItem_FinishingAnvil(Gui_FinishingAnvil gui, float sx, float sy, float sz)
- {
- super();
- anvilGui = gui;
- this.sx = sx;
- this.sy = sy;
- this.sz = sz;
- }
-
- @Override
- public void renderItemAndEffectIntoGUI(FontRenderer fontRenderer, TextureManager textureManager, ItemStack itemStack, int x, int y)
- {
- if(itemStack == null)
- return;
-
- RenderHelper.enableGUIStandardItemLighting();
-
- final Slot slot = anvilGui.inventorySlots.getSlotFromInventory(anvilGui.inventory, 0);
-
- if(slot.getStack() != null)
- {
- GL11.glPushMatrix();
-
- GL11.glScalef(sx, sy, sz);
- super.renderItemAndEffectIntoGUI(fontRenderer, textureManager, itemStack, x, y);
-
- GL11.glPopMatrix();
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Renderer_FinishingAnvil.java b/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Renderer_FinishingAnvil.java
deleted file mode 100644
index c3013e4..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/Renderer_FinishingAnvil.java
+++ /dev/null
@@ -1,45 +0,0 @@
-package lance5057.tDefense.finishingAnvil.blocks.finishingAnvil;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
-import net.minecraft.entity.Entity;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ResourceLocation;
-
-import org.lwjgl.opengl.GL11;
-
-public class Renderer_FinishingAnvil extends TileEntitySpecialRenderer
-{
- private final ModelFinishingAnvil model;
-
- public Renderer_FinishingAnvil()
- {
- model = new ModelFinishingAnvil();
- }
-
- @Override
- public void renderTileEntityAt(TileEntity te, double x, double y, double z, float scale)
- {
-
- GL11.glPushMatrix();
-
- GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
-
- final ResourceLocation textures = (new ResourceLocation(
- "tinkersdefense:textures/blocks/armoranvil.png"));
-
- Minecraft.getMinecraft().renderEngine.bindTexture(textures);
-
- GL11.glPushMatrix();
-
- te.getBlockMetadata();
-
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
-
- model.render((Entity) null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
- GL11.glPopMatrix();
- GL11.glPopMatrix();
-
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/TileEntity_FinishingAnvil.java b/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/TileEntity_FinishingAnvil.java
deleted file mode 100644
index e0567bb..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/blocks/finishingAnvil/TileEntity_FinishingAnvil.java
+++ /dev/null
@@ -1,195 +0,0 @@
-package lance5057.tDefense.finishingAnvil.blocks.finishingAnvil;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.nbt.NBTTagList;
-import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.util.Constants;
-
-public class TileEntity_FinishingAnvil extends TileEntity implements IInventory
-{
- public static int invSize = 1;
- public ItemStack[] inventory;
-
- private final String name = "Anvil Inventory";
-
- public TileEntity_FinishingAnvil()
- {
- super();
- inventory = new ItemStack[invSize];
- }
-
- @Override
- public void updateEntity()
- {
- super.updateEntity();
- }
-
- @Override
- public Packet getDescriptionPacket()
- {
- final NBTTagCompound tag = new NBTTagCompound();
- writeToNBT(tag);
- return new S35PacketUpdateTileEntity(xCoord, yCoord, zCoord, 0, tag);
- }
-
- @Override
- public void onDataPacket(NetworkManager net, S35PacketUpdateTileEntity pkt)
- {
- readFromNBT(pkt.func_148857_g());
- }
-
- @Override
- public int getSizeInventory()
- {
- return invSize;
- }
-
- @Override
- public ItemStack getStackInSlot(int slot)
- {
- return inventory[slot];
- }
-
- @Override
- public ItemStack decrStackSize(int slot, int amount)
- {
- ItemStack stack = getStackInSlot(slot);
- if(stack != null)
- {
- if(stack.stackSize > amount)
- {
- stack = stack.splitStack(amount);
-
- if(stack.stackSize == 0)
- {
- setInventorySlotContents(slot, null);
- }
- }
- else
- {
- setInventorySlotContents(slot, null);
- }
-
- markDirty();
- }
- return stack;
- }
-
- @Override
- public ItemStack getStackInSlotOnClosing(int slot)
- {
- final ItemStack stack = getStackInSlot(slot);
-
- if(stack != null)
- {
- setInventorySlotContents(slot, stack);
- }
- return stack;
- }
-
- @Override
- public void setInventorySlotContents(int slot, ItemStack itemstack)
- {
- inventory[slot] = itemstack;
-
- if(itemstack != null && itemstack.stackSize > getInventoryStackLimit())
- {
- itemstack.stackSize = getInventoryStackLimit();
- }
-
- markDirty();
- }
-
- @Override
- public String getInventoryName()
- {
- return name;
- }
-
- @Override
- public boolean hasCustomInventoryName()
- {
- return name.length() > 0;
- }
-
- @Override
- public int getInventoryStackLimit()
- {
- return 1;
- }
-
- @Override
- public boolean isUseableByPlayer(EntityPlayer p_70300_1_)
- {
- return true;
- }
-
- @Override
- public void openInventory()
- {
-
- }
-
- @Override
- public void closeInventory()
- {
-
- }
-
- @Override
- public boolean isItemValidForSlot(int p_94041_1_, ItemStack p_94041_2_)
- {
- return true;
- }
-
- @Override
- public void writeToNBT(NBTTagCompound compound)
- {
- super.writeToNBT(compound);
- writeInventoryToNBT(compound);
- }
-
- @Override
- public void readFromNBT(NBTTagCompound compound)
- {
- super.readFromNBT(compound);
- readInventoryFromNBT(compound);
- }
-
- public void readInventoryFromNBT(NBTTagCompound tags)
- {
- final NBTTagList nbttaglist = tags.getTagList("Items", Constants.NBT.TAG_COMPOUND);
- for(int iter = 0; iter < nbttaglist.tagCount(); iter++)
- {
- final NBTTagCompound tagList = nbttaglist.getCompoundTagAt(iter);
- final byte slotID = tagList.getByte("Slot");
- if(slotID >= 0 && slotID < inventory.length)
- {
- inventory[slotID] = ItemStack.loadItemStackFromNBT(tagList);
- }
- }
- }
-
- public void writeInventoryToNBT(NBTTagCompound tags)
- {
- final NBTTagList nbttaglist = new NBTTagList();
- for(int iter = 0; iter < inventory.length; iter++)
- {
- if(inventory[iter] != null)
- {
- final NBTTagCompound tagList = new NBTTagCompound();
- tagList.setByte("Slot", (byte) iter);
- inventory[iter].writeToNBT(tagList);
- nbttaglist.appendTag(tagList);
- }
- }
-
- tags.setTag("Items", nbttaglist);
- }
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/utilities/FileGetter.java b/src/main/java/lance5057/tDefense/finishingAnvil/utilities/FileGetter.java
deleted file mode 100644
index 9221376..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/utilities/FileGetter.java
+++ /dev/null
@@ -1,21 +0,0 @@
-package lance5057.tDefense.finishingAnvil.utilities;
-
-import java.nio.file.FileVisitResult;
-import java.nio.file.Path;
-import java.nio.file.SimpleFileVisitor;
-import java.nio.file.attribute.BasicFileAttributes;
-import java.util.ArrayList;
-import java.util.List;
-
-public class FileGetter extends SimpleFileVisitor<Path>
-{
- final public List<String> filenames = new ArrayList<String>();
-
- @Override
- public FileVisitResult visitFile(Path file,
- BasicFileAttributes attr)
- {
- filenames.add(file.getFileName().toString());
- return FileVisitResult.CONTINUE;
- }
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/utilities/Injector.java b/src/main/java/lance5057/tDefense/finishingAnvil/utilities/Injector.java
deleted file mode 100644
index 9b2138f..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/utilities/Injector.java
+++ /dev/null
@@ -1,722 +0,0 @@
-package lance5057.tDefense.finishingAnvil.utilities;
-
-import java.io.IOException;
-import java.nio.file.FileSystem;
-import java.nio.file.FileSystems;
-import java.nio.file.Files;
-import java.nio.file.Path;
-import java.nio.file.Paths;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import lance5057.tDefense.Reference;
-import lance5057.tDefense.TinkersDefense;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.item.Item;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.ResourceLocation;
-import tconstruct.library.TConstructRegistry;
-import tconstruct.library.crafting.PatternBuilder;
-import tconstruct.library.crafting.PatternBuilder.MaterialSet;
-import tconstruct.library.tools.ToolCore;
-
-public class Injector extends ToolCore
-{
- List<String> heads = new ArrayList<String>();
- List<String> accessories = new ArrayList<String>();
- List<String> handles = new ArrayList<String>();
- List<String> extras = new ArrayList<String>();
-
- public HashMap<String, ToolCoreTip> tools = new HashMap<String, ToolCoreTip>();
-
- public Injector(int baseDamage)
- {
- super(0);
- }
-
- protected void loadHeads(IIconRegister iconRegister)
- {
-
- // final URL jarFile =
- // TinkersDefense.class.getResource("assets/tinkersdefense/textures/items/");
-
- final int toolLength = TConstructRegistry.tools.size();
- for(int i = 0; i < toolLength; i++)
- {
- final String toolName = TConstructRegistry.tools.get(i).getUnlocalizedName().toLowerCase().substring(TConstructRegistry.tools.get(i).getUnlocalizedName().lastIndexOf('.') + 1, TConstructRegistry.tools.get(i).getUnlocalizedName().length());
- final String path = "/assets/tinkersdefense/textures/items/" + toolName + "/";
-
- final ResourceLocation loc = new ResourceLocation(
- "tinkersdefense:textures/items/");
- //final InputStream in = Minecraft.getMinecraft().getResourceManager().getResource(loc).getInputStream();
- //final List<String> filenames = new ArrayList<String>();
- //final File files = new File(Minecraft.getMinecraft().mcDataDir.getPath() + "/mods/tinkersdefense-1.3.6.jar");
-
- final Path zipfile = Paths.get(Minecraft.getMinecraft().mcDataDir.getPath() + "/mods/" + Reference.MOD_ID + "-" + Reference.VERSION + ".jar");
- // if(Files.exists(zipfile))
- // {
- Path root = null;
- FileSystem fs;
- try
- {
- fs = FileSystems.newFileSystem(zipfile, Minecraft.class.getClassLoader());
- root = fs.getPath(path);
- }
- catch(final IOException e)
- {
- // TODO Auto-generated catch block
- //e.printStackTrace();
- continue;
- }
-
- //final Iterable<FileStore> files = fs.getFileStores();
- final FileGetter fileget = new FileGetter();
-
- if(root != null)
- {
- try
- {
- Files.walkFileTree(root, fileget);
- }
- catch(final IOException e)
- {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
-
- //IDE
- //final File files = new File(url.toURI());
-
- if(TinkersDefense.config.debug)
- {
- for(final String file : fileget.filenames)
- {
- System.out.println(file);
- }
- }
- setup(TConstructRegistry.tools.get(i), toolName, fileget.filenames, iconRegister);
- }
- }
-
- // }
-
- //}
- //}
-
- private void setup(ToolCore tool, String name, List<String> filenames, IIconRegister iconRegister)
- {
- {
- heads.clear();
- accessories.clear();
- handles.clear();
- extras.clear();
-
- headStrings.clear();
- headIcons.clear();
- accessoryStrings.clear();
- accessoryIcons.clear();
- handleStrings.clear();
- handleIcons.clear();
- extraStrings.clear();
- extraIcons.clear();
-
- final IIcon origHead = tool.headIcons.get(-1);
- final IIcon origAccessory = tool.accessoryIcons.get(-1);
- final IIcon origHandle = tool.handleIcons.get(-1);
- final IIcon origExtra = tool.extraIcons.get(-1);
-
- final ToolCoreTip tt = new ToolCoreTip();
-
- tt.accessory = "Accessory";
- tt.head = "Head";
- tt.handle = "Handle";
- tt.extra = "Extra";
-
- tt.headTT.add("Standard");
- tt.accessoryTT.add("Standard");
- tt.handleTT.add("Standard");
- tt.extraTT.add("Standard");
-
- for(int i = 0; i < filenames.size(); i++)
- {
- final String filename = filenames.get(i);
-
- if(filename.contains("head"))
- {
- String formatted = filename.substring(0, filename.indexOf(".png"));
- heads.add(formatted);
- formatted = formatted.substring(1, formatted.length());
- formatted = formatted.replace('_', ' ');
- tt.headTT.add(formatted);
- }
-
- if(filename.contains("accessory"))
- {
- String formatted = filename.substring(0, filename.indexOf(".png"));
- accessories.add(formatted);
- formatted = formatted.substring(1, formatted.length());
- formatted.replace("_", " ");
- tt.accessoryTT.add(formatted);
- }
-
- if(filename.contains("handle"))
- {
- String formatted = filename.substring(0, filename.indexOf(".png"));
- handles.add(formatted);
- formatted = formatted.substring(1, formatted.length());
- formatted.replace("_", " ");
- tt.handleTT.add(formatted);
- }
-
- if(filename.contains("extra"))
- {
- String formatted = filename.substring(0, filename.indexOf(".png"));
- extras.add(formatted);
- formatted = formatted.substring(1, formatted.length());
- formatted.replace("_", " ");
- tt.extraTT.add(formatted);
- }
- }
- // tt.headTT.add("Magic Backhead");
- // tt.headTT.add("Scythe Backhead");
- //
- // extras.add("_magic_extra");
- // extras.add("_scythe_extra");
- // extras.add("_halbard_extra");
- // extras.add("_ornate_extra");
- //
- // tt.extraTT.add("Halbard Head");
- // tt.extraTT.add("Magic Head");
- // tt.extraTT.add("Scythe Head");
- // tt.extraTT.add("Ornate Head");
- //
- // accessories.add("_magic_accessory");
- // accessories.add("_halbard_accessory");
- // accessories.add("_knob_accessory");
-
- //Metallurgy 5
-
- tools.put(name, tt);
-
- // if(tool.getToolName().equals("Battleaxe"))
- // {
- // BattleAxe();
- // }
- // if(tool.getToolName().equals("Arrow"))
- // {
- // Arrow();
- // }
- // if(tool.getToolName().equals("Broadsword"))
- // {
- // Broadsword();
- // }
- // if(tool.getToolName().equals("Battlesign"))
- // {
- // Battlesign();
- // }
- // if(tool.getToolName().equals("Hatchet"))
- // {
- // Axe();
- // }
- // if(tool.getToolName().equals("Mattock"))
- // {
- // Mattock();
- // }
- // if(tool.getToolName().equals("Longbow"))
- // {
- // Longbow();
- // }
- // if(tool.getToolName().equals("HeaterShield"))
- // {
- // HeaterShield();
- // }
- setupIcons(tool, iconRegister, heads, headStrings, headIcons);
- setupIcons(tool, iconRegister, accessories, accessoryStrings, accessoryIcons);
- setupIcons(tool, iconRegister, handles, handleStrings, handleIcons);
- setupIcons(tool, iconRegister, extras, extraStrings, extraIcons);
-
- tool.headStrings.putAll(headStrings);
- tool.headIcons.putAll(headIcons);
-
- tool.accessoryStrings.putAll(accessoryStrings);
- tool.accessoryIcons.putAll(accessoryIcons);
-
- tool.handleStrings.putAll(handleStrings);
- tool.handleIcons.putAll(handleIcons);
-
- tool.extraStrings.putAll(extraStrings);
- tool.extraIcons.putAll(extraIcons);
-
- tool.headIcons.put(-1, origHead);
- tool.accessoryIcons.put(-1, origAccessory);
- tool.handleIcons.put(-1, origHandle);
- tool.extraIcons.put(-1, origExtra);
- }
- }
-
- @Override
- public void registerIcons(IIconRegister iconRegister)
- {
- loadHeads(iconRegister);
- }
-
- @Override
- public String getDefaultTexturePath()
- {
- return "tinkersdefense:" + getDefaultFolder();
- }
-
- @Override
- public Item getAccessoryItem()
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- @Override
- public String getDefaultFolder()
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- @Override
- public String getEffectSuffix()
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- @Override
- public Item getHeadItem()
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- @Override
- public String getIconSuffix(int arg0)
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- @Override
- public String[] getTraits()
- {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void setupIcons(ToolCore tool, IIconRegister iconRegister, List<String> newList, HashMap<Integer, String> toolStrings, HashMap<Integer, IIcon> toolIcons)
- {
- for(int i = 0; i < newList.size(); i++)
- {
- final PatternBuilder pb = PatternBuilder.instance;
- for(final Map.Entry<String, MaterialSet> entry : pb.materialSets.entrySet())
- {
- String icon = "tinkersdefense:";
- icon += tool.getDefaultFolder() + "/" + newList.get(i);
- //toolIcons[i] = icon;
- toolStrings.put(entry.getValue().materialID + (TinkersDefense.config.MaterialIndex * (i + 1)), icon);
- }
- }
-
- addIcons(toolStrings, toolIcons, iconRegister, null, false);
- }
-
- void BattleAxe()
- {
- final ToolCoreTip tt = new ToolCoreTip();
-
- tt.accessory = "Front Head";
- tt.head = "Back Head";
- tt.handle = "Handle";
- tt.extra = "Binding";
-
- heads.add("_halbard_head");
- heads.add("_magic_head");
- heads.add("_scythe_head");
-
- tt.headTT.add("Halbard Backhead");
- tt.headTT.add("Magic Backhead");
- tt.headTT.add("Scythe Backhead");
-
- extras.add("_magic_extra");
- extras.add("_scythe_extra");
- extras.add("_halbard_extra");
- extras.add("_ornate_extra");
-
- tt.extraTT.add("Halbard Head");
- tt.extraTT.add("Magic Head");
- tt.extraTT.add("Scythe Head");
- tt.extraTT.add("Ornate Head");
-
- accessories.add("_magic_accessory");
- accessories.add("_halbard_accessory");
- accessories.add("_knob_accessory");
-
- //Metallurgy 5
-
- tools.put("Battleaxe", tt);
- }
-
- void Axe()
- {
- final ToolCoreTip tt = new ToolCoreTip();
-
- tt.head = "Head";
- tt.handle = "Handle";
-
- heads.add("_thin_head");
- tt.headTT.add("Thin Head");
- heads.add("_minecraft_head");
- tt.headTT.add("Vanilla Head");
- heads.add("_m5zinc_head");
- tt.headTT.add("Metallurgy 5 Zinc Head");
- heads.add("_m5whitegold_head");
- tt.headTT.add("Metallurgy 5 WhiteGold Head");
- heads.add("_m5tin_head");
- tt.headTT.add("Metallurgy 5 Tin Head");
- heads.add("_m5silver_head");
- tt.headTT.add("Metallurgy 5 Silver Head");
- heads.add("_m5rosegold_head");
- tt.headTT.add("Metallurgy 5 RoseGold Head");
- heads.add("_m5platinum_head");
- tt.headTT.add("Metallurgy 5 Platinum Head");
- heads.add("_m5pewter_head");
- tt.headTT.add("Metallurgy 5 Pewter Head");
- heads.add("_m5nickelsteel_head");
- tt.headTT.add("Metallurgy 5 NickelSteel Head");
- heads.add("_m5nickel_head");
- tt.headTT.add("Metallurgy 5 Nickel Head");
- heads.add("_m5monel_head");
- tt.headTT.add("Metallurgy 5 Monel Head");
- heads.add("_m5molybdochalkos_head");
- tt.headTT.add("Metallurgy 5 Molybdochalkos Head");
- heads.add("_m5manganesesteel_head");
- tt.headTT.add("Metallurgy 5 ManganeseSteel Head");
- heads.add("_m5manganese_head");
- tt.headTT.add("Metallurgy 5 Manganese Head");
- heads.add("_m5lead_head");
- tt.headTT.add("Metallurgy 5 Lead Head");
- heads.add("_m5iron_head");
- tt.headTT.add("Metallurgy 5 Iron Head");
- heads.add("_m5ignatius_head");
- tt.headTT.add("Metallurgy 5 Ignatius Head");
- heads.add("_m5hepatizon_head");
- tt.headTT.add("Metallurgy 5 Hepatizon Head");
- heads.add("_m5heavysteel_head");
- tt.headTT.add("Metallurgy 5 HeavySteel Head");
- heads.add("_m5gold_head");
- tt.headTT.add("Metallurgy 5 Gold Head");
- heads.add("_m5fungalsteel_head");
- tt.headTT.add("Metallurgy 5 FungalSteel Head");
- heads.add("_m5electrum_head");
- tt.headTT.add("Metallurgy 5 Electrum Head");
- heads.add("_m5diamond_head");
- tt.headTT.add("Metallurgy 5 Diamond Head");
- heads.add("_m5damascussteel_head");
- tt.headTT.add("Metallurgy 5 DamascusSteel Head");
- heads.add("_m5cupronickel_head");
- tt.headTT.add("Metallurgy 5 Cupronickel Head");
- heads.add("_m5crowngold_head");
- tt.headTT.add("Metallurgy 5 CrownGold Head");
- heads.add("_m5copper_head");
- tt.headTT.add("Metallurgy 5 Copper Head");
- heads.add("_m5bronze_head");
- tt.headTT.add("Metallurgy 5 Bronze Head");
- heads.add("_m5brass_head");
- tt.headTT.add("Metallurgy 5 Brass Head");
- heads.add("_m5angmallen_head");
- tt.headTT.add("Metallurgy 5 Angmallen Head");
- heads.add("_broad_head");
- tt.headTT.add("Broad Head");
- heads.add("_bearded_head");
- tt.headTT.add("Bearded Head");
-
- handles.add("_long_handle");
- tt.handleTT.add("Long Handle");
- handles.add("_ornate_handle");
- tt.handleTT.add("Ornate Handle");
- handles.add("_longornate_handle");
- tt.handleTT.add("Long Ornate Handle");
- handles.add("_offset_handle");
- tt.handleTT.add("Offset Handle");
- handles.add("_offsetlong_handle");
- tt.handleTT.add("Offset Long Handle");
- handles.add("_offsetornate_handle");
- tt.handleTT.add("Offset Ornate Handle");
- handles.add("_offsetlongornate_handle");
- tt.handleTT.add("Offset Long Ornate Handle");
-
- tools.put("Hatchet", tt);
- }
-
- void Battlesign()
- {
- handles.add("_small_handle");
- handles.add("_smalllong_handle");
-
- heads.add("_arrow_head");
- heads.add("_caution_head");
- heads.add("_noentry_head");
- heads.add("_railroad_head");
- heads.add("_stop_head");
- heads.add("_X_head");
- }
-
- void Arrow()
- {
- heads.add("_broad_head");
- heads.add("_elven_head");
- heads.add("_horned_head");
- heads.add("_trident_head");
- heads.add("_winged_head");
-
- handles.add("_bulbous_handle");
- handles.add("_natural_handle");
-
- accessories.add("_matted_accessory");
- accessories.add("_magic_accessory");
- accessories.add("_pixie_accessory");
- accessories.add("_small_accessory");
- }
-
- void Broadsword()
- {
- final ToolCoreTip tt = new ToolCoreTip();
-
- tt.head = "Blade";
- tt.accessory = "Guard";
- tt.handle = "Handle";
-
- tt.headTT.add("Standard Blade");
- heads.add("_tapered_head");
- tt.headTT.add("Tapered Blade");
- heads.add("_dull_head");
- tt.headTT.add("Dull Blade");
- heads.add("_glass_head");
- tt.headTT.add("Glass Blade");
- heads.add("_plumed_head");
- tt.headTT.add("Plumed Blade");
- heads.add("_spiked_head");
- tt.headTT.add("Spiked Blade");
- heads.add("_widebase_head");
- tt.headTT.add("Widebase Blade");
- heads.add("_mace_head");
- tt.headTT.add("Mace \"Blade\"");
- heads.add("_elusive_head");
- tt.headTT.add("Elusive Blade");
- heads.add("_repulsive_head");
- tt.headTT.add("Repulsive Blade");
- heads.add("_falchion_head");
- tt.headTT.add("Falchion Blade");
- heads.add("_big_head");
- tt.headTT.add("Big Blade");
- heads.add("_nofuller_head");
- tt.headTT.add("No Fuller Blade");
- heads.add("_segmented_head");
- tt.headTT.add("Segmented Blade");
- heads.add("_hourglass_head");
- tt.headTT.add("Hourglass Blade");
- heads.add("_flat_head");
- tt.headTT.add("Flat Tip Blade");
-
- heads.add("_m5zinc_head");
- tt.headTT.add("Metallurgy 5 Zinc Blade");
- heads.add("_m5whitegold_head");
- tt.headTT.add("Metallurgy 5 WhiteGold Blade");
- heads.add("_m5tin_head");
- tt.headTT.add("Metallurgy 5 Tin Blade");
- heads.add("_m5silver_head");
- tt.headTT.add("Metallurgy 5 Silver Blade");
- heads.add("_m5rosegold_head");
- tt.headTT.add("Metallurgy 5 RoseGold Blade");
- heads.add("_m5platinum_head");
- tt.headTT.add("Metallurgy 5 Platinum Blade");
- heads.add("_m5pewter_head");
- tt.headTT.add("Metallurgy 5 Pewter Blade");
- heads.add("_m5nickelsteel_head");
- tt.headTT.add("Metallurgy 5 NickelSteel Blade");
- heads.add("_m5nickel_head");
- tt.headTT.add("Metallurgy 5 Nickel Blade");
- heads.add("_m5monel_head");
- tt.headTT.add("Metallurgy 5 Monel Blade");
- heads.add("_m5molybdochalkos_head");
- tt.headTT.add("Metallurgy 5 Molybdochalkos Blade");
- heads.add("_m5manganesesteel_head");
- tt.headTT.add("Metallurgy 5 ManganeseSteel Blade");
- heads.add("_m5manganese_head");
- tt.headTT.add("Metallurgy 5 Manganese Blade");
- heads.add("_m5lead_head");
- tt.headTT.add("Metallurgy 5 Lead Blade");
- heads.add("_m5iron_head");
- tt.headTT.add("Metallurgy 5 Iron Blade");
- heads.add("_m5ignatius_head");
- tt.headTT.add("Metallurgy 5 Ignatius Blade");
- heads.add("_m5hepatizon_head");
- tt.headTT.add("Metallurgy 5 Hepatizon Blade");
- heads.add("_m5heavysteel_head");
- tt.headTT.add("Metallurgy 5 HeavySteel Blade");
- heads.add("_m5gold_head");
- tt.headTT.add("Metallurgy 5 Gold Blade");
- heads.add("_m5fungalsteel_head");
- tt.headTT.add("Metallurgy 5 FungalSteel Blade");
- heads.add("_m5electrum_head");
- tt.headTT.add("Metallurgy 5 Electrum Blade");
- heads.add("_m5diamond_head");
- tt.headTT.add("Metallurgy 5 Diamond Blade");
- heads.add("_m5damascussteel_head");
- tt.headTT.add("Metallurgy 5 DamascusSteel Blade");
- heads.add("_m5cupronickel_head");
- tt.headTT.add("Metallurgy 5 Cupronickel Blade");
- heads.add("_m5crowngold_head");
- tt.headTT.add("Metallurgy 5 CrownGold Blade");
- heads.add("_m5copper_head");
- tt.headTT.add("Metallurgy 5 Copper Blade");
- heads.add("_m5bronze_head");
- tt.headTT.add("Metallurgy 5 Bronze Blade");
- heads.add("_m5brass_head");
- tt.headTT.add("Metallurgy 5 Brass Blade");
- heads.add("_m5angmallen_head");
- tt.headTT.add("Metallurgy 5 Angmallen Blade");
-
- accessories.add("_basket_accessory");
- accessories.add("_curved_accessory");
- accessories.add("_elusive_accessory");
- accessories.add("_extended_accessory");
- accessories.add("_legendary_accessory");
- accessories.add("_no_accessory");
- accessories.add("_basket_accessory");
- accessories.add("_repulsive_accessory");
- accessories.add("_square_accessory");
- accessories.add("_straight_accessory");
- accessories.add("_straight_accessory");
- accessories.add("_bulbous_accessory");
- accessories.add("_sun_accessory");
- accessories.add("_lamenting_accessory");
- accessories.add("_pixie_accessory");
- accessories.add("_forked_accessory");
-
- handles.add("_ornate_handle");
- handles.add("_thick_handle");
- handles.add("_short_handle");
-
- tools.put("Broadsword", tt);
- }
-
- void Mattock()
- {
- heads.add("_head_bearded");
- heads.add("_head_magic");
- heads.add("_head_scythe");
- heads.add("head_wide");
-
- accessories.add("_back_straight");
-
- heads.add("_m5copper_head");
- accessories.add("_m5copper_accessory");
- }
-
- void Longbow()
- {
- heads.add("_m5copper_head");
- accessories.add("_m5copper_accessory");
- handles.add("_m5copper_handle");
- extras.add("_m5copper_extra");
- }
-
- void HeaterShield()
- {
- final ToolCoreTip tt = new ToolCoreTip();
-
- tt.head = "Plate";
- tt.accessory = "Emblem";
- tt.handle = "Edge";
- tt.extra = "Binding";
-
- tt.headTT.add("Standard Plate");
- heads.add("_glass_plate");
- tt.headTT.add("Glass Plate");
-
- tt.accessoryTT.add("Standard Emblem");
- accessories.add("_test_face");
- tt.accessoryTT.add("Villager Emblem");
- accessories.add("_skeleton_face");
- tt.accessoryTT.add("Skeleton Emblem");
- accessories.add("_ender_face");
- tt.accessoryTT.add("Ender Emblem");
- accessories.add("_creeper_face");
- tt.accessoryTT.add("Creeper Emblem");
- accessories.add("_square_face");
- tt.accessoryTT.add("Block Emblem");
- accessories.add("_angel_face");
- tt.accessoryTT.add("Angel Emblem");
- accessories.add("_fancy_face");
- tt.accessoryTT.add("Fancy Emblem");
- accessories.add("_cross_face");
- tt.accessoryTT.add("Cross Emblem");
- accessories.add("_stripe_face");
- tt.accessoryTT.add("Vertical Stripe Emblem");
- accessories.add("_bar_face");
- tt.accessoryTT.add("Vertical Bars Emblem");
- accessories.add("_horbar_face");
- tt.accessoryTT.add("Horizontal Bars Emblem");
- accessories.add("_horstripe_face");
- tt.accessoryTT.add("Horizontal Stripe Emblem");
- accessories.add("_triangle_face");
- tt.accessoryTT.add("Triangles Emblem");
- accessories.add("_arrow_face");
- tt.accessoryTT.add("Arrow Emblem");
- accessories.add("_checker_face");
- tt.accessoryTT.add("Checkered Emblem");
-
- tt.handleTT.add("Standard Edge");
- handles.add("_demon_edge");
- tt.handleTT.add("Demonic Edge");
- handles.add("_squared_edge");
- tt.handleTT.add("Squared Edge");
- handles.add("_heart_edge");
- tt.handleTT.add("Heart Edge");
-
- tt.extraTT.add("Standard Binding");
- extras.add("_spider_binding");
- tt.extraTT.add("Spider Binding");
- extras.add("_love_binding");
- tt.extraTT.add("Heart Binding");
- extras.add("_enforced_binding");
- tt.extraTT.add("Enforced Binding");
- extras.add("_slime_binding");
- tt.extraTT.add("Slimey Binding");
- extras.add("_small_binding");
- tt.extraTT.add("Small Binding");
- extras.add("_demon_binding");
- tt.extraTT.add("Demon Binding");
- extras.add("_pig_binding");
- tt.extraTT.add("Pig Binding");
- extras.add("_wolf_binding");
- tt.extraTT.add("Wolf Binding");
- extras.add("_wide_binding");
- tt.extraTT.add("Wide Binding");
- extras.add("_reinforced_binding");
- tt.extraTT.add("Strong Binding");
- extras.add("_skull_binding");
- tt.extraTT.add("Skull Binding");
- extras.add("_hell_binding");
- tt.extraTT.add("Hell Binding");
- extras.add("_queen_binding");
- tt.extraTT.add("Queen's Binding");
- extras.add("_tri_binding");
- tt.extraTT.add("Tri Binding");
- extras.add("_fancy_binding");
- tt.extraTT.add("Fancy Binding");
-
- tools.put("Heater Shield", tt);
- }
-
-}
diff --git a/src/main/java/lance5057/tDefense/finishingAnvil/utilities/ToolCoreTip.java b/src/main/java/lance5057/tDefense/finishingAnvil/utilities/ToolCoreTip.java
deleted file mode 100644
index e93a11d..0000000
--- a/src/main/java/lance5057/tDefense/finishingAnvil/utilities/ToolCoreTip.java
+++ /dev/null
@@ -1,59 +0,0 @@
-package lance5057.tDefense.finishingAnvil.utilities;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class ToolCoreTip
-{
- String head = "";
- String handle = "";
- String accessory = "";
- String extra = "";
-
- List<String> headTT = new ArrayList<String>();
- List<String> accessoryTT = new ArrayList<String>();
- List<String> handleTT = new ArrayList<String>();
- List<String> extraTT = new ArrayList<String>();
-
- public ToolCoreTip()
- {
- }
-
- public String getPart(int id /*1-4*/)
- {
- switch(id)
- {
- case 1:
- return head;
- case 3:
- return handle;
- case 2:
- return accessory;
- case 4:
- return extra;
- default:
- return "";
- }
- }
-
- public String getPartName(int partId /*1-4*/, int id)
- {
- switch(partId)
- {
- case 1:
- if(headTT.size() > 0 && headTT.size() - 1 >= id && headTT.get(id) != null)
- return headTT.get(id);
- case 3:
- if(handleTT.size() > 0 && handleTT.size() - 1 >= id && handleTT.get(id) != null)
- return handleTT.get(id);
- case 2:
- if(accessoryTT.size() > 0 && accessoryTT.size() - 1 >= id && accessoryTT.get(id) != null)
- return accessoryTT.get(id);
- case 4:
- if(extraTT.size() > 0 && extraTT.size() - 1 >= id && extraTT.get(id) != null)
- return extraTT.get(id);
- default:
- return "";
- }
- }
-}
diff --git a/src/main/java/lance5057/tDefense/holiday/HolidayBase.java b/src/main/java/lance5057/tDefense/holiday/HolidayBase.java
index 2728689..45ff00e 100644
--- a/src/main/java/lance5057/tDefense/holiday/HolidayBase.java
+++ b/src/main/java/lance5057/tDefense/holiday/HolidayBase.java
@@ -2,23 +2,27 @@ package lance5057.tDefense.holiday;
import lance5057.tDefense.holiday.xmas.XmasBase;
import lance5057.tDefense.util.ModuleBase;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
-public class HolidayBase
+public class HolidayBase extends ModuleBase
{
- ModuleBase xmas;
-
- public HolidayBase()
- {
- xmas = new XmasBase();
+ @Override
+ public void preInit(FMLPreInitializationEvent e) {
+ // TODO Auto-generated method stub
+
}
-
- public void preInit()
- {
- xmas.preInit();
+
+ @Override
+ public void init(FMLInitializationEvent e) {
+ // TODO Auto-generated method stub
+
}
-
- public void init()
- {
- xmas.init();
+
+ @Override
+ public void postInit(FMLPostInitializationEvent e) {
+ // TODO Auto-generated method stub
+
}
}
diff --git a/src/main/java/lance5057/tDefense/holiday/xmas/XmasBase.java b/src/main/java/lance5057/tDefense/holiday/xmas/XmasBase.java
index ea6f10e..2c83902 100644
--- a/src/main/java/lance5057/tDefense/holiday/xmas/XmasBase.java
+++ b/src/main/java/lance5057/tDefense/holiday/xmas/XmasBase.java
@@ -3,21 +3,39 @@ package lance5057.tDefense.holiday.xmas;
import slimeknights.tconstruct.world.entity.EntityBlueSlime;
import lance5057.tDefense.TinkersDefense;
import lance5057.tDefense.holiday.xmas.gumdropslime.GumDropSlime;
+import lance5057.tDefense.util.ItemsBase;
import lance5057.tDefense.util.ModuleBase;
import net.minecraft.world.storage.loot.LootTableList;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
import net.minecraftforge.fml.common.registry.EntityRegistry;
public class XmasBase extends ModuleBase {
+
+ protected ItemsBase items;
+
public XmasBase() {
items = new XmasItems();
}
@Override
- public void preInit() {
-
- items.preInit();
+ public void preInit(FMLPreInitializationEvent e) {
+ // TODO Auto-generated method stub
+ items.preInit(e);
EntityRegistry.registerModEntity(GumDropSlime.class, "gumdropslime", 0,
TinkersDefense.instance, 64, 5, true, 0x963430, 0xDDDDDD);
//LootTableList.register(GumDropSlime.LOOT_TABLE);
}
-}
+
+ @Override
+ public void init(FMLInitializationEvent e) {
+ // TODO Auto-generated method stub
+
+ }
+
+ @Override
+ public void postInit(FMLPostInitializationEvent e) {
+ // TODO Auto-generated method stub
+
+ }}
diff --git a/src/main/java/lance5057/tDefense/holiday/xmas/XmasItems.java b/src/main/java/lance5057/tDefense/holiday/xmas/XmasItems.java
index ff51fa0..3ac3d58 100644
--- a/src/main/java/lance5057/tDefense/holiday/xmas/XmasItems.java
+++ b/src/main/java/lance5057/tDefense/holiday/xmas/XmasItems.java
@@ -3,11 +3,18 @@ package lance5057.tDefense.holiday.xmas;
import lance5057.tDefense.util.Color16Util;
import lance5057.tDefense.util.ItemsBase;
import lance5057.tDefense.util.MetaItem;
+import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
+import slimeknights.mantle.client.CreativeTab;
public class XmasItems extends ItemsBase {
+ CreativeTab xmas;
+
public static Item item_redmintcane;
public static Item item_greenmintcane;
public static Item item_redmintIngot;
@@ -16,19 +23,25 @@ public class XmasItems extends ItemsBase {
public static MetaItem item_gumdrop;
- public void preInit() {
- setTab("TDefense_Xmas", new ItemStack(Items.SHIELD));
+ public void preInit(FMLPreInitializationEvent e) {
+ xmas = new CreativeTab("TDefense_Xmas", new ItemStack(Items.SHIELD));
}
- public void init() {
- item_redmintcane = register("redmintcane", 64);
- item_redmintIngot = register("redmintIngot", 64);
- item_greenmintcane = register("greenmintcane", 64);
- item_greenmintIngot = register("greenmintIngot", 64);
- item_gingerbread = register("gingerbread", 64);
+ public void init(FMLInitializationEvent e) {
+ item_redmintcane = register("redmintcane", 64, xmas);
+ item_redmintIngot = register("redmintIngot", 64, xmas);
+ item_greenmintcane = register("greenmintcane", 64, xmas);
+ item_greenmintIngot = register("greenmintIngot", 64, xmas);
+ item_gingerbread = register("gingerbread", 64, xmas);
- item_gumdrop = registerMeta("gumdrop", Color16Util.colors, 64);
+ item_gumdrop = registerMeta("gumdrop", Color16Util.colors, 64, xmas);
- this.tabName.setDisplayIcon(new ItemStack(item_redmintcane));
+ xmas.setDisplayIcon(new ItemStack(item_redmintcane));
+ }
+
+ @Override
+ public void postInit(FMLPostInitializationEvent e) {
+ // TODO Auto-generated method stub
+
}
}
diff --git a/src/main/java/lance5057/tDefense/holiday/xmas/gumdropslime/GumDropSlimeRenderer.java b/src/main/java/lance5057/tDefense/holiday/xmas/gumdropslime/GumDropSlimeRenderer.java
index e6384f6..e17f336 100644
--- a/src/main/java/lance5057/tDefense/holiday/xmas/gumdropslime/GumDropSlimeRenderer.java
+++ b/src/main/java/lance5057/tDefense/holiday/xmas/gumdropslime/GumDropSlimeRenderer.java
@@ -15,7 +15,7 @@ public class GumDropSlimeRenderer extends RenderTinkerSlime
public static final Factory FACTORY_GumDropSlime = new Factory();
public GumDropSlimeRenderer(RenderManager renderManager) {
- super(renderManager, Color16Util.colorsHex[Minecraft.getMinecraft().theWorld.rand.nextInt(16)],
+ super(renderManager, Color16Util.colorsHex[Minecraft.getMinecraft().world.rand.nextInt(16)],
new ResourceLocation(Reference.MOD_ID,"textures/entity/slime.png"));
// TODO Auto-generated constructor stub
}
diff --git a/src/main/java/lance5057/tDefense/proxy/ClientProxy.java b/src/main/java/lance5057/tDefense/proxy/ClientProxy.java
index 278bd83..800ba02 100644
--- a/src/main/java/lance5057/tDefense/proxy/ClientProxy.java
+++ b/src/main/java/lance5057/tDefense/proxy/ClientProxy.java
@@ -2,6 +2,8 @@ package lance5057.tDefense.proxy;
import lance5057.tDefense.Reference;
import lance5057.tDefense.TD_Commands;
+import lance5057.tDefense.baubles.BaublesClientProxy;
+import lance5057.tDefense.core.CoreClientProxy;
import lance5057.tDefense.core.CoreItems;
import lance5057.tDefense.core.tools.TDTools;
import lance5057.tDefense.holiday.HolidayClientProxy;
@@ -39,10 +41,15 @@ public class ClientProxy extends CommonProxy
// public static ModelTinkersChausses chausses;
// public static ModelTinkersBoots boots;
+ public static BaublesClientProxy baubles = new BaublesClientProxy();;
+
ToolBuildGuiInfo roundshieldGUI;
ToolBuildGuiInfo heatershieldGUI;
- HolidayClientProxy holiProxy = new HolidayClientProxy();
+ ToolBuildGuiInfo zweihanderGUI;
+
+ public static CoreClientProxy coreProxy = new CoreClientProxy();
+ public static HolidayClientProxy holiProxy = new HolidayClientProxy();
@Override
public void preInit()
@@ -50,10 +57,12 @@ public class ClientProxy extends CommonProxy
ClientCommandHandler.instance.registerCommand(new TD_Commands());
registerToolRenderers();
+ coreProxy.preInit();
+ baubles.preInit();
}
@Override
- public void Init()
+ public void init()
{
// Minecraft.getMinecraft().getRenderItem().getItemModelMesher()
// .register(TDTools.heatershield, 0, new ModelResourceLocation("modid:itemname", "inventory"));
@@ -67,14 +76,16 @@ public class ClientProxy extends CommonProxy
registerItemRenderer(CoreItems.item_dogbeariumIngot, 0, CoreItems.item_dogbeariumIngot.getUnlocalizedName());
registerItemRenderer(CoreItems.item_queensgoldIngot, 0, CoreItems.item_queensgoldIngot.getUnlocalizedName());
+ coreProxy.init();
holiProxy.Init();
+ baubles.init();
}
public void registerToolRenderers()
{
ModelRegisterUtil.registerToolModel(TDTools.roundshield);
ModelRegisterUtil.registerToolModel(TDTools.heatershield);
-
+ ModelRegisterUtil.registerToolModel(TDTools.zweihander);
}
@@ -82,6 +93,7 @@ public class ClientProxy extends CommonProxy
{
roundshieldGUI = new ToolBuildGuiInfo(TDTools.roundshield);
heatershieldGUI = new ToolBuildGuiInfo(TDTools.heatershield);
+ zweihanderGUI = new ToolBuildGuiInfo(TDTools.zweihander);
}
public void setupToolGuis()
@@ -94,18 +106,26 @@ public class ClientProxy extends CommonProxy
heatershieldGUI.addSlotPosition(25, 33+8);
heatershieldGUI.addSlotPosition(43, 33+8);
heatershieldGUI.addSlotPosition(34, 51+8);
+
+ zweihanderGUI.addSlotPosition(34, 15+8);
+ zweihanderGUI.addSlotPosition(25, 33+8);
+ zweihanderGUI.addSlotPosition(43, 33+8);
+ zweihanderGUI.addSlotPosition(34, 51+8);
}
public void registerToolGuis()
{
TinkerRegistryClient.addToolBuilding(roundshieldGUI);
TinkerRegistryClient.addToolBuilding(heatershieldGUI);
+ TinkerRegistryClient.addToolBuilding(zweihanderGUI);
}
@Override
public void reloadRenderers()
{
setToolGuis();
+
+ baubles.reloadRenderers();
}
public void setToolGuis()
@@ -120,6 +140,12 @@ public class ClientProxy extends CommonProxy
heatershieldGUI.addSlotPosition(25, 33);
heatershieldGUI.addSlotPosition(43, 33);
heatershieldGUI.addSlotPosition(34, 51);
+
+ zweihanderGUI.positions.clear();
+ zweihanderGUI.addSlotPosition(34, 15);
+ zweihanderGUI.addSlotPosition(25, 33);
+ zweihanderGUI.addSlotPosition(43, 33);
+ zweihanderGUI.addSlotPosition(34, 51);
}
public static void registerItemRenderer(Item item, int meta, String id) {
diff --git a/src/main/java/lance5057/tDefense/proxy/CommonProxy.java b/src/main/java/lance5057/tDefense/proxy/CommonProxy.java
index a76da7b..8ae3d90 100644
--- a/src/main/java/lance5057/tDefense/proxy/CommonProxy.java
+++ b/src/main/java/lance5057/tDefense/proxy/CommonProxy.java
@@ -1,10 +1,17 @@
package lance5057.tDefense.proxy;
-import lance5057.tDefense.TD_Commands;
-import net.minecraftforge.client.ClientCommandHandler;
+import lance5057.tDefense.TinkersDefense;
+import lance5057.tDefense.core.blocks.crestMount.Container_CrestMount;
+import lance5057.tDefense.core.blocks.crestMount.Gui_CrestMount;
+import lance5057.tDefense.core.blocks.crestMount.TileEntity_CrestMount;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.util.math.BlockPos;
+import net.minecraft.world.World;
+import net.minecraftforge.fml.common.network.IGuiHandler;
+import net.minecraftforge.fml.common.network.NetworkRegistry;
-public class CommonProxy// implements IGuiHandler
+public class CommonProxy implements IGuiHandler
{
//public static ModifierSoulHandler SoulHandler = null;
@@ -12,8 +19,9 @@ public class CommonProxy// implements IGuiHandler
{
}
- public void Init()
+ public void init()
{
+ NetworkRegistry.INSTANCE.registerGuiHandler(TinkersDefense.instance, this);
}
public void registerTileEntitySpecialRenderer()
@@ -26,6 +34,11 @@ public class CommonProxy// implements IGuiHandler
}
+ public void postInit() {
+ // TODO Auto-generated method stub
+
+ }
+
// public EntityPlayer getPlayerEntity(MessageContext ctx)
// {
// return ctx.getServerHandler().playerEntity;
@@ -41,28 +54,28 @@ public class CommonProxy// implements IGuiHandler
// return null;
// }
//
-// @Override
-// public Object getServerGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z)
-// {
-// if(ID == TinkersDefense.GUI_CREST_INV)
-// return new Container_CrestMount(player.inventory,
-// (TileEntity_CrestMount) world.getTileEntity(x, y, z));
+ @Override
+ public Object getServerGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z)
+ {
+ if(ID == TinkersDefense.GUI_CREST_INV)
+ return new Container_CrestMount(player.inventory,
+ (TileEntity_CrestMount) world.getTileEntity(new BlockPos(x, y, z)));
// if(ID == TinkersDefense.GUI_ANVIL_INV)
// return new Container_FinishingAnvil(player.inventory,
// (TileEntity_FinishingAnvil) world.getTileEntity(x, y, z));
-//
-// return null;
-// }
-//
-// @Override
-// public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z)
-// {
-// if(ID == TinkersDefense.GUI_CREST_INV)
-// return new Gui_CrestMount(player.inventory,
-// (TileEntity_CrestMount) world.getTileEntity(x, y, z));
+
+ return null;
+ }
+
+ @Override
+ public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z)
+ {
+ if(ID == TinkersDefense.GUI_CREST_INV)
+ return new Gui_CrestMount(player.inventory,
+ (TileEntity_CrestMount) world.getTileEntity(new BlockPos(x, y, z)));
// if(ID == TinkersDefense.GUI_ANVIL_INV)
// return new Gui_FinishingAnvil(player.inventory,
// (TileEntity_FinishingAnvil) world.getTileEntity(x, y, z));
-// return null;
-// }
+ return null;
+ }
}
diff --git a/src/main/java/lance5057/tDefense/util/BlocksBase.java b/src/main/java/lance5057/tDefense/util/BlocksBase.java
new file mode 100644
index 0000000..5cd3ac6
--- /dev/null
+++ b/src/main/java/lance5057/tDefense/util/BlocksBase.java
@@ -0,0 +1,49 @@
+package lance5057.tDefense.util;
+
+import lance5057.tDefense.Reference;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemBlock;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
+import net.minecraftforge.fml.common.registry.GameRegistry;
+
+public abstract class BlocksBase {
+
+ public BlocksBase()
+ {
+
+ }
+
+ public abstract void preInit(FMLPreInitializationEvent e);
+
+ public abstract void init(FMLInitializationEvent e);
+
+ public abstract void postInit(FMLPostInitializationEvent e);
+
+ protected Block register(String name, CreativeTabs tabName, float hardness)
+ {
+ Block block = new Block(Material.IRON).setCreativeTab(tabName).setUnlocalizedName(name).setRegistryName(Reference.MOD_ID, name).setHardness(hardness);
+ GameRegistry.register(block);
+ return block;
+ }
+
+ protected ItemBlock register(String name, int size, CreativeTabs tabName, Block block)
+ {
+ ItemBlock item = new ItemBlock(block);
+ item.setCreativeTab(tabName).setMaxStackSize(size).setUnlocalizedName(name).setRegistryName(Reference.MOD_ID, name).setCreativeTab(tabName);
+ GameRegistry.register(item);
+ return item;
+ }
+}
+
+// protected MetaItem registerMeta(String name, String[] names,int size)
+// {
+// Item item = new MetaItem(names).setCreativeTab(tabName).setMaxStackSize(size).setUnlocalizedName(name).setRegistryName(Reference.MOD_ID, name);
+//
+// GameRegistry.register(item);
+// return (MetaItem) item;
+// } \ No newline at end of file
diff --git a/src/main/java/lance5057/tDefense/util/ItemsBase.java b/src/main/java/lance5057/tDefense/util/ItemsBase.java
index ddfa882..e146579 100644
--- a/src/main/java/lance5057/tDefense/util/ItemsBase.java
+++ b/src/main/java/lance5057/tDefense/util/ItemsBase.java
@@ -1,38 +1,35 @@
package lance5057.tDefense.util;
import lance5057.tDefense.Reference;
-import lance5057.tDefense.proxy.ClientProxy;
-import net.minecraft.init.Items;
+import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
import net.minecraftforge.fml.common.registry.GameRegistry;
import slimeknights.mantle.client.CreativeTab;
public abstract class ItemsBase {
- public CreativeTab tabName;
-
public ItemsBase()
{
}
- public abstract void preInit();
+ public abstract void preInit(FMLPreInitializationEvent e);
- public abstract void init();
+ public abstract void init(FMLInitializationEvent e);
- protected void setTab(String tab, ItemStack stack)
- {
- tabName = new CreativeTab(tab, stack);
- }
+ public abstract void postInit(FMLPostInitializationEvent e);
- protected Item register(String name, int size)
+ protected Item register(String name, int size, CreativeTabs tabName)
{
Item item = new Item().setCreativeTab(tabName).setMaxStackSize(size).setUnlocalizedName(name).setRegistryName(Reference.MOD_ID, name);
GameRegistry.register(item);
return item;
}
- protected MetaItem registerMeta(String name, String[] names,int size)
+ protected MetaItem registerMeta(String name, String[] names,int size, CreativeTabs tabName)
{
Item item = new MetaItem(names).setCreativeTab(tabName).setMaxStackSize(size).setUnlocalizedName(name).setRegistryName(Reference.MOD_ID, name);
diff --git a/src/main/java/lance5057/tDefense/util/ModuleBase.java b/src/main/java/lance5057/tDefense/util/ModuleBase.java
index d8264ce..f03ef9c 100644
--- a/src/main/java/lance5057/tDefense/util/ModuleBase.java
+++ b/src/main/java/lance5057/tDefense/util/ModuleBase.java
@@ -2,18 +2,15 @@ package lance5057.tDefense.util;
import net.minecraft.init.Items;
import net.minecraft.item.ItemStack;
+import net.minecraftforge.fml.common.event.FMLInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
+import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
public abstract class ModuleBase
-{
- protected ItemsBase items;
+{
+ public abstract void preInit(FMLPreInitializationEvent e);
- public void preInit()
- {
- items.preInit();
- }
+ public abstract void init(FMLInitializationEvent e);
- public void init()
- {
- items.init();
- }
+ public abstract void postInit(FMLPostInitializationEvent e);
}
diff --git a/src/main/resources/assets/tinkersdefense/models/item/tools/zweihander.tcon.json b/src/main/resources/assets/tinkersdefense/models/item/tools/zweihander.tcon.json
new file mode 100644
index 0000000..32cec80
--- /dev/null
+++ b/src/main/resources/assets/tinkersdefense/models/item/tools/zweihander.tcon.json
@@ -0,0 +1,36 @@
+{
+ "textures": {
+ "layer0": "tinkersdefense:items/zweihander/blade",
+ "layer1": "tinkersdefense:items/zweihander/core",
+ "layer2": "tinkersdefense:items/zweihander/guard",
+ "layer3": "tinkersdefense:items/zweihander/handle",
+ "broken1": "tinkersdefense:items/zweihander/broken"
+ },
+ "display": {
+ "thirdperson_righthand": {
+ "rotation": [ 0, 90, 45 ],
+ "translation": [ 0, 8, 0 ],
+ "scale": [ 1.5, 1.5, 1 ]
+ },
+ "thirdperson_lefthand": {
+ "rotation": [ 0, 90, 45 ],
+ "translation": [ 0, 8, 0 ],
+ "scale": [ 1.5, 1.5, 1 ]
+ },
+ "firstperson_righthand": {
+ "rotation": [ 0, 90, 45 ],
+ "translation": [ 0, 8, 0 ],
+ "scale": [ 1.5, 1.5, 1 ]
+ },
+ "firstperson_lefthand": {
+ "rotation": [ 0, 90, 45 ],
+ "translation": [ 0, 8, 0 ],
+ "scale": [ 1.5, 1.5, 1 ]
+ },
+ "fixed": {
+ "rotation": [ 0, 180, 0 ],
+ "translation": [ -2, 4, -5],
+ "scale":[ 0.5, 0.5, 0.5]
+ }
+ }
+}
diff --git a/src/main/resources/assets/tinkersdefense/models/sheathe_1.png b/src/main/resources/assets/tinkersdefense/models/sheathe_1.png
new file mode 100644
index 0000000..87cf001
--- /dev/null
+++ b/src/main/resources/assets/tinkersdefense/models/sheathe_1.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/beheading_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/beheading_zweihander_effect.png
index 64d883e..64d883e 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/beheading_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/beheading_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_blade.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/blade.png
index 05ee7ad..05ee7ad 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_blade.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/blade.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/blaze_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/blaze_zweihander_effect.png
index 8563571..8563571 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/blaze_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/blaze_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/bloodoath_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/bloodoath_zweihander_effect.png
index f2d35ef..f2d35ef 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/bloodoath_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/bloodoath_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/bloodoath_zweihander_effect.png.mcmeta b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/bloodoath_zweihander_effect.png.mcmeta
index 191c85a..191c85a 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/bloodoath_zweihander_effect.png.mcmeta
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/bloodoath_zweihander_effect.png.mcmeta
diff --git a/src/main/resources/assets/tinkersdefense/textures/items/zweihander/broken.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/broken.png
new file mode 100644
index 0000000..00b5fdc
--- /dev/null
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/broken.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_core.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/core.png
index 9106565..9106565 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_core.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/core.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/corpseivy_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/corpseivy_zweihander_effect.png
index e77311c..e77311c 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/corpseivy_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/corpseivy_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/diamond_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/diamond_zweihander_effect.png
index 795efe6..795efe6 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/diamond_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/diamond_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/emerald_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/emerald_zweihander_effect.png
index 8164a71..8164a71 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/emerald_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/emerald_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/flux_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/flux_zweihander_effect.png
index 804447e..804447e 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/flux_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/flux_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_blade.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_blade.png
index 3e2ec7b..3e2ec7b 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_blade.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_blade.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_core.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_core.png
index 7ce220b..7ce220b 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_core.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_core.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_guard.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_guard.png
index 6e1980f..6e1980f 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_guard.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_guard.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_handle.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_handle.png
index ecbe5f3..ecbe5f3 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/greenmint_zweihander_handle.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/greenmint_zweihander_handle.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_guard.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/guard.png
index 70bf386..70bf386 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_guard.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/guard.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_handle.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/handle.png
index edf805d..edf805d 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/_zweihander_handle.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/handle.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/lapis_zweihander_effect (1).png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/lapis_zweihander_effect (1).png
index cfe6390..cfe6390 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/lapis_zweihander_effect (1).png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/lapis_zweihander_effect (1).png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/lapis_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/lapis_zweihander_effect.png
index cfe6390..cfe6390 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/lapis_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/lapis_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/lava_zweihander_effect (1).png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/lava_zweihander_effect (1).png
index 454f57a..454f57a 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/lava_zweihander_effect (1).png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/lava_zweihander_effect (1).png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/lava_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/lava_zweihander_effect.png
index 454f57a..454f57a 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/lava_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/lava_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/manacore_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/manacore_zweihander_effect.png
index e0e79c9..e0e79c9 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/manacore_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/manacore_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/moss_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/moss_zweihander_effect.png
index 9cd743a..9cd743a 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/moss_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/moss_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/necrotic_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/necrotic_zweihander_effect.png
index 5f81bf4..5f81bf4 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/necrotic_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/necrotic_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/piston_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/piston_zweihander_effect.png
index dc9af5a..dc9af5a 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/piston_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/piston_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/quartz_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/quartz_zweihander_effect.png
index 8cc7817..8cc7817 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/quartz_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/quartz_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_blade.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_blade.png
index edc328a..edc328a 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_blade.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_blade.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_core.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_core.png
index 98b5f54..98b5f54 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_core.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_core.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_guard.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_guard.png
index c0beeb3..c0beeb3 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_guard.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_guard.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_handle.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_handle.png
index 5e999d8..5e999d8 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/redmint_zweihander_handle.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redmint_zweihander_handle.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/redstone_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redstone_zweihander_effect.png
index 4a601eb..4a601eb 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/redstone_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/redstone_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/reinforced_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/reinforced_zweihander_effect.png
index bb66d4e..bb66d4e 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/reinforced_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/reinforced_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/scabbing_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/scabbing_zweihander_effect.png
index 7e0551a..7e0551a 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/scabbing_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/scabbing_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/silk_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/silk_zweihander_effect.png
index 92c910a..92c910a 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/silk_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/silk_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/smite_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/smite_zweihander_effect.png
index 830c2df..830c2df 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/smite_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/smite_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/spider_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/spider_zweihander_effect.png
index df3bf8e..df3bf8e 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/spider_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/spider_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/terracore_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/terracore_zweihander_effect.png
index ebb74c2..ebb74c2 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/terracore_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/terracore_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinker/textures/items/zweihander/textbook_zweihander_effect.png b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/textbook_zweihander_effect.png
index d65cae8..d65cae8 100644
--- a/src/main/resources/assets/tinker/textures/items/zweihander/textbook_zweihander_effect.png
+++ b/src/main/resources/assets/tinkersdefense/textures/items/zweihander/textbook_zweihander_effect.png
Binary files differ
diff --git a/src/main/resources/assets/tinkersdefense/textures/model/sheathe.png b/src/main/resources/assets/tinkersdefense/textures/model/sheathe.png
new file mode 100644
index 0000000..9bb3952
--- /dev/null
+++ b/src/main/resources/assets/tinkersdefense/textures/model/sheathe.png
Binary files differ
diff --git a/src/main/resources/mcmod.info b/src/main/resources/mcmod.info
index 5fca141..6707487 100644
--- a/src/main/resources/mcmod.info
+++ b/src/main/resources/mcmod.info
@@ -7,8 +7,8 @@
"mcversion": "1.10.2",
"url": "",
"authorList": ["Sir Lance"],
- "requiredMods": [ "Forge", "tconstruct"],
- "dependencies": ["tconstruct"],
+ "requiredMods": [ "Forge", "tconstruct","Baubles"],
+ "dependencies": ["tconstruct","Baubles"],
"useDependencyInformation": "true"
}
]