Announcement

Collapse
No announcement yet.

Able Ability System Info and Support Thread

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

    Following the Able tutorial 1 on youtube. ( https://www.youtube.com/watch?v=edItxti5cW0 ).

    As soon as I change damage target to Target Actor, the ability gives data validation errors on save:

    No Query Dependency Defined: stdAttack with GetCopyResultsToContext
    /Game/Abilities/stdAttack contains invalid data.
    Data validation FAILED.
    Files Checked: 1, Passed: 0, Failed: 1, Skipped: 0, Unable to validate: 0

    Any idea what would be causing this?

    Thanks for your time.

    Comment


      Originally posted by jhirsh View Post
      Following the Able tutorial 1 on youtube. ( https://www.youtube.com/watch?v=edItxti5cW0 ).

      As soon as I change damage target to Target Actor, the ability gives data validation errors on save:

      No Query Dependency Defined: stdAttack with GetCopyResultsToContext
      /Game/Abilities/stdAttack contains invalid data.
      Data validation FAILED.
      Files Checked: 1, Passed: 0, Failed: 1, Skipped: 0, Unable to validate: 0

      Any idea what would be causing this?

      Thanks for your time.
      It's complaining that you have the Task Target set to "Target Actor" but you don't have Targeting defined on the Ability or a Dependency setup on a Query Task (you need one of the two to use the Target Actor Task Target). If you have a query Task setup in your Ability, just make sure you add a Depedency (right click on the Damage Task and set the dependency on your Query).
      Able Ability System - A high performance, robust ability system for UE4. Now Available!

      Comment


        Able 3.50 being submitted later today, notes below:

        3.50 Notes

        New Features:
        • Able will now re-use Scratchpads and Ability Contexts, this means less runtime object creation and better memory utilization / less fragmentation.
          • You can control how many (if any) Contexts Able will pre-create at World start, and the max contexts/scratchpads it will hold on to. See the settings for more info.
          • You can disable the Scratchpad / Context re-use if you see problems.
        • Custom Tasks use the new pooling system, but it requires some hook up on the user side (see the next bullet point).
        • "CreateScratchPad" is now deprecated. You'll get some warnings if you try to use it that point you to the new method.
          • There is a new BP Method called "GetTaskScratchPadClass" which returns the class you want to use for your scratchpad and instantiation is handled interally according to your settings (this mirrors what the Ability Scratchpad setup is).
          • There is a new BP method called "ResetScratchPad", because ScratchPads are re-used - you must use this method to reset any variables back to what you expect (empty arrays out, etc).
        • Ability Scratchpads will attempt to use the system as well (if enabled in the settings).
          • Like Custom Tasks, there is now a "ResetAbilityScratchPad" method on the Ability BP. That method should be used to reset any variables back to their default state (empty arrays out, etc).
        • Able Targeting Locations are now Runtime bindable and exposed to Blueprints.
        • New Filter (Targeting / Collision) - Line of Sight, checks for any blocking collision between the source and target and filters out the target if something is in the way.
        • You can "Lock" tasks on the Timeline now. Locked Tasks cannot be dragged around.
        • There is a new BP method on the Ability - "GetSkeletalMeshComponentForActor". This method is called by the Play Animation Task to allow users to pick, at runtime, which Skeletal Mesh component to execute the animation call on. By default, Able uses the previous behavior of just calling the animation call on all skeletal meshes a character may have.
        • 120 FPS Tick mode is now allowed in the Timeline.
        • Lots of internal changes to reduce/reuse UObject use. The end result is Able is even lighter and faster now.
        • Added PS5 / XSX as valid platforms. - EDIT: Not yet, those platforms aren't in 4.26 yet.
        • When Looping, the Ability will re-perform the "IsDisabled" check on Tasks to see if the user wants to change which Tasks are executing each iteration.

        Major API Changes:
        • UAblAbilityInstance is now FAblAbilityInstance (and no longer a UObject).
        • 4.26 support (which required changes to Animation, Queries, and a handful of other systems).
        • CreateScratchPad deprecated in C++ and BP.

        Bug Fixes:
        • Fixed an issue where HasAllTag on the Ability was using "HasAny" internally.
        • Fixed an issue where the Depedencies could be out of date when using a Custom Task and not rebuilt.
        • Fixed a crash when trying to set a Material Parameter on an invalid material.
        • Added verification checks to make sure that remote clients are playing the Server Abilities even if they haven't received an update (for example, playing the same Ability back to back instantly (e.g., same frame) - which replication sees as a non-delta).
        Last edited by ExtraLifeMatt; 12-04-2020, 12:22 PM. Reason: EDIT: Few note tweaks
        Able Ability System - A high performance, robust ability system for UE4. Now Available!

        Comment


          Originally posted by ExtraLifeMatt View Post
          Able 3.50 being submitted later today, notes below:
          • There is a new BP method on the Ability - "GetSkeletalMeshComponentForActor". This method is called by the Play Animation Task to allow users to pick, at runtime, which Skeletal Mesh component to execute the animation call on. By default, Able uses the previous behavior of just calling the animation call on all skeletal meshes a character may have.
          Matt, you are magnificent. Thank you.
          @thereisnoscotty
          Grand Marshal of the Parade of Madfellows

          Comment


            Originally posted by soctty View Post

            Matt, you are magnificent. Thank you.
            Good idea is a good idea. Thanks for suggesting it.
            Able Ability System - A high performance, robust ability system for UE4. Now Available!

            Comment


              So I recently got the system and I have been trying to figure out the ins and outs of the system ever since.
              I got stuck on many simple things and for the most part your tutorials helped me figure out what I was either doing wrong or how to approach a problem. So that was cool and helpful.

              But I have still some things that I am trying to figure out how to do at all, and several things that I have figured out how to do, but I am unsure if they would be considered best practice.

              Anyway, enough of preamble, I really really like the system and hope it can achieve all I am looking for it to accomplish, so let us get down to the heart of the matter.

              #1: I guess is maybe a bug;
              If I had an animation to play that I wanted to loop. It would work fine if the animation was shorter than 1.0 seconds, since that is the default length of the loop property. But, something that took me some trial and error to find out was that, if you have animation longer than 1.0 seconds both the loop length and ability length needed to be equal to or greater than the animation length for it to loop. Otherwise it would not loop and I assume because the animation would start, but would never signal that it was complete, thus not allowing it to start again. If the loop length and ability length was exactly the same length as the animation, it would still not loop in some cases. I think this was due to possible rounding error of the animation length. So increasing the loop length and ability length by 0.01 would allow it to loop again. Maybe this is just my lack of understanding, but maybe it is something that needed fixing.

              #2: An issue I could not find a solution for;
              I would like to have something like an ability going with an animation, and allow it to be cancelled out in the start or in the end of the ability - before committing to the ability and after it had done it's "thing". Sort of an abort window in the start for a certain period, in case you quickly decided to do something else, like a dodge away. Let us say for the sake of example the first 0.5 seconds. Also, in the end of the ability, the animation could also be cancelled, sort of like if the damage had been dealt and now you could, if you wanted, shorten the last bit of the animation by cancelling it out.

              In both these cases (the start and end of the ability), I would like to react to something less specific than a bunch of inputs but rather something generic, like "any key", so if the player controller either moved or used an input that would start another ability, regardless of which input that was. So a "cancel on any key".

              I tried channeling in the ability settings, but could not get it to work well, and required a lot of specific inputs to look for, and even with this approach I could not figure out how to cancel on moving.
              I tried a condition check, but couldn't figure out a good way to check for generic input that would not be confused with that initial input that started the ability in question.

              Any help on this issue would be appreciated.

              #3: It would be cool to have a tutorial that is a bit more complex;
              To understand what is the best practices, flows and ways to communicate with several abilities interacting. For example:
              -1 Pawn 1 does ability A, an axe swing. Ability A scans for targets. One of the targets, Pawn 2, is using another ability that interupts swings. Have pawn 1 cancel ability A, transition into ability B, some form of ability showing the pawn being stunned. Have pawn 2 react that it successfully interupted an ability, by playing some particle effect and sound effect in the location where pawn 1 detected a hit on pawn 2 with ability A.

              I hope you get what I am getting at, some communcating between pawns and having things be affected and changed based on different bit of information back and forth. A best practice of those scenarios would be really awesome.

              #4: Just thought of another thing as well, an issue I ran into,
              In one of your tutorials you show how to extend calculating damage based on for example the armor type of the target. That is fine and all, but I tried to put this kind of logic more easily accessable in a blueprint function library, so that this logic would not have to be copy pasted into every ability that was going to determine damage the same way. But it seems function libraries are off limits to be called from inside the ability, atleast in the determine damage methods. I would really like to know why and how to better solve this situation so that I could alter a damage calculation in one place rather than ten different abilities.

              Comment


                Originally posted by ExtraLifeMatt View Post

                I can look at that. It may have to wait till the 4.26 support patch, but we'll see. I already have one update pending so that needs to clear.
                Great update! And I want to know does this feature supported? Feature: My one ability is looping, and I found this ability's task's Disable just only check at first loop, but I need to check every loop, in order to Enable/Disable some task at runtime. btw, my ability is activity ability not passive.

                Comment


                  Originally posted by MichaelLiew View Post

                  Great update! And I want to know does this feature supported? Feature: My one ability is looping, and I found this ability's task's Disable just only check at first loop, but I need to check every loop, in order to Enable/Disable some task at runtime. btw, my ability is activity ability not passive.
                  Yea, it's in there. Just missed it on the notes.
                  Able Ability System - A high performance, robust ability system for UE4. Now Available!

                  Comment


                    Originally posted by Incom View Post
                    So I recently got the system and I have been trying to figure out the ins and outs of the system ever since.
                    I got stuck on many simple things and for the most part your tutorials helped me figure out what I was either doing wrong or how to approach a problem. So that was cool and helpful.

                    But I have still some things that I am trying to figure out how to do at all, and several things that I have figured out how to do, but I am unsure if they would be considered best practice.

                    Anyway, enough of preamble, I really really like the system and hope it can achieve all I am looking for it to accomplish, so let us get down to the heart of the matter.

                    #1: I guess is maybe a bug;
                    If I had an animation to play that I wanted to loop. It would work fine if the animation was shorter than 1.0 seconds, since that is the default length of the loop property. But, something that took me some trial and error to find out was that, if you have animation longer than 1.0 seconds both the loop length and ability length needed to be equal to or greater than the animation length for it to loop. Otherwise it would not loop and I assume because the animation would start, but would never signal that it was complete, thus not allowing it to start again. If the loop length and ability length was exactly the same length as the animation, it would still not loop in some cases. I think this was due to possible rounding error of the animation length. So increasing the loop length and ability length by 0.01 would allow it to loop again. Maybe this is just my lack of understanding, but maybe it is something that needed fixing.

                    #2: An issue I could not find a solution for;
                    I would like to have something like an ability going with an animation, and allow it to be cancelled out in the start or in the end of the ability - before committing to the ability and after it had done it's "thing". Sort of an abort window in the start for a certain period, in case you quickly decided to do something else, like a dodge away. Let us say for the sake of example the first 0.5 seconds. Also, in the end of the ability, the animation could also be cancelled, sort of like if the damage had been dealt and now you could, if you wanted, shorten the last bit of the animation by cancelling it out.

                    In both these cases (the start and end of the ability), I would like to react to something less specific than a bunch of inputs but rather something generic, like "any key", so if the player controller either moved or used an input that would start another ability, regardless of which input that was. So a "cancel on any key".

                    I tried channeling in the ability settings, but could not get it to work well, and required a lot of specific inputs to look for, and even with this approach I could not figure out how to cancel on moving.
                    I tried a condition check, but couldn't figure out a good way to check for generic input that would not be confused with that initial input that started the ability in question.

                    Any help on this issue would be appreciated.

                    #3: It would be cool to have a tutorial that is a bit more complex;
                    To understand what is the best practices, flows and ways to communicate with several abilities interacting. For example:
                    -1 Pawn 1 does ability A, an axe swing. Ability A scans for targets. One of the targets, Pawn 2, is using another ability that interupts swings. Have pawn 1 cancel ability A, transition into ability B, some form of ability showing the pawn being stunned. Have pawn 2 react that it successfully interupted an ability, by playing some particle effect and sound effect in the location where pawn 1 detected a hit on pawn 2 with ability A.

                    I hope you get what I am getting at, some communcating between pawns and having things be affected and changed based on different bit of information back and forth. A best practice of those scenarios would be really awesome.

                    #4: Just thought of another thing as well, an issue I ran into,
                    In one of your tutorials you show how to extend calculating damage based on for example the armor type of the target. That is fine and all, but I tried to put this kind of logic more easily accessable in a blueprint function library, so that this logic would not have to be copy pasted into every ability that was going to determine damage the same way. But it seems function libraries are off limits to be called from inside the ability, atleast in the determine damage methods. I would really like to know why and how to better solve this situation so that I could alter a damage calculation in one place rather than ten different abilities.
                    #1 Sounds like maybe you have Animation Interrupt on Stop enabled? Or you are using some Animation Mode (Single Instance) that is causing Able to reset your Animation Mode back to whatever it previously was when the Ability started after the Task ends. I highly suggest you check out the Ability Animation Node mode for Able as that won't reset your instance, dynamic montages should be fine as well.

                    #2 You can put branches in your first 0.5 seconds of your Ability if you know what they are trying to branch to (either hardcoded or return the expected Branch ability in Blueprints). Otherwise I'd just interrupt the current Ability in progress, no reason why not.

                    #3 In your example you could just do what you mentioned, Pawn 2 cancels the Ability of Pawn 1. Pawn 1 can override the "On Ability Interrupted" in the Ability A to play some new Ability that transitions to the stumble / stun Ability. I've been trying to think of some new tutorials lately (a bunch of stars have to align - e.g., I have to make all the assets to I can distribute the example, etc), so it's definitely on my mind to add a few more examples.

                    #4 You should be able to use Blueprint Function Libraries with the callbacks. Not sure why you wouldn't be able to. Maybe you had the Context Sensitive option checked? I'll try that locally and see what I find.
                    Able Ability System - A high performance, robust ability system for UE4. Now Available!

                    Comment


                      Updated was submitted this morning. Took me a bit do the integrate as I had to touch every file to update the copyright info (and 4.24 is a nightmare to maintain due to it being before the UProperty -> FProperty mass change). As always, let me know if you run into any issues once it goes live.
                      Able Ability System - A high performance, robust ability system for UE4. Now Available!

                      Comment


                        Thanks a lot for taking the time to help. I will try to recreate what I can to more clearly explain the troubles I have run into. Let me start with the 4:th point.

                        Originally posted by ExtraLifeMatt View Post
                        #4 You should be able to use Blueprint Function Libraries with the callbacks. Not sure why you wouldn't be able to. Maybe you had the Context Sensitive option checked? I'll try that locally and see what I find.
                        So to show what I have done I made this picture of what I experienced.
                        https://ibb.co/6N7rLmy

                        Top part of the image is a blueprint function library and I made a simple pure function without any logic in it.
                        Left part is an ability damage calculation where I try to call this function, and it does not show up.
                        Right part is a character blueprint in the event graph where I try to do the same and it shows up like expected.

                        I assume I have done something fundamentally erroneous.
                        Last edited by Incom; 12-04-2020, 01:56 PM.

                        Comment


                          Originally posted by ExtraLifeMatt View Post

                          #1 Sounds like maybe you have Animation Interrupt on Stop enabled? Or you are using some Animation Mode (Single Instance) that is causing Able to reset your Animation Mode back to whatever it previously was when the Ability started after the Task ends. I highly suggest you check out the Ability Animation Node mode for Able as that won't reset your instance, dynamic montages should be fine as well.
                          Ok so I recorded a recreation of what I experienced to show what is happening. I am sorry for the poor video quality, I just threw together the recording to show the issue.
                          I will explain some of the things going on.

                          I add a play animation task and add a montage. I hover over the animation length shown in hte middle (it says 2.03 seconds, but the quality is a bit poor).
                          I uncheck stop on interupt (that you suggested might be the issue), I change to dynamic montage.
                          I copy the ability length to the loop end time (length is 2.033333 despite animation showing as 2.03 in the main window, I assume because of two decimal rounding). I play the ability again to show it not loop.
                          I change ability length to 2.05 as well as loop end to 2.05. I play again and the ability loops.

                          Video link: https://youtu.be/b5DL0O-Vu5o

                          I hope that makes it clear.

                          Comment


                            Originally posted by Incom View Post

                            Ok so I recorded a recreation of what I experienced to show what is happening. I am sorry for the poor video quality, I just threw together the recording to show the issue.
                            I will explain some of the things going on.

                            I add a play animation task and add a montage. I hover over the animation length shown in hte middle (it says 2.03 seconds, but the quality is a bit poor).
                            I uncheck stop on interupt (that you suggested might be the issue), I change to dynamic montage.
                            I copy the ability length to the loop end time (length is 2.033333 despite animation showing as 2.03 in the main window, I assume because of two decimal rounding). I play the ability again to show it not loop.
                            I change ability length to 2.05 as well as loop end to 2.05. I play again and the ability loops.

                            Video link: https://youtu.be/b5DL0O-Vu5o

                            I hope that makes it clear.
                            Huh, weird. Likely the loop time is so close to the actual ability time that when it goes to loop it's filtering out the Animation Task when figuring out what to loop (it removes any Tasks that aren't within that Loop Start / Loop End times). At least that's my wild guess. I'll look at it once the pending update is out in the wild.
                            Able Ability System - A high performance, robust ability system for UE4. Now Available!

                            Comment


                              Originally posted by ExtraLifeMatt View Post

                              #2 You can put branches in your first 0.5 seconds of your Ability if you know what they are trying to branch to (either hardcoded or return the expected Branch ability in Blueprints). Otherwise I'd just interrupt the current Ability in progress, no reason why not.
                              So let us say that I want to be able to cancel the active ability playing by moving in any direction according to axis mappings. Then I would put the logic outside of the ability itself instead of inside the ability, where the axis mappings are handled?
                              I have tried different things but to no avail can I get an ability to cancel out, from inside the ability, if "any key", either a different ability or movement is triggered. Is my understanding correct?

                              While going throug the documentation to make sure I did not miss anything, I noticed that the task "Branch" variable "Identifier" under "Dynamic properties" is not mentioned in the documentation. I am having trouble seeing how and where I can access this identifier. It does not seem to available in context or branching ability data in the "CanBranchTo" function. Would you mind pointing me in the right direction?

                              Lastly, could you look at the picture in the link that I posted in comment #1631 and tell me what I am doing wrong when trying to access a blueprint function library from inside an ability?

                              Comment


                                Originally posted by Incom View Post

                                So let us say that I want to be able to cancel the active ability playing by moving in any direction according to axis mappings. Then I would put the logic outside of the ability itself instead of inside the ability, where the axis mappings are handled?
                                I have tried different things but to no avail can I get an ability to cancel out, from inside the ability, if "any key", either a different ability or movement is triggered. Is my understanding correct?

                                While going throug the documentation to make sure I did not miss anything, I noticed that the task "Branch" variable "Identifier" under "Dynamic properties" is not mentioned in the documentation. I am having trouble seeing how and where I can access this identifier. It does not seem to available in context or branching ability data in the "CanBranchTo" function. Would you mind pointing me in the right direction?

                                Lastly, could you look at the picture in the link that I posted in comment #1631 and tell me what I am doing wrong when trying to access a blueprint function library from inside an ability?

                                Yes, you would want to put that in your character somewhere. In theory you could put it in the Ability Task Tick - but that's a bit heavy IMO. I would just make a gameplay tag called, "AbilityCancelOnMovement" and when your Ability plays, add that tag to the character. In the Character's Tick (which has to run anyway) - check if the Player is playing an Ability, and if that Ability has that tag - if so and the player is moving, simply cancel the Ability.

                                I go into that in the latest video a bit. https://www.youtube.com/watch?v=fOJ0WR9B75E Those are "Dynamic Bindings" which allow you to swap the value of that field at runtime. They're called automatically by Able under the hood. In theory, since their just BP functions, you could call them - but only by the Ability's own blueprint, not by anyone else.

                                With regard to the Blueprint Library, I can't really say. I haven't had a lot of time to dig into it yet. If you open up the Ability Blueprint and just filter methods by "library" - you'll see quite a few methods (I get Oculus and a few other VR items). Looks like a normal Blueprint function library under the hood, BlueprintPure / BlueprintCallable both seem to work. You might want to make sure you setup a proper category so you can find things directly "MyFunctionLibrary|MyFunction". But, that's all I can offer at the moment. I can look once this update is out and my plate thins a bit.
                                Able Ability System - A high performance, robust ability system for UE4. Now Available!

                                Comment

                                Working...
                                X