Looking through your script there a lot of illogical things..
This part in you script makes no sense at all:
if ("BulletBase" in _objs) then {_c = 1};
waitUntil {_c==1};
This makes the code waitUntil forever if "BulletBase" is not in the object array..
You first search the bullet with the first while/do loop, but then you apparently try to search it later again with this line.
_bullet = [_boomerang, ["BulletBase"], _boomerange];
Which by the way is wrong, it's missing the
nearestObjects command.
You have already found the bullet so why try find it again?
Besides, nearestObjects command does not find bullets, it only finds vehicle class objects (basicly everything else than most foliage and bullets).
You have typos which will make things not function (_boom
erange->_boomrange), missing variables (_boompos is not defined anywhere).
Anyway, I have tried several methods of finding bulletbase with all of the nearestObject commands and it's not possible; all the new ArmA nearestObject commands such as the above mentioned
nearestObjects [] and
nearObjects only detect vehicle class objects, not bullets.
Only the OFP era nearestObject can find bullets but it works only to 50m radius and didn't seem to work unless I use it from a fired eventhandler.
EDIT:
What I don't understand is what you're trying to achieve with this? How are you going to make the player know that the computer has found a sniper? How exactly does it find it if you search say 1000 meter area and there are several people engaged in a fire fight?
(well, these questions are moot since you can't detect bullets with the nearestObjects stuff)
If you are just trying to find snipers you can simulate the whole system by adding fired events to all enemy snipers (example given earlier) and when one those fires you can instantly get data such as snipers position ([x,y,z]) and weapon direction vector (at the moment of firing) so you can tell which sniper was aiming at who, and then point out that sniper, or something like that