can you hire a witness as your lawyer to exclude their testimony?
That is pure fiction and misleading. Unfortunately scenes like that contribute to keep people ignorant about the law, which then makes it easier for courts to dissimulate their recurrent miscarriage of justice.
But Purdue University v. Wartell, 5 N.E.3d 797 (2014) is an example where the Indiana courts did the right thing, and is pertinent to your question. There, Purdue University first assigned an investigator in regard to plaintiff's grievance, and thereafter the University tried to withhold information under pretext that the investigator was also its lawyer and thus that the information was protected by the privilege. Because that person hitherto had been portrayed only as an independent investigator, the Indiana courts concluded that Purdue University was estopped from invoking the attorney-client privilege (as well as the work-product doctrine).
Thus, the guy in the film or series who said to be "screwed on Kardashian" reflects pure cluelessness about how the law supposedly operates. I have not seen the plot of that film or series, but the information that the friend-lawyer obtained prior to becoming O.J.'s attorney would not be protected by the privilege because it was not obtained in preparation for O.J.'s defense.
If there were one star witness on the opposing side and they happened
to be a lawyer, could you simply pay them off by hiring them as your
lawyer?
This question is somewhat unclear to me, but I will mention that lawyers have a duty to disclose to their potential or actual client any conflict of interests. The rules of so-called "professional conduct" discourage lawyers to ignore conflict of interests in that this conflict may impair their "services".
And, as I explained previously, any information that a lawyer obtains as witness rather than as attorney in the matter is not protected by the privilege.
Thus, as for
If you committed a crime at a law-firm and everyone who witnessed it
was a lawyer, is there any rule preventing you from just hiring all of
them?
the answer is: Nothing prevents the criminal from hiring all of them, but that information is not protected.