Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[SOLVED]Can not get the texture of fluid to show[1.7.10][help]

Featured Replies

Posted

Please take a look

http://imgur.com/A5ERhTR

 

Fluid class

 

package com.chaoshunter.blocks;

 

import net.minecraft.util.ResourceLocation;

import net.minecraftforge.fluids.Fluid;

import net.minecraftforge.fluids.FluidRegistry;

 

public class acidFluid extends Fluid{

 

public acidFluid(String fluidName) {

super(fluidName);

// TODO Auto-generated constructor stub

 

setDensity(3);

setViscosity(600);

setLuminosity(5);

 

}

 

}

 

 

 

fluidblock class

 

 

package com.chaoshunter.blocks;

 

import com.chaoshunter.Tabs.MODED_Tabs;

 

import cpw.mods.fml.relauncher.Side;

import cpw.mods.fml.relauncher.SideOnly;

import net.minecraft.block.material.Material;

import net.minecraft.client.renderer.texture.IIconRegister;

import net.minecraft.util.IIcon;

import net.minecraft.world.IBlockAccess;

import net.minecraft.world.World;

import net.minecraftforge.fluids.BlockFluidClassic;

import net.minecraftforge.fluids.Fluid;

 

public class acidBlock extends BlockFluidClassic{

 

@SideOnly(Side.CLIENT)protected IIcon stillIcon;

@SideOnly(Side.CLIENT)protected IIcon flowingIcon;

 

 

public acidBlock(Fluid fluid, Material material) {

super(fluid, material);

setCreativeTab(MODED_Tabs.tabBlock);

// TODO Auto-generated constructor stub

}

@Override public IIcon getIcon(int side, int meta){

return (side == 0 || side == 1) ? this.stillIcon : this.flowingIcon;

}

 

@SideOnly(Side.CLIENT)

@Override public void registerBlockIcons(IIconRegister register) {

stillIcon = register.registerIcon("testmod:fluidStill");

flowingIcon = register.registerIcon("testmod:fluidFlowing");

}

@Override public boolean canDisplace(IBlockAccess world, int x, int y, int z) {

if (world.getBlock(x, y, z).getMaterial().isLiquid())

return false;

return super.canDisplace(world, x, y, z);

}

 

@Override public boolean displaceIfPossible(World world, int x, int y, int z) {

if (world.getBlock(x, y, z).getMaterial().isLiquid())

return false;

return super.displaceIfPossible(world, x, y, z);

}

 

}

 

 

 

 

If you find a way to fix it please let me know Thanks in advance! ;)

life is easy if you stay claim and code

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.