| 07-13-2009, 10:04 PM | #1 |
Hey dudes! I'm having an issue right now with a spell I'm making. You see, I want to damage a unit, and then check if it's dead (to do some more actions). However, it doesn't quite seem to work properly (it doesn't seem like it's dead), so I was wondering if UnitDamageTarget instantly changes <target's> value, or if it's got some kind of 'pause' in between. I could solve it by just checking if target's life - <damage> is less than 0.405, but I still wanted to check here about this native (I might aswell be doing something wrong with the 'then' code) Thanks on behalf. Cheezeman (Sum: Does UnitDamageTarget() change the target's hit points instantly or not?) |
| 07-13-2009, 10:09 PM | #2 |
... and I'm confused as to why don't you test it? Anyway, yes, damage is dealt instantaneously. |
| 07-13-2009, 10:13 PM | #3 |
Well, my if/then/else statment is very complicated (for me) so it would be somewhat hard (and I usually come to the oposite conclusion anyway) |
| 07-13-2009, 11:23 PM | #4 |
Then why not make a separate test map and test the issue on its own? |
| 07-14-2009, 10:36 AM | #5 |
Note that your thread will be interrupted by any events on damage. |
| 07-14-2009, 11:10 AM | #6 |
yes there is pause, you can heal unit by damage event soo it wont die. |
| 07-14-2009, 11:17 AM | #7 |
DioD, given my post above you, that doesn't necessarily follow. In fact, the exact opposite is likely to follow from the conjuction of our posts - that there is no pause, and it is instant. |
| 07-14-2009, 11:51 AM | #8 |
Yes it instant BUT can be interrupted (also all shield systems currently available uses 5 yeas old way of damage prevention with additional useless work) sorry for map with additional content, just run, focus on peon, press esc, trigger deal 500 damage and prevent it. |
