Minecraftforge: [Future suggestion] Forge provided fluid rendering

Created on 7 May 2017  路  13Comments  路  Source: MinecraftForge/MinecraftForge

Yet we have IFluidTank here to store the fluid, but we have to write rendering ourselves.
Why not make a universal fluid rendering utility/system? That would be a good news for developers(especially for new mod developers).

Feature Stale

Most helpful comment

There is one: https://github.com/MinecraftForge/MinecraftForge/blob/1.11.x/src/main/java/net/minecraftforge/client/model/ModelFluid.java
This is what's rendering for fluids in-world. X and Z bounds are static constants in code right now, but it should be possible to change those to be parameters instead easily. And add tiling for tanks that are bigger than 1 block.

All 13 comments

There is one: https://github.com/MinecraftForge/MinecraftForge/blob/1.11.x/src/main/java/net/minecraftforge/client/model/ModelFluid.java
This is what's rendering for fluids in-world. X and Z bounds are static constants in code right now, but it should be possible to change those to be parameters instead easily. And add tiling for tanks that are bigger than 1 block.

we want it for gui rendering

@RainWarrior Yes we have fluid rendering in the world, but we also need a flexible GUI for players or developers.

Whether you're rendering in the GUI or in the world doesn't make much difference for the rendering code itself. I don't see how that's relevant at all.

@RainWarrior i think their question is a forge provided method where they can have forge render a fluid in a gui by just passing the fluid and dimensions

This issue has been automatically marked as stale because it has not had activity in a long time, and will be closed if no further activity occurs. If this issue was overlooked, forgotten, or should remain open for any other reason, please reply here to call attention to it and remove the stale status. Thank you for your contributions.

I believe such a utility is still useful.

@mezz Maybe you can migrate the render functions in JEI into Forge as a util gui class?

That would work, but usually we don't add utility functions to Forge that aren't being used somewhere. Someone needs to discuss with Lex to see if something like this would be accepted.

This issue has been automatically marked as stale because it has not had activity in a long time. If this issue is still relevant and should remain open, please reply with a short explanation (e.g. "I have checked the code and this issue is still relevant because ___." or "Here's a screenshot of this issue on the latest version"). Thank you for your contributions!

This issue has been automatically closed because it has not had activity in a long time. Please feel free to reopen it or create a new issue.

Was this page helpful?
0 / 5 - 0 ratings