• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Deafening Blast Help

Status
Not open for further replies.
Level 5
Joined
Jul 18, 2007
Messages
110
  • DeafeningBlast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Deafening Blast
    • Actions
      • Set temp_point = (Position of (Casting unit))
      • Unit - Create 1 Dummy (projectile) for (Owner of (Casting unit)) at temp_point facing (Facing of (Casting unit)) degrees
      • Unit - Add a 10.00 second Generic expiration timer to (Last created unit)
      • Set unitDummyProjectile = (Last created unit)
      • Set pointAbilityTarget = (Target point of ability being cast)
      • Set unitCaster = (Casting unit)
      • Unit - Order unitDummyProjectile to move pointAbilityTarget
      • Trigger - Turn on DeafeningBlastP <gen>
      • Custom script: call RemoveLocation (udg_temp_point)
  • DeafeningBlastP
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Set tempDamage = (5 + (80 x (Level of Deafening Blast for unitCaster)))
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Or - Any (Conditions) are true
            • Conditions
              • (Integer((Distance between pointAbilityTarget and (Position of unitDummyProjectile)))) Less than 15
              • (Integer((Distance between (Position of unitCaster) and (Position of unitDummyProjectile)))) Greater than 600
        • Then - Actions
          • Trigger - Turn off DeafeningBlastP <gen>
          • Unit - Remove unitDummyProjectile from the game
          • Skip remaining actions
        • Else - Actions
          • Do nothing
      • Unit - Move unitDummyProjectile instantly to ((Position of unitDummyProjectile) offset by 15.00 towards (Facing of unitDummyProjectile) degrees)
      • Set temp_group = (Units within 150.00 of (Position of unitDummyProjectile))
      • Unit Group - Pick every unit in temp_group and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Owner of (Picked unit)) is an enemy of (Owner of unitDummyProjectile)) Equal to True
            • Then - Actions
              • Set temp_point = (Position of (Picked unit))
              • Unit - Move (Picked unit) instantly to (temp_point offset by 15.00 towards (Facing of unitDummyProjectile) degrees)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • ((Picked unit) has buff Deafening Blast ) Equal to False
                • Then - Actions
                  • Unit - Create 1 Dummy (silenceCaster) for (Owner of unitDummyProjectile) at temp_point facing Default building facing (270.0) degrees
                  • Set Blast = (Last created unit)
                  • Unit - Set level of Silence (Blast) for Blast to (Level of Deafening Blast for unitCaster)
                  • Unit - Order Blast to Neutral Dark Ranger - Silence temp_point
                  • Unit - Cause Blast to damage (Picked unit), dealing (Real(tempDamage)) damage of attack type Spells and damage type Normal
                  • Unit - Add a 1.00 second Generic expiration timer to Blast
                  • Custom script: call DestroyGroup (udg_temp_group)
                  • Custom script: call RemoveLocation (udg_temp_point)
                • Else - Actions
                  • Do nothing
            • Else - Actions
              • Do nothing
Ok, the problem is in the damage being done with this ability (and I'm just making sure that it will properly level). The rest works fine, but for some reason the damage seemingly accumulates on the targets; just simply does dramatically more damage than it should, sometimes just one hitting all heroes. How can I properly apply or fix the damage with this? Any help would be appreciated, thanks.

-Credit to CokeMonkey11 for writing the ability.
 
One of the causes may be because of the silence buff isn't attached or not in time.
The silence targets the ground and it needs some time to cast it out, the unit may be already away from the location it is that time.
Another cause that makes the damage higher is because of the damage type and attack type.

Anyway, you leaked the pointAbilityTarget location and you didn't nullify the unit variables.
 
Level 5
Joined
Jul 18, 2007
Messages
110
Yeah, Coke was telling me to forcefully attach it, I tried that though and it didn't work either =/. The buff is also notably active when casted.

Hm..? Where at, could you specify please?

Ok, I just tried putting the units into a unit group and specifying that way into the condition. It didn't work, so it must not be the buff.

Nvm, got it to work, thanks all.
 
Last edited:
The timer expires every 0.03 seconds, are you sure it isn't possible that the problem is with the buff? Try adding a GameText trigger that shows for example "TRIGGERED" just below the damage function. Then cast the spell in game to only 1 unit, if there are more than 1 "TRIGGERED" game text that means its the problem with the buff.
 
Status
Not open for further replies.
Top