I want a "condition" on my trigger (It's an If Then Else) that checks if Unit B (Spell X's target) is a specific unit type (For this example lets use Zergling).
So Unit A can cast Spell X on any unit (Not just Zerglings), but I want to fire an additional action if Unit B (Spell X's target) is a Zergling.
My First attempt:
I used the condition (Comparison: Triggering Ability Target Unit == Value Y). I wanted to assign a "Unit Type" variable to "Value Y", the "unit type" variable was Zergling. This way the condition would check if the target of Spell X was a Zergling.
The problem with this method was that I couldn't assign a "unit type" variable to Value Y.
EDIT: Crud I ended up solving my problem before I got a response, maybe I should have waited longer than an hour of investigating to post in the forum DX. I found the "Unit Type of Unit" condition through google.
I am obliterating so many obstacles right now, I never thought I would make a trigger this complex.
The editor isn't that complicated once you become familiar with it. I think there might be something in the actor to specify the animation time. Im not sure though as I don't have too much experience with actors. If you are still having trouble finding where things are in the editor I recommend going to the tutorials link in my signature. It has tons of great tutorials about just about everything.
Also, in general, it is better to use only data when possible, as using triggers for things that can be done using data can sometimes create issues.
I want to avoid editing the animation itself because I am using the unit's "attack" animation for the casting animation and I don't want the unit to animate for 5 seconds after attacking once.
I still haven't found a way around it, and this detail is probably going to bug me to death since I can't stand watching my unit in idle animation while gathering or in attack animation while not attacking XD.
Once I am done with this problem I am going to avoid using actors as much as I can. (Triggers are my only strong point atm)
I am making a trigger where:
Unit A (Caster) casts spell X on Unit B (Target).
I want a "condition" on my trigger (It's an If Then Else) that checks if Unit B (Spell X's target) is a specific unit type (For this example lets use Zergling).
So Unit A can cast Spell X on any unit (Not just Zerglings), but I want to fire an additional action if Unit B (Spell X's target) is a Zergling.
My First attempt: I used the condition (Comparison: Triggering Ability Target Unit == Value Y). I wanted to assign a "Unit Type" variable to "Value Y", the "unit type" variable was Zergling. This way the condition would check if the target of Spell X was a Zergling.
The problem with this method was that I couldn't assign a "unit type" variable to Value Y.
EDIT: Crud I ended up solving my problem before I got a response, maybe I should have waited longer than an hour of investigating to post in the forum DX. I found the "Unit Type of Unit" condition through google.
I am obliterating so many obstacles right now, I never thought I would make a trigger this complex.
@wisesquirrel: Go
Fixed it.
BUT NOW I HAVE A NEW PROBLEM
How do I play an animation for a duration of 5 seconds via triggers?
I know how to play it once...I know how to play it forever, I don't know to play it for 5 seconds...this editor is so hard and non-intuitive D;
@wisesquirrel: Go
The editor isn't that complicated once you become familiar with it. I think there might be something in the actor to specify the animation time. Im not sure though as I don't have too much experience with actors. If you are still having trouble finding where things are in the editor I recommend going to the tutorials link in my signature. It has tons of great tutorials about just about everything.
Also, in general, it is better to use only data when possible, as using triggers for things that can be done using data can sometimes create issues.
New to the Editor? Need a tutorial? Click Here
Want data assets? Click Here
@fishy77: Go
I want to avoid editing the animation itself because I am using the unit's "attack" animation for the casting animation and I don't want the unit to animate for 5 seconds after attacking once.
I still haven't found a way around it, and this detail is probably going to bug me to death since I can't stand watching my unit in idle animation while gathering or in attack animation while not attacking XD.
Once I am done with this problem I am going to avoid using actors as much as I can. (Triggers are my only strong point atm)
@wisesquirrel: Go
Through the power of comparing and limited reasoning I have DONE IT!!!
By using the tinting method here http://www.sc2mapster.com/forums/development/data/34764-help-with-actor-to-behavior-solved/
And replacing the Set Tint / Clear Tint with Animation Play (Play Forever) / Animation Clear by reading this tutorial http://www.sc2mapster.com/forums/resources/tutorials/4656-data-working-with-actors-beginner-difficulty/
I have somehow (I'm still not completely sure what I did) made the unit play the animation while it has a Behavior active.
Another obstacle out of the way.