Well, I've picked up this script again, and am in the process of a total overhaul. I've completely changed the mathematical model behind it, and now the script compensates just great for changes in elevation between the shooter and target.
I still have a lot of work to do to make this into a usable product, but for now I figured I'd post a little test mission of what I have so far. Play the mission, and click on the map to make the grenadier shoot at that position. Some debug hints will pop up telling you things like distance to target, etc, but just ignore them. Anyway, as long as the location you clicked on can be targetted by the script (roughly 300m range, but depends on elevation differences), the grenadier will shoot a grenade pretty darn close to it. The script will teleport you and a jeep to that location, so you can see where he is supposed to hit.
Like I said, this is still a total work-in-progress, but I'm starting to lose steam when I've already done so much, so hopefully this will get me motivated again. A usable version will hopefully be released in 2 weeks or less *crosses fingers*.