Pass the brush~

This commit is contained in:
Lizbeth Rika committed 2014-09-26 22:14:14 +01:00
1 parent 2472ac399e
commit 5cb0e1ef3a
12 files changed
+28 -29

No files matched your search

@@ -29,12 +29,11 @@ import vazkii.botania.common.item.equipment.bauble.ItemFlightTiara;
import baubles.common.container.InventoryBaubles;
import baubles.common.lib.PlayerHandler;
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
import cpw.mods.fml.common.gameevent.TickEvent;
public final class TiaraWingRenderHandler {
private static ResourceLocation textureHalo = new ResourceLocation(LibResources.MISC_HALO);
@SubscribeEvent
public void onPlayerRender(RenderPlayerEvent.Specials.Post event) {
InventoryBaubles inv = PlayerHandler.getPlayerBaubles(event.entityPlayer);
@@ -139,36 +138,36 @@ public final class TiaraWingRenderHandler {
GL11.glColor3f(1F, 1F, 1F);
GL11.glPopMatrix();
// Jibril's Halo
if(meta == 1)
if(meta == 1)
renderHalo(event.entityPlayer, event.partialRenderTick);
}
}
}
private void renderHalo(EntityPlayer player, float partialTicks) {
float yaw = player.prevRotationYawHead + (player.rotationYawHead - player.prevRotationYawHead) * partialTicks;
float yawOffset = player.prevRenderYawOffset + (player.renderYawOffset - player.prevRenderYawOffset) * partialTicks;
float pitch = player.prevRotationPitch + (player.rotationPitch - player.prevRotationPitch) * partialTicks;
GL11.glPushMatrix();
GL11.glRotatef(yawOffset, 0, -1, 0);
GL11.glRotatef(yaw - 270, 0, 1, 0);
GL11.glRotatef(pitch, 0, 0, 1);
GL11.glRotatef(pitch, 0, 0, 1);
GL11.glShadeModel(GL11.GL_SMOOTH);
OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, 240, 240);
GL11.glDisable(GL11.GL_LIGHTING);
GL11.glColor4f(1F, 1F, 1F, 1F);
Minecraft.getMinecraft().renderEngine.bindTexture(textureHalo);
GL11.glTranslated(0, -player.getDefaultEyeHeight() + (player.isSneaking() ? 0.0625 : 0), 0);
GL11.glRotated(30, 1, 0, -1);
GL11.glTranslatef(-0.1F, -0.5F, -0.1F);
GL11.glRotatef(player.ticksExisted + partialTicks, 0, 1, 0);
Tessellator tes = Tessellator.instance;
ShaderHelper.useShader(ShaderHelper.halo);
tes.startDrawingQuads();
@@ -178,7 +177,7 @@ public final class TiaraWingRenderHandler {
tes.addVertexWithUV(0.75, 0, -0.75, 1, 0);
tes.draw();
ShaderHelper.releaseShader();
GL11.glEnable(GL11.GL_LIGHTING);
GL11.glShadeModel(GL11.GL_FLAT);
GL11.glPopMatrix();
@@ -90,7 +90,7 @@ public final class LibResources {
public static final String MODEL_SPAWNER_CLAW = PREFIX_MODEL + "spawnerClaw.png";
public static final String MODEL_CAPE = "/assets/botania/textures/model/cape.png";
public static final String MISC_PARTICLES = PREFIX_MISC + "particles.png";
public static final String MISC_WISP_LARGE = PREFIX_MISC + "wispLarge.png";
public static final String MISC_WISP_SMALL = PREFIX_MISC + "wispSmall.png";
@@ -46,7 +46,7 @@ public class RenderSpark extends RenderEntity {
time += new Random(par1Entity.getEntityId()).nextInt();
GL11.glColor4f(1F, 1F, 1F, 0.7F + 0.3F * (float) (Math.sin(time / 5.0) + 0.5) * 2);
float scale = 0.75F + 0.1F * (float) Math.sin((double) time / 10);
float scale = 0.75F + 0.1F * (float) Math.sin(time / 10);
GL11.glScalef(scale, scale, scale);
bindEntityTexture(par1Entity);
Tessellator tessellator = Tessellator.instance;
@@ -42,7 +42,7 @@ public class RenderTileAlfPortal extends TileEntitySpecialRenderer {
GL11.glColor4f(1F, 1F, 1F, 1F);
GL11.glDisable(GL11.GL_ALPHA_TEST);
GL11.glEnable(GL11.GL_CULL_FACE);
float alpha = (float) Math.min(1F, (Math.sin((double) (ClientTickHandler.ticksInGame + f) / 8D) + 1D) / 7D + 0.6D) * (Math.min(60, portal.ticksOpen) / 60F);
float alpha = (float) Math.min(1F, (Math.sin((ClientTickHandler.ticksInGame + f) / 8D) + 1D) / 7D + 0.6D) * (Math.min(60, portal.ticksOpen) / 60F);
GL11.glColor4f(1F, 1F, 1F, alpha);
Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.locationBlocksTexture);
@@ -70,7 +70,7 @@ public class RenderTileEnchanter extends TileEntitySpecialRenderer {
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
GL11.glColor4f(1F, 1F, 1F, 1F);
GL11.glDisable(GL11.GL_ALPHA_TEST);
float alpha = (float) ((Math.sin((double) (ClientTickHandler.ticksInGame + f) / 8D) + 1D) / 5D + 0.4D) * alphaMod;
float alpha = (float) ((Math.sin((ClientTickHandler.ticksInGame + f) / 8D) + 1D) / 5D + 0.4D) * alphaMod;
if(ShaderHelper.useShaders())
GL11.glColor4f(1F, 1F, 1F, alpha);
else {
@@ -78,7 +78,7 @@ public class RenderTileEnchanter extends TileEntitySpecialRenderer {
int lightmapX = light % 65536;
int lightmapY = light / 65536;
OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, lightmapX, lightmapY);
GL11.glColor4f(0.6F + (float) ((Math.cos((double) (ClientTickHandler.ticksInGame + f) / 6D) + 1D) / 5D), 0.1F, 0.9F, alpha);
GL11.glColor4f(0.6F + (float) ((Math.cos((ClientTickHandler.ticksInGame + f) / 6D) + 1D) / 5D), 0.1F, 0.9F, alpha);
}
Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.locationBlocksTexture);
@@ -87,7 +87,7 @@ public class RenderTilePool extends TileEntitySpecialRenderer {
GL11.glEnable(GL11.GL_BLEND);
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
GL11.glDisable(GL11.GL_ALPHA_TEST);
GL11.glColor4f(1F, 1F, 1F, (float) ((Math.sin((double) (ClientTickHandler.ticksInGame + f) / 20.0) + 1) * 0.3 + 0.2));
GL11.glColor4f(1F, 1F, 1F, (float) ((Math.sin((ClientTickHandler.ticksInGame + f) / 20.0) + 1) * 0.3 + 0.2));
GL11.glTranslatef(-0.5F, -1F - 0.43F, -0.5F);
GL11.glRotatef(90F, 1F, 0F, 0F);
GL11.glScalef(s, s, s);
@@ -60,7 +60,7 @@ public class RenderTileRuneAltar extends TileEntitySpecialRenderer {
angles[i] = totalAngle += anglePer;
double time = ClientTickHandler.ticksInGame + partticks;
for(int i = 0; i < altar.getSizeInventory(); i++) {
GL11.glPushMatrix();
GL11.glScalef(0.5F, 0.5F, 0.5F);
@@ -57,7 +57,7 @@ public class RenderTileSpreader extends TileEntitySpecialRenderer {
GL11.glScalef(1F, -1F, -1F);
double time = ClientTickHandler.ticksInGame + f;
if(spreader.isULTRA_SPREADER()) {
Color color = Color.getHSBColor((float) ((time * 5 + new Random(spreader.xCoord ^ spreader.yCoord ^ spreader.zCoord).nextInt(10000)) % 360) / 360F, 0.4F, 0.9F);
GL11.glColor3f(color.getRed() / 255F, color.getGreen() / 255F, color.getBlue() / 255F);
@@ -46,7 +46,7 @@ public class RenderTileTinyPotato extends TileEntitySpecialRenderer {
float jump = potato.jumpTicks;
if(jump > 0)
jump += var8;
float up = (float) -Math.abs(Math.sin(jump / 10 * Math.PI)) * 0.2F;
float rot = (float) Math.sin(jump / 10 * Math.PI) * 2;
@@ -66,12 +66,12 @@ public final class ModManaInfusionRecipes {
manaQuartzRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.quartz, 1, 1), new ItemStack(Items.quartz), 250);
tinyPotatoRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModBlocks.tinyPotato), new ItemStack(Items.potato), 1337);
if(Botania.thaumcraftLoaded) {
Item inkwell = (Item) Item.itemRegistry.getObject("Thaumcraft:ItemInkwell");
manaInkwellRecipe = BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.manaInkwell), new ItemStack(inkwell), 35000);
}
BotaniaAPI.registerManaInfusionRecipe(new ItemStack(ModItems.manaBottle), new ItemStack(Items.glass_bottle), 5000);
}
@@ -13,7 +13,6 @@ package vazkii.botania.common.item.interaction.thaumcraft;
import java.util.List;
import cpw.mods.fml.common.Optional;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
@@ -24,6 +23,7 @@ import vazkii.botania.api.mana.IManaItem;
import vazkii.botania.common.core.helper.ItemNBTHelper;
import vazkii.botania.common.item.ItemMod;
import vazkii.botania.common.lib.LibItemNames;
import cpw.mods.fml.common.Optional;
@Optional.Interface(modid = "Thaumcraft", iface = "thaumcraft.api.IScribeTools")
public class ItemManaInkwell extends ItemMod implements IManaItem, IScribeTools {
@@ -40,13 +40,13 @@ public class ItemManaInkwell extends ItemMod implements IManaItem, IScribeTools
setMaxStackSize(1);
setNoRepair();
}
@Override
public void getSubItems(Item item, CreativeTabs tab, List list) {
list.add(new ItemStack(item, 1, USES));
list.add(new ItemStack(item));
}
@Override
public int getDamage(ItemStack stack) {
float mana = getMana(stack);
@@ -66,7 +66,7 @@ public class ItemManaInkwell extends ItemMod implements IManaItem, IScribeTools
}
super.setDamage(stack, damage);
}
@Override
public int getDisplayDamage(ItemStack stack) {
return getDamage(stack);
@@ -121,5 +121,5 @@ public class ItemManaInkwell extends ItemMod implements IManaItem, IScribeTools
public boolean isNoExport(ItemStack stack) {
return true;
}
}
@@ -641,7 +641,7 @@ public final class LexiconData {
starfield = new ALexiconEntry(LibLexicon.MISC_STARFIELD, categoryMisc);
starfield.setLexiconPages(new PageText("0"), new PageCraftingRecipe("1", ModCrafingRecipes.recipeStarfield));
if(Botania.thaumcraftLoaded) {
tcIntegration = new BLexiconEntry(LibLexicon.MISC_TC_INTEGRATION, categoryMisc);
tcIntegration.setLexiconPages(new PageText("0"), new PageText("1"), new PageCraftingRecipe("2", ModCrafingRecipes.recipeHelmetOfRevealing), new PageText("3"), new PageManaInfusionRecipe("4", ModManaInfusionRecipes.manaInkwellRecipe), new PageText("5"));