diff --git a/build.properties b/build.properties index cff894589..d52816bcc 100644 --- a/build.properties +++ b/build.properties @@ -1,5 +1,5 @@ # -#Tue Jun 13 14:30:58 BST 2017 +#Sat Jul 15 14:52:56 BST 2017 mod_name=Botania cf_meta_version=1.12 forge_version=14.21.1.2419 @@ -7,5 +7,5 @@ dir_repo=./ mc_mappings=snapshot_20170624 version=r1.9 dir_output=../Build Output/Botania/ -build_number=345 +build_number=346 mc_version=1.12 diff --git a/contributors.properties b/contributors.properties index e47896730..63f07e05c 100644 --- a/contributors.properties +++ b/contributors.properties @@ -83,3 +83,4 @@ creeper_in_black=2 egoisticalgoat=6 konotyran=12 rosareven=14 +xanderwolf4=11 diff --git a/src/main/java/vazkii/botania/client/core/handler/MiscellaneousIcons.java b/src/main/java/vazkii/botania/client/core/handler/MiscellaneousIcons.java index ce32836a6..f07bd1a8c 100644 --- a/src/main/java/vazkii/botania/client/core/handler/MiscellaneousIcons.java +++ b/src/main/java/vazkii/botania/client/core/handler/MiscellaneousIcons.java @@ -8,34 +8,21 @@ */ package vazkii.botania.client.core.handler; -import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.block.model.IBakedModel; import net.minecraft.client.renderer.block.model.ModelResourceLocation; import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.client.renderer.texture.TextureMap; -import net.minecraft.launchwrapper.Launch; import net.minecraftforge.client.event.ModelBakeEvent; import net.minecraftforge.client.event.TextureStitchEvent; -import net.minecraftforge.event.entity.player.ArrowLooseEvent; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; -import org.lwjgl.BufferUtils; -import org.lwjgl.opengl.GL11; -import org.lwjgl.opengl.GL12; import vazkii.botania.client.core.helper.IconHelper; import vazkii.botania.client.model.FloatingFlowerModel; import vazkii.botania.client.model.GunModel; import vazkii.botania.client.model.LexiconModel; import vazkii.botania.client.model.PlatformModel; -import vazkii.botania.common.Botania; import vazkii.botania.common.item.ItemSparkUpgrade; import vazkii.botania.common.item.equipment.bauble.ItemFlightTiara; import vazkii.botania.common.item.relic.ItemKingKey; - -import javax.imageio.ImageIO; -import java.awt.image.BufferedImage; -import java.io.File; -import java.io.IOException; -import java.nio.IntBuffer; +import vazkii.botania.common.lib.LibMisc; public class MiscellaneousIcons { @@ -98,7 +85,10 @@ public class MiscellaneousIcons { evt.getModelRegistry().putObject(new ModelResourceLocation("botania:platform", "normal"), new PlatformModel()); // Lexicon - evt.getModelRegistry().putObject(new ModelResourceLocation("botania:lexicon", "inventory"), new LexiconModel()); + evt.getModelRegistry().putObject(new ModelResourceLocation("botania:lexicon_3d_default", "inventory"), + new LexiconModel(new ModelResourceLocation("botania:lexicon_default", "inventory"))); + evt.getModelRegistry().putObject(new ModelResourceLocation("botania:lexicon_3d_elven", "inventory"), + new LexiconModel(new ModelResourceLocation("botania:lexicon_elven", "inventory"))); // Mana Blaster ModelResourceLocation key = new ModelResourceLocation("botania:manaGun", "inventory"); diff --git a/src/main/java/vazkii/botania/client/core/handler/ModelHandler.java b/src/main/java/vazkii/botania/client/core/handler/ModelHandler.java index 636b464c0..a88ef7442 100644 --- a/src/main/java/vazkii/botania/client/core/handler/ModelHandler.java +++ b/src/main/java/vazkii/botania/client/core/handler/ModelHandler.java @@ -21,6 +21,7 @@ import net.minecraftforge.client.model.obj.OBJLoader; import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.fml.relauncher.ReflectionHelper; +import net.minecraftforge.fml.relauncher.Side; import net.minecraftforge.registries.IRegistryDelegate; import vazkii.botania.api.BotaniaAPIClient; import vazkii.botania.api.item.IFloatingFlower; @@ -48,7 +49,7 @@ import java.util.Locale; import java.util.Map; import java.util.function.IntFunction; -@Mod.EventBusSubscriber +@Mod.EventBusSubscriber(Side.CLIENT) public final class ModelHandler { @SubscribeEvent public static void registerModels(ModelRegistryEvent evt) { diff --git a/src/main/java/vazkii/botania/client/core/handler/RenderLexicon.java b/src/main/java/vazkii/botania/client/core/handler/RenderLexicon.java index 6efaf4770..b5a49f0aa 100644 --- a/src/main/java/vazkii/botania/client/core/handler/RenderLexicon.java +++ b/src/main/java/vazkii/botania/client/core/handler/RenderLexicon.java @@ -28,7 +28,8 @@ import vazkii.botania.common.lexicon.page.PageText; @Mod.EventBusSubscriber(Side.CLIENT) public class RenderLexicon { private static final ModelBook model = new ModelBook(); - private static final ResourceLocation texture = new ResourceLocation(LibResources.MODEL_LEXICA); + private static final ResourceLocation texture = new ResourceLocation(LibResources.MODEL_LEXICA_DEFAULT); + private static final ResourceLocation elvenTexture = new ResourceLocation(LibResources.MODEL_LEXICA_ELVEN); private static final String[] QUOTES = new String[] { "\"Neat!\" - Direwolf20", @@ -78,7 +79,7 @@ public class RenderLexicon { Minecraft mc = Minecraft.getMinecraft(); GlStateManager.pushMatrix(); - mc.renderEngine.bindTexture(texture); + mc.renderEngine.bindTexture(((ItemLexicon) ModItems.lexicon).isElvenItem(stack) ? elvenTexture : texture); float opening; float pageFlip; diff --git a/src/main/java/vazkii/botania/client/core/helper/ShaderHelper.java b/src/main/java/vazkii/botania/client/core/helper/ShaderHelper.java index 3d24d0114..6f0abe72f 100644 --- a/src/main/java/vazkii/botania/client/core/helper/ShaderHelper.java +++ b/src/main/java/vazkii/botania/client/core/helper/ShaderHelper.java @@ -10,7 +10,9 @@ */ package vazkii.botania.client.core.helper; +import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.OpenGlHelper; +import net.minecraft.client.resources.SimpleReloadableResourceManager; import org.lwjgl.opengl.ARBFragmentShader; import org.lwjgl.opengl.ARBShaderObjects; import org.lwjgl.opengl.ARBVertexShader; @@ -43,6 +45,32 @@ public final class ShaderHelper { public static int categoryButton = 0; public static int alpha = 0; + private static void deleteShader(int id) { + if (id != 0) { + ARBShaderObjects.glDeleteObjectARB(id); + } + } + + public static void registerReloadListener() { + if (Minecraft.getMinecraft().getResourceManager() instanceof SimpleReloadableResourceManager) { + ((SimpleReloadableResourceManager) Minecraft.getMinecraft().getResourceManager()).registerReloadListener(manager -> { + deleteShader(pylonGlow); pylonGlow = 0; + deleteShader(enchanterRune); enchanterRune = 0; + deleteShader(manaPool); manaPool = 0; + deleteShader(doppleganger); doppleganger = 0; + deleteShader(halo); halo = 0; + deleteShader(dopplegangerBar); dopplegangerBar = 0; + deleteShader(terraPlateRune); terraPlateRune = 0; + deleteShader(filmGrain); filmGrain = 0; + deleteShader(gold); gold = 0; + deleteShader(categoryButton); categoryButton = 0; + deleteShader(alpha); alpha = 0; + + initShaders(); + }); + } + } + public static void initShaders() { if(!useShaders()) return; diff --git a/src/main/java/vazkii/botania/client/core/proxy/ClientProxy.java b/src/main/java/vazkii/botania/client/core/proxy/ClientProxy.java index f925ac86b..142d922e5 100644 --- a/src/main/java/vazkii/botania/client/core/proxy/ClientProxy.java +++ b/src/main/java/vazkii/botania/client/core/proxy/ClientProxy.java @@ -236,6 +236,7 @@ public class ClientProxy implements IProxy { RenderingRegistry.registerEntityRenderingHandler(EntityEnderAirBottle.class, renderManager -> new RenderSnowballStack<>(renderManager, ModItems.manaResource, Minecraft.getMinecraft().getRenderItem(), entity -> new ItemStack(ModItems.manaResource, 1, 15))); ShaderHelper.initShaders(); + ShaderHelper.registerReloadListener(); } private void initAuxiliaryRender() { diff --git a/src/main/java/vazkii/botania/client/fx/FXSparkle.java b/src/main/java/vazkii/botania/client/fx/FXSparkle.java index ab0f9096e..005f51ee3 100644 --- a/src/main/java/vazkii/botania/client/fx/FXSparkle.java +++ b/src/main/java/vazkii/botania/client/fx/FXSparkle.java @@ -210,22 +210,26 @@ public class FXSparkle extends Particle { float f = rand.nextFloat() * 0.05F + 0.025F; // Botania - made multiplier and add both smaller float f1 = enumfacing.getAxisDirection().getOffset(); - float secondary = (rand.nextFloat() - rand.nextFloat()) * 0.1F; // Botania - Make and use a secondary movement variable below + float secondary = (rand.nextFloat() - rand.nextFloat()) * 0.1F; // Botania - Make and use secondary movement variables below + float secondary2 = (rand.nextFloat() - rand.nextFloat()) * 0.1F; if (enumfacing.getAxis() == EnumFacing.Axis.X) { motionX = f1 * f; - motionY = motionZ = secondary; + motionY = secondary; + motionZ = secondary2; } else if (enumfacing.getAxis() == EnumFacing.Axis.Y) { motionY = f1 * f; - motionX = motionZ = secondary; + motionX = secondary; + motionZ = secondary2; } else if (enumfacing.getAxis() == EnumFacing.Axis.Z) { motionZ = f1 * f; - motionX = motionY = secondary; + motionX = secondary; + motionY = secondary2; } return true; diff --git a/src/main/java/vazkii/botania/client/lib/LibResources.java b/src/main/java/vazkii/botania/client/lib/LibResources.java index e4431fd78..d81be0141 100644 --- a/src/main/java/vazkii/botania/client/lib/LibResources.java +++ b/src/main/java/vazkii/botania/client/lib/LibResources.java @@ -77,7 +77,8 @@ public final class LibResources { public static final String MODEL_PYLON_GREEN = PREFIX_MODEL + "pylon1.png"; public static final String MODEL_PYLON_PINK_OLD = PREFIX_MODEL + "pylonOld2.png"; public static final String MODEL_PYLON_PINK = PREFIX_MODEL + "pylon2.png"; - public static final String MODEL_LEXICA = PREFIX_MODEL + "lexica.png"; + public static final String MODEL_LEXICA_DEFAULT = PREFIX_MODEL + "lexica0.png"; + public static final String MODEL_LEXICA_ELVEN = PREFIX_MODEL + "lexica1.png"; public static final String MODEL_MANASTEEL_0 = PREFIX_MODEL + "manasteel0.png"; public static final String MODEL_MANASTEEL_1 = PREFIX_MODEL + "manasteel1.png"; public static final String MODEL_MANASTEEL_2 = PREFIX_MODEL + "manasteel2.png"; diff --git a/src/main/java/vazkii/botania/client/model/LexiconModel.java b/src/main/java/vazkii/botania/client/model/LexiconModel.java index fd73cbba6..1b2b573f2 100644 --- a/src/main/java/vazkii/botania/client/model/LexiconModel.java +++ b/src/main/java/vazkii/botania/client/model/LexiconModel.java @@ -17,18 +17,21 @@ import javax.annotation.Nonnull; import javax.vecmath.Matrix4f; import java.util.List; -@SuppressWarnings("deprecation") public class LexiconModel implements IBakedModel { + private final ModelResourceLocation path2D; - private static final ModelResourceLocation path = new ModelResourceLocation("botania:lexicon_default", "inventory"); + public LexiconModel(ModelResourceLocation path) { + this.path2D = path; + } + @Nonnull @Override public Pair handlePerspective(ItemCameraTransforms.TransformType cameraTransformType) { - IBakedModel original = Minecraft.getMinecraft().getBlockRendererDispatcher().getBlockModelShapes().getModelManager().getModel(path); if((cameraTransformType == ItemCameraTransforms.TransformType.FIRST_PERSON_RIGHT_HAND || cameraTransformType == ItemCameraTransforms.TransformType.FIRST_PERSON_LEFT_HAND) && ConfigHandler.lexicon3dModel) return Pair.of(this, null); + IBakedModel original = Minecraft.getMinecraft().getBlockRendererDispatcher().getBlockModelShapes().getModelManager().getModel(path2D); return original.handlePerspective(cameraTransformType); } @@ -37,6 +40,6 @@ public class LexiconModel implements IBakedModel { @Override public boolean isGui3d() { return false; } @Override public boolean isBuiltInRenderer() { return false; } @Nonnull @Override public TextureAtlasSprite getParticleTexture() { return Minecraft.getMinecraft().getTextureMapBlocks().getAtlasSprite("botania:items/lexicon"); } - @Nonnull @Override public ItemCameraTransforms getItemCameraTransforms() { return ItemCameraTransforms.DEFAULT; } + @SuppressWarnings("deprecation") @Nonnull @Override public ItemCameraTransforms getItemCameraTransforms() { return ItemCameraTransforms.DEFAULT; } @Nonnull @Override public ItemOverrideList getOverrides() { return ItemOverrideList.NONE; } } diff --git a/src/main/java/vazkii/botania/common/block/decor/BlockElfGlass.java b/src/main/java/vazkii/botania/common/block/decor/BlockElfGlass.java index 4adc6bbeb..ced9f1129 100644 --- a/src/main/java/vazkii/botania/common/block/decor/BlockElfGlass.java +++ b/src/main/java/vazkii/botania/common/block/decor/BlockElfGlass.java @@ -10,7 +10,6 @@ */ package vazkii.botania.common.block.decor; -import net.minecraft.block.state.IBlockState; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.util.math.BlockPos; @@ -32,11 +31,6 @@ public class BlockElfGlass extends BlockManaGlass implements IElvenItem, ILexico return true; } - @Override - public boolean isFullBlock(IBlockState state) { - return true; - } - @Override public LexiconEntry getEntry(World world, BlockPos pos, EntityPlayer player, ItemStack lexicon) { return LexiconData.elvenResources; diff --git a/src/main/java/vazkii/botania/common/block/decor/BlockManaGlass.java b/src/main/java/vazkii/botania/common/block/decor/BlockManaGlass.java index 2bf7b1afc..2dc9aac05 100644 --- a/src/main/java/vazkii/botania/common/block/decor/BlockManaGlass.java +++ b/src/main/java/vazkii/botania/common/block/decor/BlockManaGlass.java @@ -50,8 +50,8 @@ public class BlockManaGlass extends BlockMod implements ILexiconable { } @Override - public boolean isFullBlock(IBlockState state) { - return true; + public boolean isFullCube(IBlockState state) { + return false; } @SideOnly(Side.CLIENT) diff --git a/src/main/java/vazkii/botania/common/block/tile/TileTerraPlate.java b/src/main/java/vazkii/botania/common/block/tile/TileTerraPlate.java index 93099cf60..2493c8db9 100644 --- a/src/main/java/vazkii/botania/common/block/tile/TileTerraPlate.java +++ b/src/main/java/vazkii/botania/common/block/tile/TileTerraPlate.java @@ -132,11 +132,11 @@ public class TileTerraPlate extends TileMod implements ISparkAttachable { return false; int meta = stack.getItemDamage(); - if(meta == 0) + if(meta == 17) ingot = stack; - else if(meta == 1) + else if(meta == 24) pearl = stack; - else if(meta == 2) + else if(meta == 25) diamond = stack; else return false; } diff --git a/src/main/java/vazkii/botania/common/entity/EntityCorporeaSpark.java b/src/main/java/vazkii/botania/common/entity/EntityCorporeaSpark.java index da87d3e50..77a9ceefb 100644 --- a/src/main/java/vazkii/botania/common/entity/EntityCorporeaSpark.java +++ b/src/main/java/vazkii/botania/common/entity/EntityCorporeaSpark.java @@ -259,7 +259,7 @@ public class EntityCorporeaSpark extends Entity implements ICorporeaSpark { @Override public boolean processInitialInteract(EntityPlayer player, EnumHand hand) { ItemStack stack = player.getHeldItem(hand); - if(!stack.isEmpty()) { + if(!isDead && !stack.isEmpty()) { if(player.world.isRemote) { boolean valid = stack.getItem() == ModItems.twigWand || stack.getItem() == ModItems.dye || stack.getItem() == ModItems.phantomInk; if(valid) diff --git a/src/main/java/vazkii/botania/common/entity/EntitySpark.java b/src/main/java/vazkii/botania/common/entity/EntitySpark.java index e95b64b8b..75c8af5cd 100644 --- a/src/main/java/vazkii/botania/common/entity/EntitySpark.java +++ b/src/main/java/vazkii/botania/common/entity/EntitySpark.java @@ -239,7 +239,7 @@ public class EntitySpark extends Entity implements ISparkEntity { @Override public boolean processInitialInteract(EntityPlayer player, EnumHand hand) { ItemStack stack = player.getHeldItem(hand); - if(!stack.isEmpty()) { + if(!isDead && !stack.isEmpty()) { if(world.isRemote) { boolean valid = stack.getItem() == ModItems.twigWand || stack.getItem() == ModItems.sparkUpgrade || stack.getItem() == ModItems.phantomInk; diff --git a/src/main/java/vazkii/botania/common/item/ItemLexicon.java b/src/main/java/vazkii/botania/common/item/ItemLexicon.java index 365c3babe..40da959ee 100644 --- a/src/main/java/vazkii/botania/common/item/ItemLexicon.java +++ b/src/main/java/vazkii/botania/common/item/ItemLexicon.java @@ -263,8 +263,16 @@ public class ItemLexicon extends ItemMod implements ILexicon, IElvenItem { @SideOnly(Side.CLIENT) @Override public void registerModels() { - ModelBakery.registerItemVariants(this, new ModelResourceLocation("botania:lexicon_default", "inventory")); - ModelLoader.setCustomModelResourceLocation(this, 0, new ModelResourceLocation(getRegistryName(), "inventory")); + // Load and bake the 2D models + ModelBakery.registerItemVariants(this, + new ModelResourceLocation("botania:lexicon_default", "inventory"), + new ModelResourceLocation("botania:lexicon_elven", "inventory")); + + ModelResourceLocation default3dPath = new ModelResourceLocation("botania:lexicon_3d_default", "inventory"); + ModelResourceLocation elven3dPath = new ModelResourceLocation("botania:lexicon_3d_elven", "inventory"); + + // smart model will dispatch between 2d/3d appropriately, see LexiconModel + ModelLoader.setCustomMeshDefinition(this, stack -> isElvenItem(stack) ? elven3dPath : default3dPath); } } diff --git a/src/main/java/vazkii/botania/common/item/ModItems.java b/src/main/java/vazkii/botania/common/item/ModItems.java index a60a64f0b..2a5663dc4 100644 --- a/src/main/java/vazkii/botania/common/item/ModItems.java +++ b/src/main/java/vazkii/botania/common/item/ModItems.java @@ -445,6 +445,8 @@ public final class ModItems { OreDictionary.registerOre(LibOreDict.PEBBLE, new ItemStack(manaResource, 1, 21)); OreDictionary.registerOre(LibOreDict.MANAWEAVE_CLOTH, new ItemStack(manaResource, 1, 22)); OreDictionary.registerOre(LibOreDict.MANA_POWDER, new ItemStack(manaResource, 1, 23)); + OreDictionary.registerOre(LibOreDict.MANA_PEARL_SHARD, new ItemStack(manaResource, 1, 24)); + OreDictionary.registerOre(LibOreDict.MANA_DIAMOND_CHUNK, new ItemStack(manaResource, 1, 25)); OreDictionary.registerOre(LibOreDict.VIAL, new ItemStack(vial, 1, 0)); OreDictionary.registerOre(LibOreDict.FLASK, new ItemStack(vial, 1, 1)); diff --git a/src/main/java/vazkii/botania/common/item/material/ItemManaResource.java b/src/main/java/vazkii/botania/common/item/material/ItemManaResource.java index b2c46a84f..d9e457f89 100644 --- a/src/main/java/vazkii/botania/common/item/material/ItemManaResource.java +++ b/src/main/java/vazkii/botania/common/item/material/ItemManaResource.java @@ -10,6 +10,7 @@ */ package vazkii.botania.common.item.material; +import net.minecraft.client.renderer.block.model.ModelResourceLocation; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.init.Items; @@ -23,6 +24,7 @@ import net.minecraft.util.NonNullList; import net.minecraft.util.SoundCategory; import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; +import net.minecraftforge.client.model.ModelLoader; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.event.entity.player.PlayerInteractEvent; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; @@ -38,13 +40,12 @@ import vazkii.botania.common.entity.EntityDoppleganger; import vazkii.botania.common.entity.EntityEnderAirBottle; import vazkii.botania.common.item.ItemMod; import vazkii.botania.common.lib.LibItemNames; +import vazkii.botania.common.lib.LibMisc; import javax.annotation.Nonnull; public class ItemManaResource extends ItemMod implements IFlowerComponent, IElvenItem { - final int types = 24; - public ItemManaResource() { super(LibItemNames.MANA_RESOURCE); setHasSubtypes(true); @@ -117,7 +118,7 @@ public class ItemManaResource extends ItemMod implements IFlowerComponent, IElve @Override public void getSubItems(@Nonnull CreativeTabs tab, @Nonnull NonNullList stacks) { if(isInCreativeTab(tab)) { - for(int i = 0; i < types; i++) { + for(int i = 0; i < LibItemNames.MANA_RESOURCE_NAMES.length; i++) { if("UNUSED".equals(LibItemNames.MANA_RESOURCE_NAMES[i])) continue; if(Botania.gardenOfGlassLoaded || i != 20 && i != 21) @@ -129,7 +130,7 @@ public class ItemManaResource extends ItemMod implements IFlowerComponent, IElve @Nonnull @Override public String getUnlocalizedName(ItemStack par1ItemStack) { - return "item." + LibItemNames.MANA_RESOURCE_NAMES[Math.min(types - 1, par1ItemStack.getItemDamage())]; + return "item." + LibItemNames.MANA_RESOURCE_NAMES[Math.min(LibItemNames.MANA_RESOURCE_NAMES.length - 1, par1ItemStack.getItemDamage())]; } @Override @@ -158,7 +159,14 @@ public class ItemManaResource extends ItemMod implements IFlowerComponent, IElve @SideOnly(Side.CLIENT) @Override public void registerModels() { - ModelHandler.registerItemMetas(this, LibItemNames.MANA_RESOURCE_NAMES.length, i -> LibItemNames.MANA_RESOURCE_NAMES[i]); + for(int i = 0; i < LibItemNames.MANA_RESOURCE_NAMES.length; i++) { + if("UNUSED".equals(LibItemNames.MANA_RESOURCE_NAMES[i])) + continue; + ModelLoader.setCustomModelResourceLocation( + this, i, + new ModelResourceLocation(LibMisc.MOD_ID + ":" + LibItemNames.MANA_RESOURCE_NAMES[i], "inventory") + ); + } } } diff --git a/src/main/java/vazkii/botania/common/lexicon/page/PageTerrasteel.java b/src/main/java/vazkii/botania/common/lexicon/page/PageTerrasteel.java index 0ed23b6ba..39163296a 100644 --- a/src/main/java/vazkii/botania/common/lexicon/page/PageTerrasteel.java +++ b/src/main/java/vazkii/botania/common/lexicon/page/PageTerrasteel.java @@ -68,10 +68,10 @@ public class PageTerrasteel extends PageRecipe { renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8, gui.getTop() + 102, new ItemStack(block3), false); GlStateManager.translate(0F, 0F, -10F); - renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8, gui.getTop() + 30, new ItemStack(ModItems.manaResource, 1, 4), false); - renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8, gui.getTop() + 80, new ItemStack(ModItems.manaResource, 1, 0), false); - renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8 - 20, gui.getTop() + 86, new ItemStack(ModItems.manaResource, 1, 1), false); - renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8 + 19, gui.getTop() + 86, new ItemStack(ModItems.manaResource, 1, 2), false); + renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8, gui.getTop() + 30, new ItemStack(ModItems.manaResource, 1, 18), false); + renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8, gui.getTop() + 80, new ItemStack(ModItems.manaResource, 1, 17), false); + renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8 - 20, gui.getTop() + 86, new ItemStack(ModItems.manaResource, 1, 24), false); + renderItem(gui, gui.getLeft() + gui.getWidth() / 2 - 8 + 19, gui.getTop() + 86, new ItemStack(ModItems.manaResource, 1, 25), false); Minecraft.getMinecraft().renderEngine.bindTexture(terrasteelOverlay); @@ -84,13 +84,13 @@ public class PageTerrasteel extends PageRecipe { @Override public void onPageAdded(LexiconEntry entry, int index) { - LexiconRecipeMappings.map(new ItemStack(ModItems.manaResource, 1, 4), entry, index); + LexiconRecipeMappings.map(new ItemStack(ModItems.manaResource, 1, 18), entry, index); } @Override public List getDisplayedRecipes() { ArrayList list = new ArrayList<>(); - list.add(new ItemStack(ModItems.manaResource, 1, 4)); + list.add(new ItemStack(ModItems.manaResource, 1, 18)); return list; } diff --git a/src/main/java/vazkii/botania/common/lib/LibItemNames.java b/src/main/java/vazkii/botania/common/lib/LibItemNames.java index 08217dc8d..d704d88fd 100644 --- a/src/main/java/vazkii/botania/common/lib/LibItemNames.java +++ b/src/main/java/vazkii/botania/common/lib/LibItemNames.java @@ -218,6 +218,8 @@ public final class LibItemNames { "livingRoot", "pebble", "manaweaveCloth", - "manaPowder" + "manaPowder", + "manaPearlShard", + "manaDiamondChunk" }; } diff --git a/src/main/java/vazkii/botania/common/lib/LibOreDict.java b/src/main/java/vazkii/botania/common/lib/LibOreDict.java index 0003909eb..c3f595df1 100644 --- a/src/main/java/vazkii/botania/common/lib/LibOreDict.java +++ b/src/main/java/vazkii/botania/common/lib/LibOreDict.java @@ -41,11 +41,12 @@ public final class LibOreDict { public static final String PEBBLE = "pebble"; public static final String MANAWEAVE_CLOTH = "clothManaweave"; public static final String MANA_POWDER = "powderMana"; + public static final String MANA_PEARL_SHARD = "shardManaPearl"; + public static final String MANA_DIAMOND_CHUNK = "nuggetManaDiamond"; public static final String VIAL = "bVial"; public static final String FLASK = "bFlask"; - public static final String PRISMARINE_BLOCK = "blockPrismarine"; public static final String BLAZE_BLOCK = "blockBlaze"; public static final String DYE_WILDCARD = "dye"; diff --git a/src/main/resources/assets/botania/lang/en_us.lang b/src/main/resources/assets/botania/lang/en_us.lang index 380e1ec27..ee138a6b9 100644 --- a/src/main/resources/assets/botania/lang/en_us.lang +++ b/src/main/resources/assets/botania/lang/en_us.lang @@ -496,7 +496,7 @@ advancement.botania:manaBlasterShoot.desc=Craft and fire a Mana Blaster advancement.botania:tiaraWings=Heart Shooter advancement.botania:tiaraWings.desc=Craft and adorn a Flügel Tiara with Flügel Wings advancement.botania:terrasteelPickup=Dancer in the Dark -advancement.botania:terrasteelPickup.desc=Conjure a Terrasteel Ingot using a Terrestrial Agglomeration Plate +advancement.botania:terrasteelPickup.desc=Conjure a Terrasteel Nugget using a Terrestrial Agglomeration Plate advancement.botania:elfPortalOpen=World Calling advancement.botania:elfPortalOpen.desc=Open a portal to the realm of Alfheim advancement.botania:gaiaGuardianKill=Dead and Seek @@ -1309,7 +1309,9 @@ item.botania:pestleAndMortar.name=Pestle and Mortar item.botania:twigWand.name=Wand of the Forest item.botania:manasteel.name=Manasteel Ingot item.botania:manaPearl.name=Mana Pearl +item.botania:manaPearlShard.name=Mana Pearl Shard item.botania:manaDiamond.name=Mana Diamond +item.botania:manaDiamondChunk.name=Mana Diamond Chunk item.botania:lensNormal.name=Mana Lens item.botania:lensSpeed.name=Mana Lens: Velocity item.botania:lensSpeed.short=Velocity @@ -2045,8 +2047,8 @@ botania.entry.terrasteel=Terrasteel botania.tagline.terrasteel=Powerful metal derived from Mana and nature botania.page.terrasteel0=&1Terrasteel&0 is a complex magical alloy, infused with a great amount of &4Mana&0. Conjuring it proves to be no small task. For starters, to create it, one requires a &1Terrestrial Agglomeration Plate&0, set on top of a checkerboard pattern of &1Lapis Lazuli Blocks&0 and &1Livingrock&0. &4Mana&0 needs to be provided to this block, with &1Sparks&0 being the most effective method. botania.page.terrasteel1=Creating the plate -botania.page.terrasteel2=After the plate is set up and ready to receive &4Mana&0, tossing a single &1Manasteel Ingot, Mana Diamond and Mana Pearl&0 on top of it will begin the infusion.
Picking up any of the items will halt the infusion causing severe &4Mana Loss&0. The infusion uses mana equivalent to about half a &1Mana Pool&0 to create a single piece of &4Terrasteel&0; multiple &1Sparks&0 will accelerate the process as well. -botania.page.terrasteel3=Creating &1Terrasteel&0 (there's &1Livingrock&0 under the plate) +botania.page.terrasteel2=After the plate is set up and ready to receive &4Mana&0, tossing a single &1Manasteel Nugget, Mana Diamond Chunk and Mana Pearl Shard&0 on top of it will begin the infusion.
Picking up any of the items will halt the infusion causing severe &4Mana Loss&0. The infusion uses mana equivalent to about 1/25 a &1Mana Pool&0 to create a single &4Terrasteel Nugget&0; multiple &1Sparks&0 will accelerate the process as well. +botania.page.terrasteel3=Creating &1Terrasteel Ingots&0 (there's &1Livingrock&0 under the plate) botania.page.terrasteel4=T.A. Plate # -- BLACK LOTUS diff --git a/src/main/resources/assets/botania/models/item/lexicon_default.json b/src/main/resources/assets/botania/models/item/lexicon_default.json index 464dc1a78..6758a056a 100644 --- a/src/main/resources/assets/botania/models/item/lexicon_default.json +++ b/src/main/resources/assets/botania/models/item/lexicon_default.json @@ -1,6 +1,6 @@ { "parent": "minecraft:item/generated", "textures": { - "layer0": "botania:items/lexicon" + "layer0": "botania:items/lexicon0" } } \ No newline at end of file diff --git a/src/main/resources/assets/botania/models/item/lexicon_elven.json b/src/main/resources/assets/botania/models/item/lexicon_elven.json new file mode 100644 index 000000000..5bf142c54 --- /dev/null +++ b/src/main/resources/assets/botania/models/item/lexicon_elven.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "botania:items/lexicon1" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/botania/models/item/manadiamondchunk.json b/src/main/resources/assets/botania/models/item/manadiamondchunk.json new file mode 100644 index 000000000..f73dfe965 --- /dev/null +++ b/src/main/resources/assets/botania/models/item/manadiamondchunk.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:item/generated", + "textures": + { + "layer0": "botania:items/manadiamondchunk" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/botania/models/item/manapearlshard.json b/src/main/resources/assets/botania/models/item/manapearlshard.json new file mode 100644 index 000000000..31fd95546 --- /dev/null +++ b/src/main/resources/assets/botania/models/item/manapearlshard.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:item/generated", + "textures": + { + "layer0": "botania:items/manapearlshard" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/botania/recipes/_constants.json b/src/main/resources/assets/botania/recipes/_constants.json index 61fa7b60e..6ff6c4c82 100644 --- a/src/main/resources/assets/botania/recipes/_constants.json +++ b/src/main/resources/assets/botania/recipes/_constants.json @@ -517,6 +517,13 @@ }, "name": "NUGGETGOLD" }, + { + "ingredient": { + "type": "forge:ore_dict", + "ore": "nuggetManaDiamond" + }, + "name": "NUGGETMANADIAMOND" + }, { "ingredient": { "type": "forge:ore_dict", @@ -832,6 +839,13 @@ }, "name": "RUNEWRATHB" }, + { + "ingredient": { + "type": "forge:ore_dict", + "ore": "shardManaPearl" + }, + "name": "SHARDMANAPEARL" + }, { "ingredient": { "type": "forge:ore_dict", diff --git a/src/main/resources/assets/botania/recipes/manaresource_0_alt.json b/src/main/resources/assets/botania/recipes/manaresource_0.json similarity index 100% rename from src/main/resources/assets/botania/recipes/manaresource_0_alt.json rename to src/main/resources/assets/botania/recipes/manaresource_0.json diff --git a/src/main/resources/assets/botania/recipes/manaresource_1.json b/src/main/resources/assets/botania/recipes/manaresource_1.json new file mode 100644 index 000000000..9e27594b4 --- /dev/null +++ b/src/main/resources/assets/botania/recipes/manaresource_1.json @@ -0,0 +1,17 @@ +{ + "result": { + "item": "botania:manaresource", + "data": 1 + }, + "pattern": [ + "III", + "III", + "III" + ], + "type": "forge:ore_shaped", + "key": { + "I": { + "item": "#SHARDMANAPEARL" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/botania/recipes/manaresource_24.json b/src/main/resources/assets/botania/recipes/manaresource_24.json new file mode 100644 index 000000000..841bd5783 --- /dev/null +++ b/src/main/resources/assets/botania/recipes/manaresource_24.json @@ -0,0 +1,13 @@ +{ + "result": { + "item": "botania:manaresource", + "data": 24, + "count": 9 + }, + "ingredients": [ + { + "item": "#MANAPEARL" + } + ], + "type": "forge:ore_shapeless" +} \ No newline at end of file diff --git a/src/main/resources/assets/botania/recipes/manaresource_25.json b/src/main/resources/assets/botania/recipes/manaresource_25.json new file mode 100644 index 000000000..3c5aa16c0 --- /dev/null +++ b/src/main/resources/assets/botania/recipes/manaresource_25.json @@ -0,0 +1,13 @@ +{ + "result": { + "item": "botania:manaresource", + "data": 25, + "count": 9 + }, + "ingredients": [ + { + "item": "#MANADIAMOND" + } + ], + "type": "forge:ore_shapeless" +} \ No newline at end of file diff --git a/src/main/resources/assets/botania/recipes/manaresource_2_alt.json b/src/main/resources/assets/botania/recipes/manaresource_2_alt.json new file mode 100644 index 000000000..8202a128a --- /dev/null +++ b/src/main/resources/assets/botania/recipes/manaresource_2_alt.json @@ -0,0 +1,17 @@ +{ + "result": { + "item": "botania:manaresource", + "data": 2 + }, + "pattern": [ + "III", + "III", + "III" + ], + "type": "forge:ore_shaped", + "key": { + "I": { + "item": "#NUGGETMANADIAMOND" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/botania/shader/category_button.frag b/src/main/resources/assets/botania/shader/category_button.frag index f019d11f0..219b91ea1 100644 --- a/src/main/resources/assets/botania/shader/category_button.frag +++ b/src/main/resources/assets/botania/shader/category_button.frag @@ -14,5 +14,8 @@ void main() { if(maskgs <= heightMatch) gl_FragColor = vec4(color.r, color.g, color.b, color.a); - else gl_FragColor = vec4(0, 0, 0, color.a); + else { + float gs = (color.r + color.g + color.b) / 3.0; + gl_FragColor = vec4(gs, gs, gs, color.a * 0.75); + } } \ No newline at end of file diff --git a/src/main/resources/assets/botania/textures/gui/categories/alfhomancy.png b/src/main/resources/assets/botania/textures/gui/categories/alfhomancy.png index c7a562ac8..122804f1f 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/alfhomancy.png and b/src/main/resources/assets/botania/textures/gui/categories/alfhomancy.png differ diff --git a/src/main/resources/assets/botania/textures/gui/categories/basics.png b/src/main/resources/assets/botania/textures/gui/categories/basics.png index c336d8be3..48277515d 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/basics.png and b/src/main/resources/assets/botania/textures/gui/categories/basics.png differ diff --git a/src/main/resources/assets/botania/textures/gui/categories/baubles.png b/src/main/resources/assets/botania/textures/gui/categories/baubles.png index b6c3af01e..882706ab3 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/baubles.png and b/src/main/resources/assets/botania/textures/gui/categories/baubles.png differ diff --git a/src/main/resources/assets/botania/textures/gui/categories/devices.png b/src/main/resources/assets/botania/textures/gui/categories/devices.png index f6ad67aa3..e95185fd1 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/devices.png and b/src/main/resources/assets/botania/textures/gui/categories/devices.png differ diff --git a/src/main/resources/assets/botania/textures/gui/categories/ender.png b/src/main/resources/assets/botania/textures/gui/categories/ender.png index 1ab2a789d..54524c26f 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/ender.png and b/src/main/resources/assets/botania/textures/gui/categories/ender.png differ diff --git a/src/main/resources/assets/botania/textures/gui/categories/functionalflowers.png b/src/main/resources/assets/botania/textures/gui/categories/functionalflowers.png index 8b7010527..8da57e450 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/functionalflowers.png and b/src/main/resources/assets/botania/textures/gui/categories/functionalflowers.png differ diff --git a/src/main/resources/assets/botania/textures/gui/categories/generationflowers.png b/src/main/resources/assets/botania/textures/gui/categories/generationflowers.png index c4fb147b5..c34d635e9 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/generationflowers.png and b/src/main/resources/assets/botania/textures/gui/categories/generationflowers.png differ diff --git a/src/main/resources/assets/botania/textures/gui/categories/index.png b/src/main/resources/assets/botania/textures/gui/categories/index.png index e0552a173..0b9a2b93b 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/index.png and b/src/main/resources/assets/botania/textures/gui/categories/index.png differ diff --git a/src/main/resources/assets/botania/textures/gui/categories/tools.png b/src/main/resources/assets/botania/textures/gui/categories/tools.png index 8cd7c4e92..78df96f28 100644 Binary files a/src/main/resources/assets/botania/textures/gui/categories/tools.png and b/src/main/resources/assets/botania/textures/gui/categories/tools.png differ diff --git a/src/main/resources/assets/botania/textures/gui/manahud.png b/src/main/resources/assets/botania/textures/gui/manahud.png index ddde39f12..542d0a7d1 100644 Binary files a/src/main/resources/assets/botania/textures/gui/manahud.png and b/src/main/resources/assets/botania/textures/gui/manahud.png differ diff --git a/src/main/resources/assets/botania/textures/gui/stencil.png b/src/main/resources/assets/botania/textures/gui/stencil.png index 3bdbce084..41ca8843b 100644 Binary files a/src/main/resources/assets/botania/textures/gui/stencil.png and b/src/main/resources/assets/botania/textures/gui/stencil.png differ diff --git a/src/main/resources/assets/botania/textures/items/lexicon.png b/src/main/resources/assets/botania/textures/items/lexicon0.png similarity index 100% rename from src/main/resources/assets/botania/textures/items/lexicon.png rename to src/main/resources/assets/botania/textures/items/lexicon0.png diff --git a/src/main/resources/assets/botania/textures/model/lexica.png b/src/main/resources/assets/botania/textures/model/lexica0.png similarity index 100% rename from src/main/resources/assets/botania/textures/model/lexica.png rename to src/main/resources/assets/botania/textures/model/lexica0.png diff --git a/version/1.11.2.txt b/version/1.11.2.txt index b7ecc0eb0..7f6e8bb32 100644 --- a/version/1.11.2.txt +++ b/version/1.11.2.txt @@ -1 +1 @@ -r1.9-344 \ No newline at end of file +r1.9-345 \ No newline at end of file diff --git a/web/changelog.txt b/web/changelog.txt index cc3e5346a..6e7c847fd 100644 --- a/web/changelog.txt +++ b/web/changelog.txt @@ -1,3 +1,8 @@ +r1.9 345 +*Fixed a bad pixel in the checkmark for mana infision. +*Fixed a dupe when interacting with sparks just as they're leaving the world. +*Fixed Managlass and Alfglass transparency (palaster). +*Fixed the Pure Daisy running its logic client sided as well. r1.9 344 *Fixed a lava dupe with the Petal Apothecary. *Fixed a Mana Enchanter game freeze. diff --git a/web/versions.ini b/web/versions.ini index bb70f54c0..20acd02ed 100644 --- a/web/versions.ini +++ b/web/versions.ini @@ -295,4 +295,5 @@ r1.9-340=1.10.2 r1.9-341=1.10.2 r1.9-342=1.11.2 r1.9-343=1.11.2 -r1.9-344=1.11.2 \ No newline at end of file +r1.9-344=1.11.2 +r1.9-345=1.11.2 \ No newline at end of file