#How i can push mobs from lava

15 messages · Page 1 of 1 (latest)

last prairie
#

i need push mobs from lava to air or to players, how i can do this.

I have a mechanic for catching a mob from fishing, I want to make it so that when catching a mob from lava, it does not drown but moves towards the player or something like that..

I have event for check nbt tag from mobs right now:

EntityEvents.spawned(event => {
    const nbt = event.entity.getNbt()
    if(nbt.Tags[0] !== "isLavaCreature") return
    //code for mob walk to player
})
meager finchBOT
#

Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!

alpine snow
#

push where?

last prairie
alpine snow
#

you want them to move to the player? oh boy

#

major complicated, dont think its possible lol

last prairie
alpine snow
#

cant change AI behavior

last prairie
alpine snow
#

simple idea would be to maybe teleport it somehow
otherwise you need a lot of vector math and forces

this is not an easy task in the slightest

last prairie
alpine snow
#

not easily, you'd need some AABB checks or just simply go through every block in order
i cant really help with it as im busy with something, either way i wouldnt even know where to start working on something like this lol

#

this is far beyond even my understanding of the game and KJS

last prairie