Core/Misc: Fixed a bunch of issues found by static analysis
Core/Misc: Another batch of fixes for issues found by static analysis
Core/Vehicles: Fixed a crash that happened during seat changes searching for a previous free seat

Closes #9609
Merge pull request #9815 from Ascathor/master

Core: Add "GetRaceNameByID" and "GetClassNameByID" to get localized class and race string.
* Batch of fixes for issues found by static analysis.
* Another issue found by static analysis fixed.
* Some more static analysis issues fixed.
* Another small batch of fixes from static analysis tool.
Core/Build: Fixed the build
Buildsystem/MSVC: Fix a minor issue with /Zm heap allocation parameters not being used 32-bit environment
Reverted part of 8be181c7e60daf9833044da61b379c2136892c37 that was not supposed to be pushed