Started by
Ghtrefg
on
Topic category: Help with Minecraft modding (Java Edition)
All I want is for my mob to lay an egg when bred with another of its kind. Clicking on my mob with a spawn egg should still spawn a baby, however, to mimic typical Vanilla mobs. I have everything pertaining to the egg itself finished, I just need my mob to lay it.
Edited by Ghtrefg on Thu, 12/26/2024 - 01:38
And no, I cannot simply despawn the babies and put an egg in their place, for that would mean having no babies at all, which I'm not particularily fond of.
You can use your entitys tick and synced data to count ticks since last lay. Then on given interval (with random changes if you will), spawn item entity that represents your egg
I suggest you check our tutorials collection playlist on our YouTube channel which contains many examples and tutorials that can help you get started with MCreator: https://www.youtube.com/playlist?list=PLAeL-oIFIEngE6jRgFYeFMfuj8WQsO3Ei