Issue is being caused by deleting the station track without removing the station track entry in the ride struct. This will prevent the crash but this should not happen in practice.
Issue caused by switching between tabs when half way through tab animation. The frame number would not be reset until the next frame and this would cause a split second glitch when moving from a long animation tab to a short animation tab. Issue fixed by reseting the frame number when switching tabs.
The bins were incorrectly displaying their filled status on some
rotations. This was caused by two mistakes. The first mistake was only
rotating the status by 1 place when it was 2 bit the second was due to
rotating it the wrong direction. This was likely caused by the implementor
not realising that there were two 'rol' commands but due to the inverted
nature of this it would end up being two 'ror's.
Use Intel-standardized _mm_popcnt_u32 instead of Microsoft-specific
__popcnt, replace assert with openrct2_assert, replace bitcount's argument
with uint32.
In order to avoid the overhead of checking whether the function pointer
to bitcount's actual implementation has been initialised every time
bitcount is called, initialise it at application startup.
Replace the current implementation of bitcount() with a one that uses the
POPCNT instruction available in most newer CPUs. Also, replace the basic
implementation with a one based on a lookup table, which has much better
performance than the old one.
The light effects mod branch #3798 by @JeroenDStout has become quite out of date. I plan to properly implement it, but first I want to merge in what we have already, so that I can branch off develop again and rebase (currently rebasing this branch is too difficult, far too many commits).
Most code that this is merging is protected by the __ENABLE_LIGHTFX__ directive, so it should not make any difference until its time to enable it via a new pull request.
I have isolated it as much as possible to lightfx.c.
Fixes#4572: Don't create .sv6 autosaves in track designs manager, roller coaster designer and scenario editor
Fixes#4573: "Save this before quitting?" in scenario editor saves to .sv6, not .sc6
Windows subsystem does not work like console subsystem which makes it almost impossible to obtain `stdout` until the application has finished. This adds a `--console` switch to make the game either attach to an existing console or show a new one and redirect the C streams to it.