forked from rosebudai/OpenRCT2-Web
Refactor maze import
This commit is contained in:
1 parent
7aa5e8d8c5
commit
f75c5035d5
2 files changed
+12
-10
No files matched your search
@@ -247,15 +247,16 @@ namespace OpenRCT2::RCT1
|
||||
const auto& rtd = GetRideTypeDescriptor(td->trackAndVehicle.rtdIndex);
|
||||
if (rtd.specialType == RtdSpecialType::maze)
|
||||
{
|
||||
TD46MazeElement t4MazeElement{};
|
||||
t4MazeElement.all = !0;
|
||||
while (t4MazeElement.all != 0)
|
||||
TD46MazeElement t4MazeElement;
|
||||
while (true)
|
||||
{
|
||||
_stream.Read(&t4MazeElement, sizeof(TD46MazeElement));
|
||||
if (t4MazeElement.all != 0)
|
||||
if (t4MazeElement.all == 0)
|
||||
{
|
||||
importMazeElement(*td, t4MazeElement);
|
||||
break;
|
||||
}
|
||||
|
||||
importMazeElement(*td, t4MazeElement);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -139,15 +139,16 @@ namespace OpenRCT2::RCT2
|
||||
const auto& rtd = GetRideTypeDescriptor(td->trackAndVehicle.rtdIndex);
|
||||
if (rtd.specialType == RtdSpecialType::maze)
|
||||
{
|
||||
TD46MazeElement t6MazeElement{};
|
||||
t6MazeElement.all = !0;
|
||||
while (t6MazeElement.all != 0)
|
||||
TD46MazeElement t6MazeElement;
|
||||
while (true)
|
||||
{
|
||||
_stream.Read(&t6MazeElement, sizeof(TD46MazeElement));
|
||||
if (t6MazeElement.all != 0)
|
||||
if (t6MazeElement.all == 0)
|
||||
{
|
||||
importMazeElement(*td, t6MazeElement);
|
||||
break;
|
||||
}
|
||||
|
||||
importMazeElement(*td, t6MazeElement);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
Reference in new issue
Block a user