Mob Block paths

Started by darktailsdoll on

Topic category: Help with MCreator software

Last seen on 13:46, 25. Sep 2023
Joined Mar 2016
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Mob Block paths
Sun, 09/24/2023 - 03:02 (edited)

How do i make a mob walk on blocks and the block under him changes as i am trying to change the stepped on block into an emerald block please tell me a detailed way to do this.

Oh and also how do i change a block that has been right clicked by an item?

And by the way i don't want to change the air blocks.

Edited by darktailsdoll on Sun, 09/24/2023 - 03:02
Last seen on 20:37, 26. Jul 2024
Joined May 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
...This shouldn't be that…
Sun, 09/24/2023 - 17:20

...This shouldn't be that difficult. Just check that the block beneath the entity's x/y/z position is solid, and, if it is, replace it with your desired block. You could also add a tag for blocks that can be replaced this way, and check if the blocks are in that tag, if you want to be more specific, then just link the procedure to your entity's update tick.

...The same principle should work for right clicking. Just check that the block right clicked meets your conditions, and that the item in the player's main hand is the correct item, and, if it is, replace the block.