I have my code which looks like this:
and my BP which looks like this:
My array is coming back with a length of zero so obviously there’s a problem here. I’m guessing this is not the correct way to have a CPP class fill a BP created array of integers.
Basically, my goal is this: My BP class needs to get an array of tiles from itself to its designated ending spot. I’ll be iterating through this array to provide the AI movement for this class (As using the Unreal AI for this situation is extremely LOUSY… jerky movement and directional movement that keeps jumping around all over the place.)
Instead of this method, should I have an array defined in CPP and copy the array to one in BP after I generate the path? Would rather be able to do this the way I’m trying, though, as my functions are extremely fast and efficient and would be completely unobtrusive to normal gameplay.