• 🏆 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!

[Trigger] Guess what? Another problem -.-

Status
Not open for further replies.
Level 10
Joined
Mar 23, 2007
Messages
261
Well ive made an ability based of "Devotion Aura". It works like critical strike, it just deals intelligence x1 damage instead. But it never works. Anyone can help me?


Magical Strike
Events
Unit - A unit starts the effect of an ability
Conditions
(Ability being cast) equal to Magical Strike
Actions
Set Chance = (Random integer between 1 and 100)
If (All conditions are true) Then do (Then actions) else do (Else actions)
If - Conditions
Chance less or equal to 15
Then - Actions
Set MagicalStrike = (Real((Intelligence of (Triggering Unit) (Include Bonuses))))
Unit - Cause (Triggering Unit) to damage (Target unit of being cast), dealing MagicalStrike damage of attack type spells and damage type normal
Else - Actions
 
Level 13
Joined
Nov 4, 2006
Messages
1,239
  • Magical Strike
  • Events
    • Unit - A unit starts the effect of an ability
  • Conditions
    • (Ability being cast) equal to Magical Strike
  • Actions
    • Set Chance = (Random integer between 1 and 100)
    • If (All conditions are true) Then do (Then actions) else do (Else actions)
    • If - Conditions
      • Chance less or equal to 15
    • Then - Actions
      • Set MagicalStrike = (Real((Intelligence of (Triggering Unit) (Include Bonuses))))
      • Unit - Cause (Triggering Unit) to damage (Target unit of being cast), dealing MagicalStrike damage of attack type spells and damage type normal
    • Else - Actions

i think you cannot use start the effect of an ability here, maybe a unit is attacked works together with, Unit has buff devotion aura
 
Level 28
Joined
Mar 25, 2008
Messages
2,955
You could put it like this:
  • MS
    • Events
      • Unit - A unit is being attacked
    • Conditions
      • ((Attacking unit) has buff Magical Strike) Equal to True
    • Actions
      • If ((Random integer number between 1 and 100) Less or equal than 15) then do (Unit - Cause (Attacking unit) to damage (Attacked unit), dealing (Real((Intelligence of (Attacking Unit) (Include Bonuses)))) damage of attack type spells and damage type normal) else do (Do nothing)
 
Status
Not open for further replies.
Top