The commanders are hard coded and I can't study that script... But there is a solution: check at start of the battle neutrals health (exit if none in slot) then give at the end the corresponding gold value according with HP. I am only an average scripter so my ideas suit my skills. There should be better solutions, but at least this one I can do it.