Rip off the old carpet yourself, paint the subfloor. The house I bought was a stinking mess. I tore out all carpeting, everything got 2 coats of primer (walls, floors, ceilings). Can't smell any cat/dog piss or cigarette smoke anymore.
After that, call the carpet guys in. Might seem silly...