The machines aren’t capable of thought
They aren't, but they do a damn good job at reading inputs, following a document of instructions, and using control output.
Setting a waypoint, retrieving imagery, using machine vision to identify a human is an easily wrote task.
Having Claude code write an app to run on a pc to do all that is trivial.
The other stuff is just something the military already does redily