Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[SOLVED][1.7.10] TileEntity under water is surrounded by a bubble?!

Featured Replies

Posted

Hi guys,

 

I am trying to render an object underwater, but it end up always having an air bubble around it, which completely kill the project if I can't find a resolution.

 

Take a look at this skeleton ... which inherit from the blockcontainer at this point (will be changed depending of the answers here.)

 

skeleton.jpg

 

 

Two questions.

 

1. Ay idea how to get rid of that bubble?

2. Does a TileEntity should always inherit from a BlockContainer? As funny as it sounds, all the examples I found were inheriting from that.

 

 

Second question first: simply do myBlock extends TileEntity. no need to always extend BlockContainer.

 

First question: Block has following methods

 

 

    public boolean isSolidFullCube()
    {
        return this.blockMaterial.blocksMovement() && this.isFullCube();
    }

    public boolean isNormalCube()
    {
        return this.blockMaterial.isOpaque() && this.isFullCube() && !this.canProvidePower();
    }

    public boolean isVisuallyOpaque()
    {
        return this.blockMaterial.blocksMovement() && this.isFullCube();
    }

    public boolean isFullCube()
    {
        return true;
    }

    public boolean isPassable(IBlockAccess worldIn, BlockPos pos)
    {
        return !this.blockMaterial.blocksMovement();
    }

 

 

I think the passable is check inside water. try making you own material and override isSolid() and blocksMovement(), both returning false;

This is just an idea and I'm using 1.8.

It doesn't work, I don't know why.

It works, I don't know why.

For a standard

Block

, using

Material.water

as the block's material will make it render with water around it while in water. I can't find the part of the rendering engine that handles this, so I'm not sure if it still applies to models rendered using

TESR

.

 

You don't need to extend

BlockContainer

to have a

TileEntity

, just override

Block#hasTileEntity

and

Block#createTileEntity

.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

  • Author

BOOM and BOOM ... you guys rock!!!

 

Both issues are solved! Thanks to you both :)

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...

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.