Announcement

Collapse
No announcement yet.

Able Ability System Info and Support Thread

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

    Oh, I understand now. Thanks for clarifications!

    Comment



      Hi there Matt, thanks for the plugin. I got it during the sale, and have been enjoying using it so far. I've run into one repeating issue - it's kind of a two-parter, so bare with me. When I create a custom task, add it to an ability, and attempt to use that ability, the editor crashes with this log:

      Fatal error: [File:/Build/++UE4/Sync/Engine/Source/Runtime/CoreUObject/Private/Templates/Casts.cpp] [Line: 10] Cast of nullptr to AblAbilityTaskScratchPad failed

       
      Spoiler


      After this, oddly enough, the task will work fine during gameplay. Ordinarily I'd just move on, except after that initial crash, any time I compile an edit to the custom task while it's added to an ability, I get a crash with this log:


      Assertion failed: bCustomPropertyListForPostConstructionInitialized [File:/Build/++UE4/Sync/Engine/Source/Runtime/Engine/Private/BlueprintGeneratedClass.cpp] [Line: 618]

       
      Spoiler


      As you may imagine, removing my custom ability from every ability I have an instance on and then adding it back after just to compile an edit is a bit much. I must be missing something. I re-created this consistently with the example custom task you made in the documentation, following all the correct procedures for the custom scratch pad. Thanks in advance for your help.
      Last edited by Its-Alf; 03-05-2020, 11:39 PM.

      Comment


        Originally posted by OneSaltyBoi View Post
        Hi there Matt, thanks for the plugin. I got it during the sale, and have been enjoying using it so far. I've run into one repeating issue - it's kind of a two-parter, so bare with me. When I create a custom task, add it to an ability, and attempt to use that ability, the editor crashes with this log:

        Fatal error: [File:/Build/++UE4/Sync/Engine/Source/Runtime/CoreUObject/Private/Templates/Casts.cpp] [Line: 10] Cast of nullptr to AblAbilityTaskScratchPad failed

        After this, oddly enough, the task will work fine during gameplay. Ordinarily I'd just move on, except after that initial crash, any time I compile an edit to the custom task while it's added to an ability, I get a crash with this log: [/FONT]

        Assertion failed: bCustomPropertyListForPostConstructionInitialized [File:/Build/++UE4/Sync/Engine/Source/Runtime/Engine/Private/BlueprintGeneratedClass.cpp] [Line: 618]

        As you may imagine, removing my custom ability from every ability I have an instance on and then adding it back after just to compile an edit is a bit much. I must be missing something. I re-created this consistently with the example custom task you made in the documentation, following all the correct procedures for the custom scratch pad. Thanks in advance for your help.[/FONT]
        Hey there Salty,

        For the 1st error, it's complaining that you don't have the CreateScratchPad Blueprint method overloaded. It expects some scratchpad, you can just create a simple UAblAbilityTaskScratchPad object and return that. Admittedly that should probably just be a warning since your task may not need a scratchpad.

        For the 2nd error, that one is a bit more confusing. So Able is trying to replace the old custom task with your newly compiled one (so you don't have to replace all your Ability tasks manually), but the BP compiler is saying it didn't finish initializing the properties yet. Maybe because of the crash in the 1st error? I'd try and fix that and see if it improves things, otherwise see if you can get me a full callstack for that 2nd error - the one you posted doesn't have where it failed in the UObject creation.
        Able Ability System - A high performance, robust ability system for UE4. Now Available!

        Comment


          Originally posted by ExtraLifeMatt View Post

          Hey there Salty,

          For the 1st error, it's complaining that you don't have the CreateScratchPad Blueprint method overloaded. It expects some scratchpad, you can just create a simple UAblAbilityTaskScratchPad object and return that. Admittedly that should probably just be a warning since your task may not need a scratchpad.

          For the 2nd error, that one is a bit more confusing. So Able is trying to replace the old custom task with your newly compiled one (so you don't have to replace all your Ability tasks manually), but the BP compiler is saying it didn't finish initializing the properties yet. Maybe because of the crash in the 1st error? I'd try and fix that and see if it improves things, otherwise see if you can get me a full callstack for that 2nd error - the one you posted doesn't have where it failed in the UObject creation.
          Hi Matt, thanks for the response. I went back in and attempted to create a custom task again, as well as recreate the second error (which I succeeded in doing).

          As for the first error, I certainly have an AbleCore.AblCustomScratchPad that I made, hooked up in the overriden function CreateScratchPadBP. I assume that is fine since it's a child of UAblAbilityTaskScratchPad?

          See below:

           
          Spoiler


          The task is named "Launch Character", but all that's in it at the moment is a print string hooked up to a GetDisplayName on a ForEach target actor from the context. It seems the first crash only occurs when I have some literal info or variable being used that doesn't come from the scratch pad, which makes sense. So in a slight tangent (this is a bit of a moot point at the moment), how do I set instance-specific variables for the scratch pad? My end-goal is to have a LaunchCharacter task that I can put in an ability and adjust exposed variables in the Able editor, so I can create double-jumps and dashes that make use of Able. I could simply use root motion, but that's only really effective for horizontal movement, and I couldn't figure out the JumpTo task, though I assume that's because it's in an experimental state.

          Here is the full callstack for the second error (or at least, I believe this is what you are looking for. I don't often do debugging of this nature):

           
          Spoiler
          Last edited by Its-Alf; 03-07-2020, 02:01 PM.

          Comment


            ExtraLifeMatt Wanted to report a couple of issues. First, it looks like BTTask_PlayAbility & BTTask_StopAbility don't implement void InitializeFromAsset, so they never resolve the AbilityKey.
            Second, I'm seeing some weird stuff with the cone target requirement. This is what I see:
            Click image for larger version  Name:	20200307_132402.gif Views:	0 Size:	416.3 KB ID:	1730093

            If I put the player in the cone that shows up in front, the ability misses, but if he is to the left of the AI, then it hits. Here are my settings, which are pretty simple:
            Click image for larger version  Name:	settings.png Views:	0 Size:	39.1 KB ID:	1730095

            It seems like maybe the Query Forward is off.

            One final thing is that, at least the cone check, will add actors to the target list multiple times. Perhaps use AddUnique?

            Thanks


            EDIT: Interestingly, if I try this in the ability editor it works when I'm standing in the cone. I get a different value for QueryToTargetDotProduct in that case though. Also, that one time it worked was an anomaly, so I can't get it to hit at all right now. I'll let you know if I figure it out.

            Yeah, I dunno man. I switch to a box and it works fine. Cone, not so much.
            Last edited by jimmay.10; 03-07-2020, 09:23 PM.

            Comment


              Originally posted by OneSaltyBoi View Post
              ...
              Are you able to send me the project you're using so I can repro this locally and debug the crash? You can drop the files here: https://www.dropbox.com/request/nD81ewNC7G3p5MNWlMKX
              Originally posted by jimmay.10 View Post
              ...
              So it's just the debug visualization that is off? Or in-game it's off as well? I haven't touched that code recently, but I can double check things. Also I'll fix up the Tasks. Thanks for the heads up.
              Able Ability System - A high performance, robust ability system for UE4. Now Available!

              Comment


                Originally posted by ExtraLifeMatt View Post

                So it's just the debug visualization that is off? Or in-game it's off as well? I haven't touched that code recently, but I can double check things. Also I'll fix up the Tasks. Thanks for the heads up.
                It wasn't working in the game as a cone. It worked as a box mostly, but even that seemed to depend on which direction I was facing and whether it was attached to a socket and using socket rotation or just using the position/rotation of the unit. I poked around at it for quite a bit and then just went another route. My AI already has the target on the blackboard so I overrode FindTargets and get that target instead.

                Comment



                  Hello, I just started implementing able into my project, first of all I was impressed how powerful it is across the network but. Event with right setup for collision channels or objects, collisions doesn't seem to be working correctly on 4.24.3. Pretty much they do not work for me and even in your demo which is thing that needs to be fixed asap. Or is it possibly problem only on my side? Thank you for response.

                  Comment


                    Originally posted by michalss View Post
                    Hello, I just started implementing able into my project, first of all I was impressed how powerful it is across the network but. Event with right setup for collision channels or objects, collisions doesn't seem to be working correctly on 4.24.3. Pretty much they do not work for me and even in your demo which is thing that needs to be fixed asap. Or is it possibly problem only on my side? Thank you for response.
                    Collisions definitely work. Check and make sure BOTH objects are marked as "Enable Overlap Queries", if one or the other isn't - the collision is ignored. Also double check your collision layer info (Although 9 times out of 10, it's that both objects weren't marked as Enable Overlaps).

                    https://docs.unrealengine.com/en-US/...iew/index.html
                    Able Ability System - A high performance, robust ability system for UE4. Now Available!

                    Comment



                      Originally posted by ExtraLifeMatt View Post

                      Collisions definitely work. Check and make sure BOTH objects are marked as "Enable Overlap Queries", if one or the other isn't - the collision is ignored. Also double check your collision layer info (Although 9 times out of 10, it's that both objects weren't marked as Enable Overlaps).

                      https://docs.unrealengine.com/en-US/...iew/index.html
                      Well, I would not have been asking if I haven't tried that yet in all possible ways. There is a screen if my setup.

                      Click image for larger version

Name:	CQ_1.jpg
Views:	84
Size:	315.8 KB
ID:	1731000Click image for larger version

Name:	CQ_4.jpg
Views:	88
Size:	317.0 KB
ID:	1731001Click image for larger version

Name:	CQ_3.jpg
Views:	88
Size:	272.7 KB
ID:	1731002Click image for larger version

Name:	CQ_2.jpg
Views:	85
Size:	303.8 KB
ID:	1731003

                      Comment


                        Originally posted by michalss View Post

                        Well, I would not have been asking if I haven't tried that yet in all possible ways. There is a screen if my setup.
                        Ah, another user was reporting Cone/Queries were off by 90 degrees. See what happens if you turn your guy to the left or right of where the debug visualization is showing. If that's the issue, I'll get a fix in - I'm still trying to repro this locally, so having your actual parameters is a great help.
                        Able Ability System - A high performance, robust ability system for UE4. Now Available!

                        Comment


                          Originally posted by ExtraLifeMatt View Post

                          Ah, another user was reporting Cone/Queries were off by 90 degrees. See what happens if you turn your guy to the left or right of where the debug visualization is showing. If that's the issue, I'll get a fix in - I'm still trying to repro this locally, so having your actual parameters is a great help.
                          Well that doesn't work as well. I was trying to setup FOV around 360° after I saw that post. Or even using box collision with scale around 4 meters, nothing. Then I tried to remove plugin from engine and put it back once again - same result. So, if there are no issues within Queries in code, then there must be something wrong with debug visualization or Queries translation? Also, I noticed that ability editor doesn't using Relative rotation for previewed actor, is that supposed to be correct behavior?

                          Comment


                            Originally posted by michalss View Post

                            Well that doesn't work as well. I was trying to setup FOV around 360° after I saw that post. Or even using box collision with scale around 4 meters, nothing. Then I tried to remove plugin from engine and put it back once again - same result. So, if there are no issues within Queries in code, then there must be something wrong with debug visualization or Queries translation? Also, I noticed that ability editor doesn't using Relative rotation for previewed actor, is that supposed to be correct behavior?
                            Define "Relative Rotation". It you point it to a blueprint for the preview actor, it'll just instantiate that blueprint - rotation and all. If you just point it to a static/skeletal mesh, then it builds an actor on the fly so the rotation can be off. There is a rotation option in the Able Editor Settings that you can use to rotate the static mesh to point in the correct location.

                            There could be a translation issue on the query, it's happened in the past but I haven't had any reports in forever until this last week so that's why I'm a bit confused on this popping up, that code hasn't changed on my end. An easy way to test is to just setup a sphere query, put it on yourself (so no translation, rotation, etc) and just set the radius up pretty high. If that works, but then you try and translate it out a bit - then it's a translation bug, otherwise it could be a setup issue with the collision actor data.
                            Able Ability System - A high performance, robust ability system for UE4. Now Available!

                            Comment


                              Originally posted by ExtraLifeMatt View Post

                              Define "Relative Rotation". It you point it to a blueprint for the preview actor, it'll just instantiate that blueprint - rotation and all. If you just point it to a static/skeletal mesh, then it builds an actor on the fly so the rotation can be off. There is a rotation option in the Able Editor Settings that you can use to rotate the static mesh to point in the correct location.
                              Thank you, that is useful info.

                              Originally posted by ExtraLifeMatt View Post
                              An easy way to test is to just setup a sphere query, put it on yourself (so no translation, rotation, etc) and just set the radius up pretty high. If that works, but then you try and translate it out a bit - then it's a translation bug, otherwise it could be a setup issue with the collision actor data.
                              Tested out, and nothing happened :-/. So, i guess it's gonna be problem with collision actor data setup but in fact that I have correct collision query settings as you can see from screenshots?


                              Comment


                                Originally posted by michalss View Post

                                Thank you, that is useful info.



                                Tested out, and nothing happened :-/. So, i guess it's gonna be problem with collision actor data setup but in fact that I have correct collision query settings as you can see from screenshots?


                                I think I see the issue, you're using a custom layer (by using the custom preset), but have the object type set to Pawn. That task searches by Layer, not object. Try setting both objects to the Pawn Layer, or World Dynamic and see if they see each other..
                                Able Ability System - A high performance, robust ability system for UE4. Now Available!

                                Comment

                                Working...
                                X