Everything posted by Scatterbuns
-
Craftable Item that spawns mobs? [Unsolved]
Thanks, that worked!
-
Craftable Item that spawns mobs? [Unsolved]
That works but it seems to spawn ghosts of the entity...
-
Craftable Item that spawns mobs? [Unsolved]
Haven't figured this out yet, I just need an item that can be crafted and, upon right-clicking a block, spawn an entity.
-
Craftable Item that spawns mobs? [Unsolved]
How would I just use the ID instead of GameRegistry.addRecipe(new ItemStack(Mod.modItem, 1), new Object[] ?
-
Craftable Item that spawns mobs? [Unsolved]
I'd like to make an item that would act as an egg and spawn a custom mob, but is craftable. Is this possible? If not, how could I make the mob's egg craftable?
-
Adding new music disk?
package daki; import java.util.List; import net.minecraft.block.Block; import net.minecraft.block.BlockJukeBox; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemRecord; import net.minecraft.item.ItemStack; import net.minecraft.world.World; public class ItemGroovyDisc extends ItemRecord { public final String recordName; public ItemGroovyDisc(int id) { super(id, "groovy.ogg"); this.setCreativeTab(CreativeTabs.tabMisc); this.maxStackSize = 1; this.recordName = "groovy.ogg"; } public String getTextureFile() { return "/Daki/dakiitems.png"; } public boolean onItemUse(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, World par3World, int par4, int par5, int par6, int par7, float par8, float par9, float par10) { if (par3World.getBlockId(par4, par5, par6) == Block.jukebox.blockID && par3World.getBlockMetadata(par4, par5, par6) == 0) { if (par3World.isRemote) { return true; } else { ((BlockJukeBox)Block.jukebox).insertRecord(par3World, par4, par5, par6, par1ItemStack); par3World.playAuxSFXAtEntity((EntityPlayer)null, 1005, par4, par5, par6, this.itemID); --par1ItemStack.stackSize; return true; } } else { return false; } } @Override public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4) { par3List.add("groovy"); } } That's my record class, this whole thing is very confusing to me, I'm relatively new to modding and have have added multiple items and mobs before but these records are just so different. I'd appreciate it if someone could point out what I'm doing wrong, and groovy.ogg is in my \resources\mod\streaming folder. EDIT: I got it! I added: public String getSoundFile() { return "/resources/mod/streaming/groovy.ogg"; }
-
Adding new music disk?
I've gotten as far as a working item, now there is just one more problem, getting the sound to play.... If I change the name for the sound to cat, it plays, so my item works, but the name I need doesn't work. Do I need to convert to .mus?
-
Adding new music disk?
Is it currently possible in forge 1.4.7 to create a new music disk? I can't find any tutorials anywhere.
IPS spam blocked by CleanTalk.