diff --git a/CMakeLists.txt b/CMakeLists.txt index 9c2d0a0829..ef3fcd847d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -68,9 +68,9 @@ set(OBJECTS_VERSION "1.3.2") set(OBJECTS_URL "https://github.com/OpenRCT2/objects/releases/download/v${OBJECTS_VERSION}/objects.zip") set(OBJECTS_SHA1 "040a99a8626ad7a7f43f8c8a17c3f4e1375b218f") -set(REPLAYS_VERSION "0.0.67") +set(REPLAYS_VERSION "0.0.68") set(REPLAYS_URL "https://github.com/OpenRCT2/replays/releases/download/v${REPLAYS_VERSION}/replays.zip") -set(REPLAYS_SHA1 "0CA2DB3BEE021F0402D3E0F0E9EDB142CCEAFFC6") +set(REPLAYS_SHA1 "FC8EFE3FCA71F75D79728494ACC42DB49B18B529") option(FORCE32 "Force 32-bit build. It will add `-m32` to compiler flags.") option(WITH_TESTS "Build tests") diff --git a/distribution/changelog.txt b/distribution/changelog.txt index 77157555c1..3145278b41 100644 --- a/distribution/changelog.txt +++ b/distribution/changelog.txt @@ -4,6 +4,7 @@ - Feature: [#16662] Show a warning message when g2.dat is mismatched. - Change: [#17319] Giant screenshots are now cropped to the horizontal view-clipping selection. - Change: [#17499] Update error text when using vehicle incompatible with TD6 and add error when using incompatible track elements. +- Fix: [#16392] Scenery on sloped surface is placed at wrong height. - Fix: [#16476] The game sometimes crashes when demolishing a maze. - Fix: [#17444] “Manta Ray” boats slowed down too much in “Ayers Rock” scenario (original bug). - Fix: [#17503] Parks with staff with an ID of 0 have all staff windows focus on that staff diff --git a/openrct2.proj b/openrct2.proj index 28997f94cd..4347b4b40a 100644 --- a/openrct2.proj +++ b/openrct2.proj @@ -47,8 +47,8 @@ 4ab0065e5a4d9f9c77d94718bbdfcfcd5a389da0 https://github.com/OpenRCT2/objects/releases/download/v1.3.2/objects.zip 040a99a8626ad7a7f43f8c8a17c3f4e1375b218f - https://github.com/OpenRCT2/replays/releases/download/v0.0.67/replays.zip - 0CA2DB3BEE021F0402D3E0F0E9EDB142CCEAFFC6 + https://github.com/OpenRCT2/replays/releases/download/v0.0.68/replays.zip + FC8EFE3FCA71F75D79728494ACC42DB49B18B529 diff --git a/src/openrct2/actions/SmallSceneryPlaceAction.cpp b/src/openrct2/actions/SmallSceneryPlaceAction.cpp index 9541569303..906300c8d0 100644 --- a/src/openrct2/actions/SmallSceneryPlaceAction.cpp +++ b/src/openrct2/actions/SmallSceneryPlaceAction.cpp @@ -135,8 +135,8 @@ GameActions::Result SmallSceneryPlaceAction::Query() const } else { - loc2.x += SceneryQuadrantOffsets[quadrant & 3].x - 1; - loc2.y += SceneryQuadrantOffsets[quadrant & 3].y - 1; + loc2.x += SceneryQuadrantOffsets[quadrant & 3].x; + loc2.y += SceneryQuadrantOffsets[quadrant & 3].y; } landHeight = tile_element_height(loc2); waterHeight = tile_element_water_height(loc2); @@ -329,8 +329,8 @@ GameActions::Result SmallSceneryPlaceAction::Execute() const } else { - x2 += SceneryQuadrantOffsets[quadrant & 3].x - 1; - y2 += SceneryQuadrantOffsets[quadrant & 3].y - 1; + x2 += SceneryQuadrantOffsets[quadrant & 3].x; + y2 += SceneryQuadrantOffsets[quadrant & 3].y; } landHeight = tile_element_height({ x2, y2 }); waterHeight = tile_element_water_height({ x2, y2 }); diff --git a/src/openrct2/network/NetworkBase.cpp b/src/openrct2/network/NetworkBase.cpp index 84a36aac78..6b18940b7c 100644 --- a/src/openrct2/network/NetworkBase.cpp +++ b/src/openrct2/network/NetworkBase.cpp @@ -42,7 +42,7 @@ // This string specifies which version of network stream current build uses. // It is used for making sure only compatible builds get connected, even within // single OpenRCT2 version. -#define NETWORK_STREAM_VERSION "1" +#define NETWORK_STREAM_VERSION "2" #define NETWORK_STREAM_ID OPENRCT2_VERSION "-" NETWORK_STREAM_VERSION static Peep* _pickup_peep = nullptr; diff --git a/src/openrct2/world/Map.cpp b/src/openrct2/world/Map.cpp index 0ec7559686..423ba3e745 100644 --- a/src/openrct2/world/Map.cpp +++ b/src/openrct2/world/Map.cpp @@ -527,7 +527,7 @@ int16_t tile_element_height(const CoordsXY& loc) uint8_t xl, yl; // coordinates across this tile - uint8_t TILE_SIZE = 31; + uint8_t TILE_SIZE = 32; xl = loc.x & 0x1f; yl = loc.y & 0x1f; @@ -569,14 +569,13 @@ int16_t tile_element_height(const CoordsXY& loc) switch (slope) { case TILE_ELEMENT_SLOPE_NE_SIDE_UP: - height += xl / 2 + 1; + height += xl / 2; break; case TILE_ELEMENT_SLOPE_SE_SIDE_UP: height += (TILE_SIZE - yl) / 2; break; case TILE_ELEMENT_SLOPE_NW_SIDE_UP: height += yl / 2; - height++; break; case TILE_ELEMENT_SLOPE_SW_SIDE_UP: height += (TILE_SIZE - xl) / 2; @@ -595,7 +594,7 @@ int16_t tile_element_height(const CoordsXY& loc) break; case TILE_ELEMENT_SLOPE_S_CORNER_DN: quad_extra = xl + yl; - quad = xl + yl - TILE_SIZE - 1; + quad = xl + yl - TILE_SIZE; break; case TILE_ELEMENT_SLOPE_E_CORNER_DN: quad_extra = TILE_SIZE - xl + yl; @@ -603,14 +602,13 @@ int16_t tile_element_height(const CoordsXY& loc) break; case TILE_ELEMENT_SLOPE_N_CORNER_DN: quad_extra = (TILE_SIZE - xl) + (TILE_SIZE - yl); - quad = TILE_SIZE - yl - xl - 1; + quad = TILE_SIZE - yl - xl; break; } if (extra_height) { height += quad_extra / 2; - height++; return height; } // This tile is essentially at the next height level @@ -628,20 +626,13 @@ int16_t tile_element_height(const CoordsXY& loc) switch (slope) { case TILE_ELEMENT_SLOPE_W_E_VALLEY: - if (xl + yl <= TILE_SIZE + 1) - { - return height; - } - quad = TILE_SIZE - xl - yl; + quad = std::abs(xl - yl); break; case TILE_ELEMENT_SLOPE_N_S_VALLEY: - quad = xl - yl; + quad = std::abs(xl + yl - TILE_SIZE); break; } - if (quad > 0) - { - height += quad / 2; - } + height += quad / 2; } return height; diff --git a/src/openrct2/world/Scenery.cpp b/src/openrct2/world/Scenery.cpp index d52ba64bdb..0c92ce7f24 100644 --- a/src/openrct2/world/Scenery.cpp +++ b/src/openrct2/world/Scenery.cpp @@ -59,10 +59,10 @@ static std::vector _restrictedScenery; // rct2: 0x009A3E74 const CoordsXY SceneryQuadrantOffsets[] = { - { 7, 7 }, - { 7, 23 }, - { 23, 23 }, - { 23, 7 }, + { 8, 8 }, + { 8, 24 }, + { 24, 24 }, + { 24, 8 }, }; LargeSceneryText::LargeSceneryText(const rct_large_scenery_text& original)