Started by
Elvis_The_Snail
on
Topic category: Help with Minecraft modding (Java Edition)
I'm making an entity, and I don't know how to stop it from entering a boat. Any way to fix this?
Topic category: Help with Minecraft modding (Java Edition)
I'm making an entity, and I don't know how to stop it from entering a boat. Any way to fix this?
Could use on tick, get each entity in area 1, if entity iterator is type boat, if entity iterator has nbt passengers = name of event/target entity. Set nbt to null. Might work. The passengers nbt is a bit odd so idk if it's possible through mcreator.
Could also despawn/break the boat if it got into one, on tick if all delta movement = 0, then do what I said above and check for boat, then despawn entity iterator, or set health to 0.
Should have thought of that earlier, thanks!
A boat is just an entity that can be mounted and dismounted. Just check if the entity is ever riding another entity, check if that second entity is a boat, and if so use the "make [entity] stop riding" procedure block.