Create absorbing shield?

Status
Not open for further replies.
Level 14
Joined
Aug 8, 2010
Messages
1,022
I almost finded what i need but i need somebody's help. Here is what i've got :
  • trig
    • Events
      • Unit - A unit Finishes casting an ability
    • Conditions
      • (Ability being cast) Equal to Ice Barrier
    • Actions
      • Set IceBarrierCaster = (Triggering unit)
      • Unit - Make (Triggering unit) Invulnerable
      • Set Damage = 3000.00
  • trig2
    • Events
      • Unit - A unit Is attacked
    • Conditions
    • Actions
      • Set Damage = (Damage - (Damage taken))
  • trig3
    • Events
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Damage Less than or equal to 0.00
        • Then - Actions
          • Unit - Make IceBarrierCaster Vulnerable
        • Else - Actions
          • Do nothing
The problem is that the unit is invulnerable, so it can't be attacked. Can someone give an idea for something that can replace the invulnerability?
IceBarrierCaster -> Unit Variable
Damage -> Real Variable
 
Level 8
Joined
Mar 28, 2009
Messages
179
Alternatively, you can also use the "Anti Magic Shield" of the banshee. There is an option to either absorb all damage for X seconds or a specific amount of physical/magical damage for X seconds. You can find it in the object editor.

Btw: Your spell doesn't work. If you make a unit invulerable, it cannot be targetted/attacked by units unless they are allowed to target invulerable units.

If you want to make a spell, that casts the spell on the unit, make a dummy unit, remove all shadows and attacks and things like that and then make it cast the spell on the triggering unit you desired it on. You can also change animations and stuff, so no problem in that case.

Hope, that helped.
If not, you can PM me or wait for another person's answer in here.

Gaegamel
 
Level 33
Joined
Mar 27, 2008
Messages
8,035
I can only think of this test map
I made it 3 weeks ago, just for solo testing, I don't know someone will need (and that person is YOU =p)
Originally created by me, improved by Maker
But this one uses Time-based limit
I see you want it a Damage-based limit
I'm gonna attach the map first, I'll improve it later, okay ?
 

Attachments

  • Damage Gather or Release Spell (1).w3x
    15.3 KB · Views: 120
Level 33
Joined
Mar 27, 2008
Messages
8,035
Test map attached
Some of the values will go to negative form (-) because it exceeds its limit
BUT don't worry, the trigger is turned off right after is negative
Max damage can be taken before the shield exploded is 300
 

Attachments

  • Damage Gather or Release Spell (1).w3x
    15.4 KB · Views: 246
Status
Not open for further replies.
Top