Commit Graph

249 Commits

Author SHA1 Message Date
Gymnasiast 140e945a7b
Increase network version 2020-10-26 23:13:49 +01:00
Haven Kim ce2f78bd51
Fix #13222 : Vehicle collision causes negative number of passengers
When peep_sprite_remove is called, RemoveFromRide() will decrease ride's num_riders
2020-10-19 23:33:54 +02:00
ζeh Matt 645289f4ec
Rename GameActionResult and use GameActions namespace instead (#13184) 2020-10-14 22:04:39 -03:00
X123M3-256 9681ea4cea
Add "Hybrid Coaster" ride type (#12110)
* Add "Hybrid coaster" ride type

* Add turns

* Add diagonal slopes

* Add bank transitions

* Add diagonal bank transitions

* Add banked turns

* Add sloped turns

* Add sloped bank transitions

* Add sloped banked turns

* Add s bends

* Add helices

* Add barrel rolls

* Add half loops

* Start changing supports to wooden

* Switch diagonals and banked turns to wooden supports

* Finish switching supports to wooden

* Alter default supports for small turns and steep turns

* Split track sprites that were glitching

* Fix incorrect sprite indices on small helices

* Add supports for large flat to steep pieces

* Fix bug with b supports

* Add supports for quarter loops

* Finalize set of track elements

* Fix strange colors when track piece is highlighted

* Update sprites.json

* Add support for corkscrews

* Fix incorrect remap colors and default supports

* Add slope to banked turn transitions

* Add support for preview image in color selection window

* Fix static glitches

* Correct Z offset

* Set segment heights (and fix more static glitches)

* Improve sloped curve supports

* Fix slope to banked turn transitions

* Fix dynamic glitches

* Fix boosters

* Remove corkscrews

* Set ride data and implement ride rating function

* Fix glitches on steep turns and gentle to steep

* Format code

* Add sprites

* Add track color preview image

* Fix formatting

* Add files to MSVC project

* Fix Testpaint

* Revert removal of RIDE_TYPE_50 from GetClassification

* Introduce constant instead of hard coded number

* Fix stray change

* Improve legibility of ride_ratings_calculate_hybrid_coaster()

* Fix comments on byte_97B23C

* Fix two other stray changes

* Fix Xcode project

* Adjust bounding boxes to make clipping behaviour more consistent

* Fix two glitches on medium and large turns

* Address comments from DuncansPumpkin

* Fix incorrect ride ID

* Fix steep turn sprites

* Run PNG images through OptiPNG

* Update changelog

* Fix namespace error

* Use arrays for supports to handle additional elements

* Rename functions to TitleCase and add namespace

* Increment network version

Co-authored-by: Edward Calver <hx010973@reading.ac.uk>
Co-authored-by: tylerleamon <59478575+tylerleamon@users.noreply.github.com>
Co-authored-by: Gymnasiast <m.o.steenbeek@gmail.com>
Co-authored-by: duncanspumpkin <duncans_pumpkin@hotmail.co.uk>
Co-authored-by: Aaron van Geffen <aaron@aaronweb.net>
2020-10-10 20:27:12 +01:00
Vinicius Sa c6b7893d77
Verify pointer against nullptr before using it
Reported by PVS-Studio (Warning: V1004).

Fix 6/7.

Issue: 12523
2020-10-06 18:21:26 -03:00
Aaron van Geffen 797fe48b0f
Merge pull request #13068 from mwnciau/json-compilation-performance
Fix #13055: Replace includes of Json.hpp in header files with json_fwd.hpp
2020-10-06 01:09:41 +02:00
Simon Jarrett 134371f03c Change includes of nlohmann/json_fwd.hpp to new core/JsonFwd.hpp 2020-10-06 00:16:21 +02:00
Julia Pinheiro 6a76547c5b
Close #12412: Refactor PROMPT_MODE to use strong enum (#13076) 2020-10-02 23:04:59 -03:00
Julia Pinheiro c36ec5c5ce
Close #12425: Refactor SOCKET_STATUS to use strong enum (#13064) 2020-10-01 22:10:51 -03:00
Julia Pinheiro 657106d4c6
Close #12424: Refactor NetworkStatisticsGroup to use strong enum (#13056) 2020-10-01 22:07:48 -03:00
Tulio Leao d01dcea98a Release v0.3.1
- Feature: [#10807] Add 2x and 4x zoom levels (currently limited to OpenGL).
- Feature: [#12703] Add scenario plugin APIs.
- Feature: [#12708] Add plugin-accessible names to all game actions.
- Feature: [#12712] Add TCP / socket plugin APIs.
- Feature: [#12840] Add Park.entranceFee to the plugin API.
- Feature: [#12884] Add BaseTileElement.occupiedQuadrants to the plugin API.
- Feature: [#12885] Add SmallSceneryElement.quadrant to the plugin API.
- Feature: [#12886] Make all scenery placement and remove actions available to the plugin API.
- Feature: [#2350, #12922] Add snow, heavy snow and blizzard to weather types.
- Fix: [#400] Unable to place some saved tracks flush to the ground (original bug).
- Fix: [#5753] Entertainers make themselves happy instead of the guests.
- Fix: [#7037] Unable to save tracks starting with a sloped turn or helix.
- Fix: [#12691] Ride graph tooltip incorrectly used count instead of number string.
- Fix: [#12694] Crash when switching ride types with construction window open.
- Fix: [#12701] Silent NSIS setup flag /S isn't silent, upgrade pop-up appears anyway.
- Fix: [#12737] Space Rings draw the same vehicle 4 times.
- Fix: [#12756] Scenario Editor crashing the game on macOS.
- Fix: [#12764] Rides don't start aged anymore.
- Fix: [#12818] Ride price not ignored in free-rides parks.
- Fix: [#12820] Title menu buttons not invalidating properly
- Fix: [#12845] Deleting ride with active ad campaign creates incorrect notification.
- Fix: [#12857] Incorrect Peep thoughts in imported RCT1 parks.
- Fix: [#12881] Guests' favourite rides are not listed in the guest window.
- Fix: [#12910] Plugin API: getRide sometimes returns null for valid ride IDs.
- Fix: [#12912] Plugin: selectedCell of CustomListView is being ignored on creation.
- Fix: [#12918] Cannot place vanilla TD6 tracks of the Hypercoaster, Monster Trucks, Classic Mini Roller Coaster, Spinning Wild Mouse and Hyper-Twister types.
- Fix: Incomplete loop collision box allowed overlapping track (original bug).
- Improved: [#12806] Add Esperanto diacritics to the sprite font.
- Improved: [#12837] Arabic text is now drawn and shaped correctly on Windows.
- Improved: [#12890] Add stroke to lowercase 'L' to differentiate from capital 'I'.
- Technical: [#12749] The required version of macOS has been lowered to 10.13 (High Sierra).
2020-09-27 17:57:34 -03:00
Duncan da82144bfb
Fix #12944. Mistake from refactor meant formatter optimised away (#12961)
Not sure why it should get optimised away but this will fix the crashes.
2020-09-18 09:25:17 +01:00
Matt b3b9a348c5
Apply review suggestions 2020-09-17 22:16:05 +03:00
Matt ccde06ab0f
Explicitly pass formatter arguments to ShowError and family 2020-09-17 22:14:36 +03:00
Matt 2639349925
Move storage into Formatter class and refactor usage 2020-09-17 22:14:36 +03:00
Simon Jarrett f1bcf20050 Refactor NetworkBase to use new JSON library 2020-09-16 20:18:52 +01:00
Michael Steenbeek 3acbb92074
Merge pull request #12922 from Gymnasiast/LetItSnow2 2020-09-15 18:11:45 +02:00
Tulio Leao c1729c8a87
Merge pull request #12858 from ju-pinheiro/network-strong-enums
NETWORK_PERMISSION and NETWORK_AUTH replaced by strong enums
2020-09-15 08:07:19 -03:00
Gymnasiast a46a21973f
Amend changelog; bump network version 2020-09-14 22:00:54 +02:00
ju-pinheiro 214620951f Close #12421: Refactor NETWORK_AUTH to use strong enum
Replacing enum NETWORK_AUTH with enum class NetworkAuth.
2020-09-10 19:32:28 -03:00
ju-pinheiro 20a8bbc322 Close #12420: Refactor NETWORK_PERMISSION to use strong enum
First approach, instead of a bigger refactor to avoid the need of "static_cast".
2020-09-10 19:32:27 -03:00
Michael Steenbeek bd28b74655
Make all game actions take an ObjectEntryIndex where applicable (#12384)
* Make all game actions take an ObjectEntryIndex where applicable

* Update replays for parameter size change

Co-authored-by: duncanspumpkin <duncans_pumpkin@hotmail.co.uk>
2020-09-09 17:03:20 +01:00
Richard Fine d2d9750a5b Fix #5753: Entertainers make themselves happy instead of the guests
After identifying guests that are near an entertainer, modify the guest's HappinessTarget and TimeInQueue values instead of the entertainer's own values.
2020-09-08 16:40:29 -04:00
chess123mate 83de5fab2a
Fix #12818 - Ride prices not ignored in free-rides parks (#12832) 2020-09-05 11:10:42 -03:00
Ted John fd6fddb61a Improve WSA handling 2020-09-03 22:38:42 +01:00
Nils Caspar 359bbee9f5
Fix #12845: Cancel marketing campaigns for demolished rides (#12848) 2020-09-03 18:20:42 -03:00
Julia Pinheiro dafde532af
Close #12426: Refactor NETWORK_READPACKET to use strong enum (#12807)
Replacing enum NETWORK_READPACKET with enum class NetworkReadPacket.
2020-08-31 09:13:15 -03:00
ju-pinheiro e9c3f31422
Close #12423: Refactor NETWORK_SERVER_STATE to use strong enum (#12802)
#12423
2020-08-29 08:05:51 -03:00
Tulio Leao 10aca0fe6e Fix #12764: Rides don't start aged anymore 2020-08-25 08:21:34 -03:00
frutiemax 4165d64e60
Part of #11159: save_for_network returns unique_ptr (#12163) 2020-08-22 18:56:34 -03:00
Simon Jarrett 9fb51c18d4 Fix: Incomplete loop collision box allowed overlap (original bug) 2020-08-18 17:03:35 +01:00
Aaron van Geffen 135cc10b47 Release v0.3.0 2020-08-15 21:13:50 +02:00
ζeh Matt c1076658fc
Merge pull request #12658 from ZehMatt/fix-network-hang
Fix freezes on incomplete packet transmission
2020-08-12 19:00:27 +02:00
Michael Steenbeek d1b193c06d
Fix #11968: Maze height is higher than it should be 2020-08-12 18:33:15 +02:00
Matt ebc2be4cd0 Fix freezes on incomplete packet transmission 2020-08-12 18:11:09 +02:00
Matt 2a9796f2cc Add more guards in network code 2020-08-11 15:56:09 +02:00
ζeh Matt cb38d28b62
Fix #12621: Missing argument for localisation 2020-08-10 14:58:39 +02:00
Matt c16bdb5c69 Fix #11085: Handle player list before game actions during map load 2020-08-08 20:47:34 +02:00
ζeh Matt 765eada18e
Merge pull request #12526 from ZehMatt/win32-cleanup
Win32 and namespace cleanup
2020-08-05 17:18:50 +02:00
Duncan 3533d1734f
Merge pull request #12571 from ZehMatt/network/update-2
Refactor more network code
2020-08-05 15:55:24 +01:00
Matt 83355e35cc Move IStream, MemoryStream, FileStream into OpenRCT2 namespace 2020-08-05 16:29:36 +02:00
Tulio Leao 78053e34d5
Fix #12561: Synchronized coasters not synced (#12572) 2020-08-04 15:51:35 +01:00
Matt 28dcaeae2f Refactor reading/writing packets 2020-08-03 00:36:02 +02:00
Matt 21f63c1010 Pass NetworkCommand type as constructor to simplify code 2020-08-02 22:31:00 +02:00
Matt 313b8a7518 Remove std::unique_ptr and use move semantics instead 2020-08-02 22:08:56 +02:00
Duncan f49bfa777a
Change maze pathfinding to not prefer a direction (#12546)
* Change maze pathfinding to not prefer a direction

* Increment network version

* Update changelog

* Update replays
2020-08-02 08:20:34 +01:00
Michael Steenbeek e0f2aa9b99
Fix: Brakes keep working during "Brakes failure"
This was an error in the original implementation back in 2015.
Thanks to @duncanspumpkin for checking the assembly.
2020-07-30 22:21:19 +02:00
Matt cf1fb9ecff Move some types into NetworkTypes.h 2020-07-30 20:29:15 +02:00
Matt 37f6a11a1f Move Network declaration into header and rename to NetworkBase 2020-07-30 20:29:15 +02:00
Renamed from src/openrct2/network/Network.cpp (Browse further)