A motion making any of these defenses shall be made before pleading if a further pleading is permitted. No defense or objection is waived by being joined with one or more other defenses or objections in a responsive pleading or motion. If a pleading sets forth a claim for relief to which the adverse party is not required to serve a responsive pleading, the adverse party may assert at the trial any defense in law or fact to that claim for relief. If, on a motion asserting the defense numbered 6 of this subsection to dismiss for failure of the pleading to state a claim upon which relief can be granted, matters outside the pleading are presented to and not excluded by the court, the motion shall be treated as one for summary judgment and all parties shall be given reasonable opportunity to present all material made pertinent to the motion by the rules for summary judgment. A motion to dismiss for failure to state a claim upon which relief can be granted shall separately state each omission or defect in the petition, and a motion that does not specify such defects or omissions shall be denied without a hearing and the defendant shall answer within twenty (20) days after notice of the court's action.
Okla. Stat. tit. 12, § 2012