HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Bounties for units killed with triggers.

06-08-2004, 08:10 AM#1
qwertyui
For some reason, all links to Lord Vexorian Spell System i can find on this forum give me a 404 error.

Anyway. I am trying to make a workaround for existing bug with direct stunning spells like Storm Bolt that allows the damage part of these spells to ignore the Spell Shield amulet.

I figured i could set the Storm Bolt damage to 0 and then add the damage part after the spell connects (target unit gets a stun buff) with a trigger.

However, i need to make sure i get the correct amount of experience and bounty for killed unit. Preferrably with yellow bounty number popping up on the screen :)

Since Lord Vexorian Spell System is nowhere to be found, can someone please explain to me how is it best to do it?
06-08-2004, 09:41 AM#2
Anitarf
I believe the way this is done is to check first if the damage would kill the target (by checking how much HP the target still has), and if it would, then instead of just substracting the hp with the trigger, create an invisible, unselectable unit with insane damage and short duration for the caster of the spell and order it to attack the target, thus killing it in a "regular" way, giving experience to the heroes allied with the killing unit and giving bounty.
06-08-2004, 10:30 AM#3
Luther
yeah, that is the way that it is regularly done, but the (smallish) problem with this is it won't take into account damage reduction, from items or from skills. so if you had a spell that's supposed to deal 200 straight damage, and a hero with 199 life gets in the way of it, and say this hero has the equivalent of frost wyrm shield from ToB, he should really only take about 120 damage from the spell, but because his life is less than 200, this will trigger the killing unit condition, and he'll die, when he shouldn't. a relatively rare hapenning, but remember that it ignores magic resiance.