Jump to content

[1.18.1] Problem with stair texture


Nomori

Recommended Posts

Hi, I'm making glass stairs for my mod, but they have an annoying line in the middle from glass border. How can I fix it or use custom textures for them?

glass-stairs.png

Here's how it looks.

Also a bonus question... how can I reference vanilla glass blocks in the registering of the stairs. I did a quick and dumb solution by adding a copy of glass to use, like this:

public static final RegistryObject<Block> JUST_WORK= registerBlock("temp_block",
            () -> new Block(BlockBehaviour.Properties.of(Material.GLASS).strength(1f).noOcclusion()));

    public static final RegistryObject<Block> GLASS_STAIRS = registerBlock("glass_stairs",
            () -> new StairBlock(() -> JUST_WORK.get().defaultBlockState(), BlockBehaviour.Properties.of(Material.GLASS).strength(1f).noOcclusion().sound(SoundType.GLASS)));

But I'm sure there's an easier way.

Link to comment
Share on other sites

1 hour ago, Nomori said:

I'm making glass stairs for my mod, but they have an annoying line in the middle from glass border. How can I fix it or use custom textures for them?

you need a custom Stair Model

1 hour ago, Nomori said:

Also a bonus question... how can I reference vanilla glass blocks in the registering of the stairs. I did a quick and dumb solution by adding a copy of glass to use, like this:

Blocks.GLASS::defaultBlockState
Edited by Luis_ST
  • Thanks 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.