Misc fixes, comment out/delete a bunch of integrations, fix some recipes

This commit is contained in:
Vincent Lee committed 2019-03-05 00:32:07 -06:00
1 parent c62e663f92
commit dec7306816
20 files changed
+215 -278

No files matched your search

@@ -15,6 +15,7 @@ import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.registry.IRegistry;
import vazkii.botania.api.BotaniaAPI;
import vazkii.botania.api.recipe.RecipeBrew;
import vazkii.botania.common.brew.ModBrews;
@@ -72,9 +73,9 @@ public class ModBrewRecipes {
}
public static void initTC() {
Item salisMundus = Item.REGISTRY.get(new ResourceLocation("thaumcraft", "salis_mundus"));
Item bathSalts = Item.REGISTRY.get(new ResourceLocation("thaumcraft", "bath_salts"));
Item amber = Item.REGISTRY.get(new ResourceLocation("thaumcraft", "amber"));
Item salisMundus = IRegistry.ITEM.get(new ResourceLocation("thaumcraft", "salis_mundus"));
Item bathSalts = IRegistry.ITEM.get(new ResourceLocation("thaumcraft", "bath_salts"));
Item amber = IRegistry.ITEM.get(new ResourceLocation("thaumcraft", "amber"));
warpWardBrew = BotaniaAPI.registerBrewRecipe(ModBrews.warpWard, new ItemStack(Items.NETHER_WART), new ItemStack(salisMundus), new ItemStack(bathSalts), new ItemStack(amber));
}
@@ -59,46 +59,50 @@ public final class ModManaAlchemyRecipes {
leatherRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.LEATHER), new ItemStack(Items.ROTTEN_FLESH), 600);
woodRecipes = new ArrayList<>();
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.LOG, 1, 0), new ItemStack(Blocks.LOG2, 1, 1), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.LOG, 1, 1), new ItemStack(Blocks.LOG, 1, 0), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.LOG, 1, 2), new ItemStack(Blocks.LOG, 1, 1), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.LOG, 1, 3), new ItemStack(Blocks.LOG, 1, 2), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.LOG2, 1, 0), new ItemStack(Blocks.LOG, 1, 3), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.LOG2, 1, 1), new ItemStack(Blocks.LOG2, 1, 0), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.SPRUCE_LOG), new ItemStack(Blocks.OAK_LOG), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.BIRCH_LOG), new ItemStack(Blocks.SPRUCE_LOG), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.JUNGLE_LOG), new ItemStack(Blocks.BIRCH_LOG), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.ACACIA_LOG), new ItemStack(Blocks.JUNGLE_LOG), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DARK_OAK_LOG), new ItemStack(Blocks.ACACIA_LOG), 40));
woodRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.OAK_LOG), new ItemStack(Blocks.DARK_OAK_LOG), 40));
saplingRecipes = new ArrayList<>();
for(int i = 0; i < 6; i++)
saplingRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.SAPLING, 1, i == 5 ? 0 : i + 1), new ItemStack(Blocks.SAPLING, 1, i), 120));
saplingRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.SPRUCE_SAPLING), new ItemStack(Blocks.OAK_SAPLING), 120));
saplingRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.BIRCH_SAPLING), new ItemStack(Blocks.SPRUCE_SAPLING), 120));
saplingRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.JUNGLE_SAPLING), new ItemStack(Blocks.BIRCH_SAPLING), 120));
saplingRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.ACACIA_SAPLING), new ItemStack(Blocks.JUNGLE_SAPLING), 120));
saplingRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DARK_OAK_SAPLING), new ItemStack(Blocks.ACACIA_SAPLING), 120));
saplingRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.OAK_SAPLING), new ItemStack(Blocks.DARK_OAK_SAPLING), 120));
glowstoneDustRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.GLOWSTONE_DUST, 4), new ItemStack(Blocks.GLOWSTONE), 25);
quartzRecipes = new ArrayList<>();
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.QUARTZ, 4), new ItemStack(Blocks.QUARTZ_BLOCK, 1, Short.MAX_VALUE), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.darkQuartz, 4), new ItemStack(ModFluffBlocks.darkQuartz, 1, Short.MAX_VALUE), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.manaQuartz, 4), new ItemStack(ModFluffBlocks.manaQuartz, 1, Short.MAX_VALUE), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.blazeQuartz, 4), new ItemStack(ModFluffBlocks.blazeQuartz, 1, Short.MAX_VALUE), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.lavenderQuartz, 4), new ItemStack(ModFluffBlocks.lavenderQuartz, 1, Short.MAX_VALUE), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.redQuartz, 4), new ItemStack(ModFluffBlocks.redQuartz, 1, Short.MAX_VALUE), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.elfQuartz, 4), new ItemStack(ModFluffBlocks.elfQuartz, 1, Short.MAX_VALUE), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.QUARTZ, 4), new ItemStack(Blocks.QUARTZ_BLOCK), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.darkQuartz, 4), new ItemStack(ModFluffBlocks.darkQuartz), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.manaQuartz, 4), new ItemStack(ModFluffBlocks.manaQuartz), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.blazeQuartz, 4), new ItemStack(ModFluffBlocks.blazeQuartz), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.lavenderQuartz, 4), new ItemStack(ModFluffBlocks.lavenderQuartz), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.redQuartz, 4), new ItemStack(ModFluffBlocks.redQuartz), 25));
quartzRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(ModItems.elfQuartz, 4), new ItemStack(ModFluffBlocks.elfQuartz), 25));
chiseledBrickRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.STONEBRICK, 1, 3), new ItemStack(Blocks.STONEBRICK), 150);
chiseledBrickRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.CHISELED_STONE_BRICKS, 1), new ItemStack(Blocks.STONE_BRICKS), 150);
iceRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.ICE), new ItemStack(Blocks.SNOW), 2250);
swampFolliageRecipes = new ArrayList<>();
swampFolliageRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.WATERLILY), new ItemStack(Blocks.VINE), 320));
swampFolliageRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.VINE), new ItemStack(Blocks.WATERLILY), 320));
swampFolliageRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.LILY_PAD), new ItemStack(Blocks.VINE), 320));
swampFolliageRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.VINE), new ItemStack(Blocks.LILY_PAD), 320));
fishRecipes = new ArrayList<>();
for(int i = 0; i < 4; i++)
fishRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.FISH, 1, i == 3 ? 0 : i + 1), new ItemStack(Items.FISH, 1, i), 200));
cropRecipes = new ArrayList<>();
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.WHEAT_SEEDS), new ItemStack(Items.DYE, 1, 3), 6000));
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.WHEAT_SEEDS), new ItemStack(Items.COCOA_BEANS), 6000));
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.POTATO), new ItemStack(Items.WHEAT), 6000));
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.CARROT), new ItemStack(Items.POTATO), 6000));
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.BEETROOT_SEEDS), new ItemStack(Items.CARROT), 6000));
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.MELON_SEEDS), new ItemStack(Items.BEETROOT_SEEDS), 6000));
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.PUMPKIN_SEEDS), new ItemStack(Items.MELON_SEEDS), 6000));
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.DYE, 1, 3), new ItemStack(Items.PUMPKIN_SEEDS), 6000));
cropRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.COCOA_BEANS), new ItemStack(Items.PUMPKIN_SEEDS), 6000));
potatoRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.POTATO), new ItemStack(Items.POISONOUS_POTATO), 1200);
netherWartRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.NETHER_WART), new ItemStack(Items.BLAZE_ROD), 4000);
@@ -123,43 +127,43 @@ public final class ModManaAlchemyRecipes {
redstoneToGlowstoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.REDSTONE), new ItemStack(Items.GLOWSTONE_DUST), 300));
redstoneToGlowstoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.GLOWSTONE_DUST), new ItemStack(Items.REDSTONE), 300));
sandRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Block.getBlockFromName("sand")), new ItemStack(Blocks.COBBLESTONE), 50);
redSandRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Block.getBlockFromName("sand"), 1, 1), new ItemStack(Blocks.HARDENED_CLAY), 50);
sandRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.SAND), new ItemStack(Blocks.COBBLESTONE), 50);
redSandRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_SAND), new ItemStack(Blocks.TERRACOTTA), 50);
clayBreakdownRecipes = new ArrayList<>();
clayBreakdownRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.CLAY_BALL, 4), new ItemStack(Blocks.CLAY), 25));
clayBreakdownRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.BRICK, 4), new ItemStack(Blocks.BRICK_BLOCK), 25));
clayBreakdownRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Items.BRICK, 4), new ItemStack(Blocks.BRICKS), 25));
coarseDirtRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DIRT, 1, 1), new ItemStack(Blocks.DIRT), 120);
coarseDirtRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.COARSE_DIRT), new ItemStack(Blocks.DIRT), 120);
stoneRecipes = new ArrayList<>();
stoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.STONE, 1, 5), new ItemStack(Blocks.STONE), 200)); // Stone->Andesite
stoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.STONE, 1, 3), new ItemStack(Blocks.STONE, 1, 5), 200)); // Andesite->Diorite
stoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.STONE, 1, 1), new ItemStack(Blocks.STONE, 1, 3), 200)); // Diorite->Granite
stoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.STONE, 1, 5), new ItemStack(Blocks.STONE, 1, 1), 200)); // Granite->Andesite
stoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.ANDESITE), new ItemStack(Blocks.STONE), 200));
stoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DIORITE), new ItemStack(Blocks.ANDESITE), 200));
stoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.GRANITE), new ItemStack(Blocks.DIORITE), 200));
stoneRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.ANDESITE), new ItemStack(Blocks.GRANITE), 200));
tallgrassRecipes = new ArrayList<>();
tallgrassRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DEADBUSH), new ItemStack(Blocks.TALLGRASS, 1, 2), 500));
tallgrassRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.TALLGRASS, 1, 1), new ItemStack(Blocks.DEADBUSH), 500));
tallgrassRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.TALLGRASS, 1, 2), new ItemStack(Blocks.TALLGRASS, 1, 1), 500));
tallgrassRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DEAD_BUSH), new ItemStack(Blocks.FERN), 500));
tallgrassRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.GRASS), new ItemStack(Blocks.DEAD_BUSH), 500));
tallgrassRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.FERN), new ItemStack(Blocks.GRASS), 500));
flowersRecipes = new ArrayList<>();
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER), new ItemStack(Blocks.YELLOW_FLOWER), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER, 1, 1), new ItemStack(Blocks.RED_FLOWER), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER, 1, 2), new ItemStack(Blocks.RED_FLOWER, 1, 1), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER, 1, 3), new ItemStack(Blocks.RED_FLOWER, 1, 2), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER, 1, 4), new ItemStack(Blocks.RED_FLOWER, 1, 3), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER, 1, 5), new ItemStack(Blocks.RED_FLOWER, 1, 4), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER, 1, 6), new ItemStack(Blocks.RED_FLOWER, 1, 5), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER, 1, 7), new ItemStack(Blocks.RED_FLOWER, 1, 6), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_FLOWER, 1, 8), new ItemStack(Blocks.RED_FLOWER, 1, 7), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DOUBLE_PLANT), new ItemStack(Blocks.RED_FLOWER, 1, 8), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DOUBLE_PLANT, 1, 1), new ItemStack(Blocks.DOUBLE_PLANT), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DOUBLE_PLANT, 1, 4), new ItemStack(Blocks.DOUBLE_PLANT, 1, 1), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DOUBLE_PLANT, 1, 5), new ItemStack(Blocks.DOUBLE_PLANT, 1, 4), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.YELLOW_FLOWER), new ItemStack(Blocks.DOUBLE_PLANT, 1, 5), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.POPPY), new ItemStack(Blocks.DANDELION), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.BLUE_ORCHID), new ItemStack(Blocks.POPPY), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.ALLIUM), new ItemStack(Blocks.BLUE_ORCHID), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.AZURE_BLUET), new ItemStack(Blocks.ALLIUM), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.RED_TULIP), new ItemStack(Blocks.AZURE_BLUET), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.ORANGE_TULIP), new ItemStack(Blocks.RED_TULIP), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.WHITE_TULIP), new ItemStack(Blocks.ORANGE_TULIP), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.PINK_TULIP), new ItemStack(Blocks.WHITE_TULIP), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.OXEYE_DAISY), new ItemStack(Blocks.PINK_TULIP), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.SUNFLOWER), new ItemStack(Blocks.OXEYE_DAISY), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.LILAC), new ItemStack(Blocks.SUNFLOWER), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.ROSE_BUSH), new ItemStack(Blocks.LILAC), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.PEONY), new ItemStack(Blocks.ROSE_BUSH), 400));
flowersRecipes.add(BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.DANDELION), new ItemStack(Blocks.PEONY), 400));
chorusRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.CHORUS_FLOWER), new ItemStack(Items.CHORUS_FRUIT_POPPED), 10000);
chorusRecipe = BotaniaAPI.registerManaAlchemyRecipe(new ItemStack(Blocks.CHORUS_FLOWER), new ItemStack(Items.POPPED_CHORUS_FRUIT), 10000);
if(Botania.gardenOfGlassLoaded) {
prismarineRecipes = new ArrayList<>();
@@ -41,15 +41,17 @@ public class ModManaConjurationRecipes {
snowballRecipe = BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Items.SNOWBALL, 2), new ItemStack(Items.SNOWBALL), 200);
netherrackRecipe = BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.NETHERRACK, 2), new ItemStack(Blocks.NETHERRACK), 200);
soulSandRecipe = BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.SOUL_SAND, 2), new ItemStack(Blocks.SOUL_SAND), 1500);
gravelRecipe = BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Block.getBlockFromName("gravel"), 2), new ItemStack(Block.getBlockFromName("gravel")), 720);
gravelRecipe = BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.GRAVEL, 2), new ItemStack(Blocks.GRAVEL), 720);
leavesRecipes = new ArrayList<>();
for(int i = 0; i < 4; i++)
leavesRecipes.add(BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.LEAVES, 2, i), new ItemStack(Blocks.LEAVES, 1, i), 2000));
for(int i = 0; i < 2; i++)
leavesRecipes.add(BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.LEAVES2, 2, i), new ItemStack(Blocks.LEAVES2, 1, i), 2000));
leavesRecipes.add(BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.OAK_LEAVES, 2), new ItemStack(Blocks.OAK_LEAVES), 2000));
leavesRecipes.add(BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.BIRCH_LEAVES, 2), new ItemStack(Blocks.BIRCH_LEAVES), 2000));
leavesRecipes.add(BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.SPRUCE_LEAVES, 2), new ItemStack(Blocks.SPRUCE_LEAVES), 2000));
leavesRecipes.add(BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.JUNGLE_LEAVES, 2), new ItemStack(Blocks.JUNGLE_LEAVES), 2000));
leavesRecipes.add(BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.ACACIA_LEAVES, 2), new ItemStack(Blocks.ACACIA_LEAVES), 2000));
leavesRecipes.add(BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.DARK_OAK_LEAVES, 2), new ItemStack(Blocks.DARK_OAK_LEAVES), 2000));
grassRecipe = BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.TALLGRASS, 2, 1), new ItemStack(Blocks.TALLGRASS, 1, 1), 800);
grassRecipe = BotaniaAPI.registerManaConjurationRecipe(new ItemStack(Blocks.GRASS), new ItemStack(Blocks.GRASS), 800);
}
}
@@ -15,6 +15,7 @@ import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.registry.IRegistry;
import vazkii.botania.api.BotaniaAPI;
import vazkii.botania.api.recipe.RecipeManaInfusion;
import vazkii.botania.common.Botania;
@@ -64,8 +65,8 @@ public final class ModManaInfusionRecipes {
pistonRelayRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModBlocks.pistonRelay), new ItemStack(Blocks.PISTON), 15000);
manaCookieRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.manaCookie), new ItemStack(Items.COOKIE), 20000);
grassSeedsRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.grassSeeds), new ItemStack(Blocks.TALLGRASS, 1, 1), 2500);
podzolSeedsRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.podzolSeeds), new ItemStack(Blocks.DEADBUSH), 2500);
grassSeedsRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.grassSeeds), new ItemStack(Blocks.GRASS), 2500);
podzolSeedsRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.podzolSeeds), new ItemStack(Blocks.DEAD_BUSH), 2500);
mycelSeedsRecipes = new ArrayList<>();
mycelSeedsRecipes.add(BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.mycelSeeds), new ItemStack(Blocks.RED_MUSHROOM), 6500));
@@ -75,8 +76,8 @@ public final class ModManaInfusionRecipes {
tinyPotatoRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModBlocks.tinyPotato), new ItemStack(Items.POTATO), 1337);
if(Botania.thaumcraftLoaded) {
Item inkwell = Item.REGISTRY.getObject(new ResourceLocation("thaumcraft", "scribing_tools"));
manaInkwellRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.manaInkwell, 1, ModItems.manaInkwell.getMaxDamage()), new ItemStack(inkwell), 35000);
Item inkwell = IRegistry.ITEM.get(new ResourceLocation("thaumcraft", "scribing_tools"));
manaInkwellRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.manaInkwell), new ItemStack(inkwell), 35000);
}
managlassRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModBlocks.manaGlass), new ItemStack(Blocks.GLASS), 150);
@@ -12,7 +12,6 @@ package vazkii.botania.common.crafting;
import net.minecraft.init.Items;
import net.minecraft.item.ItemStack;
import scala.runtime.RichDouble;
import vazkii.botania.api.BotaniaAPI;
import vazkii.botania.api.recipe.RecipePetals;
import vazkii.botania.common.Botania;
@@ -77,7 +77,7 @@ public final class ModRuneRecipes {
recipeEnvyRune = BotaniaAPI.registerRuneAltarRecipe(new ItemStack(ModItems.runeEnvy), costTier3, LibOreDict.MANA_DIAMOND, LibOreDict.MANA_DIAMOND, LibOreDict.RUNE[7], LibOreDict.RUNE[0]);
recipePrideRune = BotaniaAPI.registerRuneAltarRecipe(new ItemStack(ModItems.runePride), costTier3, LibOreDict.MANA_DIAMOND, LibOreDict.MANA_DIAMOND, LibOreDict.RUNE[5], LibOreDict.RUNE[1]);
recipeHead = new HeadRecipe(new ItemStack(Items.PLAYER_HEAD), 22500, new ItemStack(Items.SKULL), LibOreDict.PIXIE_DUST, "gemPrismarine", new ItemStack(Items.NAME_TAG), new ItemStack(Items.GOLDEN_APPLE));
recipeHead = new HeadRecipe(new ItemStack(Items.PLAYER_HEAD), 22500, new ItemStack(Items.SKELETON_SKULL), LibOreDict.PIXIE_DUST, "gemPrismarine", new ItemStack(Items.NAME_TAG), new ItemStack(Items.GOLDEN_APPLE));
BotaniaAPI.runeAltarRecipes.add(recipeHead);
}
}
@@ -312,9 +312,9 @@ public class EntityCorporeaSpark extends Entity implements ICorporeaSpark {
@Override
protected void writeAdditional(@Nonnull NBTTagCompound cmp) {
cmp.setBoolean(TAG_MASTER, isMaster());
cmp.setInt(TAG_NETWORK, getNetwork().getId());
cmp.setInt(TAG_INVIS, isInvisible() ? 1 : 0);
cmp.putBoolean(TAG_MASTER, isMaster());
cmp.putInt(TAG_NETWORK, getNetwork().getId());
cmp.putInt(TAG_INVIS, isInvisible() ? 1 : 0);
}
}
@@ -15,7 +15,6 @@ import net.minecraft.block.Block;
import net.minecraft.block.state.IBlockState;
import net.minecraft.client.Minecraft;
import net.minecraft.client.audio.MovingSound;
import net.minecraft.client.gui.ScaledResolution;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.client.renderer.texture.TextureMap;
import net.minecraft.entity.*;
@@ -41,7 +40,6 @@ import net.minecraft.potion.PotionEffect;
import net.minecraft.tileentity.TileEntityBeacon;
import net.minecraft.util.DamageSource;
import net.minecraft.util.EnumFacing;
import net.minecraft.util.EnumParticleTypes;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.SoundCategory;
import net.minecraft.util.math.AxisAlignedBB;
@@ -149,7 +147,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
private boolean hardMode = false;
private BlockPos source = BlockPos.ORIGIN;
private final List<UUID> playersWhoAttacked = new ArrayList<>();
private final BossInfoServer bossInfo = (BossInfoServer) new BossInfoServer(new TextComponentTranslation("entity." + LibEntityNames.DOPPLEGANGER_REGISTRY + ".name"), BossInfo.Color.PINK, BossInfo.Overlay.PROGRESS).setCreateFog(true);;
private final BossInfoServer bossInfo = (BossInfoServer) new BossInfoServer(TYPE.func_212546_e(), BossInfo.Color.PINK, BossInfo.Overlay.PROGRESS).setCreateFog(true);;
private UUID bossInfoUUID = bossInfo.getUniqueId();
public EntityPlayer trueKiller = null;
@@ -268,7 +266,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
pos = beaconPos.add(x, y, z);
boolean expectedBlockHere = y == -1; //the floor
boolean isBlockHere = world.getBlockState(pos).getCollisionBoundingBox(world, pos) != null;
boolean isBlockHere = !world.getBlockState(pos).getCollisionShape(world, pos).isEmpty();
if(expectedBlockHere != isBlockHere) {
trippedPositions.add(pos);
@@ -286,8 +284,8 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
}
@Override
protected void entityInit() {
super.entityInit();
protected void registerData() {
super.registerData();
dataManager.register(INVUL_TIME, 0);
}
@@ -416,7 +414,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
}
playSound(SoundEvents.ENTITY_GENERIC_EXPLODE, 20F, (1F + (world.rand.nextFloat() - world.rand.nextFloat()) * 0.2F) * 0.7F);
world.spawnParticle(Particles.EXPLOSION_EMITTER, posX, posY, posZ, 1D, 0D, 0D);
world.addParticle(Particles.EXPLOSION_EMITTER, posX, posY, posZ, 1D, 0D, 0D);
}
@Override
@@ -428,7 +426,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
}
@Override
protected boolean canDespawn() {
public boolean canDespawn() {
return false;
}
@@ -840,8 +838,8 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
setPositionAndUpdate(newX, newY, newZ);
//play sound
world.playSound(null, oldX, oldY, oldZ, SoundEvents.ENTITY_ENDERMEN_TELEPORT, this.getSoundCategory(), 1.0F, 1.0F);
this.playSound(SoundEvents.ENTITY_ENDERMEN_TELEPORT, 1.0F, 1.0F);
world.playSound(null, oldX, oldY, oldZ, SoundEvents.ENTITY_ENDERMAN_TELEPORT, this.getSoundCategory(), 1.0F, 1.0F);
this.playSound(SoundEvents.ENTITY_ENDERMAN_TELEPORT, 1.0F, 1.0F);
Random random = getRNG();
@@ -855,7 +853,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
double px = oldX + (newX - oldX) * progress + (random.nextDouble() - 0.5D) * width * 2.0D;
double py = oldY + (newY - oldY) * progress + random.nextDouble() * height;
double pz = oldZ + (newZ - oldZ) * progress + (random.nextDouble() - 0.5D) * width * 2.0D;
world.spawnParticle(EnumParticleTypes.PORTAL, px, py, pz, vx, vy, vz);
world.addParticle(Particles.PORTAL, px, py, pz, vx, vy, vz);
}
Vec3d oldPosVec = new Vec3d(oldX, oldY + height / 2, oldZ);
@@ -864,7 +862,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
if(oldPosVec.squareDistanceTo(newPosVec) > 1) {
//damage players in the path of the teleport
for(EntityPlayer player : getPlayersAround()) {
RayTraceResult rtr = player.getEntityBoundingBox().grow(0.25).calculateIntercept(oldPosVec, newPosVec);
RayTraceResult rtr = player.getBoundingBox().grow(0.25).calculateIntercept(oldPosVec, newPosVec);
if(rtr != null)
player.attackEntityFrom(DamageSource.causeMobDamage(this), 6);
}
@@ -926,10 +924,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
mc.getItemRenderer().renderItemIntoGUI(stack, px, py);
net.minecraft.client.renderer.RenderHelper.disableStandardItemLighting();
boolean unicode = mc.fontRenderer.getUnicodeFlag();
mc.fontRenderer.setUnicodeFlag(true);
mc.fontRenderer.drawStringWithShadow("" + playerCount, px + 15, py + 4, 0xFFFFFF);
mc.fontRenderer.setUnicodeFlag(unicode);
GlStateManager.popMatrix();
return 5;
@@ -968,7 +963,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
}
@Override
public void writeSpawnData(ByteBuf buffer) {
public void writeSpawnData(PacketBuffer buffer) {
buffer.writeInt(playerCount);
buffer.writeBoolean(hardMode);
buffer.writeLong(source.toLong());
@@ -1017,7 +1012,7 @@ public class EntityDoppleganger extends EntityLiving implements IBotaniaBoss, IE
@Override
public boolean matches(World world, BlockPos pos) {
return world.getBlockState(pos).getBlock().isBeaconBase(world, pos, pos.add(new BlockPos(-relPos.getX(), -relPos.getY(), -relPos.getZ())));
return world.getBlockState(pos).isBeaconBase(world, pos, pos.add(new BlockPos(-relPos.getX(), -relPos.getY(), -relPos.getZ())));
}
}
@@ -26,9 +26,11 @@ import net.minecraft.block.BlockBush;
import net.minecraft.block.BlockLeaves;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityType;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.projectile.EntityThrowable;
import net.minecraft.init.Blocks;
import net.minecraft.init.Particles;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.network.datasync.DataParameter;
@@ -44,6 +46,7 @@ import net.minecraft.util.math.Vec3d;
import net.minecraft.world.World;
import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.api.distmarker.OnlyIn;
import net.minecraftforge.registries.ObjectHolder;
import vazkii.botania.api.BotaniaAPI;
import vazkii.botania.api.internal.IManaBurst;
import vazkii.botania.api.internal.VanillaPacketDispatcher;
@@ -60,9 +63,11 @@ import vazkii.botania.common.Botania;
import vazkii.botania.common.core.handler.ConfigHandler;
import vazkii.botania.common.core.helper.Vector3;
import vazkii.botania.common.item.equipment.bauble.ItemTinyPlanet;
import vazkii.botania.common.lib.LibMisc;
public class EntityManaBurst extends EntityThrowable implements IManaBurst {
@ObjectHolder(LibMisc.MOD_ID + ":mana_burst")
public static EntityType<EntityManaBurst> TYPE;
private static final String TAG_TICKS_EXISTED = "ticksExisted";
private static final String TAG_COLOR = "color";
private static final String TAG_MANA = "mana";
@@ -100,7 +105,7 @@ public class EntityManaBurst extends EntityThrowable implements IManaBurst {
public final List<PositionProperties> propsList = new ArrayList<>();
public EntityManaBurst(World world) {
super(world);
super(TYPE, world);
setSize(0F, 0F);
}
@@ -154,67 +159,59 @@ public class EntityManaBurst extends EntityThrowable implements IManaBurst {
setMotion(mx, my, mz);
}
// Copy of EntityThrowable.onUpdate. Relevant edits indicated.
private void superUpdate() {
lastTickPosX = posX;
lastTickPosY = posY;
lastTickPosZ = posZ;
// super.onUpdate(); Botania - inline supersuperclass's onUpdate
this.lastTickPosX = this.posX;
this.lastTickPosY = this.posY;
this.lastTickPosZ = this.posZ;
// Botania - inline supersuperclass.tick()
{
if (!world.isRemote)
{
setFlag(6, isGlowing());
if (!this.world.isRemote) {
this.setFlag(6, this.isGlowing());
}
baseTick();
this.baseTick();
}
if (this.throwableShake > 0) {
--this.throwableShake;
}
if (throwableShake > 0)
{
--throwableShake;
if (this.inGround) {
this.inGround = false;
this.motionX *= (double)(this.rand.nextFloat() * 0.2F);
this.motionY *= (double)(this.rand.nextFloat() * 0.2F);
this.motionZ *= (double)(this.rand.nextFloat() * 0.2F);
}
// Botania - remove inGround check and its else branch. Bursts are never inGround.
Vec3d vec3d = new Vec3d(posX, posY, posZ);
Vec3d vec3d1 = new Vec3d(posX + motionX, posY + motionY, posZ + motionZ);
RayTraceResult raytraceresult = world.rayTraceBlocks(vec3d, vec3d1);
vec3d = new Vec3d(posX, posY, posZ);
vec3d1 = new Vec3d(posX + motionX, posY + motionY, posZ + motionZ);
if (raytraceresult != null)
{
Vec3d vec3d = new Vec3d(this.posX, this.posY, this.posZ);
Vec3d vec3d1 = new Vec3d(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
RayTraceResult raytraceresult = this.world.rayTraceBlocks(vec3d, vec3d1);
vec3d = new Vec3d(this.posX, this.posY, this.posZ);
vec3d1 = new Vec3d(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
if (raytraceresult != null) {
vec3d1 = new Vec3d(raytraceresult.hitVec.x, raytraceresult.hitVec.y, raytraceresult.hitVec.z);
}
if(!scanBeam && !world.isRemote) { // Botania - only do entity colliding on server and while not scanning
if (!scanBeam && !world.isRemote) { // Botania - collide only on server and non-scanbeam
Entity entity = null;
List<Entity> list = world.getEntitiesWithinAABBExcludingEntity(this, getEntityBoundingBox().offset(motionX, motionY, motionZ).grow(1.0D));
List<Entity> list = this.world.getEntitiesWithinAABBExcludingEntity(this, this.getBoundingBox().expand(this.motionX, this.motionY, this.motionZ).grow(1.0D));
double d0 = 0.0D;
for (int i = 0; i < list.size(); ++i)
{
boolean flag = false;
for (int i = 0; i < list.size(); ++i) {
Entity entity1 = list.get(i);
if (entity1.canBeCollidedWith())
{
if (entity1 == ignoreEntity)
{
}
else if (ticksExisted < 2 && ignoreEntity == null)
{
ignoreEntity = entity1;
}
else
{
AxisAlignedBB axisalignedbb = entity1.getBoundingBox().grow(0.30000001192092896D);
if (entity1.canBeCollidedWith()) {
if (entity1 == this.ignoreEntity) {
flag = true;
} else if (this.thrower != null && this.ticksExisted < 2 && this.ignoreEntity == null) {
this.ignoreEntity = entity1;
flag = true;
} else {
flag = false;
AxisAlignedBB axisalignedbb = entity1.getBoundingBox().grow((double) 0.3F);
RayTraceResult raytraceresult1 = axisalignedbb.calculateIntercept(vec3d, vec3d1);
if (raytraceresult1 != null)
{
if (raytraceresult1 != null) {
double d1 = vec3d.squareDistanceTo(raytraceresult1.hitVec);
if (d1 < d0 || d0 == 0.0D)
{
if (d1 < d0 || d0 == 0.0D) {
entity = entity1;
d0 = d1;
}
@@ -223,83 +220,74 @@ public class EntityManaBurst extends EntityThrowable implements IManaBurst {
}
}
if (ignoreEntity != null)
{
/*if (flag)
{
this.ignoreTime = 2;
}
else if (this.ignoreTime-- <= 0)
{
this.ignoreEntity = null;
}*/
if (this.ignoreEntity != null) {
/*
if (flag) {
this.ignoreTime = 2;
} else if (this.ignoreTime-- <= 0) {
this.ignoreEntity = null;
}
*/
}
if (entity != null)
{
if (entity != null) {
raytraceresult = new RayTraceResult(entity);
}
} // End wrap - only do entity colliding on server
if (raytraceresult != null)
{
if (raytraceresult.type == RayTraceResult.Type.BLOCK && world.getBlockState(raytraceresult.getBlockPos()).getBlock() == Blocks.NETHER_PORTAL)
{
setPortal(raytraceresult.getBlockPos());
}
else
{
onImpact(raytraceresult);
}
}
posX += motionX;
posY += motionY;
posZ += motionZ;
float f = MathHelper.sqrt(motionX * motionX + motionZ * motionZ);
rotationYaw = (float)(MathHelper.atan2(motionX, motionZ) * (180D / Math.PI));
if (raytraceresult != null) {
if (raytraceresult.type == RayTraceResult.Type.BLOCK && this.world.getBlockState(raytraceresult.getBlockPos()).getBlock() == Blocks.NETHER_PORTAL) {
this.setPortal(raytraceresult.getBlockPos());
} else if (!net.minecraftforge.event.ForgeEventFactory.onProjectileImpact(this, raytraceresult)){
this.onImpact(raytraceresult);
}
}
for (rotationPitch = (float)(MathHelper.atan2(motionY, f) * (180D / Math.PI)); rotationPitch - prevRotationPitch < -180.0F; prevRotationPitch -= 360.0F)
{
this.posX += this.motionX;
this.posY += this.motionY;
this.posZ += this.motionZ;
float f = MathHelper.sqrt(this.motionX * this.motionX + this.motionZ * this.motionZ);
this.rotationYaw = (float)(MathHelper.atan2(this.motionX, this.motionZ) * (double)(180F / (float)Math.PI));
for(this.rotationPitch = (float)(MathHelper.atan2(this.motionY, (double)f) * (double)(180F / (float)Math.PI)); this.rotationPitch - this.prevRotationPitch < -180.0F; this.prevRotationPitch -= 360.0F) {
;
}
while (rotationPitch - prevRotationPitch >= 180.0F)
{
prevRotationPitch += 360.0F;
while(this.rotationPitch - this.prevRotationPitch >= 180.0F) {
this.prevRotationPitch += 360.0F;
}
while (rotationYaw - prevRotationYaw < -180.0F)
{
prevRotationYaw -= 360.0F;
while(this.rotationYaw - this.prevRotationYaw < -180.0F) {
this.prevRotationYaw -= 360.0F;
}
while (rotationYaw - prevRotationYaw >= 180.0F)
{
prevRotationYaw += 360.0F;
while(this.rotationYaw - this.prevRotationYaw >= 180.0F) {
this.prevRotationYaw += 360.0F;
}
rotationPitch = prevRotationPitch + (rotationPitch - prevRotationPitch) * 0.2F;
rotationYaw = prevRotationYaw + (rotationYaw - prevRotationYaw) * 0.2F;
float f2 = getGravityVelocity();
// Botania - don't do water particles, bursts are never inWater
/*
if (isInWater())
{
for (int j = 0; j < 4; ++j)
{
this.rotationPitch = this.prevRotationPitch + (this.rotationPitch - this.prevRotationPitch) * 0.2F;
this.rotationYaw = this.prevRotationYaw + (this.rotationYaw - this.prevRotationYaw) * 0.2F;
float f1 = 0.99F;
float f2 = this.getGravityVelocity();
if (this.isInWater()) {
for(int j = 0; j < 4; ++j) {
float f3 = 0.25F;
world.spawnParticle(EnumParticleTypes.WATER_BUBBLE, posX - motionX * f3, posY - motionY * f3, posZ - motionZ * f3, motionX, motionY, motionZ, new int[0]);
this.world.addParticle(Particles.BUBBLE, this.posX - this.motionX * 0.25D, this.posY - this.motionY * 0.25D, this.posZ - this.motionZ * 0.25D, this.motionX, this.motionY, this.motionZ);
}
}*/
// Botania - don't apply drag
// this.motionX *= (double)f1;
// this.motionY *= (double)f1;
// this.motionZ *= (double)f1;
motionY -= f2;
setPosition(posX, posY, posZ);
f1 = 0.8F;
}
/* Botania - no drag
this.motionX *= (double)f1;
this.motionY *= (double)f1;
this.motionZ *= (double)f1;
*/
if (!this.hasNoGravity()) {
this.motionY -= (double)f2;
}
this.setPosition(this.posX, this.posY, this.posZ);
}
@Override
@@ -322,7 +310,7 @@ public class EntityManaBurst extends EntityThrowable implements IManaBurst {
accumulatedManaLoss -= loss;
if(getMana() <= 0)
setDead();
remove();
}
particles();
@@ -596,7 +584,7 @@ public class EntityManaBurst extends EntityThrowable implements IManaBurst {
Botania.proxy.sparkleFX((float) posX, (float) posY, (float) posZ, r, g, b, 4, 2);
}
setDead();
remove();
}
}
@@ -1,3 +1,4 @@
/*
package vazkii.botania.common.integration.buildcraft;
import java.util.Collection;
@@ -55,3 +56,4 @@ public class StatementAPIPlugin implements ITriggerProvider {
triggers.add(triggerRuneAltarCanCraft);
}
}
*/
@@ -1,3 +1,4 @@
/*
package vazkii.botania.common.integration.buildcraft;
import buildcraft.api.statements.IStatement;
@@ -29,3 +30,4 @@ public abstract class StatementBase implements IStatement {
return new IStatement[] { this };
}
}
*/
@@ -1,3 +1,4 @@
/*
package vazkii.botania.common.integration.buildcraft;
import buildcraft.api.core.render.ISprite;
@@ -5,9 +6,11 @@ import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.texture.TextureAtlasSprite;
import net.minecraft.client.renderer.texture.TextureMap;
*/
/**
* Adapts Minecraft TAS to buildcraft ISprite
*/
*//*
public class TASprite implements ISprite {
private final TextureAtlasSprite sprite;
@@ -30,3 +33,4 @@ public class TASprite implements ISprite {
return sprite.getInterpolatedV(v * 16);
}
}
*/
@@ -1,3 +1,4 @@
/*
package vazkii.botania.common.integration.buildcraft;
import buildcraft.api.core.render.ISprite;
@@ -51,3 +52,4 @@ public class TriggerManaDetector extends StatementBase implements ITriggerIntern
}
}
*/
@@ -1,3 +1,4 @@
/*
package vazkii.botania.common.integration.buildcraft;
import buildcraft.api.core.render.ISprite;
@@ -72,3 +73,4 @@ public class TriggerManaLevel extends StatementBase implements ITriggerExternal
};
}
}
*/
@@ -1,3 +1,4 @@
/*
package vazkii.botania.common.integration.buildcraft;
import buildcraft.api.core.render.ISprite;
@@ -40,3 +41,4 @@ public class TriggerRuneAltarCanCraft extends StatementBase implements ITriggerE
}
}
*/
@@ -1,72 +0,0 @@
/**
* This class was created by <Vazkii>. It's distributed as
* part of the Botania Mod. Get the Source Code in github:
* https://github.com/Vazkii/Botania
*
* Botania is Open Source and distributed under the
* Botania License: http://botaniamod.net/license.php
*
* File Created @ [Sep 1, 2015, 5:32:15 PM (GMT)]
*//*
package vazkii.botania.common.integration.multipart;
import java.util.ArrayList;
import java.util.List;
import net.minecraft.block.Block;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import vazkii.botania.common.block.ModBlocks;
import vazkii.botania.common.block.ModFluffBlocks;
import codechicken.microblock.BlockMicroMaterial;
import codechicken.microblock.MicroMaterialRegistry;
public class MultipartHandler {
public MultipartHandler() {
registerMultiparts(ModBlocks.livingrock, 0, 4);
registerMultiparts(ModBlocks.livingwood, 0, 5);
registerMultiparts(ModBlocks.storage, 0, 4);
registerMultiparts(ModBlocks.dreamwood, 0, 4);
registerMultiparts(ModBlocks.prismarine, 0, 2);
registerMultiparts(ModBlocks.seaLamp);
registerMultiparts(ModBlocks.reedBlock);
registerMultiparts(ModBlocks.thatch);
registerMultiparts(ModBlocks.customBrick, 0, 15);
registerMultiparts(ModBlocks.elfGlass);
registerMultiparts(ModBlocks.manaGlass);
registerMultiparts(ModBlocks.endStoneBrick, 0, 3);
registerMultiparts(ModBlocks.blazeBlock);
registerMultiparts(ModBlocks.bifrostPerm);
registerMultiparts(ModBlocks.shimmerrock);
registerMultiparts(ModBlocks.shimmerwoodPlanks);
registerMultiparts(ModFluffBlocks.darkQuartz, 0, 2);
registerMultiparts(ModFluffBlocks.manaQuartz, 0, 2);
registerMultiparts(ModFluffBlocks.blazeQuartz, 0, 2);
registerMultiparts(ModFluffBlocks.lavenderQuartz, 0, 2);
registerMultiparts(ModFluffBlocks.redQuartz, 0, 2);
registerMultiparts(ModFluffBlocks.elfQuartz, 0, 2);
registerMultiparts(ModFluffBlocks.sunnyQuartz, 0, 2);
registerMultiparts(ModFluffBlocks.biomeStoneA, 0, 15);
registerMultiparts(ModFluffBlocks.biomeStoneB, 0, 15);
registerMultiparts(ModFluffBlocks.stone, 0, 15);
registerMultiparts(ModFluffBlocks.pavement, 0, 5);
}
private static void registerMultiparts(Block block) {
registerMultiparts(block, 0);
}
private static void registerMultiparts(Block block, int meta) {
MicroMaterialRegistry.registerMaterial(new BlockMicroMaterial(block, meta), block.getUnlocalizedName() + (meta == 0 ? "" : "_" + meta));
}
private static void registerMultiparts(Block block, int metamin, int metamax) {
for (int i = metamin; i <= metamax; i++) {
registerMultiparts(block, i);
}
}
}*/
@@ -74,7 +74,7 @@ public class PacketBotaniaEffect {
switch (message.type) {
case PAINT_LENS: {
EnumDyeColor placeColor = EnumDyeColor.byId(message.args[0]);
int hex = placeColor.getColorValue();
int hex = placeColor.colorValue;
int r = (hex & 0xFF0000) >> 16;
int g = (hex & 0xFF00) >> 8;
int b = hex & 0xFF;
@@ -103,7 +103,7 @@ public class PacketBotaniaEffect {
case ITEM_SMOKE: {
Entity item = world.getEntityByID(message.args[0]);
if (item == null) return;
int p = message.args[1];
for(int i = 0; i < p; i++) {
@@ -42,7 +42,7 @@ public class PacketDodge {
IItemHandler baublesInv = BaublesApi.getBaublesHandler(player);
int slot = BaublesApi.isBaubleEquipped(player, ModItems.dodgeRing);
if(slot < 0) {
ctx.get().getSender().connection.disconnect(new TextComponentTranslation("botaniamisc.invalidDodge"));
player.connection.disconnect(new TextComponentTranslation("botaniamisc.invalidDodge"));
return;
}
ItemStack ringStack = baublesInv.getStackInSlot(slot);
@@ -146,7 +146,7 @@ public final class SkyblockWorldEvents {
if(player instanceof EntityPlayerMP) {
EntityPlayerMP pmp = (EntityPlayerMP) player;
pmp.setPositionAndUpdate(pos.getX() + 0.5, pos.getY() + 1.6, pos.getZ() + 0.5);
pmp.setSpawnPoint(pos, true, player.world.getDimension().getId());
pmp.setSpawnPoint(pos, true, player.world.getDimension().getType());
player.inventory.addItemStackToInventory(new ItemStack(ModItems.lexicon));
}
@@ -10,11 +10,19 @@
*/
package vazkii.botania.common.world;
import net.minecraft.init.Biomes;
import net.minecraft.init.Blocks;
import net.minecraft.server.MinecraftServer;
import net.minecraft.world.World;
import net.minecraft.world.WorldServer;
import net.minecraft.world.WorldType;
import net.minecraft.world.biome.provider.BiomeProvider;
import net.minecraft.world.biome.provider.BiomeProviderType;
import net.minecraft.world.biome.provider.SingleBiomeProviderSettings;
import net.minecraft.world.gen.ChunkGeneratorFlat;
import net.minecraft.world.gen.ChunkGeneratorType;
import net.minecraft.world.gen.FlatGenSettings;
import net.minecraft.world.gen.FlatLayerInfo;
import net.minecraft.world.gen.IChunkGenerator;
import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.api.distmarker.OnlyIn;
@@ -38,16 +46,6 @@ public class WorldTypeSkyblock extends WorldType {
return true;
}
@Override
public int getMinimumSpawnHeight(@Nonnull World world) {
return 86;
}
@Override
public int getSpawnFuzz(@Nonnull WorldServer world, MinecraftServer server) {
return 0;
}
@Override
public float getCloudHeight() {
return 260f;
@@ -55,10 +53,17 @@ public class WorldTypeSkyblock extends WorldType {
@Nonnull
@Override
public IChunkGenerator getChunkGenerator(@Nonnull World world, String generatorOptions) {
ChunkGeneratorFlat flat = new ChunkGeneratorFlat(world, world.getSeed(), false, "3;minecraft:air;");
public IChunkGenerator<?> createChunkGenerator(@Nonnull World world) {
world.setSeaLevel(64);
return flat;
FlatGenSettings settings = new FlatGenSettings();
settings.setBiome(Biomes.PLAINS);
settings.getFlatLayers().add(new FlatLayerInfo(1, Blocks.AIR));
settings.updateLayers();
BiomeProvider biomeProvider = BiomeProviderType.FIXED.create(BiomeProviderType.FIXED.createSettings().setBiome(settings.getBiome()));
return ChunkGeneratorType.FLAT.create(world, biomeProvider, settings);
}
/* In skyblock worlds, do not darken the sky until player hits y=0 */