GLOBAL_GET is an expensive operation which should not be used each frame / tick.
This PR adds macros which do a cheaper revision check, and only call the expensive GLOBAL_GET when project settings have changed.
Co-authored-by: Lukas Tenbrink <lukas.tenbrink@gmail.com>
Instantiating a new ProjectSettings is *not* the way to go.
ConfigFile works just fine to read/change a single value.
Fixes memory leaks as the instantiated ProjectSettings was never freed.
Forbid doing this to prevent such problems.
Fixes#25661.
- akien-mga
9a340a2868