Why don't you talk to one of the Finance and Insurance guys at your local BMW dealership (not the sales guys) to see if they would be willing to do a dealer pass through sale.
Basically, it's like the dealership is selling you the car even tho they don't own the car yet... and your friend is giving them an instant buyer (you). The benefit for the dealership is they can sell you additional products and sell you the "CPO" warranty/CPO inspection (1 hour labor) if you want it and any CPO deals they have going on (Those are all profit for the dealership). You could also buy the Wheel and tire warranty as well if it has the stock RFT's. Everyone wins, plus if your friend is getting a replacement car at the same time... then he can save on the taxes for the purchase price of another car.