What I've got now is:
function WingmanImage::OnWingmanOpen(%this, %obj, %slot)
{
%obj.playThread(2, shiftleft);
%obj.schedule(150, playThread, 2, activate);
serverPlay3D(%this.RYG_ClipOutSound,%obj.getPosition());
displayAmmo(%obj, %obj.getMountedImage(0));
%pos = %WingmanImage.getPosition();
%obj = new Explosion()
{
datablock = shellExplosion;
position = %pos;
};
}
But the shell explosion seems to be spawning at the world center rather than from the gun.