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

Problem with target point of an ability

Status
Not open for further replies.
Level 4
Joined
Jan 5, 2014
Messages
79
I was doing somethink with trigger spells and dummy units and i found out this:

I have a dreadlord with the ability Carrion swarm.

I have a trigger, which should do this:

  • Untitled Trigger 001
    • Events
      • Unit - A unit Finishes casting an ability
    • Conditions
    • Actions
      • Unit - Create 1 Dummy for Player 1 (Red) at (Target point of ability being cast) facing Default building facing degrees
but the Dummy unit is created always at one point (probably at the centre of playable map area). Do you know why?

Edit:
I alredy found out. The target point of ability being cast is always 0,0. Now the question is: does someone know why?
 
Level 28
Joined
Sep 26, 2009
Messages
2,520
There is no "target point of ability being cast" for the event "Unit finishes casting an ability" nor is for "unit stops casting an ability".
There is also no "target unit of ability being cast" for such events.

You will most likely need to use different event ("Start the effect of an ability") or store the information (in this case: target point) when unit starts casting the ability and then load the point when unit finishes casting an ability.
 
Level 4
Joined
Jan 5, 2014
Messages
79
Somethink i found out: The response Target point of ability being cast does rospond to unit starts casting an ability but does not respond to Unit finishes casting an ability. strange
 
Level 28
Joined
Sep 26, 2009
Messages
2,520
It's not strange really. There is no longer any ability being currently cast, since the event fires the moment the unit stops casting it. That way all the relevant data (target unit, target point and maybe some other) are lost.

As I wrote in my previous post, you will either need to use the event "Starts casting an ability" for the event to fire, or you will use that event to just save the target point of ability being cast into variable and when unit "Finishes casting an ability", you will load the point from the variable you saved it into.
 
Status
Not open for further replies.
Top