I'd like to point out that science could easily win the ground battle as well. The most useful thing about firearms is that they require almost no training to be used, and you don't have to stand in intimidating and pretty lines to use them. An army of horse-backed mounted swordsman would just get creamed about a hundred or two hundred yards away. there goes about 5 years of training, and if you want more, another 5 years are going to have to be spent training them.
You can't pull the gods, cause they have their own set up and could side with sci-fi if they feel they have the stronger chance of victory. Quite a few fantasy gods don't like humanity cause they created them, they like them because they are the strongest guys on the planet who still worship them. But it would still be interesting, because if the gods do side with fantasy, it would be a very close match, until the commander goes "oh well I've had my fun. Biological, nuclear and all sorts of other nasty bombs ftw!" and then drops them hard on the planet.