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

Casting ability but facing wrong...

Status
Not open for further replies.
Level 2
Joined
Aug 20, 2017
Messages
14
I made a ground-target ability(Shockwave,Envision) and make a trigger with it.... Everytime i cast it, a bullet will come out and shoot. But the problem is when casting behind my unit-facing , the attack animation is already performed while the rotating(angle,direction) process is still ongoing..It's look like cast and turn. But there is no problem when the different within the casting angle and the facing angle of my unit is close like casting angle is (60 degrees) and current angle is (30 degrees)...
 
Level 7
Joined
May 14, 2019
Messages
255
I think you may solve the problem by adding wait 0.5 or so seconds of gametime to the trigger

in my experimentation triggers often need to have the wait action in them because they are executed instantly while spells take time
 
Level 8
Joined
May 21, 2019
Messages
435
The problem is that your character is turning at a certain rate. You can edit this in the object editor, but even then, it's fairly limited, I think a 160 degree turn takes about 0.5 seconds at the very least. I believe that the stat is called turn rate.
There's probably some clever hack that can be used to instantly turn units around, but the base function in the trigger editor uses the units turn rate as the maximum speed. I found that even moving units instantly with the facing specified, is still subject to regular turn rate restriction. If the unit is not a hero, you could probably get away with replacing the unit really fast, but that's not gonna work well if there's a lot of factors to take into account. It could of course be done with a hero as well, but then there's a ton of things that you need to take into account to make it seemless.
Either way, I might run a few tests on ways to instantly turn units later, as I have a current need for that myself, but as of now, I am not aware of any way to do it without creating a new unit.
 
Status
Not open for further replies.
Top