Page 1 of 1
Unit dies by healing
Posted: Sat Nov 24, 2007 9:07 pm
by gugusm
I've created some dark unit, and it dies when healed by my unit. So, I want to get rid of that, but can't figure out what is causing that. I know I have to mess up with tags, but I can't see any flag that makes my unit die by healing. By the way, "Cannot be healed" flag doesn't seem to work.
Posted: Sat Nov 24, 2007 9:11 pm
by A-Red
There's a healing fraction in the main monster window, near flinch fraction and pathfinding radius and stuff. It's probably set to 0.
Posted: Sat Nov 24, 2007 11:39 pm
by rifthead
I always thought it was the "Is undead" flag, but what you're saying makes more sense.
Posted: Sun Nov 25, 2007 12:03 am
by Gleep
A-Red is correct the heal fraction is what is doing it. It sets how much health a unit has after healing. If it is set to 0 then that is what it has after healing and hence it dies.
Posted: Sun Nov 25, 2007 1:30 pm
by gugusm
Heh, it's so obvious. Thanks, it works fine now
Posted: Mon Nov 26, 2007 11:23 am
by Khadrelt
Gleep wrote:A-Red is correct the heal fraction is what is doing it. It sets how much health a unit has after healing. If it is set to 0 then that is what it has after healing and hence it dies.
I don't think that's exactly how it works - i.e. if you set a unit's healing fraction to .1 and heal it when at full health, it doesn't lose any (it doesn't go down to .1). It only seems to lose health if it's actually 0 - if it's higher that's the maximum amount of health a unit can have after healing, not the health it's set to after healing.
Posted: Mon Nov 26, 2007 1:44 pm
by gugusm
Khadrelt wrote:Gleep wrote:A-Red is correct the heal fraction is what is doing it. It sets how much health a unit has after healing. If it is set to 0 then that is what it has after healing and hence it dies.
I don't think that's exactly how it works - i.e. if you set a unit's healing fraction to .1 and heal it when at full health, it doesn't lose any (it doesn't go down to .1). It only seems to lose health if it's actually 0 - if it's higher that's the maximum amount of health a unit can have after healing, not the health it's set to after healing.
Yeah, you're certainly right, because you would hurt your units while healing them when their health is full