I've been enjoying all the Gamemode 4 stuff that has been going on for the past weeks and I really got inspired to get my hands on some work as well. I've done several modules already, though I want to optimize and test them a little more before I pop them here ^.^ For now, it's time for Aging Animals.
Aging Animals is a simple module that will keep track of a (farmable) animal's age. When an animal exceeds a set (configurable on my website) amount of days, it will die (and a new baby will spawn in a 128 block radius to prevent animals going extinct). Sadly, just like in real life. The animals that will get tracked are cows, chickens, rabbits, sheep, pigs and mooshrooms.
If you do not want some specific animals to despawn, you can throw an Anti-Aging Cream Splash Potion (Beauty in a bottle) on them to grant them eternal life. This potion is mainly supposed to counter the effect of the module to mob farms. Because of it's great power, the potion is quite end-game (recipe can be found below). [Huge thanks to EvilPenguinJ2 ^.^]
The schematics, one-clicks and the command overview can be found at sugarcaney.co.nf/.../aging-animals. The one-click as shown on the page will install a bedrock box at the bottom of the map. If you want to summon the contraption right before your eyes, you have to execute the 1-Click Summon command that can be found below the 1-Click Install.
The module should not cause lots of lag. I execute afew commands only once a minecraft day (hopper clock with TransferCooldown:23993) and the Anti-Aging Cream's commands will get fired with the Custom Crafter's clock. However, all the ages of all the animals are stored in a scoreboard objective. So the only problem I see is when there are way too many animals loaded in.
And finally some pictures:
Hope you'll like it :)