Skip 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.

Choonster

Moderators
  • Joined

  • Last visited

Everything posted by Choonster

  1. The -D option sets system properties, which the -X options aren't. Forge's documentation explains how to give Gradle more memory here.
  2. Block s should be created and registered before Item s. You should be using the new registry events, RegistryEvent.Register<Block> will be fired before RegistryEvent.Register<Item> . If you don't want to call a bunch of setter methods at the place of instantiation, move them to the constructor.
  3. It looks like you passed a null Block to World#canBlockBePlaced from ItemCheeseCake#onItemUse . Side note: It looks like you've copy-pasted the vanilla cake code. Why not just use/extend the existing classes?
  4. Aren't those just String constants he's using to name the NBT fields? Not sure how that could cause any trouble... The attributes field is storing the attribute values, the attributeTags field is storing the tag names.
  5. I've never used Lombok myself, but it looks like Blood Magic uses a Gradle plugin for it; you may have more luck using this.
  6. CapAttributeData.attributes is a static field, so it's shared between all instances of CapAttributeData .
  7. Can you post the output from Gradle with and without --stacktrace ?
  8. There is no build/libs folder in my folder Only taskLogs and tmp I'm not sure why the libs directory wouldn't be there. Can you post the output from gradlew build and either your build.gradle file and a screenshot of your project's directory structure or a link to a complete repository of your project?
  9. Actually that means it couldnt find an Itemmodel.json and started looking for a blockstate because yes they can have those. I didn't know that, thanks. So items can have blockstates too? Yes. I have a description of the model loading process here, which explains this in more detail.
  10. Running the build Gradle task should compile and reobfuscate your code, outputting the JAR to build/libs. Gradle will skip a task if it doesn't need to be run (i.e. it already has a current and valid copy of the output file(s)).
  11. The speed reduction while using an item is handled in EntityPlayerSP#onLivingUpdate (line 934). You can probably counteract this by applying an AttributeModifier to the player's SharedMonsterAttributes.MOVEMENT_SPEED attribute from Item#onUsingTick . You'll also need to remove the modifier from this method if the player is mounted (because they won't be slowed in the first place) and also remove it from Item#onItemUseFinish . You may also want to handle FOVUpdateEvent to stop the FOV from increasing.
  12. Lines 159-162 of StatList : for (ItemStack itemstack : FurnaceRecipes.instance().getSmeltingList().values()) { set.add(itemstack.getItem()); } Someone added a furnace recipe with a null output.
  13. Lines 267-269 of SuperOresGeneration : if(Config.SapphireOre) { this.runGenerator(this.UraniumOre, world, random, chunkX, chunkZ, Config.SapphireRate, 0, 54); } this.UraniumOre is almost certainly the wrong field to use here.
  14. ItemBlock s are rendered in exactly the same way as regular Item s, including the ability to use translucent textures. You can see an example of this here.
  15. You can use the forge:multi-layer model to combine other models that are rendered in different layers. I explain this in more detail here.
  16. is this file even needed? i'm updating old FarLands Mod https://github.com/Valiec/FarLands and i found this file in his repo and this file makes me unable to setup the workspace and i'm updating to 1.8.9 be cause then i'm going to update to 1.9 and then to 1.10.2 and i cant et the errors frm console bcause it closes No, it's not needed; it's included in Forge itself. I'm not sure why the original author decided to copy that and the Forge logo into their mod. If you're running the setupDecompWorkspace Gradle task from the command line, open a console window and then run the batch/shell script from that window instead of double-clicking on it.
  17. You need to call ModelLoader.setCustomModelResourceLocation to set the model for each metadata value of the Item . Consider creating an enum to store the metadata value, unlocalised name and other properties of each sub-item. For examples, look at ItemFishFood / ItemFishFood.FishType and ItemDye / EnumDyeColor .
  18. That appears to be Forge's AT, not yours. What are the errors? Why are you updating to 1.8.9 and not 1.10.2?
  19. You can have two entries for a golden apple in the same loot pool with different "entryName" properties, yes.
  20. Each entry in a loot pool must have a unique name. The default name of an entry is the name of the item or loot pool that it references. If you have multiple entries with the same default name, you need to set the "entryName" property of each entry to a unique name. The wiki has an explanation of the vanilla loot table format here. Forge adds the requirement that each loot pool must have a unique "name" property and each loot entry must have a unique name (either the default name or the "entryName" property). These requirements don't apply to vanilla's loot tables, only to mod loot tables.
  21. There are some examples linked in this thread.
  22. Instead of overriding Block#getItemDropped and calling super.getDrops , just create the List to return from getDrops yourself.
  23. The BlockFlowerPot.CONTENTS property isn't stored in the metadata, it's set by BlockFlowerPot#getActualState from the values stored in TileEntityFlowerPot . After setting the block to Blocks.FLOWER_POT , you need to get the TileEntity from the World and call TileEntityFlowerPot#setFlowerPotData to set the contents. Side note: Metadata should be considered an implementation detail, you shouldn't be calling Block#getStateFromMeta yourself. Instead, call Block#getDefaultState to get the default IBlockState and call IBlockState#withProperty to get an IBlockState with the appropriate property values.
  24. First you need to delay the removal of the TileEntity by overriding Block#removedByPlayer and Block#harvestBlock like BlockFlowerPot does in Forge's patch. Then you need to override Block#getDrops to create an ItemStack of the Item to drop and write the TileEntity 's NBT to the "BlockEntityTag" sub-compound of the ItemStack 's compound tag. Minecraft will automatically read your TileEntity from the "BlockEntityTag" sub-compound of the ItemStack used to place your block.
  25. You can still store data in ItemStack NBT, but I'd recommend using a capability if your data is complex, you intend to store the same type of data for multiple different items or you intend for other mods to interact with/extend the data.

Important Information

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

Account

Navigation

Search

Search

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.