Started by
Stardust178
on
Topic category: Help with Minecraft modding (Java Edition)
My walrus mob goes to swim but can't get back to the surface. How do I make it breaks ice blocks that are right above it and then jump onto the surface?
Edited by Stardust178 on Mon, 08/01/2022 - 09:59
Add a procedure on mob tick
If -block x y+1 z = ice
place air block at x y+1 z
set location of entity to x+1, get world surface height x+1 z, z
you could also make it so the block also makes a breaking sound and has breaking particles when it replaces it with air but that's about the best way you can have it
@NerdyPuzzle I tried this but it didn't work.
Your procedure is checking for ice blocks on y: 1. It's a simple fix though, you just need to use y + 1 instead. Also, the procedure is getting the world height at x: 1 and the z of your entity. I hope this helps.
You need to replace your get block with a math section addition block (the one that has []+[]) and the number 0. Make make it get a block at [y]+1 not 1. Also set the location to x+1, surface height of x+1 z, z