Chaining an ending sound to looping sound?

I have a repeating sound for a gun that loops while firing. I would like to concatenate an ending sound onto the end of the loop to complete the firing sequence. So what I need is to tell the looping sound to stop looping, and then have the finishing sound seamlessly played at the end of the loop. Is there a way to do this?