Help with detecting/setting rotation of block

Started by legoboomer on

Topic category: Help with modding (Java Edition)

Last seen on 17:13, 13. Aug 2020
Joined Jul 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Help with detecting/setting rotation of block

I'm trying to create a block that will switch into a new (but similar block) when you right click it with an item.  However, it always resets to the default rotation whenever I replace it with the other block.  How the code is set up right now,it just places the block I want it to change into in the previous block's cube.  Does anybody know a way to fix this?  I really appreciate comments, even if they confirm that this is impossible.

Last seen on 19:55, 7. Jan 2021
Joined Aug 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Perhaps you could test what…
Sat, 09/21/2019 - 10:18

Perhaps you could test what direction the player is facing upon placing the block, give the block a custom NBT value based on that, and have multiple duplicates of this block for each direction. You can then just transfer the NBT value to the new block.