Better texture-colors for regular metals. Added bismuth texture to tool. Fixed explosion of tiberiumOre.
@@ -43,15 +43,19 @@ public class BlockTiberium extends BasicBlock {
|
||||
|
||||
@Override
|
||||
public void onBlockDestroyedByExplosion(World worldIn, BlockPos pos, Explosion explosionIn) {
|
||||
if (!worldIn.isRemote) {
|
||||
if (MathHelper.getRandomIntegerInRange(random, 1, 15) > 10) {
|
||||
worldIn.newExplosion(null, pos.getX(), pos.getY(), pos.getZ(), 1.3f, true, true);
|
||||
worldIn.newExplosion(null, pos.getX(), pos.getY(), pos.getZ(), 1.6f, true, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockDestroyedByPlayer(World worldIn, BlockPos pos, IBlockState state) {
|
||||
if (MathHelper.getRandomIntegerInRange(random, 1, 30) < 3) {
|
||||
worldIn.newExplosion(null, pos.getX(), pos.getY(), pos.getZ(), 1.0f, true, true);
|
||||
if (!worldIn.isRemote) {
|
||||
worldIn.newExplosion(null, pos.getX(), pos.getY() + 1 / 16f, pos.getZ(), 1.1f, true, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -7,10 +7,13 @@ import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.block.model.ModelResourceLocation;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
import slimeknights.tconstruct.library.client.MaterialRenderInfo;
|
||||
import slimeknights.tconstruct.library.materials.Material;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
|
||||
import static com.sosnitzka.ztic_addon.Materials.bismuth;
|
||||
|
||||
public class ClientProxy extends ServerProxy {
|
||||
|
||||
private static void registerBlockModel(Block block) {
|
||||
@@ -53,6 +56,10 @@ public class ClientProxy extends ServerProxy {
|
||||
}
|
||||
|
||||
public void setRenderInfo(Material material, Fluid fluid) {
|
||||
material.setRenderInfo(fluid.getColor());
|
||||
if (material != bismuth) {
|
||||
material.setRenderInfo(new MaterialRenderInfo.Metal(fluid.getColor(), 0.8f, 0.2f, 0f));
|
||||
} else bismuth.setRenderInfo(new MaterialRenderInfo.BlockTexture("ztic_addon:blocks/bismuth_block"));
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -16,7 +16,6 @@ public class Utils {
|
||||
public static String PREFIX_ORE = "ore";
|
||||
public static String PREFIX_BLOCK = "block";
|
||||
|
||||
|
||||
public static void registerBlockWithItem(Block block) {
|
||||
System.out.println(String.format("Register Block: %s", block.getUnlocalizedName()));
|
||||
GameRegistry.register(block);
|
||||
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |