So instead of fixing the bug they actually replicated it into a second function. :(
It's too bad that we cannot enable proper writing of NaNs and Infs because it makes most JSON formatters emit an error on this undefined extension of the format.
The main bulk of this is the new start screen code. To make this work in Raze some more work on the startup procedure is needed.
What this does provide is support for the DOS end-of-game text screens in Duke and SW on non-Windows systems.
Since everything uses the same warning number, the old setup resulted in [[deprecated]] being silenced.
So this explicitly adds the needed #defines to silence the very noisy warning from the MSVC headers but leaves warning 4996 active otherwise.
In particlular this does:
* silence all warnings in the subprojects
* do not derive TIterator from std::iterator anymore as C++17 deprecates this.
* silence the above for RapidJSON because altering that code is not desirable.
* explicitly disable warning 4996 in some Windows files that call the deprecated (but still needed) GetVersionEx function.
* define _CRT_SECURE_NO_DEPRECATE, _CRT_SECURE_NO_WARNINGS and _CRT_NONSTDC_NO_WARNINGS through CMake to disable the CRT's deprecation and security warnings.
Currently this will print several (intended) deprecation warnings about 'updatesector' that point to code that needs to be changed but cannot yet without other refactorings being done first.
Revert "- `xs_Float.h`: Add `getint()` getter to `_xs_doubleints` struct."
Revert "- SW: When adjusting horizon in `DoPlayerDeathHoriz()`, just use integer horizon values and not Q16.16."
Revert "- Duke (RR): Clean up some unnecessary `FixedToFloat()` usage with the `fixedhoriz` `asbuildf()` method."
Revert "- `binaryangle.h`: Use `constexpr` on inline functions where it was previously not possible to do so."
Revert "- `m_fixed.h`: Use `constexpr` on inline functions where it was previously not possible to do so."
Revert "- `xs_Float.h`: Convert header to `constexpr`."
This does nor work as it violates the constexpr rules for unions. The code will error out on compilation for accessing an inactive member of a union.
* Removes situations where calling `xs_CRoundToUInt()` and other unsigned inlines would go through extra casts (`uint32_t` > `int32_t` > `uint32_t`).
* Because the native data in the `_xs_doubleints` struct is a union of a double and `uint32_t`, it makes sense to do everything unsigned and convert to `int32_t` if needed instead.
* Allow use of this library in static initialisers.
* Required re-arranging a little bit to order everything so inlines could be used without prototypes.