• 💀 Happy Halloween! 💀 It's time to vote for the best terrain! Check out the entries to Hive's HD Terrain Contest #2 - Vampire Folklore.❗️Poll closes on November 14, 2023. 🔗Click here to cast your vote!
  • 🏆 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!
  • 🏆 HD Level Design Contest #1 is OPEN! Contestants must create a maze with at least one entry point, and at least one exit point. The map should be made in HD mode, and should not be openable in SD. Only custom models from Hive's HD model and texture sections are allowed. The only exceptions are DNC models and omnilights. This is mainly a visual and design oriented contest, not technical. The UI and video walkthrough rules are there to give everyone an equal shot at victory by standardizing how viewers see the terrain. 🔗Click here to enter!

[Spell] On hit spells

Status
Not open for further replies.
Level 3
Joined
Jan 4, 2009
Messages
45
Hello. I have problems making a spell and I would need some help, I don't know how to make it. I want to make a spell, that will cause the casters next attack to deal bonus damage and stun the enemy and knock it back (like a normal bash). But I want it to be an active ability. Like you cast it, and your next attack will bash. I tried it in different ways, but none of them works.
 
Level 29
Joined
Mar 10, 2009
Messages
5,016
if you give a buff, it will be debuffed so the next attack will be null...

anyway, what to explain further, it works like this...
  • Bash
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Thunder Clap
    • Actions
      • -------- get the ID and save the integer to a hashtable --------
      • Custom script: set udg_BashID = GetHandleId(GetTriggerUnit())
      • Hashtable - Save 1 as 1 of BashID in BashHash
      • Set BashOffIndex = (BashOffIndex + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BashOffIndex Equal to 1
        • Then - Actions
          • Trigger - Turn on BashOn <gen>
        • Else - Actions
  • BashOn
    • Events
      • Game - GDD_Event becomes Equal to 0.00
    • Conditions
      • (Level of Thunder Clap for GDD_DamageSource) Greater than 0
    • Actions
      • Custom script: set udg_BashID = GetHandleId(udg_GDD_DamageSource)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Load 1 of BashID from BashHash) Equal to 1
        • Then - Actions
          • -------- this is the Bash/knockback start (too lazy to add it :) --------
          • Unit - Kill GDD_DamagedUnit
          • Set BashOffIndex = (BashOffIndex - 1)
          • -------- clearing the value so that this will not run again until the next ability cast --------
          • Hashtable - Clear all child hashtables of child BashID in BashHash
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • BashOffIndex Equal to 0
            • Then - Actions
              • Trigger - Turn off (This trigger)
            • Else - Actions
        • Else - Actions
 
Status
Not open for further replies.
Top