I've been working on a much more primitive magma machine gun, with just rollers, making up for it with much larger floor plan and a massive power plant. I still don't really understand impulse ramps yet myself, but maybe one of these days I should give them a try. It's a bit off topic for machine guns "that don't jam" because jamming has been a consistent problem that has taken me several revisions to address, and it's probably not 100% fixed yet. But, I have video of the thing killing mobs so I wanted to share!
My design just circulates a huge number of mine carts through a pool of magma, down a 20-z level ramp, and crash them into a fortification above a pit that has a recovery mechanism at the bottom. The carts have to pass through the magma on low speed rollers so they can fill, which limits the cycle time to 28, but I make up for it with triple barrels.
The loading and security aspects took me a while to work out. The loading mechanism is basically a roller, with multiple cart routes that push onto it from the side. From the roller, they drop down into the same waiting area as carts returned by the return mechanism. While they're down there, they're unreachable by the dwarfs, which is handy so they don't try to reload the cart route. On the hauling screen, the "loaded" carts (not necessarily with magma...just the ones loaded into the system) have a red X next to them which is critical to differentiate them. If I get tired of scrolling past the red Xs, I can d-b-f forbid all the loaded carts so they disappear from the hauling screen. Or I can do that if I need to unforbid the hatch to do work down there (for example, there was a loading accident, sadly). It's still a chore to get all 300 carts loaded into the system, though. Doesn't seem like I need all of them, though.
On the left you can see my attempt to deposit the carts evenly among the barrels, but it doesn't work very reliably yet. The orthoclase rollers push the cart towards the pit at the top (where they fall down onto rollers), and the microcline rollers push the carts sideways as they go. The pressure plates turn the microcline rollers on and off so that the carts end up either going straight, left, or right. But I still am having a problem where one of the microcline rollers gets powered from an orthoclase roller and doesn't shut off via the gear mechanism. There's probably a design that avoids that problem, but I haven't found it yet. It would be cool if we could link rollers directly to pressure plates. Note that replacing the roller on the same Y row as the microcline roller with an axle would help, but then minecarts get stuck on top of the axle. One of the rollers is working at least so the gun still functions.
The one problem with this design as in the video is that trolls decide to destroy the iron grates on the right side where the gun doesn't hit. There's nothing down there for them but firey death: a pool of magma with a drain to the edge of the map. But since I took the video, I replaced those grates with constructed floors. But, I made a few too many into floors since the chamber got blocked with magma the last time I used it. So this is still a work in progress. I also built a wall in front of the fortifications at this level, because things were getting stuck inside them (there's no way to un-carve fortifications on a map edge, right?).
Anyway, without further ado:
https://i.imgur.com/RfZjUiM.mp4