-
Custom Block Rendering (HELP)
I have been working on a custom rendered block but there seems to be a bunch of tutorials but all are extremely useless because their modloader based. I know FML is forge modloader but I am just looking for a forge only tutorial, something that will walk me through it. If anybody would like to help me via PM or Skype many thanks would be given. Thanks
-
[UNSOLVED]Requesting help on problem "Walking through custom blocks?"
Google will not help me on this so will somebody else help me
-
[UNSOLVED]Requesting help on problem "Walking through custom blocks?"
public AxisAlignedBB getCollisionBoundingBoxFromPool(World par1World, int par2, int par3, int par4) { return AxisAlignedBB.getAABBPool().addOrModifyAABBInPool(2,2,2,3,3,3); } is what fence uses and it doesnt change the fact i can walk through my block no matter what i put as the min and max
-
[UNSOLVED]Requesting help on problem "Walking through custom blocks?"
Bro im using mcp so of course they will be like that
-
[UNSOLVED]Requesting help on problem "Walking through custom blocks?"
I have created some new items and i have set their bounds different then normal. For example if i made one 10 blocks long i would be able to walk through 9 of the blocks. The texture still shows though on the 10 long block. i have tryed setting public AxisAlignedBB getSelectedBoundingBoxFromPool(World par1World, int par2, int par3, int par4) { float var5 = 1F; return AxisAlignedBB.getAABBPool().addOrModifyAABBInPool((double)((float)par2 + var5), (double)par3, (double)((float)par4 + var5), (double)((float)(par2 + 1) - var5), (double)(par3 + 1), (double)((float)(par4 + 1) - var5)); } but im still able to walk through them
-
[Modding Help] I am requesting help on make a new jukebox Block
Or can you post some code bc i think we live in different time zones
-
[Modding Help] I am requesting help on make a new jukebox Block
Will you get on skype I have done what you said but my jukebox wont accept the disc
-
[Modding Help] I am requesting help on make a new jukebox Block
This is one of the ways i have tryed but i have been working on trying to make a new jukebox type block that plays music, i have also tryed extending block container and that doesnt work either, i would very much appreciated if one of you could skype me and help. Skype name is "werdwed" package net.minecraft.src.Schylar; import net.minecraft.block.BlockContainer; import net.minecraft.block.BlockJukeBox; import net.minecraft.block.TileEntityRecordPlayer; import net.minecraft.block.material.Material; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.tileentity.TileEntity; import net.minecraft.world.World; public class BlockSoundBoard extends BlockJukeBox{ public BlockSoundBoard(int id, int texture, Material mat) { super(id, texture, mat); setBlockBounds(0.0F, 0.0F, 0.0F, 3.0F, 1.0F, 1.0F); this.setCreativeTab(mod_SAKD.TabRave); } /** * Returns the block texture based on the side being looked at. Args: side */ public int getBlockTextureFromSide(int par1) { return this.blockIndexInTexture + (par1 == 1 ? 1 : 0); } /** * Called upon block activation (right click on the block.) */ public boolean onBlockActivated(World par1World, int par2, int par3, int par4, EntityPlayer par5EntityPlayer, int par6, float par7, float par8, float par9) { if (par1World.getBlockMetadata(par2, par3, par4) == 0) { return false; } else { this.ejectRecord(par1World, par2, par3, par4); return true; } } /** * Insert the specified music disc in the jukebox at the given coordinates */ public void insertRecord(World par1World, int par2, int par3, int par4, ItemStack par5ItemStack) { if (!par1World.isRemote) { TileEntityRecordPlayer var6 = (TileEntityRecordPlayer)par1World.getBlockTileEntity(par2, par3, par4); if (var6 != null) { var6.record = par5ItemStack.copy(); var6.onInventoryChanged(); par1World.setBlockMetadataWithNotify(par2, par3, par4, 1); } } } /** * Ejects the current record inside of the jukebox. */ public void ejectRecord(World par1World, int par2, int par3, int par4) { if (!par1World.isRemote) { TileEntityRecordPlayer var5 = (TileEntityRecordPlayer)par1World.getBlockTileEntity(par2, par3, par4); if (var5 != null) { ItemStack var6 = var5.record; if (var6 != null) { par1World.playAuxSFX(1005, par2, par3, par4, 0); par1World.playRecord((String)null, par2, par3, par4); var5.record = null; var5.onInventoryChanged(); par1World.setBlockMetadataWithNotify(par2, par3, par4, 0); float var7 = 0.7F; double var8 = (double)(par1World.rand.nextFloat() * var7) + (double)(1.0F - var7) * 0.5D; double var10 = (double)(par1World.rand.nextFloat() * var7) + (double)(1.0F - var7) * 0.2D + 0.6D; double var12 = (double)(par1World.rand.nextFloat() * var7) + (double)(1.0F - var7) * 0.5D; ItemStack var14 = var6.copy(); EntityItem var15 = new EntityItem(par1World, (double)par2 + var8, (double)par3 + var10, (double)par4 + var12, var14); var15.delayBeforeCanPickup = 10; par1World.spawnEntityInWorld(var15); } } } } /** * ejects contained items into the world, and notifies neighbours of an update, as appropriate */ public void breakBlock(World par1World, int par2, int par3, int par4, int par5, int par6) { this.ejectRecord(par1World, par2, par3, par4); super.breakBlock(par1World, par2, par3, par4, par5, par6); } /** * Drops the block items with a specified chance of dropping the specified items */ public void dropBlockAsItemWithChance(World par1World, int par2, int par3, int par4, int par5, float par6, int par7) { if (!par1World.isRemote) { super.dropBlockAsItemWithChance(par1World, par2, par3, par4, par5, par6, 0); } } /** * Returns a new instance of a block's tile entity class. Called on placing the block. */ public TileEntity createNewTileEntity(World par1World) { return new TileEntityRecordPlayer(); } public boolean isOpaqueCube(){ return false; } public boolean renderasnormalblock(){ return false; } public String getTextureFile(){ return "/TItemTextures/items.png"; } }
IPS spam blocked by CleanTalk.