1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-26 16:24:35 +01:00
Commit Graph

320 Commits

Author SHA1 Message Date
rpstester
f7348b1f06 Close #12389: Refactor PeepSittingSubState (#12908)
* Refactor PeepSittingSubState

* Fix formatting
2020-09-14 20:11:17 +01:00
ryan-bello
cc2bb33892 changed enum STAFF_TYPE to strong enum StaffType, moved it to Peep.h 2020-08-17 22:59:02 -04:00
ryan-bello
54a33cbde8 renamed StaffType to AssignedStaffType 2020-08-17 20:16:09 -04:00
Arran Ireland
4de58e1fd4 Close #12440: Refactor VEHICLE_STATUS to use strong enum (#12606)
* Close #12440: Refactor VEHICLE_STATUS to use strong enum

* Fix code formatting for VEHICLE_STATUS refactoring

* Refactor VehicleStatus enum to be inside Vehicle

This commit moves VehicleStatus inside Vehicle,
renamed as Status.
2020-08-09 06:24:25 +01:00
Łukasz Pękalski
399e0abe2e Close #12497: Remove extra SPRITE_INDEX_NULL checks (#12601) 2020-08-08 09:12:52 -03:00
pizza2004
d217dfa9b9 Refactor NewsItem into namespace and Pascal Case (#12511) 2020-08-02 23:14:00 -03: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
Sidney
97d74e142e Close #12441: Refactor VEHICLE_TRACK_SUBPOSITION to use strong enum (#12550) 2020-08-02 07:50:07 +01:00
Duncan
c6e26267a4 Reduce the use of GET_VEHICLE (#12494)
* Start removing GET_VEHICLE macro use

* Further work

* Remove further GET_VEHICLE's

* Further removal of GET_VEHICLE

* Remove the last of GET_VEHICLE

* Fix testpaint

* Fix nullptr deref

* Make review changes

Also swapped in helper functions and used a standard patern for iterating the train cars

* Further simplify loops for train cars
2020-07-31 07:48:27 +01:00
Tulio Leao
63f683853e Merge pull request #12479 from pizza2004/news-enum
Refactor NewsItem to use strong enums
2020-07-28 18:21:45 -03:00
pizza2004
cee7f8d34c Close #12397: Refactor NEWS_ITEM_* to use strong enum 2020-07-28 12:54:18 -06:00
Duncan
8a378ad236 Remove uses of GET_PEEP macro and replace with GetEntity (#12467)
* Use TryGetEntity and GetEntity instead of macro

* Use GetEntity for ui guest window

* Remove final GET_PEEP macro uses

* Fix remaining issues
2020-07-26 17:42:02 +01:00
Matt
fa2bd4cad6 Refactor PeepType to use strong enum 2020-07-25 11:54:37 +02:00
frutiemax
f549698e96 Close #12338: Remove goto from Tick128UpdateGuest (#12367) 2020-07-25 07:16:40 +01:00
Michael Steenbeek
5c411390bd Fix #12226: Crash in FindVehicleToEnter (#12310) 2020-07-18 23:54:55 +02:00
Gymnasiast
d703768d5d Use old ride types in RideTypesBeenOn 2020-07-17 00:19:49 +02:00
Gymnasiast
e8d6383f57 Clean up voucher arguments 2020-07-07 21:13:40 +02:00
Gymnasiast
65fa08ef35 Clean up GuestHeadingToRideId 2020-07-07 21:13:10 +02:00
duncanspumpkin
e51bbeed23 Convert SPRITE_LIST to an enum class 2020-07-04 07:38:11 +01:00
TomasZilinek
f08206a5d0 Fix #11963 - Refactor Peep::OutsideOfPark (#12060)
* Fix #11963 - Refactor Peep::OutsideOfPark

Changed the definition of Peep::OutsideOfPark from uint8_t to bool and refactored all its occurences in code accordingly.

* Fix #11963 - Refactor Peep::OutsideOfPark

One forgotten instance of Peep::OutsideOfPark occurrence

* Fix #11963 - Refactor Peep::OutsideOfPark

Fix code according to a review suggestion.
2020-06-28 08:39:30 +01:00
frutiemax
6e47385b90 Part of #11389 : in peep class, FormatTo* use Formatter class (#12035) 2020-06-23 14:52:08 +01:00
Tulio Leao
f6dae982a6 Make MoneyEffect::CreateAt use CoordsXYZ 2020-06-21 14:32:01 -03:00
Tulio Leao
40a7dfbb24 Make litter_create use CoordsXYZD 2020-06-21 14:32:01 -03:00
Tulio Leao
f329644dd5 Make sprite_misc_explosion_flare_create use CoordsXYZ 2020-06-21 14:00:37 -03:00
Tulio Leao
2e31a7d64d Make sprite_misc_explosion_cloud_create use CoordsXYZ 2020-06-21 13:58:13 -03:00
Tulio Leao
d5c7063214 Make create_balloon use CoordsXYZ 2020-06-21 13:43:42 -03:00
Hudson Oliveira
28c9ddd706 Part of #9473: Create Vehicle::GetRideEntry (#12003) 2020-06-20 00:25:40 -03:00
Michael Steenbeek
e2b187c24a Merge pull request #11921 from duncanspumpkin/CreateSprite6
Entity List Iterator
2020-06-17 21:28:36 +02:00
Gymnasiast
9e702d9e01 Replace 'Bathroom' with 'Toilet' 2020-06-17 18:12:13 +02:00
Michael Steenbeek
97b99122de Merge pull request #11962 from Gymnasiast/refactor/rtd-rtd-rtd
Move RideNaming, RideHeights and max mass to RTDs
2020-06-17 13:06:26 +02:00
Michael Steenbeek
ba5e730c06 Rename UpdateFlag to HasUpdateFlag; refactor to bool (#11966) 2020-06-17 00:05:37 -03:00
duncanspumpkin
6ed17b4ff9 Remove FOR_ALL_PEEPS/GUESTS/STAFF macros
Replaced with an EntityList iterator

Fix formatting

Fix nullptr issues
2020-06-16 20:27:44 +01:00
duncanspumpkin
c45a0536eb Use new class 2020-06-16 20:27:40 +01:00
duncanspumpkin
a30374d200 Use new iterator
Fix mac builds

Fix minor mistake

Fix vehicle loops
2020-06-16 20:25:47 +01:00
duncanspumpkin
133d8c4a0a Implement GetSprite and use it in a number of places
This will eventually replace all of the get_sprite and try_get_sprite calls

Further use of GetSprite

Use GetSprite in all remaining easy to use functions

Correct formatting

Rename GetSprite to GetEntity

Make suggested changes

Remove const to allow for building

Fix crashes due to next sprite
2020-06-16 20:25:03 +01:00
duncanspumpkin
904e6c6987 Implement GetSprite and use it in a number of places
This will eventually replace all of the get_sprite and try_get_sprite calls

Further use of GetSprite

Use GetSprite in all remaining easy to use functions

Correct formatting

Rename GetSprite to GetEntity

Make suggested changes

Remove const to allow for building

Fix crashes due to next sprite
2020-06-16 20:21:56 +01:00
Gymnasiast
9cf12e763d Move RideHeights and max mass to RTDs 2020-06-16 20:57:55 +02:00
Gymnasiast
140f2d6922 Rename rct_ride_data_5 and its fields to RideHeights 2020-06-16 20:17:07 +02:00
Tulio Leao
e54a3d89f2 Rename some Peep member variables to use TitleCase (#11931)
* Rename Peep::destination_tolerance to use TitleCase

* Rename Peep::destination_y to use TitleCase

* Rename Peep::destination_x to use TitleCase

* Rename Peep::trousers_colour to use Title Case

* Rename Peep::tshirt_colour to use TitleCase

* Rename Peep::no_of_rides to use Title Case

* Rename Peep::staff_type to use TitleCase

* Rename Peep::type to use TitleCase

* Rename Peep::sprite_type to use TitleCase

* Rename Peep::sub_state to use TitleCase

* Rename Peep::state to use TitleCase

* Rename Peep::outside_of_park to use TitleCase

* Rename Peep::next_flags to use TitleCase

* Rename Peep::name to use TitleCase

* Rename Peep::NoOfRides to GuestNoOfRides

* Rename Peep::Type to AssignedPeepType

* Rename Peep::GuestNoOfRides to GuestNumRides
2020-06-14 06:31:08 +01:00
Michael Steenbeek
8f29810e04 Move RideData4 to RideTypeDescriptors (#11939) 2020-06-13 11:29:00 +01:00
hdpoliveira
55bb2eaec9 Change all invalidate_sprite_2(Vehicle*) to Vehicle->Invalidate() (#11935) 2020-06-11 20:42:11 +01:00
Tulio Leao
5d57012390 Rename Peep::var_37 to Var37 2020-06-08 23:47:45 -03:00
Tulio Leao
a993ad8408 Rename Peep::energy to Energy 2020-06-08 23:34:35 -03:00
Tulio Leao
1c59cc2aae Rename Peep::energy_target to EnergyTarget 2020-06-08 23:32:22 -03:00
Tulio Leao
92fbb9fc04 Rename Peep::happiness to Happiness 2020-06-08 23:30:27 -03:00
Tulio Leao
1b7223462f Rename Peep::happiness_target to use TitleCase 2020-06-08 23:27:47 -03:00
Tulio Leao
e387539802 Rename Peep::nausea to Nausea 2020-06-08 23:25:37 -03:00
Tulio Leao
71dc82e79a Rename Peep::nausea_target to NauseaTarget 2020-06-08 23:21:17 -03:00
Tulio Leao
533695cbe6 Rename Peep::hunger to Hunger 2020-06-08 23:18:12 -03:00
Tulio Leao
aad80d3390 Rename Peep::thirst to Thirst 2020-06-08 23:12:38 -03:00