`memset` takes an integer as argument which gets converted to an unsigned byte. `SPRITE_INDEX_NULL` has a value of 0xFFFF, essentially cutting it to 0xFF. Calling `std::fill_n` instead of `memcpy` assigns the given value to each element in its range rather than setting the bytes. In this case, the result is the same.
None of the other calls to `memset` in the project use values bigger than 0xFF.
By default enumerators use type `int` which can store values up to `1 << 31 - 1`. The clang compiler generates this error for enums values that use the sign bit: `enumerator value is not representable in the underlying type 'int'.`
To get rid of those warnings (and technically improve the code) the erroneous enums are now of type of `uint32`.
Note: I've skipped peep.h to prevent conflicts with the peep refactor branch.
Warnings are shown if the built binaries have not been signed due to the sign key not being set. Now that we no longer have a certficate to sign our binaries, the warning always shows. They can be re-enabled again if we ever get another certficate.
This aims to make future refactoring easier. The arguments are removed where possible, but kept and marked with C++17's [[maybe_unused]] where they could not be removed (e.g. when they are used as a callback, rather than called directly).
I've skipped the rides/<category>/* and peep/* source files, because the rides source files are mostly generated and have a ton of unused variables, and the peep source files are being refactored.
I've also skipped most of window/* source files, because most of the functions are used as callbacks and will be bulk-renamed at some point.
* Rename and refactor `vehicle_is_boat_on_water` to better reflect the actual functionality
New name is `vehicle_boat_is_location_accessible`
* Refactor `vehicle_boat_is_location_accessible` take `TileCoordsXYZ` as parameter