A common atheist tactic is to read through the Bible, find literally any violent text they can, and twist it to make God look evil and violent. A lot of these verses are, to say the least, laughable. Take, for example, Luke 19:27 "But bring here those enemies of mine, who did not want me to reign over them, and slay them before me." See? And in some Bibles, that's in red letters, so clearly Jesus wants us to kill all atheists! Right? Wrong! Verse 11 clearly tells us that this is a parable (and to make it easier, many modern Bibles even have a caption "The Parable of the 10 Minas"), so while it is Jesus talking in verse 19:27, and He genuinely did say "bring my enemies and kill them in front of me", this is a spiritual story not intended to be a command. Furthermore, in context, this is about judgement day, when Jesus returns, so even if it could be understood to mean Jesus eventually will command Christians to kill atheists, that literally won't happen until He comes back. And if you're an atheist, you don't believe He ever will, so you have to go by what the New Testament currently tells Christians to do, which is "love your enemies," "pray for those who persecute you", "if possible, as far as it depends on you, live at peace with all men" etc.
But not every atheist attempt to slander God is as wildly out of context. To be sure, they're still misreading the Bible, but in a more easily forgiven sense. In other words, yes, of course you can find places in the Bible in which God violently judges certain cultures or individuals.
However, while atheists try to frame it as God being a bully to innocent people who didn't deserve it, a look at the context reveals that God doesn't like to judge the wicked (Ezekiel 18:21-23; 33:10-11), waits a significant amount of time before carrying out those judgments (Genesis 15:16), holds off large-scale judgments for just 10 righteous people (Genesis 18:32), and of course, let's not forget that Jesus literally gave His life so that everyone can be forgiven for their sins just through faith.
With all of this in mind, it's quite clear that we're not serving an angry God. Those who received His harshest judgments certainly deserved it. Nineveh, for example, was known for its horrific war crimes. In Nahum 3:19, we read that everyone who heard of their downfall would celebrate, "For upon whom has not your wickedness passed continually?" This is not an unfounded claim. Nineveh was notoriously violent, gouging out eyes, chopping off hands, skinning people alive, impaling them on spikes, all this for the sake of plunder. What possible reason could God have for allowing this to continue not just in His world, but also against the nation through whom the Christ would be born? Surely even the most angry atheist troll should have some threshold for war crimes before they admit God was right to take action? Let's be clear: God is justified in punishing even the slightest thought of sin, but can atheists at least acknowledge that a culture so violent that the entire continent fears their oppression needs to be collared?
Nineveh was far from the only nation deserving of God's judgments, and not even the worst. Some cultures, a few of which even influenced Israel, worshiped brutal demons such as Baal and Molech, who required their followers to sacrifice children to them, and if there is one thing you don't do if you want to be treated kindly by God, it's sacrifice children. If atheists really want to object to God's judgement of such unbelievably evil human beings, that says a lot more about those atheists than it will ever say about God. I do not want to meet the man who looks at a culture that places their own babies on burning trays, then bangs drums to cover the screams as the children cook to death, and says "no, God should not have harmed them". If you meet someone who is ok with that, that is a psychopath.
Clearly, therefore, the atheist objection holds no water. Even if we set aside the simple fact that God can do whatever He sees fit, it's obvious to the studious why He saw fit to do it. The only issue left to discuss is how do we, who also deserve His wrath, deal with this? The answer, as alluded to above, is faith in Christ. He took the punishment we deserve, so we may now receive the reward He deserves. "God kills war criminals" is a silly objection to that.