This is an interesting one. Reading the original question, I know for a certain fact that the answer is yes. However, I have no idea whatsoever of how to do it. Regular readers of my posts (if any) will appreciate that this summarises my scripting non-skill beautifully.
It is frequently the case that OFP code will do what you want, but is a little inelegant. In such cases it is necessary to make a judgement call as to whether you can stomach the inelegance or not. Not, of course, means abandoning the whole misssion/addon/idea.
It would seem, in this case, that your options are to
1) abandon the whole thing
2) go with GB's function (he's a good lad, it probably works)
3) invent your own better, faster, sexier, cooler function