Search in sources :

Example 11 with ShaderLayer

use of blusunrize.immersiveengineering.api.shader.ShaderCase.ShaderLayer in project ImmersiveEngineering by BluSunrize.

the class ShaderRegistry method registerShader_Balloon.

/**
	 * Method to register a default implementation of Balloon Shaders
	 * @param name name of the shader
	 * @param overlayType uses IE's existing overlays. To use custom ones, you'll need your own method.
	 * @param rarity Rarity of the shader item
	 * @param colour0 base colour
	 * @param colour1 design colour
	 * @param additionalTexture additional overlay texture. Null if not needed.
	 * @param colourAddtional colour for the additional texture, if present
	 * @return the registered ShaderCase
	 */
public static ShaderCaseBalloon registerShader_Balloon(String name, String overlayType, EnumRarity rarity, int colour0, int colour1, String additionalTexture, int colourAddtional) {
    ArrayList<ShaderLayer> list = new ArrayList();
    list.add(new ShaderLayer(new ResourceLocation("immersiveengineering:blocks/shaders/balloon_0"), colour0));
    list.add(new ShaderLayer(new ResourceLocation("immersiveengineering:blocks/shaders/balloon_1_" + overlayType), colour1));
    if (additionalTexture != null) {
        ResourceLocation rl = new ResourceLocation("immersiveengineering:blocks/shaders/balloon_" + additionalTexture);
        list.add(new ShaderLayer(rl, colourAddtional).setTextureBounds(defaultLayerBounds.get(rl)));
    }
    list.add(new ShaderLayer(new ResourceLocation("immersiveengineering:blocks/shaders/balloon_uncoloured"), 0xffffffff));
    ShaderCaseBalloon shader = new ShaderCaseBalloon(list);
    return registerShaderCase(name, shader, rarity);
}
Also used : ShaderLayer(blusunrize.immersiveengineering.api.shader.ShaderCase.ShaderLayer) ResourceLocation(net.minecraft.util.ResourceLocation)

Aggregations

ShaderLayer (blusunrize.immersiveengineering.api.shader.ShaderCase.ShaderLayer)11 ResourceLocation (net.minecraft.util.ResourceLocation)10 ShaderCase (blusunrize.immersiveengineering.api.shader.ShaderCase)2 ItemStack (net.minecraft.item.ItemStack)2 ComparableItemStack (blusunrize.immersiveengineering.api.ComparableItemStack)1 ShaderWrapper (blusunrize.immersiveengineering.api.shader.CapabilityShader.ShaderWrapper)1 IShaderItem (blusunrize.immersiveengineering.api.shader.IShaderItem)1 ShaderRegistry (blusunrize.immersiveengineering.api.shader.ShaderRegistry)1 ShaderRegistryEntry (blusunrize.immersiveengineering.api.shader.ShaderRegistry.ShaderRegistryEntry)1 BulletHandler (blusunrize.immersiveengineering.api.tool.BulletHandler)1 ITextureOverride (blusunrize.immersiveengineering.common.items.IEItemInterfaces.ITextureOverride)1 DrillHeadPerm (blusunrize.immersiveengineering.common.items.ItemDrillhead.DrillHeadPerm)1 Method (java.lang.reflect.Method)1 ArrayList (java.util.ArrayList)1 BakedQuad (net.minecraft.client.renderer.block.model.BakedQuad)1 ModelResourceLocation (net.minecraft.client.renderer.block.model.ModelResourceLocation)1 UnpackedBakedQuad (net.minecraftforge.client.model.pipeline.UnpackedBakedQuad)1 TRSRTransformation (net.minecraftforge.common.model.TRSRTransformation)1 IExtendedBlockState (net.minecraftforge.common.property.IExtendedBlockState)1 SubscribeEvent (net.minecraftforge.fml.common.eventhandler.SubscribeEvent)1