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.

MrProg

Members
  • Joined

  • Last visited

  1. Here is my enchanted_gem.json: { "parent": "builtin/generated", "textures": { "layer0": "vp:items/enchanted_gem" }, "display": { "thirdperson": { "rotation": [ -90, 0, 0 ], "translation": [ 0, 1, -3 ], "scale": [ 0.55, 0.55, 0.55 ] }, "firstperson": { "rotation": [ 0, -135, 25 ], "translation": [ 0, 4, 2 ], "scale": [ 1.7, 1.7, 1.7 ] } } }
  2. Images of the issue: The top and side of this item is a bit weird, it looks like not all of the pixels are rendering in 3D. The code should be fine but here it is: public static void init(){ enchanted_gem = new ItemBasic().setUnlocalizedName("enchanted_gem"); enchanted_dust = new ItemEnchantedDust().setUnlocalizedName("enchanted_dust"); } public static void register(){ GameRegistry.registerItem(enchanted_gem, "enchanted_gem"); GameRegistry.registerItem(enchanted_dust, "enchanted_dust"); } public static void registerRenders(){ registerRender(enchanted_gem); registerRender(enchanted_dust); } public static void registerRender(Item item){ Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item, 0, new ModelResourceLocation(Reference.MOD_ID + ":" + item.getUnlocalizedName().substring(5), "inventory")); } The item in the pics is the enchanted_gem, while enchanted_dust works perfectly fine.
  3. So I'm trying to use the PlayerSleepInBedEvent but I want all of my code to execute somewhat while the player is in the middle of sleeping not as soon as the player right-clicks the bed. Is there a way to do this? Before I started using this event I used a PlayerTickEvent and just used the sleepTimer from the player of when to activate the event but I feel that the tick event may cause lag if it's always checking the if statement. Please correct me if I'm wrong but any help is appreciated
  4. Thanks! Forgot I had that. Also done! Thanks for the help.
  5. Alright so I have these achievements here: if(player.inventory.hasItem(Item.getItemFromBlock(WinterBlocks.icedStone))){ player.addStat(WinterAch.icedStone, 1); } if(player.inventory.hasItem(WinterItems.iceCrystal)){ player.addStat(WinterAch.iceCrystal, 1); } if(player.inventory.hasItem(WinterItems.iceIngot)){ player.addStat(WinterAch.iceIngot, 1); } So basically I have these all in a PlayerTickEvent which can lead onto some lag. At least logically. So I was wondering if there was a different place I could put these items with the same effect. These items are crafted in a custom furnace so using the pickup or crafting events won't be useful here.
  6. So Im trying to get an item array pick out a random item drop. But I've been testing and all I get is null. The metaList works because I get back 4 but for some reason my itemList only returns null. Here is the code for better understanding: public Item[] itemList = {WinterItems.crystalSword,WinterItems.refIcePickaxe,WinterItems.candyCaneAxe,WinterItems.commonItem}; public int[] metaList = {0,0,0,4}; public Item itemDropped; public int metaDropped; public BlockChristmasPresent(Material par2Material) { super(par2Material); this.itemDropped = itemList[3]; this.metaDropped = metaList[3]; } public void onBlockHarvested(World par1World, int par2, int par3, int par4, int par5, EntityPlayer par6EntityPlayer) { par1World.playSoundAtEntity(par6EntityPlayer, "wintercraft:rip", 1F, 1F); System.out.println(itemList[0]); System.out.println(metaDropped); } Thanks for any help!
  7. Oh yeah. Sorry I forgot all about that. Here it is: package wintercraft.items; import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.item.ItemRecord; import net.minecraft.util.ResourceLocation; import wintercraft.Wintercraft; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; public class ItemChristmasMusicDisk extends ItemRecord{ public ItemChristmasMusicDisk(String recordName) { super(recordName); this.setCreativeTab(Wintercraft.WintercraftTab); this.maxStackSize = 1; } @Override public ResourceLocation getRecordResource(String name) { return new ResourceLocation(recordName); } @SideOnly(Side.CLIENT) public void registerIcons(IIconRegister par1IconRegister) { this.itemIcon = par1IconRegister.registerIcon(Wintercraft.modid + ":" + this.getUnlocalizedName().substring(5)); } }
  8. If I'm not mistaken, all that is required for adding sound in 1.7.10 is the sounds.json correct? Here it is anyway:
  9. Nope just tested with Optifine. It works on vanilla so it must be that.
  10. For some reason Optifine is conflicting with my mod and whenever I go to use a custom music disk it just doesn't play but the text will show up. Any ideas?
  11. That make sense, I had Optifine before and turned it higher than the default max. Thanks!

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.