- allow treatment as one-character string constants as character constants. This became necessary because name constants already use single quotes and are much harder to repurpose due to a higher degree of ambiguity.
- fixed: protected methods in structs were not usable.
It looks like the memory management at use here is not capable of maintaining multiple instances simultaneously and the camera textures create another scene drawer so the initialization of the main scene drawer has to be delayed until after the camera textures are done.
- replaced TStaticArray with regular TArrays.
They had incomplete implementations preventing proper cleanup of the level loading code. It makes more sense to add the missing methods to the regular TArray and use that.
This also makes some changes to how the game nodes are used to avoid creating a copy: If the head node's pointer is stored in a separate variable, no code needs to check which of the two arrays gets used.
src/p_glnodes.cpp:670:3: error: cannot jump from this goto statement to its label
src/p_glnodes.cpp:682:4: error: cannot jump from this goto statement to its label
- consolidated the code to calculate a sprite's display angle for all 3 renderers.
As it turned out, they all differed in their feature support because they had always been updated independently by different people.
The values were still 8 and 32 respectively which applied to hardware from last decade, but for modern mods these are simply too low. New values are 64 as minimum and 128 as default.
- added script access to a sector's colormap and specialcolors fields. (Writing only through dedicated functions because these fields are render state which may need to trigger some form of refresh if the renderer changes.)
With no 3D floors this appears to be ok, but there are so many places where colormaps are being set in the software renderer that I cannot guarantee that I got all of them correct. This will need some testing.
- moved testcolor and test fades into SWRenderer files.
These CCMDs work by hacking the default colormap and were never implemented for hardware rendering because they require many checks throughout the code.
This has increasingly become an obstacle with the hardware renderer, so now the values are being stored as plain data in the sector, with the software renderer getting the actual color tables when needed. While this is a bit slower than storing the pregenerated colormap, in realistic situations the added time is mostly negligible in the microseconds range.