Spawn actor between two other actors

Hi.

I’m wondering if there is an easy way (blueprint hopefully) way to spawn an actor in relation to some other actors?

Without going into too much detail, I have the Player starting point as one actor, and then I have randomly distributed points representing the wall in the game (without any bounds as to the distance from the player to the walls), and what I need is for content (other actors) to spawn between the player and the randomly drawn walls (spawning them outside the walls would not help much) at a random distance.

Cheers.

i don’t know if it may help… but just the very hacky way, and i just know that in the cpp realm, you know the nav mesh bound volume??? the one that you use when you wanted navigation system for AI and will make a green color if you press ‘p’??

so if iam not wrong, what you wanted to spawn actor to a position randomly as long as it not in the walls, position… and i assume you already had the walls in your level, and just wanted to spawn actor without collide with the wall.
to do that you can spawn actor normally but with the location given by UNavigationSystem::GetRandomPointInRadius(). it will get you a position that in the volume of the navmesh and also in the area that just be generated by navmesh. which is not the wall. so your point gonna be random and hopefully not on the wall position or in that respective mesh of the wall.

Yes you could also set up you own system, like creating a few “invisible” points in the level and then get a random position in between. Calculating the position is just Vector Math, in my game I do the opposite I destroy the actors in between :), here’s some link I found recently: