> The specific example I was thinking of was racing games that use real cars (Forza, Gran Turismo, etc.). Do those companies get paid to feature real cars or do they have to pay to use them?
I'm not sure, but I imagine so.
What gets complicated is how the cars are depicted in the games. I've heard stories of racing simulators which couldn't use realistic damage models because the licensors for their cars wouldn't approve of having their cars depicted in a damaged state. I can imagine there might be issues with having some models of cars modelled as having worse performance than their competitors (slower, worse handling, etc) as well.
It's not as though this is unique to video games, though. A company that's paying to have their car appear in a movie might stipulate that it not appear in situations involving it breaking down or crashing, for instance.