Skip to content

Introduce embedded save previews #23876

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

Merged
merged 8 commits into from
Mar 5, 2025

Conversation

AaronVanGeffen
Copy link
Member

@AaronVanGeffen AaronVanGeffen commented Feb 22, 2025

This PR adds a new chunk to .park save files containing an embedded minimap image (128x128), viewport screenshot (250x200), and an optional logo (250x200), along with several basic stats. This information is then read by the load/save file browser.

NB: I have not yet incremented the park version number. While we probably should increment it, save games created with this extra chunk are fully compatible with develop.

I would also like to propose we change the default colour of the load/save file browser from blue to green. Altogether, that gets us to the following screenshot.

file-browser-previews

A video of the changes in action:

Screen.Recording.2025-02-28.at.13.29.54.mp4

@AaronVanGeffen AaronVanGeffen added changelog This issue/PR deserves a changelog entry. park file version Requires updating the park file version number labels Feb 22, 2025
@AaronVanGeffen AaronVanGeffen modified the milestone: v0.4.20 Feb 22, 2025
@AaronVanGeffen AaronVanGeffen added this to the After v0.4.20 milestone Feb 22, 2025
@karst

This comment was marked as resolved.

@AaronVanGeffen

This comment was marked as outdated.

@karst

This comment was marked as outdated.

@AaronVanGeffen

This comment was marked as outdated.

Copy link
Member

@ZehMatt ZehMatt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested this quite a bit and all seems to work, there is a small noticeable lag when hovering over the saves quickly but we can off-load this later to the background once I've come up with a better way to deal with this.

@karst

This comment was marked as resolved.

@AaronVanGeffen

This comment was marked as outdated.

@karst

This comment was marked as outdated.

@AaronVanGeffen

This comment was marked as outdated.

@AaronVanGeffen

This comment was marked as outdated.

@karst

This comment was marked as outdated.

@AaronVanGeffen

This comment was marked as outdated.

@AaronVanGeffen
Copy link
Member Author

@karst Should be sorted as of the latest commit ("Fix issue with OpenGL")

Copy link
Member

@karst karst left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Latest commit fixed the issue :)

@AaronVanGeffen
Copy link
Member Author

I have compacted the commit history from 29 commits into 7 commits, increased the park version version, and amended the changelog file. With that, I think this is ready for merging.

Copy link
Member

@Gymnasiast Gymnasiast left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I get an immediate crash when I try to save a game.

@AaronVanGeffen AaronVanGeffen enabled auto-merge March 5, 2025 22:54
@AaronVanGeffen AaronVanGeffen merged commit 5294b9e into OpenRCT2:develop Mar 5, 2025
22 checks passed
@AaronVanGeffen AaronVanGeffen deleted the save-previews branch March 5, 2025 23:05
Gymnasiast added a commit that referenced this pull request Apr 5, 2025
- Feature: [#22646] New scenario files now contain a minimap image, shown in the scenario selection window.
- Feature: [#23774] Climates can now be customised using objects.
- Feature: [#23876] New park save files now contain a preview image, shown in the load/save window.
- Improved: [#24078] Handrails on Wooden Roller Coaster station sprites with no platforms have been removed.
- Improved: [objects#379] Add additional colour schemes to Mine Train.
- Change: [#23932] The land rights window now checks “Land Owned” by default.
- Change: [#23936] The ‘guests prefer less/more intense rides’ settings have been turned into a dropdown.
- Change: [#24059] The ‘select other ride’ button is now available in the track designs manager.
- Change: [#24067] [Plugin] Registered menu items are now listed alphabetically.
- Change: [#24070] Footpath selection menus now show object names on hover using a tooltip.
- Change: [#24101] Frozen peeps are no longer removed when using the 'remove all guests' cheat.
- Fix: [#4225] Ride Construction window offers non-existent banked sloped to level curve (original bug).
- Fix: [#5281] Missing supports on miniature railways built backwards.
- Fix: [#7222] Transparent pixels in sloped path tunnels (original bug).
- Fix: [#10379] Banners outside the park can be renamed and modified (original bug).
- Fix: [#10582] Low clearance tunnels below water are drawn incorrectly (original bug).
- Fix: [#17524, #23710] Station bases are drawn on many ride types when the “No entrance, no platform station” style is selected.
- Fix: [#18169] CJK, Arabic and Vietnamese display all text as ‘???’ on Android.
- Fix: [#18309] Flying and Multi Dimension trains glitch when changing between inverted and uninverted track when uncap fps is on.
- Fix: [#19506] Queue paths can be placed on level crossings by replacing an existing regular path.
- Fix: [#21803] The park fence is drawn differently in OpenGL compared to software rendering when zoomed out.
- Fix: [#21824] Some sprites are drawn incorrectly when zoomed out in OpenGL rendering.
- Fix: [#21908] Ride mode warnings when hovering track designs.
- Fix: [#22820] OpenGL does not draw masked sprites correctly.
- Fix: [#22961] Clicking on the construction preview places duplicate flat rides and stalls.
- Fix: [#23359] Scripting: Add car.moveToTrack, an easier API than setting car.trackLocation directly.
- Fix: [#23443] New GOG version of RCT2 is not extracted correctly.
- Fix: [#23484] Stray coloured pixels on castle-themed stations and Roman-themed entrances/exits (original bug).
- Fix: [#23486] Object selection minimum requirements can be bypassed with close window hotkey.
- Fix: [#23743] Parks with guest goals over 32767 do not appear in the scenario list.
- Fix: [#23844] Sound effects keep playing when loading another save.
- Fix: [#23881] Compiling on Raspbian/arm-linux-gnueabihf fails.
- Fix: [#23891] Inverted Hairpin Coaster track can draw over things above it (original bug).
- Fix: [#23892] Gentle banked Wooden Roller Coaster track glitches as trains pass (original bug).
- Fix: [#23897] Reverse Freefall Coaster slope up to vertical track piece does not draw a vertical tunnel.
- Fix: [#23910] Heartline Twister Coaster track can draw over things above it (original bug).
- Fix: [#23939] Incorrect assertion when trying to load heightmap.
- Fix: [#23941] Underflow in “Repay loan and achieve a certain park value” objective when using Japanese.
- Fix: [#23949] Walls draw over sloped rear water edges and those edge sprites are misaligned (original bug).
- Fix: [#23960] Corner path fences can draw over adjacent sloped land (original bug).
- Fix: [#23961] Lamps and queue line tvs draw incorrectly on paths with fences.
- Fix: [#23983] Ordering files by size does not work and occasionally crashes the game.
- Fix: [#24009] [Plugin] The object manager API does not identify recently introduced object types.
- Fix: [#24028] Giga and LSM Launched Coaster booster sprites have pixels that draw over transparent pixels.
- Fix: [#24077] Track Designer crashes when clicking the park fence.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog This issue/PR deserves a changelog entry. park file version Requires updating the park file version number
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants