Started by
Kotoro
on
Topic category: Help with modding (Java Edition)
Hello ! My situation is more complicated than the title says:
I've created an item. I'd like it if, when I right-click on a VANILLA mob (it's important to specify this, because I don't know if you can add procedures to vanilla mobs...), it disappears to make one of my new mobs appear.
Finally, my item (which is a book) would lose one point of durability.
Also, how do I get the exact mob?
Can you help? It's been so long since I last used MCreator that I'm totally rusty :/.
PS: There's a left-click procedure, but I'd rather not have to use it.
This should be able to help you
(Book is the item the entity is clicked with)
(Pig is the original entity
(Creeper is the converted entity)
You don't need to attach this to an entity, because the global trigger will activate when the player clicks on the entity, so you just have to leave it unattached to anything and it will work.
Wow, I'm going to try that! You're my savior! I always thought that procedures had to be attached to a trigger to work.
It works! Thanks again! <33
You're welcome! :D