Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent underground view during title sequence #16424

Merged
merged 1 commit into from Jan 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions distribution/changelog.txt
Expand Up @@ -20,6 +20,7 @@
- Improved: [#16258] Increased image limit in the engine.
- Improved: [#16408] Improve --version cli option to report more compatibility information.
- Change: [#16077] When importing SV6 files, the RCT1 land types are only added when they were actually used.
- Change: [#16424] Following an entity in the title sequence no longer toggles underground view when it's underground.
- Fix: [#15571] Non-ASCII characters in scenario description get distorted while saving.
- Fix: [#15830] Objects with RCT1 images are very glitchy if OpenRCT2 is not linked to an RCT1 install.
- Fix: [#15998] Cannot set map size to the actual maximum.
Expand Down
9 changes: 6 additions & 3 deletions src/openrct2/interface/Viewport.cpp
Expand Up @@ -665,10 +665,13 @@ void viewport_update_sprite_follow(rct_window* window)
{
return;
}
int32_t height = (tile_element_height({ sprite->x, sprite->y })) - 16;
int32_t underground = sprite->z < height;

viewport_set_underground_flag(underground, window, window->viewport);
if (!(gScreenFlags & SCREEN_FLAGS_TITLE_DEMO))
{
int32_t height = (tile_element_height({ sprite->x, sprite->y })) - 16;
int32_t underground = sprite->z < height;
viewport_set_underground_flag(underground, window, window->viewport);
}

auto centreLoc = centre_2d_coordinates(sprite->GetLocation(), window->viewport);
if (centreLoc.has_value())
Expand Down