Jump to content

Recommended Posts

Posted

Hello,

 

So I created a block where it's model is copied from the cauldron and I altered it in a program called "Blockbench" which was listed on the minecraft wiki but when I open it ingame the block registers it as a "full block" and removed things like transparency (it seems).

 

Blockbench render:

image.thumb.png.06c20eda9f043a3611517bcec70a0137.png]

 

Minecraft render:
image.thumb.png.0d9ee3ca06d26c1318bc7fa02e546c57.png

image.png.fc00de7fb5b79cd2fd0848c04b4b0833.png

 

So the 2 main problems are that the glass is not transparent. Which is weird because I copied textures from a normal glass block in paint.NET and the top is transparent.

And the other one is have the block below it turns into an transparent block which is logical because it's face isn't drawn because it has a full block above but I want to prevent this.

 

So what approach do I need to make this "fish tank" into a block like the cauldron with the same hitboxes?

Thanks in advance!

 

 

Code:

 

  Reveal hidden contents
  Reveal hidden contents

 

Posted

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 7/9/2019 at 8:52 PM, Draco18s said:
Expand  

@Draco18s thanks I also remodeled the block but your methods there are deprecated and I searched thru the `Block` class and can't find a way for entities to walk inside of the block like you can do with a cauldron.  I'm guessing its the `isFullCube` override but this is deprecated. So where would I find documentation for this to get the right methods and properties

Posted (edited)
  On 7/9/2019 at 10:52 PM, Finiox said:

@Draco18s thanks I also remodeled the block but your methods there are deprecated and I searched thru the `Block` class and can't find a way for entities to walk inside of the block like you can do with a cauldron.  I'm guessing its the `isFullCube` override but this is deprecated. So where would I find documentation for this to get the right methods and properties

Expand  

Forge's Mojang's "deprecated" means that modders should not call the method.

Overriding it, however, is fine (as stated in the Javadoc of such methods).

Edited by DavidM
Forge -> Mojang

Some tips:

  Reveal hidden contents

 

Posted
  On 7/10/2019 at 1:01 AM, DavidM said:

Forge's "deprecated" means that modders should not call the method.

Overriding it, however, is fine (as stated in the Javadoc of such methods).

Expand  

Those aren't from Forge, they're from Mojang.

(But you're otherwise correct)

  • Haha 1

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted

isOpaqueCube() is definitely still in Block (although the method signature has changed).  Its default implementation should be fine for most cases.

 

isFullCube() is gone and no longer needed since Minecraft can determine that from your block's voxel shape.

  • 3 weeks later...
Posted (edited)

Thry out:

    @Override
    public boolean isSolid(BlockState state)
    {
        return false;
    }

my custom shaped blocks have no transparent holes in the ground below them with it.

 

And in my block registry, my blocks have ".variableOpacity()" in their registry-lines. so maybe try around with it.

Edited by Drachenbauer

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.

Announcements



×
×
  • Create New...

Important Information

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