diff --git a/.travis.yml b/.travis.yml index 7e151ce803..37e630a032 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,7 +23,7 @@ matrix: - mv OpenRCT2/bin/openrct2 OpenRCT2/ && mv OpenRCT2/share/openrct2 OpenRCT2/data && mv OpenRCT2/share/doc/openrct2 OpenRCT2/doc - rm -rf OpenRCT2/bin OpenRCT2/share # remove empty dirs - tar cvzf openrct2-linux.tar.gz OpenRCT2/ - - if [[ "z$OPENRCT2_ORG_TOKEN" != "z" ]] ; then curl -o - -v --form "key=$OPENRCT2_ORG_TOKEN" --form "fileName=OpenRCT2-${OPENRCT2_VERSION}-${TRAVIS_BRANCH}-${TRAVIS_COMMIT:0:7}-linux.tar.gz" --form "version=${OPENRCT2_VERSION}" --form "gitHash=$TRAVIS_COMMIT" --form "gitBranch=$TRAVIS_BRANCH" --form "flavourId=4" --form "file=@openrct2-linux.tar.gz" "https://openrct2.org/altapi/?command=push-build"; fi + - if [[ "z$OPENRCT2_ORG_TOKEN" != "z" && ("${TRAVIS_BRANCH}" =~ "^(develop|push/)" || "z${TRAVIS_TAG}" != "z") ]] ; then curl -o - -v --form "key=$OPENRCT2_ORG_TOKEN" --form "fileName=OpenRCT2-${OPENRCT2_VERSION}-${TRAVIS_BRANCH}-${TRAVIS_COMMIT:0:7}-linux.tar.gz" --form "version=${OPENRCT2_VERSION}" --form "gitHash=$TRAVIS_COMMIT" --form "gitBranch=$TRAVIS_BRANCH" --form "flavourId=4" --form "file=@openrct2-linux.tar.gz" "https://openrct2.org/altapi/?command=push-build"; fi - os: linux env: OPENRCT2_CMAKE_OPTS="-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++" - os: linux @@ -43,7 +43,7 @@ matrix: after_success: - cd build/Release - zip -r openrct2-osx.zip OpenRCT2.app - - if [[ "z$OPENRCT2_ORG_TOKEN" != "z" ]] ; then curl -o - -v --form "key=$OPENRCT2_ORG_TOKEN" --form "fileName=OpenRCT2-${OPENRCT2_VERSION}-${TRAVIS_BRANCH}-${TRAVIS_COMMIT:0:7}-osx.zip" --form "version=${OPENRCT2_VERSION}" --form "gitHash=$TRAVIS_COMMIT" --form "gitBranch=$TRAVIS_BRANCH" --form "flavourId=3" --form "file=@openrct2-osx.zip" "https://openrct2.org/altapi/?command=push-build"; fi + - if [[ "z$OPENRCT2_ORG_TOKEN" != "z" && ("${TRAVIS_BRANCH}" =~ "^(develop|push/)" || "z${TRAVIS_TAG}" != "z") ]] ; then curl -o - -v --form "key=$OPENRCT2_ORG_TOKEN" --form "fileName=OpenRCT2-${OPENRCT2_VERSION}-${TRAVIS_BRANCH}-${TRAVIS_COMMIT:0:7}-osx.zip" --form "version=${OPENRCT2_VERSION}" --form "gitHash=$TRAVIS_COMMIT" --form "gitBranch=$TRAVIS_BRANCH" --form "flavourId=3" --form "file=@openrct2-osx.zip" "https://openrct2.org/altapi/?command=push-build"; fi # Following entries used to be included in testing, but they only proved useful while changing things in CMake setup. # They are meant to be used when there are changes to CMakeLists.txt # - os: linux diff --git a/appveyor.yml b/appveyor.yml index d6bb665114..b765041d0b 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -28,5 +28,5 @@ artifacts: name: OpenRCT2-portable - path: .\artifacts\*.exe name: OpenRCT2-installer -- path: .\artifacts\openrct2-symbols.zip +- path: .\artifacts\openrct2-symbols-*.zip name: OpenRCT2 debug symbols diff --git a/contributors.md b/contributors.md index 0cea0befc4..6920b61bf1 100644 --- a/contributors.md +++ b/contributors.md @@ -50,6 +50,7 @@ Includes all git commit authors. Aliases are GitHub user names. * James Robertson (rd3k) - Misc. * Robert Jordan (trigger-death) - UI theming, title sequence editor, misc. * Aaron van Geffen (AaronVanGeffen) - scenario select screen, font detection, misc. +* Kelson Blakewood - title sequence for 0.0.4 ## Bug fixes * (halfbro) @@ -86,19 +87,21 @@ Includes all git commit authors. Aliases are GitHub user names. * Extracting from original files: Ted John (IntelOrca) * Reviewing and merging: Rune Laenen (runelaenen), Michael Steenbeek (Gymnasiast) * Fixing unmaintained languages: Michael Steenbeek (Gymnasiast) +* Miscellaneous fixes: Alexander Overvoorde (Overv), Ed Foley (e-foley) * English (UK) - Ted John (IntelOrca), (Tinytimrob) -* English (US) - Ted John (IntelOrca), Michael Steenbeek (Gymnasiast) -* Czech - Martin Černáč (octaroot) -* Dutch - Michael Steenbeek (Gymnasiast), Yannic Geurts (xzbobzx), (mrtnptrs), Thomas den Hollander (ThomasdenH), (hostbrute); reviewing and discussion: Aaron van Geffen (AaronVanGeffen), (Balletie) and Sijmen Schoon (Vijfhoek). -* Finnish - (DJHasis) -* French - (fbourigault), Joël Troch (JoelTroch), Michael Steenbeek (Gymnasiast), Romain Vigier (rvgr) -* German - (danidoedel), (atmaxinger), (Yepoleb), Daniel Kessel (dkessel), Leon (AllGoodNamesAreTaken) -* Korean - "TELK" (telk5093) -* Polish - Adrian Wielgosik (adrian17) -* Portuguese (BR) - (kaudy) +* English (US) - Ted John (IntelOrca), Michael Steenbeek (Gymnasiast); small fixes: LRFLEW, mike-koch +* Czech - Martin Černáč (octaroot), (Clonewayx), Tomáš Pazdiora (Aroidzap) +* Dutch - Michael Steenbeek (Gymnasiast), Yannic Geurts (xzbobzx), (mrtnptrs), Thomas den Hollander (ThomasdenH), (hostbrute), Marijn van de Werf (marijnvdwerf); reviewing and discussion: Aaron van Geffen (AaronVanGeffen), (Balletie) and Sijmen Schoon (Vijfhoek). +* Finnish - (DJHasis), (Zode), (TheWing) +* French - (fbourigault), Joël Troch (JoelTroch), Michael Steenbeek (Gymnasiast), Romain Vigier (rvgr), (AziasYur), Hugo Courtial (s0r00t), David Delobel (incyclum) +* German - (danidoedel), (atmaxinger), (Yepoleb), Daniel Kessel (dkessel), Leon (AllGoodNamesAreTaken), (raidcookie) +* Japanese - Aaron van Geffen (AaronVanGeffen), Nick Hall (nickhall), (jhako) +* Korean - "TELK" (telk5093), (NeverDruid); small fixes: (kexplo) +* Polish - Adrian Wielgosik (adrian17), (lopezloo), Michał Janiszewski (janisozaur) +* Portuguese (BR) - (kaudy), (renansimoes) * Russian - (Soosisya) -* Simplified Chinese - Naiji Ma (naijim) -* Spanish - (mdtrooper), Josué Acevedo (Wirlie) +* Simplified Chinese - Naiji Ma (naijim), (izhangfei), Eric Zhao (sczyh30) +* Spanish - (mdtrooper), Josué Acevedo (Wirlie), Daniel Trujillo Viedma (gdabi); small fixes: (teapartycthulu) * Swedish - (Jinxit), (mharrys), (Slimeyo), (Nubbie) * Traditional Chinese - Harry Lam (daihakken) diff --git a/data/title/openrct2/Cypress Grove Title.sv6 b/data/title/openrct2/Cypress Grove Title.sv6 new file mode 100644 index 0000000000..0becfb65cb Binary files /dev/null and b/data/title/openrct2/Cypress Grove Title.sv6 differ diff --git a/data/title/openrct2/Ill Paradise.sv6 b/data/title/openrct2/Ill Paradise.sv6 new file mode 100644 index 0000000000..62ac421cf8 Binary files /dev/null and b/data/title/openrct2/Ill Paradise.sv6 differ diff --git a/data/title/openrct2/TaCW.sv6 b/data/title/openrct2/TaCW.sv6 new file mode 100644 index 0000000000..fefd623dcd Binary files /dev/null and b/data/title/openrct2/TaCW.sv6 differ diff --git a/data/title/openrct2/Title Sequence Park 1.sv6 b/data/title/openrct2/Title Sequence Park 1.sv6 new file mode 100644 index 0000000000..873ebb9b80 Binary files /dev/null and b/data/title/openrct2/Title Sequence Park 1.sv6 differ diff --git a/data/title/openrct2/achilleshiel.sv6 b/data/title/openrct2/achilleshiel.sv6 deleted file mode 100644 index 24ce7be588..0000000000 Binary files a/data/title/openrct2/achilleshiel.sv6 and /dev/null differ diff --git a/data/title/openrct2/alexfablelake.SV6 b/data/title/openrct2/alexfablelake.SV6 deleted file mode 100644 index b48dbf132e..0000000000 Binary files a/data/title/openrct2/alexfablelake.SV6 and /dev/null differ diff --git a/data/title/openrct2/bigfoot.sv6 b/data/title/openrct2/bigfoot.sv6 deleted file mode 100644 index 662a7b28ac..0000000000 Binary files a/data/title/openrct2/bigfoot.sv6 and /dev/null differ diff --git a/data/title/openrct2/gymnasiast1.sv6 b/data/title/openrct2/gymnasiast1.sv6 deleted file mode 100644 index 916823ef7a..0000000000 Binary files a/data/title/openrct2/gymnasiast1.sv6 and /dev/null differ diff --git a/data/title/openrct2/gymnasiast2.sv6 b/data/title/openrct2/gymnasiast2.sv6 deleted file mode 100644 index a678752eb4..0000000000 Binary files a/data/title/openrct2/gymnasiast2.sv6 and /dev/null differ diff --git a/data/title/openrct2/mci.sv6 b/data/title/openrct2/mci.sv6 deleted file mode 100644 index 95008afc08..0000000000 Binary files a/data/title/openrct2/mci.sv6 and /dev/null differ diff --git a/data/title/openrct2/netgrouppark.sv6 b/data/title/openrct2/netgrouppark.sv6 deleted file mode 100644 index 4d8554ce80..0000000000 Binary files a/data/title/openrct2/netgrouppark.sv6 and /dev/null differ diff --git a/data/title/openrct2/pfckrutonium1.sv6 b/data/title/openrct2/pfckrutonium1.sv6 deleted file mode 100644 index 907da0bde0..0000000000 Binary files a/data/title/openrct2/pfckrutonium1.sv6 and /dev/null differ diff --git a/data/title/openrct2/phann.sv6 b/data/title/openrct2/phann.sv6 deleted file mode 100644 index ca3846acb5..0000000000 Binary files a/data/title/openrct2/phann.sv6 and /dev/null differ diff --git a/data/title/openrct2/poke.sv6 b/data/title/openrct2/poke.sv6 deleted file mode 100644 index f9702ff6dc..0000000000 Binary files a/data/title/openrct2/poke.sv6 and /dev/null differ diff --git a/data/title/openrct2/rid6.sv6 b/data/title/openrct2/rid6.sv6 deleted file mode 100644 index c83a3af928..0000000000 Binary files a/data/title/openrct2/rid6.sv6 and /dev/null differ diff --git a/data/title/openrct2/script.txt b/data/title/openrct2/script.txt index 0943a1bd72..a20b7ecab8 100644 --- a/data/title/openrct2/script.txt +++ b/data/title/openrct2/script.txt @@ -1,81 +1,84 @@ -# OpenRCT2 0.0.3 Title Sequence Script -# Arranged by Gymnasiast (Michael Steenbeek). -# Based on the 0.0.2 script, which was arranged by IntelOrca. +# OpenRCT2 0.0.4 Title Sequence Script +# Arranged by NWSpacek (Kelson Blakewood). +# If you have parks you think would work well in a title sequence (must be NCSO), contact me on reddit at u/spacek_toast -LOAD pfckrutonium1.sv6 -LOCATION 7 41 -WAIT 10 +LOAD Ill Paradise.sv6 +LOCATION 113 105 +WAIT 15 -LOAD netgrouppark.sv6 -LOCATION 91 10 -WAIT 9 - -LOCATION 25 15 -WAIT 9 - -LOAD bigfoot.sv6 -LOCATION 58 29 -WAIT 10 - -ROTATE 1 -LOCATION 29 63 -WAIT 10 - -LOAD gymnasiast2.sv6 -LOCATION 39 79 -WAIT 11 - -LOAD achilleshiel.sv6 -LOCATION 25 77 -WAIT 10 - -LOCATION 36 58 +LOCATION 120 102 ROTATE 3 -WAIT 8 +WAIT 10 -LOAD mci.sv6 -LOCATION 46 60 -WAIT 6 - -LOCATION 76 32 +LOCATION 73 136 ROTATE 1 -WAIT 11 +WAIT 15 -LOAD phann.sv6 -LOCATION 96 73 -WAIT 8 +LOAD Title Sequence Park 1.sv6 +ROTATE 2 +LOCATION 120 43 +WAIT 15 -LOAD rid6.sv6 -LOCATION 56 34 -WAIT 8 - -LOCATION 10 29 -ROTATE 1 -WAIT 8 - -LOAD gymnasiast1.sv6 -LOCATION 51 46 -WAIT 11 - -LOAD alexfablelake.SV6 -LOCATION 50 25 -WAIT 9 +LOCATION 124 74 +WAIT 15 ROTATE 1 -LOCATION 35 74 -WAIT 9 +LOCATION 120 90 +WAIT 10 -LOAD poke.sv6 -LOCATION 43 83 -WAIT 9 +LOCATION 123 130 +WAIT 20 -LOCATION 63 35 +LOCATION 70 85 +ROTATE 1 +WAIT 15 + +LOAD Cypress Grove Title.sv6 +LOCATION 106 43 ROTATE 3 -WAIT 9 +WAIT 15 -LOCATION 12 47 +LOCATION 60 103 +ROTATE 1 +WAIT 10 + +LOCATION 91 83 +WAIT 10 + +ROTATE 1 +LOCATION 117 61 +WAIT 10 + +LOCATION 82 95 +ROTATE 1 +WAIT 20 + +LOCATION 110 94 ROTATE 3 -WAIT 6 +WAIT 15 + +LOCATION 79 94 +WAIT 10 + +LOCATION 63 97 +ROTATE 1 +WAIT 10 + +LOAD TaCW.sv6 +WAIT 15 + +ROTATE 1 +LOCATION 110 95 +WAIT 15 + +LOCATION 57 101 +ROTATE 3 +WAIT 15 + +LOCATION 100 63 +ROTATE 2 +WAIT 15 RESTART +END diff --git a/debian/changelog b/debian/changelog index 375a6fca0a..965f2d8c56 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,5 +1,5 @@ openrct2 (0.0.5-develop-1) unstable; urgency=medium - * Initial release. (Closes: #XXXXXX) + * Fourth stable release. (Closes: #XXXXXX) -- Michał Janiszewski Sun, 10 Jan 2016 23:41:16 +0100 diff --git a/distribution/changelog.txt b/distribution/changelog.txt index cd8a212060..076e9aa443 100644 --- a/distribution/changelog.txt +++ b/distribution/changelog.txt @@ -1,4 +1,4 @@ -0.0.4 (not yet released) +0.0.4 ------------------------------------------------------------------------ - Feature: Full native OSX .app support. - Feature: Add displaying of frames per second (FPS). diff --git a/distribution/known_issues.txt b/distribution/known_issues.txt index 7954655d51..d041833e06 100644 --- a/distribution/known_issues.txt +++ b/distribution/known_issues.txt @@ -1,6 +1,8 @@ -Release version: 0.0.3-1-beta +Release version: 0.0.4 ------------------------------------------------------------------------ -* Some sounds play at their maximum volume irrespective of the sound volume control. * Scenario editor object selection window will show object names in the selected language at the time of building the object cache. (Deleting plugin.dat in Documents/OpenRCT2 will fix this) +* Guest AI is slightly worse than the original game. +* Multiplayer is very experimental and is likely to desynchronise often. +* Picking up / hiring of staff and guests in multiplayer may cause the game to crash. Some bugs or limitations present in the original game have not yet been fixed or lifted. diff --git a/distribution/windows/build.ps1 b/distribution/windows/build.ps1 index 2dd5770727..11cecea326 100644 --- a/distribution/windows/build.ps1 +++ b/distribution/windows/build.ps1 @@ -6,6 +6,6 @@ param ( $path = Split-Path $Script:MyInvocation.MyCommand.Path Write-Host "Building Windows Installer (NSIS script)"; Write-Host " $VersionExtra"; -makensis /DAPPV_EXTRA=-$VersionExtra ` +makensis /DAPPV_EXTRA=$VersionExtra ` /DVERSION_INCLUDE=$path\win32.txt ` $path\install.nsi > $path\win32.log; diff --git a/readme.md b/readme.md index 260e149c28..e3b466c3f7 100644 --- a/readme.md +++ b/readme.md @@ -4,7 +4,7 @@ An open source re-implementation of Roller Coaster Tycoon 2. A construction and ### Build Status | | Windows | Linux / OSX | Download | |-------------|---------|-------------|----------| -| **master** | [![AppVeyor](https://ci.appveyor.com/api/projects/status/7efnemxhon6i5n34/branch/develop?svg=true)](https://ci.appveyor.com/project/IntelOrca/openrct2-ject9) | [![Travis CI](https://travis-ci.org/OpenRCT2/OpenRCT2.svg?branch=master)](https://travis-ci.org/OpenRCT2/OpenRCT2) | [OpenRCT2.org](https://openrct2.org/downloads/master/latest) | +| **master** | [![AppVeyor](https://ci.appveyor.com/api/projects/status/7efnemxhon6i5n34/branch/master?svg=true)](https://ci.appveyor.com/project/IntelOrca/openrct2-ject9) | [![Travis CI](https://travis-ci.org/OpenRCT2/OpenRCT2.svg?branch=master)](https://travis-ci.org/OpenRCT2/OpenRCT2) | [OpenRCT2.org](https://openrct2.org/downloads/master/latest) | | **develop** | [![AppVeyor](https://ci.appveyor.com/api/projects/status/7efnemxhon6i5n34/branch/develop?svg=true)](https://ci.appveyor.com/project/IntelOrca/openrct2-ject9) | [![Travis CI](https://travis-ci.org/OpenRCT2/OpenRCT2.svg?branch=develop)](https://travis-ci.org/OpenRCT2/OpenRCT2) | [OpenRCT2.org](https://openrct2.org/downloads/develop/latest) | ### Chat diff --git a/scripts/ps/appveyor_run.ps1 b/scripts/ps/appveyor_run.ps1 index 7b4f606d88..d438056160 100644 --- a/scripts/ps/appveyor_run.ps1 +++ b/scripts/ps/appveyor_run.ps1 @@ -43,16 +43,20 @@ $installer = $false $symbols = $false if (${env:OPENRCT2.ORG_TOKEN} -ne $null) { - $pushBuilds = $true $installer = $true $symbols = $true + + if ($tag -ne $null -or $env:APPVEYOR_REPO_BRANCH -match "^develop$|^push/") + { + $pushBuilds = $true + } } # Write out summary of the build Write-Host "AppVeyor CI Build" -ForegroundColor Green if ($tag -ne $null) { - Write-Host " $version-$tag" -ForegroundColor Green + Write-Host " $version ($tag)" -ForegroundColor Green } else { @@ -117,7 +121,11 @@ if ($pushBuilds) $versionExtension = "" if ($tag -ne $null) { - $versionExtension = "-$tag" + # Hide tag if it is a version + if ($GitTag -notmatch "^v[0-9]") + { + $versionExtension = "-$tag" + } } else { @@ -146,7 +154,7 @@ if ($pushBuilds) if ($symbols) { Write-Host "Sending symbols to OpenRCT2.org" -ForegroundColor Cyan - Push-Build -file ".\artifacts\openrct2-symbols.zip" ` + Push-Build -file ".\artifacts\openrct2-symbols-${env:APPVEYOR_REPO_COMMIT_SHORT}.zip" ` -name "$pushFileName-symbols.zip" ` -version $version ` -flavourId 5 diff --git a/scripts/ps/publish.ps1 b/scripts/ps/publish.ps1 index 05b94deddf..ed2d4288da 100644 --- a/scripts/ps/publish.ps1 +++ b/scripts/ps/publish.ps1 @@ -50,7 +50,15 @@ function Do-PrepareSource() $defines["OPENRCT2_BUILD_SERVER"] = $Server; if ($GitTag -ne "") { - $defines["OPENRCT2_BRANCH"] = $GitTag; + # Hide tag if it is a version + if ($GitTag -match "^v[0-9]") + { + $defines["OPENRCT2_BRANCH"] = ""; + } + else + { + $defines["OPENRCT2_BRANCH"] = $GitTag; + } } else { @@ -104,9 +112,10 @@ function Do-Symbols() Write-Host "Publishing OpenRCT2 debug symbols as zip..." -ForegroundColor Cyan $artifactsDir = "$rootPath\artifacts" $releaseDir = "$rootPath\bin" - $outZip = "$rootPath\artifacts\openrct2-symbols.zip" + $outZip = "$rootPath\artifacts\openrct2-symbols-$GitSha1Short.zip" Copy-Item -Force "$releaseDir\openrct2.pdb" $artifactsDir -ErrorAction Stop + Copy-Item -Force "$releaseDir\openrct2.dll" $artifactsDir -ErrorAction Stop # Create archive using 7z (renowned for speed and compression) $7zcmd = "7za" @@ -120,7 +129,7 @@ function Do-Symbols() return 1 } } - & $7zcmd a -tzip -mx9 $outZip "$artifactsDir\openrct2.pdb" > $null + & $7zcmd a -tzip -mx9 $outZip "$artifactsDir\openrct2.pdb" "$artifactsDir\openrct2.dll" > $null if ($LASTEXITCODE -ne 0) { Write-Host "Failed to create zip." -ForegroundColor Red @@ -192,11 +201,15 @@ function Do-Installer() $VersionExtra = "" if ($GitTag -ne "") { - $VersionExtra = "$GitTag" + # Hide tag if it is a version + if ($GitTag -notmatch "^v[0-9]") + { + $VersionExtra = "-$GitTag"; + } } else { - $VersionExtra = "$GitBranch-$GitCommitSha1Short" + $VersionExtra = "-$GitBranch-$GitCommitSha1Short" } # Create installer diff --git a/src/game.c b/src/game.c index 0cd73fada0..2f65bd5df5 100644 --- a/src/game.c +++ b/src/game.c @@ -1001,7 +1001,7 @@ void save_game() SDL_RWops* rw = SDL_RWFromFile(gScenarioSavePath, "wb+"); if (rw != NULL) { - scenario_save(rw, 0x80000000); + scenario_save(rw, 0x80000000 | (gConfigGeneral.save_plugin_data ? 1 : 0)); log_verbose("Saved to %s", gScenarioSavePath); SDL_RWclose(rw); diff --git a/src/input.c b/src/input.c index 0257ba6da6..ab8efc3672 100644 --- a/src/input.c +++ b/src/input.c @@ -538,7 +538,13 @@ static void input_viewport_drag_continue() dx = newDragX - gInputDragLastX; dy = newDragY - gInputDragLastY; w = window_find_by_number(_dragWidget.window_classification, _dragWidget.window_number); - assert(w != NULL); + + // #3294: Window can be closed during a drag session, so just finish + // the session if the window no longer exists + if (w == NULL) { + input_viewport_drag_end(); + return; + } viewport = w->viewport; _ticksSinceDragStart += RCT2_GLOBAL(RCT2_ADDRESS_TICKS_SINCE_LAST_UPDATE, sint16); diff --git a/src/localisation/language.cpp b/src/localisation/language.cpp index 9ce07e3f7a..5de1f473c9 100644 --- a/src/localisation/language.cpp +++ b/src/localisation/language.cpp @@ -48,10 +48,10 @@ enum { }; static TTFFontSetDescriptor TTFFontMSGothic = {{ - { "msgothic_02.ttf", "MS PGothic", 9, 1, 0, 15, nullptr }, - { "msgothic_02.ttf", "MS PGothic", 12, 1, 0, 17, nullptr }, - { "msgothic_02.ttf", "MS PGothic", 12, 1, 0, 17, nullptr }, - { "msgothic_02.ttf", "MS PGothic", 13, 1, 0, 20, nullptr }, + { "msgothic.ttc", "MS PGothic", 9, 1, 0, 15, nullptr }, + { "msgothic.ttc", "MS PGothic", 12, 1, 0, 17, nullptr }, + { "msgothic.ttc", "MS PGothic", 12, 1, 0, 17, nullptr }, + { "msgothic.ttc", "MS PGothic", 13, 1, 0, 20, nullptr }, }}; static TTFFontSetDescriptor TTFFontMingLiu = {{ diff --git a/src/platform/posix.c b/src/platform/posix.c index 850ad1df5a..d7984e2b92 100644 --- a/src/platform/posix.c +++ b/src/platform/posix.c @@ -658,7 +658,10 @@ void platform_resolve_user_data_path() const char separator[2] = { platform_get_path_separator(), 0 }; if (gCustomUserDataPath[0] != 0) { - realpath(gCustomUserDataPath, _userDataDirectoryPath); + if (realpath(gCustomUserDataPath, _userDataDirectoryPath) == NULL) { + log_error("Could not resolve path \"%s\"", gCustomUserDataPath); + return; + } // Ensure path ends with separator int len = strlen(_userDataDirectoryPath); @@ -703,7 +706,10 @@ void platform_resolve_openrct_data_path() const char separator[2] = { platform_get_path_separator(), 0 }; if (gCustomOpenrctDataPath[0] != 0) { - realpath(gCustomOpenrctDataPath, _openrctDataDirectoryPath); + if (realpath(gCustomOpenrctDataPath, _openrctDataDirectoryPath)) { + log_error("Could not resolve path \"%s\"", gCustomUserDataPath); + return; + } // Ensure path ends with separator int len = strlen(_openrctDataDirectoryPath); diff --git a/src/rct2.c b/src/rct2.c index 1f56898f63..e862f2d89a 100644 --- a/src/rct2.c +++ b/src/rct2.c @@ -356,6 +356,7 @@ bool rct2_open_file(const char *path) if (_stricmp(extension, "sv6") == 0) { strcpy((char*)RCT2_ADDRESS_SAVED_GAMES_PATH_2, path); game_load_save(path); + gFirstTimeSave = 0; return true; } else if (_stricmp(extension, "sc6") == 0) { // TODO scenario install diff --git a/src/ride/ride.c b/src/ride/ride.c index 9c9f99633f..cab105fda3 100644 --- a/src/ride/ride.c +++ b/src/ride/ride.c @@ -6544,32 +6544,32 @@ void game_command_set_ride_price(int *eax, int *ebx, int *ecx, int *edx, int *es } } ride = get_ride(0); - rideEntry = get_ride_entry(ride->subtype); - uint8 count = 0; - while (count < 0xFF) { - if (ride->type != 0xFF) { - if (ride->type != RIDE_TYPE_TOILETS || shop_item != 0x1F) { - if (rideEntry->shop_item == shop_item) { - ride->price = price; - window_invalidate_by_number(WC_RIDE, count); - } - } - else { - ride->price = price; - window_invalidate_by_number(WC_RIDE, count); - } - // If the shop item is the same or an on-ride photo - if (rideEntry->shop_item_secondary == shop_item || - (rideEntry->shop_item_secondary == 0xFF && - (shop_item == 0x3 || shop_item == 0x20 || shop_item == 0x21 || shop_item == 0x22))) { - ride->price_secondary = price; - window_invalidate_by_number(WC_RIDE, count); + for (uint8 rideId = 0; rideId < 0xFF; rideId++, ride++) { + // Unplaced rides have a type of NULL + if (ride->type == RIDE_TYPE_NULL) + continue; + + rideEntry = get_ride_entry(ride->subtype); + + if (ride->type != RIDE_TYPE_TOILETS || shop_item != 0x1F) { + if (rideEntry->shop_item == shop_item) { + ride->price = price; + window_invalidate_by_number(WC_RIDE, rideId); } } - count++; - ride++; - rideEntry = get_ride_entry(ride->subtype); + else { + ride->price = price; + window_invalidate_by_number(WC_RIDE, rideId); + } + // If the shop item is the same or an on-ride photo + if (rideEntry->shop_item_secondary == shop_item || + (rideEntry->shop_item_secondary == 0xFF && + (shop_item == 0x3 || shop_item == 0x20 || shop_item == 0x21 || shop_item == 0x22))) { + + ride->price_secondary = price; + window_invalidate_by_number(WC_RIDE, rideId); + } } } } diff --git a/src/windows/ride.c b/src/windows/ride.c index 5d9ab4add9..4355ee7070 100644 --- a/src/windows/ride.c +++ b/src/windows/ride.c @@ -2819,7 +2819,7 @@ static void window_ride_mode_tweak_increase(rct_window *w) uint8 increment = ride->mode == RIDE_MODE_BUMPERCAR ? 10 : 1; uint8 newValue = ride->operation_option + increment; - if (newValue < maxValue) { + if (newValue <= maxValue) { window_ride_mode_tweak_set(w, newValue); } }