Started by
darktailsdoll
on
Topic category: Help with MCreator software
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
...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.