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. Did you create and register the Serializer ? Look at the pig loot table to see how it uses the on_fire property to determine whether the meat should be cooked.
  2. You need to implement EntityProperty , look at EntityOnFire for an example.
  3. Then the load time is unrelated to the loading screen. Sky Factory does have approximately 118 mods, whereas Tekkit has approximately 62 mods. It's not that surprising that loading almost twice as many mods will take longer.
  4. It looks like you'll need to create an EntityProperty to test whether the entity has been tamed. You'll also need to create its EntityProperty.Serializer and register an instance of it with EntityPropertyManager.registerProperty . In your loot table, use the entity_properties condition with your property.
  5. I can assure you that the method and field both exist in 1.8.9.
  6. Side note: The instanceof operator already returns false if the object is null , there's no need to check for null before using the operator.
  7. The EAQ explains how to disable the loading screen (search for "loading screen"). Try disabling the loading screen and see if it makes any difference to the loading time.
  8. You shouldn't need a custom implementation of IItemHandler , just use ItemStackHandler . Create an IItemHandler field in your TileEntity to contain its inventory and set it to an instance of ItemStackHandler . To replicate ISidedInventory , use a separate IItemHandler for each group of slots. Override hasCapability to return true when the Capability is CapabilityItemHandler.ITEM_HANDLER_CAPABILITY and the inventory can be accessed from the specified EnumFacing (if you actually care about the facing at all). Override getCapability to check if the Capability is CapabilityItemHandler.ITEM_HANDLER_CAPABILITY . If it is, return the appropriate IItemHandler for the specified EnumFacing . In both hasCapability and getCapability , return the result of the super method when the Capability isn't CapabilityItemHandler.ITEM_HANDLER_CAPABILITY . This allows external capabilities attached from AttachCapabilitiesEvent to be used.
  9. I'm not entirely sure if this is possible with the baked model system. You can disable shadows for a model element/ BakedQuad (see the model format or this example), but that doesn't render the model at full brightness. You may need to use a TESR for this.
  10. Minecraft#getCurrentServerData returns the ServerData of the current server, if any. ServerData#serverIP contains the IP/URL of the server.
  11. See the wiki page. They're basically a more flexible replacement for ChestGenHooks / WeightedRandomChestContent that are also used for entity drops. Forge hasn't added any hooks for loot tables yet, but you can still register your own using the vanilla classes. You can see my loot table registration class here and a loot table here.
  12. Don't call ModelBakery.registerItemVariants for the override models, they will automatically be loaded. This error looks like it's caused by Forge trying to load tetracraft:item/ballisticBow_pulling_1 , which is trying to load the parent model tetracraft:item/ballisticBow , which is trying to load the override model tetracraft:item/ballisticBow_pulling_1 . If you allow the override models to be loaded automatically, you won't run into any circular reference errors.
  13. The last argument of World#rayTraceBlocks (used by both EntityLivingBase#rayTrace and Item#getMovingObjectPositionFromPlayer ) determines whether it should return the MovingObjectPosition of the last uncollidable block or null when the raytrace doesn't hit anything. You'll need to call this yourself with the appropriate arguments rather than using one of its wrappers, though you can reuse the code from Item#getMovingObjectPositionFromPlayer .
  14. Minecraft ran out of memory. There are lots of tutorials out there that explain how to give Minecraft more memory.
  15. Some 1.8 mods may work in 1.8.9, but there's no guarantee that every mod will. 1.8.8/1.8.9 didn't change a lot of things, but there were a few minor changes that will break some 1.8 mods.
  16. Although I agree that the imports should be cleaned up, imported classes aren't actually loaded at runtime unless they're referenced in the code itself. Importing a client-only class won't crash the server, using it outside of client-only code will. In IDEA (which I believe the OP is using), Ctrl-Alt-O optimises imports. I also make heavy use of Ctrl-Alt-L to reformat the current class, which also optimises imports.
  17. It's trying to load the client-only interface IStateMapper on the server when you call Registers.addItem because another method of Registers references IStateMapper . This is exactly the same error as diesieben07 was talking about earlier in the thread: you need to separate your client-only code from your common code (the proper solution) or mark client-only methods with @SideOnly(Side.CLIENT) (a quick fix).
  18. It used to, but it now returns a ResourceLocation under the new registry system. Edit: I can't spell.
  19. Raytracing doesn't have to happen on the client side, you've just picked a client-only method. Look at ItemMonsterPlacer#onItemRightClick to see how it raytraces on the server side.
  20. Have you updated your models to use the new override system? You can see my bow's new model here.
  21. Update your MCP mappings by setting the minecraft.mappings property in build.gradle, re-run setupDecompWorkspace and refresh your IDE project. The MCPBot website shows the mappings available for each version of Minecraft.
  22. Method references were introduced in Java 8, so setting the language level to 8 should allow them. There is no isAmmo method in ItemBow , though; only isArrow .
  23. I briefly skimmed through your code and couldn't see any obvious errors. I suggest you post the FML log from the server and client using Gist. I did notice a few things that could be improved: Instead of checking the event's side in your @EventHandler methods to do client-only things, use the @SidedProxy system. Instead of using the deprecated GameRegistry.registerItem method, use the new GameRegistry.register method. It's recommended that you use the single-argument overload of this method and set the registry name of the object you're registering (e.g. an Item ) with IForgeRegistryEntry#setRegistryName (or one of the overloads from IForgeRegistryEntry.Impl ) before registering it. Instead of registering models with ItemModelMesher#register in init, use ModelLoader.setCustomModelResourceLocation / setCustomMeshDefinition in preInit. The default model loaded for every Item is the one with its registry name ( IForgeRegistryEntry#getRegistryName ), so you should use this rather than creating your own name field and getName methods.
  24. Look for the getBlockReachDistance / setBlockReachDistance methods of ItemInWorldManager (1.8.9 and earlier) or PlayerInteractionManager (1.9+).
  25. To give a sound event a subtitle, set the "subtitle" key of the sound event in sounds.json to a string containing the translation key. An example from the vanilla sounds.json file: "item.shovel.flatten": { "sounds": [ "item/shovel/flatten1", "item/shovel/flatten2", "item/shovel/flatten3", "item/shovel/flatten4" ], "subtitle": "subtitles.item.shovel.flatten" },

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.