1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-28 09:14:58 +01:00

Map size refactors from NSF (#15112)

* Support large map sizes

* Fix top spin painting

* Fix crooked house

* Increase bb size

* Decrease limit back

* Clang format

* Remove asserts and apply review comments

* Fix rebase mistake

Co-authored-by: Ted John <ted@brambles.org>
This commit is contained in:
Duncan
2021-08-16 20:51:16 +01:00
committed by GitHub
parent bef853d0ab
commit 940cab87d3
36 changed files with 229 additions and 269 deletions

View File

@@ -42,8 +42,8 @@ GameActions::Result::Ptr SurfaceSetStyleAction::Query() const
auto normRange = _range.Normalise();
auto x0 = std::max(normRange.GetLeft(), 32);
auto y0 = std::max(normRange.GetTop(), 32);
auto x1 = std::min(normRange.GetRight(), static_cast<int32_t>(gMapSizeMaxXY));
auto y1 = std::min(normRange.GetBottom(), static_cast<int32_t>(gMapSizeMaxXY));
auto x1 = std::min(normRange.GetRight(), GetMapSizeMaxXY());
auto y1 = std::min(normRange.GetBottom(), GetMapSizeMaxXY());
MapRange validRange{ x0, y0, x1, y1 };
@@ -160,8 +160,8 @@ GameActions::Result::Ptr SurfaceSetStyleAction::Execute() const
auto normRange = _range.Normalise();
auto x0 = std::max(normRange.GetLeft(), 32);
auto y0 = std::max(normRange.GetTop(), 32);
auto x1 = std::min(normRange.GetRight(), static_cast<int32_t>(gMapSizeMaxXY));
auto y1 = std::min(normRange.GetBottom(), static_cast<int32_t>(gMapSizeMaxXY));
auto x1 = std::min(normRange.GetRight(), GetMapSizeMaxXY());
auto y1 = std::min(normRange.GetBottom(), GetMapSizeMaxXY());
MapRange validRange{ x0, y0, x1, y1 };