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

[Spell] Dummy Unit don't cast spell at the same time with hero and idk why

Level 13
Joined
Sep 11, 2013
Messages
487
Greetings!

I found a weird problem with my trigger.
  • Shadow Strike WISP 0 MS
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Unit-type of (Casting unit)) Equal to Infernal WISP 0 MS
      • (Ability being cast) Equal to Shadow Strike - INT Channel
    • Actions
      • Game - Display to (All players) the text: WISP 0 MS
      • Unit - Create 1 Wisp Shadow Strike Dummy 0 MS for (Owner of (Casting unit)) at (Position of (Casting unit)) facing (Angle from (Position of (Casting unit)) to (Position of (Target unit of ability being cast))) degrees
      • Unit - Add a 10.00 second Generic expiration timer to (Last created unit)
      • Unit - Add Shadow Strike XXX to (Last created unit)
      • Unit - Set level of Shadow Strike XXX for (Last created unit) to (Level of Shadow Strike - INT Channel for (Casting unit))
      • Unit - Order (Last created unit) to Neutral - Parasite (Target unit of ability being cast)
So, the problem is that this dummy unit has a spell (Shadow Strike XXX) that has even more cast range than my Hero spell (Shadow Strike - INT Channel) and if the enemy unit is running away from me, but somehow I manage to cast the hero spell at maximum cast range while the enemy unit is running away, the dummy (even with 100 bonus cast range on his spell) will not release the spell on that enemy unit. Why my dummy is not cast his spell in the same time with my hero? (In this case Dummy WISP has 0 Movement Speed)

In the second case, I set Dummy WISP movement speed to 522)
Now, When I cast the spell with my hero in the same scenario, The dummy unit will start to move to the enemy unit and then release his spell.
That's make no sense for me because dummy has more cast range than me on his spell. The only explanation is that, there is a delay between spells.

BUT I tested that with the same spell on both units and seems to be instant while the enemy is not moving.
BUT When the enemy is moving, the spells are no more instant and work only on Hero. :peasant-confused:

Here is an example of dummy with 0 ms and dummy with 522 ms behavior.


If I put global cast range on dummy spell, there is another problem because if an enemy unit blink away or teleports imediately after I start casting the hero spell, the dummy spell will go the entire map after that enemy and I don't want that. What I wish is simple.. If hero manage to cast the spell and enemy blink or teleport, the poison/missile must miss the enemy. Also, If hero manage to cast the spell, the dummy must launch the second spell at the same time.

How can I do that?

I attached the map with samples.

The help will be appreciated!
 

Attachments

  • Shadow Strike delay BUG.w3m
    19.4 KB · Views: 3
Last edited:
Level 13
Joined
Sep 11, 2013
Messages
487
Is there a reason you give such a short specific range to your dummy spell? Sure it's higher than the hero's spell but you could give it e.g. 5000 range and it'll most likely solve the issue
As I said here
If I put global cast range on dummy spell, there is another problem because if an enemy unit blink away or teleports imediately after I start casting the hero spell, the dummy spell will go the entire map after that enemy and I don't want that. What I wish is simple.. If hero manage to cast the spell and enemy blink or teleport, the poison/missile must miss the enemy. Also, If hero manage to cast the spell, the dummy must launch the second spell at the same time.
This is the problem.

I still don't understand why my dummy refuse to cast the spell at the same time with my hero when the enemy is moving.. If the hero has enough range to cast the spell, why the dummy refuse to cast the spell even with bigger range?
 
Level 29
Joined
Sep 26, 2009
Messages
2,612
You may have increased dummy's spell range by 100, but that is too low.
Simply put, you may have set dummy's cast point to 0.00, but you have ignored caster's Cast point. Caster's cast point offsets time when dummy is created.
  • Your caster's cast point is 0.3 seconds.
  • Your mortar team unit is moving at 450.00 speed per second, that means it will move 135.00 range over the 0.3 second duration.

So even if your dummy unit's cast range is increased by 100 range, it will be of no use because the dummy unit is created after 0.3 seconds since caster started the spell, and during those 0.3 seconds mortar team moves away by 135.00 range, getting outside dummy's increased cast range.
 
Level 24
Joined
Feb 27, 2019
Messages
842
Theres a gameplay constant called: Spells - Target Motion Allowance (default 300 range). Its a gameplay mechanic which allows spells that have begun casting an additional 300 range until it starts the effect. Without it units would just run after the target, try to cast but fail cuz instantly out of range and repeat.

The problem you are talking about exists in vanilla and possibly all custom games but its such a rare event that basically must be triggered by something like Starts the effect -> Move target unit of ability being cast to point. When the event occurs you can consider that the missile will be spawned and will hit its target. I guess blink and possibly teleport has inbuilt behaviour to nullify missiles so if a missile is cast and the target blinks, the missile will miss the target. You may possibly be able to do some stupid shit with these abilities to nullify a missile but as I said what youre talking about is vanilla behaviour already and probably wont happen ever.

Anyway if you add 300 range to the dummy ability itll probably behave as excpected.
 
Level 13
Joined
Sep 11, 2013
Messages
487
Have you changed the dummy animation - cast point and animation - backswing value in object editor? they must be 0.00.
Yes, they are and were 0 when I tested in that video.
You may have increased dummy's spell range by 100, but that is too low.
Simply put, you may have set dummy's cast point to 0.00, but you have ignored caster's Cast point. Caster's cast point offsets time when dummy is created.
  • Your caster's cast point is 0.3 seconds.
  • Your mortar team unit is moving at 450.00 speed per second, that means it will move 135.00 range over the 0.3 second duration.

So even if your dummy unit's cast range is increased by 100 range, it will be of no use because the dummy unit is created after 0.3 seconds since caster started the spell, and during those 0.3 seconds mortar team moves away by 135.00 range, getting outside dummy's increased cast range.
That makes a lot of sense. Thank you for explanation, but the problem is still there even if I set the Caster like a dummy with cast point to 0.00. The dummy still has +100 bonus cast range on that spell, but don't cast the spell. I think this is a bug or we miss something.

Theres a gameplay constant called: Spells - Target Motion Allowance (default 300 range). Its a gameplay mechanic which allows spells that have begun casting an additional 300 range until it starts the effect. Without it units would just run after the target, try to cast but fail cuz instantly out of range and repeat.

The problem you are talking about exists in vanilla and possibly all custom games but its such a rare event that basically must be triggered by something like Starts the effect -> Move target unit of ability being cast to point. When the event occurs you can consider that the missile will be spawned and will hit its target. I guess blink and possibly teleport has inbuilt behaviour to nullify missiles so if a missile is cast and the target blinks, the missile will miss the target. You may possibly be able to do some stupid shit with these abilities to nullify a missile but as I said what youre talking about is vanilla behaviour already and probably wont happen ever.

Anyway if you add 300 range to the dummy ability itll probably behave as excpected.

I didn't know about that Target Motion Allowance. Hmm.. Interesting. Thank you for explanation. However, from what I understand, If I set caster's cast point to 0.00, the Target Motion Allowance will be 0 in that case, no? But somehow the dummy still refuse to cast the spell even with +100 bonus cast range..

Why this happen? Is this a bug? :peasant-confused: :peasant-confused: :peasant-confused:
 
Top