I'm trying to make an Ability - Instant, that checks if there are units in Radius of 12. If so (if not, an error pops up and ablity is not cast) equal or more than 1, then a Persistent is created with a period count of 8 times with duration of 0.8. Periodic effect is search area ,count 1 (TargetSort: LargestLife) with the effect to launch an missile (damage on impact) to the unit it found in the search.
Have it sort of working, however
1: A validator at the ability will not prevent the ability from working when there are no targets nearby (radius 12).
2: Also a problem I just cannot fix: How can I let my unit turn to the targets its shooting at, cause now it looks really weird.
Try an EnumerateArea validator on the effect produced by the ability, or possibly the "Smart Validators" field on the ability itself. Validators on effects further down the chain will merely block the effect, not the cast.
Use an Issue Order effect to make the unit turn. Turning is part of the Move ability, you can view all its command keys on the ability itself, Turn is "4". This uses the turning speed of the unit itself though, and afaik there is no way of turning the actual unit "instantly". Visually you can do it with actor trickery if needed.
I suggest you first apply the Issue Order, then the delay, and then launch the missile. At 0.8s fire rate and 360° firing arc with no angle-based preference the result might still look patently ridiculous, so you might want to rethink those stats or the visual design of the ability if it isn't to your liking. (infantry-launched combat drone, vertical missile launch or a central large blue energy orb to list some alternative visuals depending on the theme of your unit)
Probably the combination of 0 casting arc and maintaining the "use ability" command through the channel. I never tried if escaping the "Arc Slop" area actually breaks the channel, but you can observe the same behavior in units continuously attacking with regular weapons (continuous use of the "Attack" ability)
You can probably get around this if need be, by having a dummy ability for the button: The command card ability you make visible to the player has 0 casting arc and triggers an Issue Order effect, which then makes the unit cast the second, hidden, ability with 360° casting arc and the actual channeled effect. Just a heads up in case you need it.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hi There,
I'm trying to make an Ability - Instant, that checks if there are units in Radius of 12. If so (if not, an error pops up and ablity is not cast) equal or more than 1, then a Persistent is created with a period count of 8 times with duration of 0.8. Periodic effect is search area ,count 1 (TargetSort: LargestLife) with the effect to launch an missile (damage on impact) to the unit it found in the search.
Have it sort of working, however
1: A validator at the ability will not prevent the ability from working when there are no targets nearby (radius 12).
2: Also a problem I just cannot fix: How can I let my unit turn to the targets its shooting at, cause now it looks really weird.
People have suggestions for this matters?
Kind Regards,
Maarten Eekhof
I suggest you first apply the Issue Order, then the delay, and then launch the missile. At 0.8s fire rate and 360° firing arc with no angle-based preference the result might still look patently ridiculous, so you might want to rethink those stats or the visual design of the ability if it isn't to your liking. (infantry-launched combat drone, vertical missile launch or a central large blue energy orb to list some alternative visuals depending on the theme of your unit)
I think I'll try your suggestion about rethink the visual design.
However, just curiosity, if you use the Ability - Target and it channels, the unit follows the target. What is causing that focus?
Probably the combination of 0 casting arc and maintaining the "use ability" command through the channel. I never tried if escaping the "Arc Slop" area actually breaks the channel, but you can observe the same behavior in units continuously attacking with regular weapons (continuous use of the "Attack" ability)
You can probably get around this if need be, by having a dummy ability for the button: The command card ability you make visible to the player has 0 casting arc and triggers an Issue Order effect, which then makes the unit cast the second, hidden, ability with 360° casting arc and the actual channeled effect. Just a heads up in case you need it.