• 🏆 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!
  • ✅ Time to vote for the top 3 models! The POLL for Hive's 6th HD Modeling Contest: Mechanical is now open! 📅 Poll close on July 16, 2024! 🔗 Cast your vote now!
  • ✅ The POLL for Hive's Texturing Contest #33 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!

Triggered Aoe spell damage problem!! PLs help

Status
Not open for further replies.
Level 5
Joined
May 27, 2007
Messages
144
I have made an aoe spell that should damage all units in her range but it damages only one in each range. The spell damages a unit in center with full damage, near center with 75% damage, 200 from center with 50% and 300 from center with 25% here is the trigger: (without specialeffects)
  • TimePortal
  • Events
    • Unit - A unit starts the effct of an ability
  • Conditions
    • (Ability being cast) Equal to TimePortal
  • Actions
    • Set TP_Place = (Target point of ability being cast)
    • Unit - Create 1 TimePortal for (Owner of (Casting unit)) at TP_Place facing (Position of (Casting unit))
    • Set TP_Effect = (Last created unit)
    • Unit - Add a 4.25 seconds Generic expiration timer to (Last creatd unit)
    • Set TP_Group = (Units within 10.00 of (Position of TP_Effect) matching ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of (casting unit)) Equal to True))
    • Unit Group - Pick every unit in TP_Group and do (Actions)
      • Loop - Actions
        • Unit - Add Time Portal damage (Center) to TP_Effect
        • Unit - Set level of Time Portal damage (Center) to (Level of Time Portal for (casting unit))
        • Unit - Order TP_Effect to Undead Lich - Frost Nova (Picked unit)
        • Wait 0.25 seconds.
        • Unit - Remove Time Portal damage (Center) from TP_Effect
    • Custom script: call DestroyGroup(udg_TP_Group)
    • Wait 1.00 seconds.
    • Set TP_Group = (Units within 115.00 of (Position of TP_Effect) matching ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of (casting unit)) Equal to True))
    • Unit Group - Pick every unit in TP_Group and do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If-Conditions
            • ((Picked unit) has buff TimePortal) Equal to True
          • Then - Actions
            • Skip remaining actions
          • Else - Actions
          • Unit - Add Time Portal damage (100Range) to TP_Effect
          • Unit - Set level of Time Portal damage (100Range) to (Level of Time Portal for (casting unit))
          • Unit - Order TP_Effect to Undead Lich - Frost Nova (Picked unit)
          • Wait 0.25 seconds.
          • Unit - Remove Time Portal damage (100Range) from TP_Effect
    • Custom script: call DestroyGroup(udg_TP_Group)
    • Wait 1.00 seconds
    • Set TP_Group = (Units within 215.00 of (Position of TP_Effect) matching ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of (casting unit)) Equal to True))
    • Unit Group - Pick every unit in TP_Group and do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If-Conditions
            • ((Picked unit) has buff TimePortal) Equal to True
          • Then - Actions
            • Skip remaining actions
          • Else - Actions
          • Unit - Add Time Portal damage (200Range) to TP_Effect
          • Unit - Set level of Time Portal damage (200Range) to (Level of Time Portal for (casting unit))
          • Unit - Order TP_Effect to Undead Lich - Frost Nova (Picked unit)
          • Wait 0.25 seconds.
          • Unit - Remove Time Portal damage (200Range) from TP_Effect
    • Custom script: call DestroyGroup(udg_TP_Group)
    • Wait 1.00 seconds
    • Set TP_Group = (Units within 315.00 of (Position of TP_Effect) matching ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of (casting unit)) Equal to True))
    • Unit Group - Pick every unit in TP_Group and do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If-Conditions
            • ((Picked unit) has buff TimePortal) Equal to True
          • Then - Actions
            • Skip remaining actions
          • Else - Actions
          • Unit - Add Time Portal damage (300Range) to TP_Effect
          • Unit - Set level of Time Portal damage (300Range) to (Level of Time Portal for (casting unit))
          • Unit - Order TP_Effect to Undead Lich - Frost Nova (Picked unit)
          • Wait 0.25 seconds.
          • Unit - Remove Time Portal damage (300Range) from TP_Effect
    • Custom script: call DestroyGroup(udg_TP_Group)
PLs Help
 
Level 11
Joined
Jul 20, 2004
Messages
2,760
Ofcourse... the unit has a limited time between two frost novas. How about setting the unit's cast animation to 0.00? Same for cooldown of frost nova. Or you could forget frost nova and just damage the unit properly. Ooooor... even better. Use an AoE Damaging spell for different AoEs. The only problem is calculating the damage. Because doing less damage on large AoE and more on tighter means multiple damaging spells on the closer units. So you have to calculate the damage really well. Fortunately, the formula for you is simple. Here is how it goes:

a - damage that affects central units (maximum damage.

1. Stomp that affects ALL ranges (even far ones) and does a/4 damage.
2. Stomp that affects only those from the first three ranges. Does a/4 damage.
3. Stomp that affects only the first two ranges. Does a/4 damage.
4. Stomp that affects only the closest units. Does a/4 damage.

Hope it helps!

-Mihai
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,233
OFCOUSE THIS DOES NOT WORK!
  • Unit Group - Pick every unit in TP_Group and do (Actions)
    • Loop - Actions
      • Unit - Add Time Portal damage (Center) to TP_Effect
      • Unit - Set level of Time Portal damage (Center) to (Level of Time Portal for (casting unit))
      • Unit - Order TP_Effect to Undead Lich - Frost Nova (Picked unit)
      • Wait 0.25 seconds.
      • Unit - Remove Time Portal damage (Center) from TP_Effect
You use a waits inside pick every unit in group actions and thus the entire trigger is aborted. You can NOT use waits inside a pick every unit in group action, thats just how WC3 works and you can not change that. You also did it many times. . .

You will have to remove them for the slighest hope of making it work.
 
Status
Not open for further replies.
Top