Press RMB over enemy creature in battle to make current stack to shoot at destination stack. Anyway, this is not full "Distant retaliation" implementation.
It's not full distant retaliation script. The full variant will lack AI, will need to check for Ammo to retaliate, some creature attack with magic, so they should retaliate magically, etc.