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.

GotoLink

Members
  • Joined

  • Last visited

Everything posted by GotoLink

  1. In ~/.gradle/caches/minecraft
  2. Override one of the getIcon method in Item class. Then return the icon that fits your need. It needs to be registered once with IconRegister before being displayed. Item has a registerIcons method for that.
  3. Added another type of setup, with more comments in build.gradle
  4. Check for gui on client side, then send a packet with enough data to perform the item NBT update on server side. You'll have to build a IPacketHandler for this.
  5. Sorry, but writing in a programming language is one of the best aspect of Gradle. It is a lot easier to understand for a programmer like me. And yes, having to know Java has been a prerequisite to mod with Forge since long ago. Don't act like you are surprised that it is used somewhere. What's the reason Forge doesn't want to use Ant? You can use Ant if you want. If you are convinced it is better, then you don't need any help to make it work.
  6. You can't make an ItemStack with a null item.
  7. That method set the block metadata, according to the last parameter given. Do you know the metadata range is [0,15] ?
  8. Use your item instance item id, not some random number.
  9. That is the whole content of the build.gradle file in Project1 folder.
  10. You can do the same you were doing previously, using batch files to copy things over the default src folder. Or tell Gradle your mod project depends on forge. Both things can be done through the build.gradle file, which also support most script language. I made a tutorial on multiple projects you might want to look into.
  11. Forge installation: While it might be a bit more complex than before, take in mind that you won't need to do it ever again. ForgeGradle will update to newer version as soon as you ask. No need to download a new forcesrc package extract run bat files then rebuild the project. It is done for you automatically. And you can downdate as easily. Building automation: You might already know, but with the Gradle plugin in Eclipse, you can run Gradle tasks within Eclipse. No longer need to run your own automated bat files to build. Granted, if you had already automated everything for modding, I don't think Gradle is giving you much. But it isn't much of an hassle to convert to, as you can probably include your scripts into Gradle. All in all, it is a great progress for new modders, whose work is going to be automated without them thinking much about it. For old modders, you can test your mods with multiple Minecraft+Forge versions really fast.
  12. AncientWarfare and BuildCraft|Core are missing/bugged.
  13. chunkX and chunkZ are the chunk coordinates, not world coordinates, by the way.
  14. That should do it: includeFlat 'src/Project1', 'src/Project2'
  15. Use include to work with Projects folder inside the Forge one. (hierarchical type) includeFlat works for folder on the same level. (flat type, ie. Forge and Project1 have the same root folder)
  16. You can have "auto versioning". I believe that is what the default build.gradle shipped with Forge tries to do with the mcmod.info: processResources { // replace stuff in mcmod.info, nothing else from(sourceSets.main.resources.srcDirs) { include 'mcmod/info' // replace version and mcversion expand 'version':project.version, 'mcversion':project.minecraft.version } So you can replace the values in files on building with expand . Or use an Ant Filter. And you can set a property value with gradle build -Pversion=NewVersion
  17. Depends on what they do, though it looks a bit confusing indeed.
  18. EntityJoinWorldEvent. Not sure what kind of mob would actually stop bat from spawning instead of killing it afterwards, but, who knows ?
  19. Then you did something wrong with your build.gradle.
  20. private static int timer; static is probably not good.
  21. Then the question is why you call player.setItemInUse(stack, maxDuration) instead of item.onPlayerStoppedUsing(ItemStack, World, EntityPlayer, int)
  22. gradlew clean cleanCache beforehand, then I am out of ideas.
  23. You mean Item#onPlayerStoppedUsing(ItemStack, World, EntityPlayer, int) ? It is public so...you only need an item instance to use it.

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.