Jump to content

1.10.2 TileEntitySpecialRenderer wont remove item render when slot is null


kitsushadow

Recommended Posts

I have a block which renders the current item in the slot. The block has two states"

1. Rotation

2. Boolean

 

==========

 

1. When an item is first added and the boolean is false the item doesn't render.

2. When the state is updated and the boolean is true the item renders.

3. When the stack is removed and the state is changed by the update method in the TileEntity the state is updated to boolean false but the item continues to render even the the slot is now empty.

 

You can view the source code here: https://bitbucket.org/kitsushadow/forgecraft/src/0c6cb00316b3d00b05a01a68c11c7a3ec042e8f9/1.10.2/src/main/java/nmd/primal/forgecraft/?at=master

 

The block in question is the Firebox

 

Link to comment
Share on other sites

1. Where am I using IInventory use capabilities?

 

2. I'm not sure if i am synchronizing the inventory to the client other than through the NBT data and by setting the tile.markDirty() at every inventory change.

 

3. Duplicate Information for the states? I'm not duplicating states.

Link to comment
Share on other sites

1. Where am I using IInventory use capabilities?
What?

 

2. I'm not sure if i am synchronizing the inventory to the client other than through the NBT data and by setting the tile.markDirty() at every inventory change.
markDirty is telling Minecraft that your TileEntity needs to be saved to disk the next time around (and notifies neighbor blocks about the TE change). It does not send things to the client.

 

 

 

3. Duplicate Information for the states? I'm not duplicating states.
You have the blockstate that mimics whether or not a slot is set, right? Or what is this ACTIVE property used for?

 

2. How should I be informing the client of inventory changes then?

 

3. The Active Property manages if the Firebox is On or not. Being On causes the stack to decrement and changes the model texture.

Link to comment
Share on other sites

That definitely says that the update packet is not being sent.

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.

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.

Announcements



×
×
  • Create New...

Important Information

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