Help with spell

erique

New Member
Reaction score
0
Hello, I've been toying around with WE for about a month now and I've just learned basic trigger making. Since I've been a fan of DotA (and all their spells are made of triggers) I decided to try myself. Although, I'm stuck now. I tried to make this spell; Flamepath which creates several Flame Strikes in front of the caster. There's something strange with this though, regardless where I cast it, it always goes towards the east. What's wrong with the code?
Code:
Flamepath
Events
    Unit - A unit Starts the effect of an ability
Conditions
    (Ability being cast) Equal to Flamepath (real) (Neutral Hostile)
Actions
    If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        If - Conditions
            (Level of (Ability being cast) for (Casting unit)) Equal to 1
        Then - Actions
            Unit - Create 1 Flamepather for Player 1 (Red) at ((Position of (Casting unit)) offset by 20.00 towards (Facing of (Casting unit)) degrees) facing (Facing of (Casting unit)) degrees
            Set Flamepath[1] = (Last created unit)
            Unit - Set level of Flamepath  for (Last created unit) to 1
            Unit - Order (Last created unit) to Human Blood Mage - Flame Strike (Position of (Last created unit))
            Wait 0.20 seconds
            Wait 0.01 seconds
            Unit - Create 1 Flamepather for Player 1 (Red) at ((Position of (Last created unit)) offset by 110.00 towards (Facing of (Casting unit)) degrees) facing (Facing of (Casting unit)) degrees
            Set Flamepath[2] = (Last created unit)
            Unit - Set level of Flamepath  for (Last created unit) to 1
            Unit - Order (Last created unit) to Human Blood Mage - Flame Strike (Position of (Last created unit))
            Wait 0.01 seconds
            Wait 0.02 seconds
            Unit - Create 1 Flamepather for Player 1 (Red) at ((Position of (Last created unit)) offset by 110.00 towards (Facing of (Casting unit)) degrees) facing (Facing of (Casting unit)) degrees
            Set Flamepath[3] = (Last created unit)
            Unit - Set level of Flamepath  for (Last created unit) to 1
            Unit - Order (Last created unit) to Human Blood Mage - Flame Strike (Position of (Last created unit))
            Wait 0.01 seconds
            Wait 0.20 seconds
            Unit - Create 1 Flamepather for Player 1 (Red) at ((Position of (Last created unit)) offset by 110.00 towards (Facing of (Casting unit)) degrees) facing (Facing of (Casting unit)) degrees
            Set Flamepath[4] = (Last created unit)
            Unit - Set level of Flamepath  for (Last created unit) to 1
            Unit - Order (Last created unit) to Human Blood Mage - Flame Strike (Position of (Last created unit))
            Wait 0.01 seconds
            Wait 0.20 seconds
            Unit - Create 1 Flamepather for Player 1 (Red) at ((Position of (Last created unit)) offset by 110.00 towards (Facing of (Casting unit)) degrees) facing (Facing of (Casting unit)) degrees
            Set Flamepath[5] = (Last created unit)
            Unit - Set level of Flamepath  for (Last created unit) to 1
            Unit - Order (Last created unit) to Human Blood Mage - Flame Strike (Position of (Last created unit))
            Wait 1.00 seconds
            Unit - Remove Flamepath[1] from the game
            Unit - Remove Flamepath[2] from the game
            Unit - Remove Flamepath[3] from the game
            Unit - Remove Flamepath[4] from the game
            Unit - Remove Flamepath[5] from the game
        Else - Actions
Is it solveable?
I really suck at this so no JASS please :)
 

PoZoR

New Member
Reaction score
5
usually if something is facing east it means 0 degrees, the default for any trigger action that somehow cannot acquire an angle. i dont recall or use "casting unit" as a reference in any actions for triggers, referencing triggering unit seems to be the most problem free, instead of casting unit that is.
 

Nerfpl

New Member
Reaction score
53
you should make it like
set real = math - Angle between (position of casting unit, target point of ability being cast)
this give you 2 leaks tho.

then crate unit facing real degrees.
 

erique

New Member
Reaction score
0
I'll try it, though I'm not 100% sure of what you mean (these terms are still a mystery to me)
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top