Topic category: Help with MCreator software
I would like to know how to code an item that, when thrown at a mob, checks to see if it has a spawn egg and create the egg in question if one is located. I know nothing about standard mod programming and have been using MCreator off and on for years, so I figured I would ask here.
How I specifically want it to work:
- Craft a throwable item. We'll call it a mob catcher for now.
- Throw the mob catcher at a mob like it's a throwable item, such as an egg or a snowball.
- If it hits the mob, either check the game's item list or an internal whitelist to see if that mob has an associated spawn egg.
- If a spawn egg for the mob is found, remove the mob from the world with no item drops and spawn the egg into the world for a player to pick up.
- If no spawn egg is found, or if the player misses entirely, say either in chat or on screen that no egg was found, and drop the mob catcher wherever it landed to be picked back up.
I wouldn't know the first thing about making this possible, either with a whitelist or the full item list, so I figured I would ask for help. Hopefully I put this in the right section; please let me know where it needs to be moved to if I didn't.