If your civilians are all in the same group, give the group a waypoint right next to the entrance of the church. In the activation field of that waypoint, put the following:
Code:
nul = [group this,nearestBuilding this] execVM "enterBuilding.sqf"
Now create a script file in your mission directory called "enterBuilding.sqf". Use the following code for the script:
Code:
_unitArray = units (_this select 0);
_building = _this select 1;
_indices = 0;
// find out how many building positions are available
while {str (_building buildingPos _indices) != "[0,0,0]"} do
{
_indices = _indices + 1;
};
// if no interior positions were found, simply move everyone to the structure
if (_indices == 0) exitWith {{_x doMove (position _building)} forEach _unitArray};
_i = _indices;
// move units into as many unique buildings positions as possible. overlap after that
{
_x doMove (_building buildingPos _i);
_i = _i - 1;
if (_i < 0) then {_i = _indices};
// have units stop after arriving at proper location, unless group leader, as he stops anyway
if (_x != leader group _x) then {_x spawn {waitUntil {unitReady _this};doStop _this}};
// delay to avoid AI clusterfucking
sleep 1;
} forEach _unitArray;
I haven't really tested that, but it should work.