• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Simple Triggered spell. I think

Status
Not open for further replies.
Level 5
Joined
Jun 18, 2004
Messages
136
i made a soul based hero for my foot wars map. hes not that complicated but i noticed that he had no offensive spells exept one that killed a unit and subtracted the units health from the heros. but i want to make a spell (this is the easy part) that kills a non hero unit and then (this is the part i cant get) damages everything around the killed unit a percentage of the killed units hp. each level should go up by 10% starting at 30%. im thinking "for each varable a 1-3 do actions" but i dont know how to use this. any help would be appreciated and credited. :wink: thx---AlphaChicken
 
Level 16
Joined
Sep 3, 2004
Messages
2,086
How about this:

Make a Finger of Death move called w/e you want

Events
A unit begins casting a spell
Conditions
Ability being cast equal to X
Actions
If then Else Multiple Actions
If Target Units of Ability being Cast is dead Equal to True
Then Pick All units within 100x Level of Ability being Cast and Have Casting Unit damage 20x Level of Ability being cast of spell damage
Create SFX
Destroy SFX
Else- Do Nothing
 
Level 11
Joined
Jul 20, 2004
Messages
2,760
Two thing... First change the event to "Unit Starts the Effect of an Ability" to ensure that the caster actually casts it. Secondly, wait about 0.40 seconds at the beginning because target may not die instantly. If the trigger works even without wait, it's ok. But the event is necessary how I said in order to actually work.
 
Level 7
Joined
Mar 26, 2004
Messages
350
it works with "unit begins casting a spell" too, but then it's buggy :wink:

btw, he wanted a % damage of the unit's hp, not a certain damage amount.
so use:
Code:
pick every unit in range (100*(levelofability(yourability)) matching condition((owner of (picked unit) is enemy of (owner of casting unit) = true) and do:
 set life (percentage) of (picked unit) to (life of picked unit) - (10*(levelofability(yourability))
 
Level 11
Joined
Jul 20, 2004
Messages
2,760
Heh... Didn't notice that. And I usually tend to do spells as less buggy as possible :D. There are abuser like Shiggy (I saw a post of his telling it...) who can find bugs easily. So, it's best not to let these guys have fun by finding bugs in your spell.

Ok, for Chicken, the bugs is that the trigger would begin even if the player would just click over the target but not cast it already. So if you move immediately to another point or something the spell takes effect and you no longer lose MP. VERY buggy...
 
Status
Not open for further replies.
Top