i want to create a combatant with an ability to fire arrow toward the farthest enemies,but i find the target selection has no suitable options available. How can i implement this?
Any comments will be much appreciated.
  • edited August 2023
    Hi,

    When you say farthest enemies do you mean you want it limited to only work on the farthest away enemy? Or just that you want it to be a longer range than your standard abilities?

    If you go to Templates --> Battle Range Templates
    You can set up ranges with minimum/maximum ranges

    Then on an ability you go to Target Selection Settings --> Use Range Setting --> Check the box for Own Use Range (this overwrites the battle setting for default range) --> Click Add Range --> Template --> select the template you created.
    (You could maybe use a formula here for finding farthest not sure?? Instead of a template)

    Otherwise, I think you'd have to check the range of enemy combatants in the schematic animating the ability or in action schematic to find the farthest.

    You can make an Actor in the Settings node of schematic that is Enemies (Battle)
    Then Select Combatant node to store that in to selected data (I think this will work for the sort?)
    Then there is a node called Sort Selected Combatants that can sort by distance.
    Post edited by GeneralK on
  • There're no options to 'select' the targets, but if you e.g. use a Group Target range to target all enemies within defined use range, you can afterwards get the farthest away targets and change the action's targets in the schematic animating the ability.

    To do this in the schematic:
    - Select Combatant node to store all current targets into selected data (enable Use All Combatants, Current combatant scope and use the Starting Object)
    - Sort Selected Combatants node to sort them based on distance to the user
    - Select Selected Data node to get single combatants from the stored selected data and put them into another selected data for your targets > i.e. you can e.g. get the first or last from the list (and remove them) to only use the closest or farthest enemies
    - Change Action Targets node to change the targets for the action to the combatants you selected
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.