EQS Generator crash on execution of Add Generated Vector node

Hello.

I’m trying to learn how to use custom generators for EQS using example from bottom of this page(example generator):
https://docs.unrealengine.com/latest/INT/Engine/AI/EnvironmentQuerySystem/UserGuide/index.html

I recreated sample blueprint and… after couple of hours of testing I found out that crush occurs always during executing first Add Generated Vector node:

If Add Generated Vector is unplugged there is no crush.

here’s pastebin of generator(print string nodes are purely for debugging purposes)

EQS using this generator:

Map I use for testing with navmesh enabled and EQS testing pawn selected.

Folder with crash report:
[link text][4]

Question is: why is it crushing and what to change to make generator work properly?

I’m still struggling with this. But I found c++ code of this node and I think something is wrong… It looks like this function uses some global variables I don’t understand…

72566-capture.png

Working example of QES generator would be helpful, because I’m not if I messed sth up or example at epic wiki is wrong.

I found case of EQS bug

yet dropbox link is no longer available so I can’t compare if it’s similar thing or something totally different.
@MieszkoZ for the rescue?

Hello,

That bug that is related to https://answers.unrealengine.com/questions/340200/bug-crash-bug-in-eqs.html has been fixed internally and should be released in a later version. Have you seen the same issue in the 4.11 Preview?

I don’t touch any preview, yet it still occurs in 4.10. I’ll test it as soon as I can(tomorrow).

Soooooo, you are think that I didn’t messed anything up, that it’s a bug, not my fault?

Dear Sean,

So far the results on 4.11.0 preview 1 are no different, it crashes but now right before Return Node… might it be because I simply converted all project to newer version?

Well, it happens… sometimes. Like 9 out of 10 times I move my testing pawn to trigger generation of EQS. Why it is? And what is it? Stack overflow, segmentation fault or what?

Regards

I’ve been able to reproduce your crash, and have noticed that it only happens when I set the Radius variable to a value greater than 500. Try lowering the value of your Radius variable and see if that makes a difference.
I was not able to reproduce the crash in the 4.11 preview though, so could you provide the logs from your 4.11 crash?

Here you are
link text

At radius set to 100 I moved testing pawn couple of times before crash yet… it still happen. I think that’s strange that ue4 crashes at not every occurrence of test but just sometimes so I looked at task manager to see if my memory usage increases drastically on triggering EQS but it just jumps once at first successful test by around 30-50 MB and then stays at this level

I

I have not been able to reproduce the crash with a radius of less than 500. Would you mind zipping up the project, uploading it to Dropbox, and providing me with a link so that I could see what is going on in your project that is different from mine?

I appreciate your help. here it is.

I noticed that in your ToTheWall blueprint, there was a mistake. Go ahead into that blueprint and right after the Number Of Spokes reference, instead of the division node that you have, use a subtraction node as shown in the tutorial. When I made this change, I didn’t experience a crash when moving the Testing Pawn or when playing the game.

Oh, well that’s one more reason for me to kill myself :slight_smile:

But… After changing this one thing the project still crush. Still not always. Is it possible it may be hardware dependant?

Aaaaand all the results of query are at 0.0.0 coordinates…

I’ve been able to reproduce a couple of crashes in your project, but I haven’t been able to nail down the exact causes.

Have you been able to reproduce this issue in a clean project? As there are multiple crashes present, it is best to have a clean project to work in. Go ahead and set up the same EQS with no unnecessary content in the project and see if you get the same crash.

I created new empty project with no startin content in 4.11 preview 1
Placed EQS testing actor, created querry based on generator seen below and distance test.

(querying actor passed as context)
Sadly, it still crashes and EQS results are all 0.0.0

Crash report:
[link text][2]

Zipped project:
[link text][3]

I now it’s experimental feature so probably it’s not often used, but do guys from Epic use it?

I noticed that you’ve made changes to the blueprint. I would like you to create it exactly as it is shown in the documentation, that way we can begin to debug it. When you make changes to it, it is much more difficult to determine why it isn’t working as well as what is causing it to crash.

EQS is experimental, but it can definitely be used in a project. Personally, I use it in a few of my projects successfully, so this could just be an issue with a particular node or the changes that you’ve made to the blueprint, which is why I’d like you to create it as shown in the documentation.

Sorry, I misunderstood you.

So there’s project, still crashing
link text
making radius very small makes crashes less frequent but in final version I need them to be at least half the room long.

We have been able to reproduce the crash in your project, but not in one of our clean projects.

It seems in the eqstesting project that you recently sent, you used the division node instead of subtraction, which is possibly part of the problem. I was getting multiple different crashes using your project, but have still been unable to reproduce it in my own project. Could you try it one more time, but ensure that you follow the exact steps? Ensure that you’re opening up the picture of the blueprint in a new tab, so that you can zoom in as much as possible and ensure that everything is accurate.

That divide node made the query check 361 instead of 360 checks.
Except that mistake I’m sure I have everything identical to example.

Can you please confirm my thoughts:

  1. In https://docs.unrealengine.com/latest/images/Engine/AI/EnvironmentQuerySystem/UserGuide/customGenExample.jpg
    the array vectors is purely to show users “that yellow 4 squares is array of vectors” and are not used in this example

  2. In environment query using this generator the Generated Item Type should be point, because it returns… well, vectors as locations on map

  3. In Project Point to Navigation node I don’t have to provide any Nav Data input and Filter Class should be RaycastFilter_UseDefaultData and Querry Extent is how far from given location in each dimension engine will look for navmash to draw point in?

  4. Except enabling Environment Query System in Experimental Tab I don’t have to set anything in Editor/Project settings?

Can you please provide me with project with this thing working so I can have a look at it and maybe I’ll get enlighten by looking at it?

After investigating the issue further, and reaching out to the Docs team, I was able to determine that there is a change you need to make inside of the Generator blueprint. Go into your blueprint, and select the Class Defaults tab. From there, set the Generated Item Type to EnvQueryItemType_Point. This fixed the crash in the test project you provided me with.

I can confirm that crash stopped occurring and I can happily tune up my AI now, thank you very much.

73288-thanks.jpg