Every app has access to an api that asks your phone to verify your fingerprint against the ones stored for the lockscreen. The phone then asks for your fingerprint and tells the app if it passed or not.
As the commenter pointed out, it’s not an image of your fingerprint either. It’s a hash that is stored on your phone that is likely unique to that device.
Not a “racing” game but you can race in BeamNG (and even do multi-player with a mod.) After trying it, other games feel underwhelming to me.