Comrades in Arms Discussion Board

Full Version: SetPosATL Multiple Units without collisions
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Okay so I was doing some quick prototyping to prepare for future updates for Home Unlimited (I'm still busy with school, but I was taking a break awaiting some post replies for my other assignments, was busy chewing on some food so I wasn't asleep yet).


Anyways, I figure I can probably randomly spawn a marker somewhere, use that to find nearestBuilding, then BIS_fnc_buildingPositions and I can spawn players in any random building without manual slave labor of selecting every single building and placing an object. The problem is, once I pick that object and spawn players there, everyone will be stacked on top of each other.


I'm wondering how do I take into account for that and spawn players near each other without stacking.
Even if you'd solve stacking, there's only so much space in a room. I'd try searching for four buildings close to each other and have each team setpos'd in their own house.
I wonder what to do when the building is isolated in the middle of nowhere then :o
Leave it as it is or setpos players outside/near the building then?
Put them in a line, with a small pitch an hope it fits in one room?
I guess I'll test and see how it goes. I'll get around to that once my assignment deadlines stop pouring in...
Poisson Disc - https://www.jasondavies.com/poisson-disc/

Implementation in C++ - https://github.com/corporateshark/poisso...-generator
(Should be transferable to SQF)