Hey Aron! This A* Asset happens to be a great life saver for me, Thanks for that! My current project is a 2D game that procedurally generates levels ahead of the player, for him to move to, The player is designed to have a Bot partner that would follow him smartly and scan areas around him, that where this great asset comes in, I then downloaded it, followed the intro video you made about setting it up and also a video by Brackeys on how to use it for 2D pathfinding, I learnt that, but I was more concerned with the procedural part of it, So I opened the procedural example, which unfortunately happens to not have a 2D example mode, but I tried to replicate the example 3D setup and appropriately switching it to the 2D way in my scene, I also made sure that all the procedural levels in my scene were spawned ahead before the grid gets there, but when I clicked play, I always get thrown this exception:
“Processing work items recursively, Please do not wait for other work items to be completed inside work items. If you think this is not caused by any of your scripts, this might be a bug.”
That is the error I get thrown every time. I tried checking what was going wrong by disabling the Procedural Grid Mover script to see if it works, of which it did but the grid was static, But I need this grid to move, I need the Procedural Pathfinding for my 2D game. Please, I need your advise on this, Thanks!
Hi
I cannot replicate this bug in version 4.2.10.
Which version of the package are you using?
Also. Please don’t create multiple identical threads.
1 Like
Hello Thanks for the reply. I’m also using 4.2.10. I’m sorry for creating another question thread, it was because no one replied my question from yesterday. I’m so sorry, I’d delete the old one.
My scene in the game is a 2d procedural scene, I don’t know what’s happening in my scene, what advice can you give me on this issue, since you say you can’t replicate it?
Do you think you could post the full stacktrace for the error?
1 Like
I would try to copy it out
Exception: Processing work items recursively. Please do not wait for other work items to be completed inside work items. If you think this is not caused by any of your scripts, this might be a bug.
Pathfinding.WorkItemProcessor.ProcessWorkItems (Boolean force) (at Assets/AstarPathfindingProject/Core/Misc/WorkItemProcessor.cs:265)
AstarPath.PerformBlockingActions (Boolean force) (at Assets/AstarPathfindingProject/Core/AstarPath.cs:881)
AstarPath.Update () (at Assets/AstarPathfindingProject/Core/AstarPath.cs:864)
Hello Aron, That’s everything. I don’t know if anything particular to 2d mode is causing this error because as I said earlier, when I disable the Procedural Grid Mover Script, it works fine in pathfinding but it’s not just procedural, I.e updating the position of the grid with respect to the target I set, I.e my AI.
Hello Aron, I’ve made a video, explaining everything so you can understand the problem. See it here https://youtu.be/jmC14JYBMBc
Hi Aron! I wanna know if you’ve acknowledged the link to the video I sent?
Hey,
I was able to reproduce this bug.
though it’s only a bug with 2D graphs.
Here is a temp solution you can apply while we wait for a fix:
In the file ProceduralGridMover.cs replace Line 245 with:
if (z >= recalculateRect.ymin && z < recalculateRect.ymax - 1) {
That made the Procedural grid mover work for me.
-Wolf
2 Likes
I’d try it as soon as I am with my computer. I really appreciate the reply, God bless you!
Hey buddy!
I just tried it now, it worked! Thanks!
1 Like
The Drone Character in my game now uses it, see the way it plays out here: https://youtu.be/NNS6PTwBTF8
1 Like
Hi
Sorry for the late reply.
It turns out the ProceduralGridMover had a bug when the grid did not have square dimensions. @ToastyStoemp got it almost right with that fix, but the actual typo was a few lines below that.
I’d guess that you will get an exception if you try to move the graph a long distance very quickly still.
Anyway. I have fixed the bug in my dev version now and the fix will be included in the next version.