Fusion (Connected Textures)

Fusion (Connected Textures)

11M Downloads

[Question] Fusion ignores Forge's `render_type` model property

LYIVX opened this issue ยท 19 comments

commented

Does The Support Transparent Textures, Because I've Been Trying To Use It For A Glass Texture And Just Seems To Come Out As Black Instead Of Transparent. I Have The Transparency Type Set As Cutout And Still Nothing. It Shows Transparent In The Players Hand Though

commented

when i take out the fusion code it goes transparent just not when the connected textures are back on

commented

Ah ok, that's likely a bug with Fusion then. No clue how Fusion would affect the render type though.

Could you share the model and texture jsons and potentially how you set the render type for the block?

commented

Yes it does support transparent textures. Here's a resource pack for Fusion which I believe also adds connecting textures for glass blocks. https://www.curseforge.com/minecraft/texture-packs/mt-ct-d

I Have The Transparency Type Set As Cutout

Note also that cutout means each pixel has either 0% transparency or 100%. If you want a truly transparent texture, you'd use the translucent render type.

commented

This mostly sounds like the render type is just somehow incorrect. The render type for the block has nothing to do with Fusion.

To make sure you could try copying the vanilla glass block model for your block and seeing if the textures are transparent. If the textures are transparent with the vanilla model, but not with Fusion's, it is likely a bug with Fusion. If the textures are also not transparent with the vanilla model, it something to do with your block and unrelated to Fusion.

commented

sorry for late respond been away, I've just tried the translucent render type and still coming up black, i had a look at the resource pack and ive set up mine in the same way.

commented

image

That seemed to fix it for now! Used following line in my ClientEvents class in FMLClientSetupEvent to set the rendertype in code! ItemBlockRenderTypes.setRenderLayer(ModBlocks.REACTOR_GLASS.get(), RenderType.cutout());

Just a quick question, could you maybe add a template png file with clear lines about full and compact mode. Its a big hard to analyse the gif given there, since its all mostly the same brown color. Thanks!

Hey would you mind showing me where you put the code?

commented

Is it the right way though, am I the problem here? :D

commented

Hey! Im experiencing the same problem, created my own glass block in my mod, same rendertype and blockproperties as the vanilla glass block, sadly the fusion overlayed texture stays black in transparent areas!
I even tried to add a "render_type": "minecraft:cutout" to the model file but didnt change anything.

image

Model: https://gist.github.com/UnhappyCodings/a68f94810d1afacddb04dac6319b9898
MCMeta: https://gist.github.com/UnhappyCodings/cea8d117f2ee36d2dda05fd14c9ba41b
Fusion-1.0.6 on 1.20.1 NeoForge 47.1.79

commented

(The item is with transparent, same for the block without fusion)

commented

Oh I see, you are using Forge's render_type property in the model file. Fusion might not pass that on correctly.

@LYIVX are you also setting the render type through the model file?

commented

No that is completely valid. I just forgot Forge added that property, so I might not have taken it into account for Fusion's models.

You could try setting the render type through code using I think ItemBlockRenderTypes#registerBlockRenderType or something like that.

commented

That seemed to fix it for now!

Ah then pretty sure that's just a bug with Fusion not respecting the render_type property.

Just a quick question, could you maybe add a template png file with clear lines about full and compact mode.

Hmm thought I already had that, but I guess I never did link to it anywhere in Fusion. You can find the files I use to create connected textures here in Rechiseled: https://github.com/SuperMartijn642/RechiseledCreate/blob/forge-1.20/src/main/resources/assets/rechiseledcreate/textures/block/template-simple.png and https://github.com/SuperMartijn642/RechiseledCreate/blob/forge-1.20/src/main/resources/assets/rechiseledcreate/textures/block/template.png. Indeed the gif is not ideal for creating textures, it was meant more as an example of how the format works, but I guess I never added the actual templates.

commented

image

That seemed to fix it for now!
Used following line in my ClientEvents class in FMLClientSetupEvent to set the rendertype in code!
ItemBlockRenderTypes.setRenderLayer(ModBlocks.REACTOR_GLASS.get(), RenderType.cutout());

Just a quick question, could you maybe add a template png file with clear lines about full and compact mode. Its a big hard to analyse the gif given there, since its all mostly the same brown color. Thanks!

commented

image
Something like this as a template for example ^^

commented

Alright, thank you for the quick response!

commented

Oh I see, you are using Forge's render_type property in the model file. Fusion might not pass that on correctly.

@LYIVX are you also setting the render type through the model file?

I was setting it through the Json file

commented

I was working on a larger update for Fusion and when I went to look into this issue, it was already working. So not entirely sure what I did that fixed this issue, but it should work now.

The changes are available in Fusion version 1.1.0.
Thank you both for reporting the issue!