How do I make custom grass blocks generate with random texture rotations like vanilla?

Started by cosmicwanderer on

Topic category: Help with MCreator software

Last seen on 01:07, 16. Oct 2023
Joined Sep 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How do I make custom grass blocks generate with random texture rotations like vanilla?

I´ve made a custom grass block to generate in a custom biome, but the texture creates too much repetition, how can I make it generate with random rotation like the vanilla grass?

Last seen on 14:30, 2. Aug 2022
Joined Aug 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Add a procedure to the "When…
Thu, 10/08/2020 - 19:54

Add a procedure to the "When block added" trigger. In the procedure, set a local variable to a random number from 0 to 1 using the "Random [0,1)" block found in the math tab. Then, if the variable is less than 0.25, use the "Set direction of block" block found in the block procedures tab to set it facing north. If the variable is between 0.25 and 0.5, make the block face east, then south then west.

Last seen on 01:07, 16. Oct 2023
Joined Sep 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Do I need to change the…
Thu, 10/08/2020 - 20:12

Do I need to change the block rotation mode for this to work?

Last seen on 14:30, 2. Aug 2022
Joined Aug 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Yes, the block needs to be…
Thu, 10/08/2020 - 21:28

Yes, the block needs to be able to point north, south, east, and west to point in those directions.

Last seen on 01:07, 16. Oct 2023
Joined Sep 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I did that but it only works…
Fri, 10/09/2020 - 00:11

I did that but it only works when I place them, they dont generate naturally in random directions

 

Last seen on 14:30, 2. Aug 2022
Joined Aug 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Hm, that's unfortunate. I…
Fri, 10/09/2020 - 11:13

Hm, that's unfortunate. I found this a forum talking about something similar: https://mcreator.net/forum/43013/how-could-i-make-my-procedure-only-run-when-ore-generated-world. It suggests using a marker block to place down the real block after an update tick. This doesn't really work for you though because there would be so many marker blocks generating in, and when I tested it the blocks just froze and didn't change.