#How to trace for targets in GAS #1

1 messages · Page 1 of 1 (latest)

orchid spoke
#

Can you explain your use case ?

ashen furnace
#

im doing the GA subclass to apply GEs on source and target while the GA is active

orchid spoke
ashen furnace
#

yeah ive read tranek sections on targeting

orchid spoke
#

How do you define a target in your case ?

ashen furnace
#

but my use case is so simple i dont understand why i cant simply get the actor

orchid spoke
#

Different games can have different definitions / workflow

ashen furnace
#

idk, "Attack Ability" Source: Player, Target: Some AI

#

i dont have any fancy targetting data, i just need a reference to the targeted actor/ASC

ashen furnace
#

yeah im using those, but i dont have a ref to the target

orchid spoke
#

whatever you think it should be.

ashen furnace
#

the GA doesnt have the attack logic

#

it serves as a tag and GE container

#

My Component -> Try Activate GA -> if suceeded run attack logic

orchid spoke
ashen furnace
#

no, i assumed i could use a default "target" thing to get a target actor

orchid spoke
#

you have to tell GAS which is it, because it can't know by default until you program it.

#

It could be ANYTHING

#

one actor, 10, all on the server, from a line trace, an overlap ... it could be an actor or a hit result

#

All is valid, and will bear +/-

ashen furnace
#

the default engine FGameplayAbilityTargetData has what i want

#

ill check how i give it to my GA

orchid spoke
#

what I want as in ?

#

An actor OR THE Actor, the right one, already named etc ?

ashen furnace
#

yes, it has an array of actors

orchid spoke
#

Yeah it has

#

but you have to fill it ... again

orchid spoke
#

YOU are responsible for that

#

You can use the target actors that GAS has to "trace"

#

How to trace for targets in GAS #1

ashen furnace
#

how do i pass my target struct to an GA ?

#

the activate func doesnt seem to have an param for that

orchid spoke
# ashen furnace the activate func doesnt seem to have an param for that

In this video, we go over how to create gameplay abilities with targeting indicators, VFX, animations, and gameplay effects. Please leave comment with what you'd like to see next in this series!

I found a surprising lack of content on Unreal Engine's Gameplay Ability System so I d...

▶ Play video
#

Seems you're trying to grok your way in.

#

I would recommend to watch / read a bit.

#

I can always make an example on Narxim later. I should.

#

I do have one very simple example with a line/capsule trace

#

that's pretty simple, not even using target data, and it works fine.

ashen furnace
#

i guess ill move the logic to the GA

#

instead of trying to pass the resulting data to the GA