If you are a developer, please build MegaGlest on your own and get in touch to contribute (or post your patches on the forums).
I think you can do this with Lua but that's really not my area of expertise. Alternatively, you could make the unit free and limited to one at a time (with a static resource). That way it would die but just come right back without costing you anything. The only problem I can think of is that all of the unit's experience will be gone.
i like the idea, i just think that instead of losing absolutely everything, you should just lose some of your exp, not all of it though
that is a cool idea...i like the conceptbut my idea is that the hero (which is a completely different unit than the ones available. [hint hint to all you modelers that need something to do...]) would be a near-uber unit that would fight with your armies...