• 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.

Channeling Blizzard

Status
Not open for further replies.
Create a new Spell:

Event: Every 2.00 of the game.
Condition //
Action:
Pick Every Unit in BlizzardCasterGroup and do
Set UnitMana of pickedUnit to (UnitMana of PickedUnit) - 25.
if Mana of Unit(pickedUnit) < 25. then
call Unit - Issue pickedUnit to stop
endif

and another trigger:
Event: A unit starts casting a spell
Condition: Spell == Blizzard
Action:
Add Unit to BlizzardCasterGroup

and another trigger:
Event: A unit gets an order without target
A unit gets an point target order
A unit gets an target order
Condition: Triggering unit is in BLizzardCasterGroup
Action:
call GroupRemoveUnit(BlizzardCasterGroup, TriggeringUnit)

Sorry, I don't have the editor here, so its written out of the head.

I hope it helps.
 
doesn't work, am I doing it wrong?

  • Blizzard Caster
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Blizzard
    • Actions
      • Unit Group - Add (Triggering unit) to BlizzardCasterGroup
  • Blizzard
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in BlizzardCasterGroup and do (Actions)
        • Loop - Actions
          • Unit - Set mana of (Picked unit) to ((Mana of (Picked unit)) - 25.00)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Mana of (Picked unit)) Less than 25.00
        • Then - Actions
          • Unit - Order (Picked unit) to Stop
        • Else - Actions
  • Remove Blizzard Caster
    • Events
      • Unit - A unit Is issued an order with no target
    • Conditions
    • Actions
      • Unit Group - Remove (Triggering unit) from BlizzardCasterGroup
      • Custom script: call DestroyGroup (udg_BlizzardCasterGroup)
 
Level 19
Joined
Sep 4, 2007
Messages
2,826
  • Blizzard
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in BlizzardCasterGroup and do (Actions)
        • Loop - Actions
          • Unit - Set mana of (Picked unit) to ((Mana of (Picked unit)) - 25.00)
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Mana of (Picked unit)) Less than 25.00
            • Then - Actions
              • Unit - Order (Picked unit) to Stop
            • Else - Actions
 
Status
Not open for further replies.
Top