Jump to content

Recommended Posts

Posted

I have added a new property to my block, that is used by TESR to display the model in correct orientation. That all works very well, but before I release I wanted to make sure that the previously placed blocks will display correctly.

And that is not the case. They are basically gone. I don't get any notification in MC about missing blocks or anything in the logs. When I try debugging I don't see any code being triggered to get the tile entities or trying to load the block with preexisting meta (which would be -1 as there were no properties previously).

The way it seems to me is that in the block registry it registers the new blockstates with the facing values, but doesn't have anything in there for the previous no property state and then just skips putting those blocks in the world.

 

I guess there's something simple that I am missing here, but can't figure that out. Is there a way to make this backwards compatible so that the blocks without any property set would get a default facing set?

 

My block:

 

  Reveal hidden contents

 

 

TESR

 

  Reveal hidden contents

 

 

blockstates json (I know that normal shouldn't be required here, was just trying it with it as well, just in case it would help)

 

  Reveal hidden contents

 

 

If you wanted to check more this code is on github at https://github.com/P3pp3rF1y/Reliquary/tree/1.3.0

Posted

Thanks a lot. That did the trick. I am still not sure why I haven't seen the meta 0 in the debug previously, but who cares now that it works :)

 

As for the code comments. The array in createBlockState is on me (copy paste from vanilla).

 

The others not so much as they are from the code I have inherited and still need to do more clean up. But thanks for pointing them out anyway. At least the pointless checks were not on my radar.

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.