Announcement

Collapse
No announcement yet.

Able Ability System Info and Support Thread

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • replied
    Alright Able v3.15 submitted. Notes below:

    • Added support for UE 4.23
    • Added Bindable Dynamic Play Rate to Play Animation Task (let me know if you run into problems with this). This lets you dynamically change your Play Animation play rate at runtime.
    • Filtered out SKEL and REINST blueprint objects when using the Add Task picker. Blueprint objects use their display name rather than their raw name (no more Default__ if you don't override the GetTaskName method).
    As always, your feedback is super important and please let me know if you run into any issues.
    Originally posted by JSwigart View Post
    I have a blueprint class that extends AblCustomTask that implements the OnTaskStart override, I add the task to the timeline of an ability, the blueprint task OnTaskStart doesn't trigger. When I debug the code, I can see the UAblCustomTask::OnTaskStartBP gets called, FindFunctionChecked finds a function, but the Script field of the function is empty, so it doesn't execute anything, just early outs. I can't seem to get any of my blueprint tasks to work.
    I just verified it by making a simply custom task, overriding OnTaskStart and telling it print a string. I can give you the project if you want to see what I did and where you may be going wrong. You can grab it here.

    Leave a comment:


  • replied
    I have a blueprint class that extends AblCustomTask that implements the OnTaskStart override, I add the task to the timeline of an ability, the blueprint task OnTaskStart doesn't trigger. When I debug the code, I can see the UAblCustomTask::OnTaskStartBP gets called, FindFunctionChecked finds a function, but the Script field of the function is empty, so it doesn't execute anything, just early outs. I can't seem to get any of my blueprint tasks to work.

    Leave a comment:


  • replied
    Originally posted by KhxiSaki View Post
    is able build from the ground up or is it similiar or using UE4 Gameplay Ability System
    Built from the ground up. It has some similarities to GAS but that's mainly coincidence. GAS was pretty opaque when I started Able.
    Originally posted by JSwigart View Post
    Seems like UAblCustomTask aren't working in the latest code.

    The UAblCustomTask::OnTaskStartBP finds a function, but there is no script associated with the function, even though my blueprint has the OnTaskStartBP implemented. Any ideas?
    Define "no script associated with the function". If you have "OnTaskStart" overridden in the blueprint - then it should be fine. If you're trying to do it through code then you need to inherit from OnTaskStart as OnTaskStartBP isn't virtual (on the C++ level).

    Leave a comment:


  • replied
    Seems like UAblCustomTask aren't working in the latest code.

    The UAblCustomTask::OnTaskStartBP finds a function, but there is no script associated with the function, even though my blueprint has the OnTaskStartBP implemented. Any ideas?

    Leave a comment:


  • replied
    is able build from the ground up or is it similiar or using UE4 Gameplay Ability System

    Leave a comment:


  • replied
    Originally posted by JSwigart View Post
    What if the only options I see have the default tag?
    Because you're asking specifically for the default object. Admittedly, Able doesn't care because it uses the default under the hood, so anything besides SKEL should be fine.

    Leave a comment:


  • replied
    What if the only options I see have the default tag?

    Leave a comment:


  • replied
    Originally posted by JSwigart View Post
    Why does creating a blueprint ability task show up in the "Add Ability Task" menu like this?
    UE creates multiple blueprints under the hood for a given blueprint class. The default and skeleton BP options are supposed to be hidden. That's a quick fix, I'll get it in for the 4.23 update.

    Leave a comment:


  • replied
    Why does creating a blueprint ability task show up in the "Add Ability Task" menu like this?

    Leave a comment:


  • replied
    Originally posted by JSwigart View Post
    You may have fixed the branch argument already. I'm not on the latest currently given the number of modifications we've made. I would like to work our modifications back into Able(or come up with good alternatives) so we can keep Able more upgraded. I like the library, but I wanted to give some feedback on some issues that really get in the way of productivity and end up making certain abilities needlessly complex and/or require modifications to Able.


    Hopefully I am just missing something here, but ability contexts being the only thing that is instantiated per instance, and the abilities being basically a shared object, really seems to work against the grain of how UE4 is set up, blueprint wise.

    For example,

    Can't use ability local variables for anything other than shared data. I'd love to be able to define ability specific blueprint local variables for information pertinent to the ability(whose values will differ for each instance of the ability). For now, we've added a general purpose TMap<FString, float> key/value store to the ability context, and to support branch passing of data, I added an option to the branch task to copy the k/v map to the new ability. It's crude but it works, but it's only necessary because the only shared resource(ability context) is the object that is blueprint extendable

    Actor delegates are useless in ability blueprints. For one of our abilities, I had some ability logic that needed information only known when a delegate is called(such as ACharacter::LandedDelegate). If the ability were instantiated, I could just bind an event to my delegate and do what I need to do in there, because when the event is called, it would still have enough self context to do something useful with. Instead, if you Bind Event to the delegate in the blueprint of the ability, such as OnAbilityStart, where I would expect to be able to, it gets called on the ability, and you don't have the ability context to know who/where you are running on, so you can't do any logic to evaluate an ability instance with delegates.

    There are workarounds to these issues of course. I could have some scratch data fields to store the information from the delegates and poll them in the ability. Or I could extend the ability context with a simplistic data storage(as we've done), but these still feel like hacks to a flawed library design that are only necessary because Able was deliberately set up in a way that runs contrary to how UE4 blueprinting works.
    Yea that's intentional. Able uses the CDO to speed up a number of things (mainly around replication and memory costs). The only thing that is instantiated per Ability call is the Context and the ScratchPad for the Task (which is a much smaller structure and far cheaper memory/construction-wise). My background is in MMOs and Consoles so I tend to be very conservative around memory/CPU/bandwidth when I can. Ideally I could do what GAS does and allow the option to instantiate vs not, but I haven't felt the need to do that yet (and don't receive much customer feedback about it either) so I'm wary about adding more complexity to the fundamental behavior of Able.

    If you wanted to store state, you could modify the ScratchPads or the Context itself (as you have). So in your example, You could add a delegate to the ScratchPad for your task. Bind the Actor when the Task starts, and then release it afterwards.

    Leave a comment:


  • replied
    You may have fixed the branch argument already. I'm not on the latest currently given the number of modifications we've made. I would like to work our modifications back into Able(or come up with good alternatives) so we can keep Able more upgraded. I like the library, but I wanted to give some feedback on some issues that really get in the way of productivity and end up making certain abilities needlessly complex and/or require modifications to Able.


    Hopefully I am just missing something here, but ability contexts being the only thing that is instantiated per instance, and the abilities being basically a shared object, really seems to work against the grain of how UE4 is set up, blueprint wise.

    For example,

    Can't use ability local variables for anything other than shared data. I'd love to be able to define ability specific blueprint local variables for information pertinent to the ability(whose values will differ for each instance of the ability). For now, we've added a general purpose TMap<FString, float> key/value store to the ability context, and to support branch passing of data, I added an option to the branch task to copy the k/v map to the new ability. It's crude but it works, but it's only necessary because the only shared resource(ability context) is the object that is blueprint extendable

    Actor delegates are useless in ability blueprints. For one of our abilities, I had some ability logic that needed information only known when a delegate is called(such as ACharacter::LandedDelegate). If the ability were instantiated, I could just bind an event to my delegate and do what I need to do in there, because when the event is called, it would still have enough self context to do something useful with. Instead, if you Bind Event to the delegate in the blueprint of the ability, such as OnAbilityStart, where I would expect to be able to, it gets called on the ability, and you don't have the ability context to know who/where you are running on, so you can't do any logic to evaluate an ability instance with delegates.

    There are workarounds to these issues of course. I could have some scratch data fields to store the information from the delegates and poll them in the ability. Or I could extend the ability context with a simplistic data storage(as we've done), but these still feel like hacks to a flawed library design that are only necessary because Able was deliberately set up in a way that runs contrary to how UE4 blueprinting works.

    Leave a comment:


  • replied
    Originally posted by JSwigart View Post
    Is it possible to pass data from one ability to another other? I'm trying to prototype some abilities that don't seem to map into the way Able works, so I'm looking for recommendations. I like the system but it feels like it has a narrow band of utility when it comes to setting up abilities, particularly abilities that involve more than 1 phase of state.

    For example, I have a "ground pound" ability that is split into 2 abilities. I'll call them Pound_Air, and Pound_Land for reference

    Pound_Air - The first ability is activated when the character is in the falling state and they press the attack button. This ability loops and starts an animation with the characters fist raised in preparation. It also has a branch which checks for whether the character has landed. When the character lands, this ability branches to Pound_Land

    Pound_Land - This action immediately starts an animation, effects, and sounds for pounding the ground, as well as some radius queries and damage tasks.

    The problem is that the Pound_Air needs to perform some logic that results in some information that Pound_Land needs, such as evaluating whether the landing (based on velocity, etc) should be a heavy or a light Pound_Land, and there doesn't appear to be a mechanism to pass data between abilities. Requiring different

    It looks like the closest thing available would require modifications, and that would be the key value set on the ability context, and extend the branch task to copy the key/value set like it does the targets, but it doesn't feel ideal. It also doesn't feel ideal to make a bunch of individual ability elements just to account for the different phases of a broader ability concepts. It'd be great if these abilities were authorable similar to how montages are authorable, with several discrete 'sections' that represent different phases of an ability. In that case the in air and land could be part of a single ability, which is far nicer to work with and also limits the scope for issues like this where data sharing is necessary.

    Have you set up some non trivial abilities like this? And if so, how did you resolve these issues?

    Sorry for the delay on this, I swear Epic only sends every other notification.

    No, currently there is no way to pass information from one ability to another. The way I got around that in the Chain Lightning example is just to store that info on the target (or the player itself) and the other ability just asks the player for the info. You could pass in the old context into the new ability to let it grab whatever, but I currently don't have that setup.

    Originally posted by JSwigart View Post
    Also, why does the code of UAblBranchTask ultimately pass the current context ability to the CanBranchTo function? I thought for sure it would pass the desired destination ability. Otherwise having multiple branch tasks within the same ability wouldn't be distinguishable from each other in the CanBranchTo code. Am I missing something here?
    It should pass the current context and the Ability it wants to transition to. If it's not, that's a bug (although I swear that was fixed recently). I'll verify again.

    Originally posted by Kenyon1977 View Post
    Hi
    Does able ability system allows additive animation playback? So we can layer one animation over another, and possible by body parts?
    Layering your animations is driven entirely through the Animation Blueprint system. Able does have a special animation node that will blend between animations you call in Able (if you're using that mode) so you can dynamically blend between sword swings or what ever, but if you want to actually break it up so the top of the skeleton does one animation while the lower half does another - you'll have to set that up yourself.

    Leave a comment:


  • replied
    Hi
    Does able ability system allows additive animation playback? So we can layer one animation over another, and possible by body parts?

    Leave a comment:


  • replied
    Also, why does the code of UAblBranchTask ultimately pass the current context ability to the CanBranchTo function? I thought for sure it would pass the desired destination ability. Otherwise having multiple branch tasks within the same ability wouldn't be distinguishable from each other in the CanBranchTo code. Am I missing something here?

    Leave a comment:


  • replied
    Is it possible to pass data from one ability to another other? I'm trying to prototype some abilities that don't seem to map into the way Able works, so I'm looking for recommendations. I like the system but it feels like it has a narrow band of utility when it comes to setting up abilities, particularly abilities that involve more than 1 phase of state.

    For example, I have a "ground pound" ability that is split into 2 abilities. I'll call them Pound_Air, and Pound_Land for reference

    Pound_Air - The first ability is activated when the character is in the falling state and they press the attack button. This ability loops and starts an animation with the characters fist raised in preparation. It also has a branch which checks for whether the character has landed. When the character lands, this ability branches to Pound_Land

    Pound_Land - This action immediately starts an animation, effects, and sounds for pounding the ground, as well as some radius queries and damage tasks.

    The problem is that the Pound_Air needs to perform some logic that results in some information that Pound_Land needs, such as evaluating whether the landing (based on velocity, etc) should be a heavy or a light Pound_Land, and there doesn't appear to be a mechanism to pass data between abilities. Requiring different

    It looks like the closest thing available would require modifications, and that would be the key value set on the ability context, and extend the branch task to copy the key/value set like it does the targets, but it doesn't feel ideal. It also doesn't feel ideal to make a bunch of individual ability elements just to account for the different phases of a broader ability concepts. It'd be great if these abilities were authorable similar to how montages are authorable, with several discrete 'sections' that represent different phases of an ability. In that case the in air and land could be part of a single ability, which is far nicer to work with and also limits the scope for issues like this where data sharing is necessary.

    Have you set up some non trivial abilities like this? And if so, how did you resolve these issues?


    Leave a comment:

Working...
X