Everything posted by Choonster
-
{Solved!!! Finally!!!} [1.10.2] Gui With Chest
Wow, every time I think I have a genuine problem, I always just look like an idiot because it is something stupid I missed. What do I need to put instead of null there? I am not sure.. Delete the TileEntityTestChest method (it has no reason to exist) and use the new operator in createNewTileEntity (this is how you create new objects).
-
[1.10.2] Custom Lead Entity Won't Render (unsolved)
EntityLeashKnot extends EntityHanging , but your EntityRopeKnot doesn't. Do you replicate all of the logic from EntityHanging yourself? There a few places where Minecraft checks if an entity is an instance of EntityHanging , so you may want to extend it (or extend EntityLeashKnot since your entity seems to be very similar).
-
[1.10.2] Custom Lead Entity Won't Render (unsolved)
Render and IRenderFactory both have a generic type argument: the entity type that they support. If you try to return an incompatible Render instance from your IRenderFactory (e.g. an instance of RenderZombie for EntityArrow ), you'll get a compilation error because the generic types don't match. Is the method that calls RenderingRegistry.registerEntityRenderingHandler definitely being called? Is RenderRopeKnot#doRender being called? Are there any errors in the log? Side note: You should always annotate override methods with @Override so you get a compilation error if they don't actually override a super method. You should also consider extending EntityLeashKnot and overriding any required methods instead of copy-pasting it.
-
[1.10.2]Where are banner/shield textures applied?
TileEntityItemStackRenderer#renderByItem is responsible for rendering the banner/shield items (as well as skulls, chests and shulker boxes). This uses TileEntityBanner#setItemValues to read colour/pattern data from the ItemStack and BannerTextures.Cache#getResourceLocation to get the ResourceLocation of the shield texture from the TileEntityBanner instance. Mods can register a TileEntitySpecialRenderer for their Item s, but this is deprecated and will be removed as soon as possible. Instead, you should use the baked model system to generate models and textures at runtime like Forge's ModelDynBucket does. You can also use the capability system to store your data as objects instead of having to read it from and write it to NBT every time you interact with it. Unfortunately, syncing of item capabilities is tricky. Capability-only changes to an ItemStack in a server-side Container will cause an SPacketSetSlot to be sent for the slot, but this doesn't include the capability data so the client-side copy of the capability data will be reset to the default. This PR and this issue discuss potential fixes for this. One way to handle the syncing currently is to register an IContainerListener , as described in this thread.
-
[Forge 1.11] Several issues with Chests, Doors, Villagers...
It looks like you already figured this out yourself, but for future reference click the Files link at the top of the site or go files.minecraftforge.net.
-
[1.10.2] Custom Lead Entity Won't Render (unsolved)
Just to be clear, you've tried calling RenderingRegistry#registerEntityRenderingHandler(Class<T>, IRenderFactory<? super T>) with an IRenderFactory that produces a RenderRopeKnot instance in preInit? Is the method that calls this definitely being called? RenderLeashKnot can only be used for entities that extend EntityLeashKnot .
-
[Forge 1.11] Several issues with Chests, Doors, Villagers...
Update to the latest version of Forge, these bugs have already been fixed.
-
Crafting is broken
It looks like you figured this out in your thread, but for future reference click the Files link at the top of the site or go files.minecraftforge.net.
-
[1.10.2] Best place to register item renderers
The currently recommended way to register things like Item s and models is using the recently-added registry events. I explain them here.
-
No Run Configuations
cpw explains how to generate the run configurations for IDEA in .
-
[SOLVED][1.10.2] Changing Item Texture at Runtime
You'll probably need to generate textures and models at runtime like ModelDynBucket does.
-
[1.10.2] Custom Lead Entity Won't Render (unsolved)
You're using the deprecated overload of RenderingRegistry.registerEntityRenderingHandler in preInit, before the RenderManager instance has been created. I'm surprised the game isn't crashing with a NullPointerException as soon as it tries to render the entity. Use the non-deprecated overload of RenderingRegistry.registerEntityRenderingHandler (the IRenderFactory one) instead.
-
Crafting is broken
Oh it turns out I had downloaded an outdated version. When was Forge most recently updated? I got it about 2 days ago, before I learned how to use it. Thank you very much! A new version is automatically released every time a change is pushed to the main repository on GitHub. This usually happens every day (or several times a day) for a Minecraft version that's been released recently or slightly less often for a Minecraft version that's been out for a while. 1.11 was released fairly recently and changed a few things around, so there's a lot of active development going on for it.
-
Problem when I start forge
Post the full FML log (logs/fml-client-latest.log) using Gist. It looks like you may be trying to load a 1.7.10 version of Forge as a mod in a newer version of Forge, which won't work (and doesn't make any sense).
-
Crafting is broken
Make sure you're using Forge 1.11-13.19.0.2178, the latest version. If the issues still happen with the latest version, upload the FML log (logs/fml-client-latest.log) to Gist and link it here.
-
[1.10.2] Intellij not correctly grabbing resources
What you're doing should work, though it's no longer the recommended way to import the project into IDEA. Try following from cpw and see if anything changes.
-
[1.10.2] Finite fluid and gas rendering problems
Does that mean I need to fix it myself again? Grumble grumble. (I'm the one that did it for 1.7.10) That's probably going to be the quickest way to get these issues fixed.
-
[1.10.2] Finite fluid and gas rendering problems
The issue with the gas (negative density fluid) has been reported here. The issue with the other fluid is probably this one. Unfortunately it may take a while for these to get fixed as Fry (Forge's rendering guy) hasn't been working much on Forge lately.
-
[SOLVED][1.10.2] Mapping Block to its Textures
IBakedModel#getQuads can give you the BakedQuad s for an EnumFacing and BakedQuad#getSprite can give you the texture of a BakedQuad . If you're storing an IBlockState , you can use BlockModelShapes#getModelForState to get the IBakedModel . If you're storing an ItemStack , you can use ItemModelMesher#getItemModel(ItemStack) , IBakedModel#getOverrides and ItemOverrideList#handleItemState to get the IBakedModel .
-
[SOLVED][1.10.2] Mapping Block to its Textures
Do you need to get this texture at runtime or can you simply create a texture for each block's armour on disk? If you do need to get the texture at runtime, you can use the particle texture of the block's model. If your armour stores an IBlockState , use BlockModelShapes#getTexture to get the particle texture of that state's model. If your armour stores an ItemStack , use ItemModelMesher#getParticleIcon to get the particle texture of that item's model.
-
[Solved]metadata checking causes crash problem
ItemStack#getDisplayName will throw a NullPointerException when you call it on an ItemStack with a null Item . Side note: Why are you raytracing once for each coordinate of the block and then immediately creating a BlockPos from those coordinates? Raytrace once and use the BlockPos from the RayTraceResult directly.
-
[1.10.2] [SOLVED] Registering sounds
Create a SoundEvent with the ResourceLocation of your sound (i.e. your mod ID as the domain and the event name from sounds.json as the path), subscribe to RegistryEvent.Register<SoundEvent> and then use RegistryEvent.Register#getRegistry to get the registry and IForgeRegistry#register or IForgeRegistry#registerAll to register your SoundEvent . RegistryEvent.Register is fired before preInit, so you need to subscribe to it with a static method annotated with @SubscribeEvent in a class annotated with @Mod.EventBusSubscriber . You can see how I do this here.
-
[1.10.2] Piston Interaction
Block#getMobilityFlag determines whether a Block can be pushed by a piston. There have been various PRs for piston events in the past, but none have been merged yet. If you need these events, consider submitting a current PR.
-
[1.10.2] Get WorldSavedData from IBlockAccess
If you know you're on the client, you should be able to access the client World through the Minecraft#world field.
-
[1.11][SOLVED] Dual Input Recipes Issue
ItemStack doesn't override Object#hashCode , so two ItemStack s will only have the same hash code if they're the same object. You shouldn't actually need to override Object#hashCode if your recipe class isn't being used as the key of a HashMap . If you do override it, you need to generate your own hash code for each ItemStack based on the parts your recipe cares about ( Item , metadata, NBT and/or capabilities). Are you sure your updated equals method is correct? You're comparing item1 and item2 , item2 and item2 and item1 and item3 . Should you not be comparing item1 and item1 , item2 and item2 , item3 and item3 ?
IPS spam blocked by CleanTalk.