Finally… a magic missile

Or two, as it turns out.

Magic missile is one of the most iconic Dungeons & Dragons spells. It’s the first spell every wizard learns because at first level (and all levels) it deals certain damage. It wasn’t until yesterday, however, that it was introduced to Mortal Wayfare.

Why? Honestly, I just never got around to it. The spell is a relatively complex implementation of combat casting with damage and animation. Over the years I’ve thought about how I would build it but now, with a simple prompt, Claude Code spit it out in minutes.

OK, let’s start with a Magic Missile spell. https://www.d20pfsrd.com/magic/all-spells/m/magic-missile/ is the spell. I use that website as a source for ‘core’ Pathfinder rules. The spell will also need an effect which will require an image artifact. I don’t yet have one for magic missile but it could be created. The ‘missile’ will need to travel from the source to the target. That could be a straight line but something that swerves around and did loops, like a paper airplane, would be cool. What else do you need to know to get started? I don’t know if this is a non-trivial feature but should we do this in plan mode?

For the image asset, I fed Claude Code a file with a bunch of icons and requested it grab “the blue one in the middle” and then “make the background transparent.” While Claude Code was “razzmatazzing,” I searched the web for some free audio effects. The whole process took about 15 minutes. Claude Code not only generated the spell logic correctly but implemented the curved trajectory animation without me having to debug path calculations. I’m not sure how long it would have taken me to do it myself but probably an order of magnitude longer.

For your viewing pleasure, here it is. Sound on!