mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-04 13:42:55 +01:00
Correct memcpy usage
This commit is contained in:
@@ -1331,12 +1331,11 @@ void S6Exporter::ExportTileElements()
|
||||
auto dst = &_s6.tile_elements[index];
|
||||
if (src->base_height == 0xFF)
|
||||
{
|
||||
std::memcpy(dst, src, sizeof(*src));
|
||||
std::memcpy(dst, src, sizeof(*dst));
|
||||
}
|
||||
else
|
||||
{
|
||||
auto tileElementType = (RCT12TileElementType)src->GetType();
|
||||
// Todo: replace with setting invisibility bit
|
||||
if (tileElementType == RCT12TileElementType::Corrupt || tileElementType == RCT12TileElementType::EightCarsCorrupt14
|
||||
|| tileElementType == RCT12TileElementType::EightCarsCorrupt15)
|
||||
std::memcpy(dst, src, sizeof(*dst));
|
||||
|
||||
Reference in New Issue
Block a user