Fusion (Connected Textures)

Fusion (Connected Textures)

40M Downloads

[Bug] model modifier and connected texture cannot be used together

alinco8 opened this issue · 1 comments

commented

Version Info

  • Minecraft, 1.21.6
  • Fusion, 1.2.7-neoforge-mc1.21.6

What mod loader are you using?: NeoForge

Are you using OptiFine: no

Description of the Bug

The base texture of ore conflicts with the overlay defined by model_modifiers, causing flickering.
It appears that the overlay and the connected texture rendering are interfering with each other.

This issue only occurs when ore blocks are adjacent to each other
If a ore block is placed in isolation, the problem does not appear.
Additionally, the issue only happens when the texture layout is set to "pieced". When using "simple", "compact", no flickering occurs.

I'm still learning how Fusion works, so I apologize in advance if this is due to a mistake on my part.

Simplified ResourcePack

Structure:

└── assets/
    └── minecraft/
        ├── fusion/model_modifiers/blocks/radiant/
        │   └── copper_ore.json
        ├── textures/block/radiant/
        │   ├── copper_ore.png
        │   └── copper_ore.png.mcmeta
        └── models/block/radiant/
            └── copper_ore.json

assets/minecraft/fusion/model_modifiers/blocks/radiant/copper_ore.json:

{
    "targets": [
        "minecraft:copper_ore"
    ],
    "append": [
        "minecraft:block/radiant/copper_ore"
    ]
}

assets/minecraft/textures/block/radiant/copper_ore.png.mcmeta:

{
    "fusion": {
        "emissive": true,
        "render_type": "cutout",
        "type": "connecting",
        "layout": "pieced"
    }
}

assets/minecraft/textures/block/radiant/copper_ore.png:
Image
assets/minecraft/models/block/radiant/copper_ore.json:

{
    "loader": "fusion:model",
    "type": "connecting",
    "parent": "block/cube_all",
    "textures": {
        "all": "minecraft:block/radiant/copper_ore"
    },
    "connections": {
        "type": "is_same_block"
    }
}

Steps to Reproduce

Install RadiantOres.zip

⚠️ This resource pack is a personal port of NewGlowingOres for Fusion.
All rights belong to the original author of NewGlowingOres.

Screenshots

2025-07-06.18-13-27.mov
commented

What you are seeing is z-fighting between the regular quads and the quads from the overlay due to floating point inaccuracy when calculating the positions of the quads. The only way to avoid z-fighting is by giving the quads at the exact same size and position, such that any inaccuracy during calculation also ends up being the same for both quads.
This is not possible with the pieced layout as it splits the quad into 4 pieces. (Only when the connections happen to match a complete tile on the texture does it just use 1 quad without splitting, hence no z-fighting for the singular block)

The full and simple layouts don't split the quads at all, hence they don't have the z-fighting issues.

I do want to add an option for the pieced layout to put all the connection combinations onto the texture atlas such that it doesn't have to split the quad into 4 (this does come at the cost of taking up significantly more space on the atlas of course), but it will likely be a while before I get to that.
For now, you'd have to use the simple or, in your case likely, the full layout to avoid the z-fighting.