Yes fighting was prescribed for the Muslims against the pagans since they drove them from their homes and stole their property. Muslims were given the right to kill them where ever they found them except near places of worship or if they surrender you must take them to a place where they feel secure. And battle was limited to men only not women and children unlike the bible.