Commit Graph

92 Commits

Author SHA1 Message Date
Gymnasiast c158854a7f
Move Park into namespace, add other park-related things to struct 2024-04-04 18:14:27 +02:00
Harry Hopkinson 8a6de886be
Move awards to GameState_t (#21601) 2024-03-14 18:16:33 -03:00
Harry Hopkinson 6deac11916 Move gTotalRideValueForMoney to GameState_t 2024-02-08 09:39:28 +00:00
Harry Hopkinson 11ae8247bd
Move gNumGuestsInPark to GameState_t (#21295)
* Move gNumGuestsInPark to GameState_t

* Replace GetGameState() with gameState
2024-01-28 19:17:43 -03:00
Hielke Morsink f85cac627d
#21193: Move gParkRating to GameState_t 2024-01-23 00:11:34 +01:00
Hielke Morsink 13351d996e #21193: Move gParkFlags to GameState_t, refactor uses
Also changed a few instances where GetGameState was called inside the same function.
The change in Peep.cpp is needed because of a function conflict. FormatStringID exists both in the global and in the OpenRCT2 namespace.
2024-01-22 16:31:35 +01:00
James103 1d8dc111f1
Replace 2023 with 2024 in copyright headers (#21139)
Replace all instances of the year 2023 with 2024 in all copyright headers
2024-01-01 12:52:28 +01:00
Aaron van Geffen d425e0a8bb Remove const qualifier from constexpr statements 2023-06-24 11:45:26 +02:00
Hielke Morsink 917c091e6b
Rename snake_case functions in OpenRCT2/marketing folder 2023-01-17 23:13:39 +00:00
Michael Steenbeek bb55c6ce66
Remove loadsasnakes (#19192)
* Rename snake_case methods in scenario folder

* Rename snake_case methods in title folder

* Rename snake_case methods in object folder

* Rename snake_case methods in platform folder

* Rename snake_case methods in windows folder

* Rename tile_inspector.h to TileInspectorGlobals.h

* Rename snake_case methods in ui/windows folder
2023-01-17 19:46:55 +00:00
Stephan Spengler 31ea968480
Change openrct2/ride methods to UpperCamelCase, part 2 2023-01-17 17:42:29 +01:00
Stephan Spengler 76b918e7ed
Change openrct2/ride methods to UpperCamelCase, part 1 2023-01-17 01:32:54 +01:00
Hielke Morsink 6dafbbfb65
Rename global window functions to TitleCase (#19167) 2023-01-16 20:13:42 +00:00
Gymnasiast 8d659a5e2f
Pass rct_ride_entry as reference 2023-01-11 17:35:01 +01:00
Michael Steenbeek 412bf8f8be
Use ride references instead of pointers 2023-01-07 14:02:18 +01:00
73 bf3cc83a7a
Allow 4 active awards for more than 1 month at a time 2023-01-02 19:38:29 +00:00
James103 73738bbdc8
Replace 2022 with 2023 in copyright headers
Replace all instances of the year 2022 with 2023 in all copyright headers
2023-01-01 11:58:01 +01:00
Hielke Morsink 31dd4bf604
Use lower-case u integral suffix 2022-10-29 16:33:05 +02:00
Hielke Morsink 97a7fcc110
Consistently use literal suffix in upper-case 2022-10-29 16:28:53 +02:00
Hielke Morsink 89fa8d8052
Rename public notification config data members 2022-10-16 21:46:06 +02:00
Duncan 5dba30778d
Code style: Remove more snakes from the park, maphelper, scenery. (#18222) 2022-10-08 06:56:17 -03:00
73 b9e677945d
Replace 20XX with 2022 (#18158)
* Replace 2020 with 2022

Replace all 2020 headers with 2022

* replace other years with 2022

add missing years
2022-10-01 08:42:14 +01:00
Hielke Morsink 7f29e4e39c
Make `rct_windowclass` strong type `WindowClass`
This already revealed some places where implicit conversions were done, including some where its use was nonsense (MouseInput.cpp).
The changes to the Intent class were necessary to keep things working, and this splits things up more neatly.
2022-08-21 18:38:25 +02:00
Michael Steenbeek a7e66535d9
Change ‘restroom’ to ‘toilet’ in the code 2022-08-06 14:33:37 +00:00
frutiemax 76104cbbee
Use RIDE_TYPE_FLAG_IS_TOILET 2022-08-06 15:00:52 +02:00
Gymnasiast d3fd31c611
Rename rct_string_id to StringId 2022-07-31 22:30:13 +02:00
Geoff Banh 85baa6f7ca Fix #14093: Replace MONEY macro with user defined literal 2022-03-29 07:23:35 -03:00
Duncan 5157b57a15
OpenRCT2 Limits (#16088)
* Move over max rides to limits file

* Move max stations to limits file

* Move over max inversions, golf holes, helices, custhistsize

* Move over max trains per ride

* Bring over Max cars per train and max circuits per ride

* Port over NumColourSchemes and max vehicle colours

* Fix compilation

* Move over max awards

* Move over max peep spawns and park entrances

* Fix rebase issues

* Remove future work

* Switch style

* Update copyright
2022-02-01 20:59:48 +00:00
Silent 8064ef288b
Fix money overflow in scenario_entrance_fee_too_high_check and more 2022-01-31 23:06:54 +01:00
ζeh Matt 269673e3aa
Profiler update (#16463)
* Add more functions to be profiled

* Add isEnabled method to Profiler scripting interface

* Bump up scripting version

* Apply review suggestions
2022-01-29 15:29:08 +02:00
Duncan 8e1fd54c5a
Rename type and add static assert from review (#16247) 2021-12-15 05:56:43 +00:00
Duncan 3deaa1af2e
Fix #16197: Park award time and type accidentally swapped 2021-12-12 11:20:17 +01:00
Duncan 6dc1efde82
Make awards a vector (#16134)
* Make awards a vector

* Fix compiler and use one less branch
2021-12-11 14:45:50 +00:00
ζeh Matt 9f23449ffb
Move Staff/Guest/Peep to entity 2021-11-26 18:26:19 +02:00
Peter Schussheim 0495b265c0
Refactor unchecked std::array subscript operator 2021-11-25 10:13:20 +01:00
Duncan 3f19d6f7d7
Split Peep header Guest into separate header (#15810)
* Move guest functions and classes to guest header

* Reduce includes of Peep.h
2021-10-28 21:38:23 +01:00
Hielke Morsink 9dd20ec619
Improve array formatting
For most of these cases, adding a trailing comma to the array block makes clang-format put each item on a new line, and clang-format exception blocks could be reduced where clang-format does not handle them properly.
2021-10-17 18:21:45 +02:00
Jamie Quigley 4f6d0a00fd
Refactor RIDE_STATUS to use strong enum (#14840)
* Refactor RIDE_STATUS to use strong enum

* Change platform-specific code to match RIDE_STATUS refactor

* Re-added check for valid RideStatus value

* Fixed errors in "g2" build target

* Use EnumValue instead of static_cast<uint8_t>

* Revert rct{1,2}.h to use uint8_t.

* Fix formatting

* Reverted from constexpr variable to additional enum variant

* Fix formatting
2021-06-10 07:09:58 +01:00
Duncan 4d152d97d2
Use entity list size rather than distance (#14343)
After the refactors with the entity lists we no longer require to walk the whole entity list to get the number of entries.
2021-03-17 08:55:10 +00:00
Duncan 6ec379cd0e
Split Entity Lists by Entity type (#14326)
* Make initial changes to add entity type

* Make further corrections

* Revert header changes

* Fix mistakes
2021-03-16 11:18:06 +00:00
Gymnasiast 56399e7188
Use the RTD instead of ride_type_has_flag() 2021-02-24 14:10:30 +01:00
Duncan 354a131892
Use specific type for peep list access (#13831)
* Use specific type for peep list access

* Simplify calculation further
2021-01-19 17:57:22 +00:00
Jamie Quigley 03a9ac9f56
Close #12387: Refactored PeepThoughtType to use strong enum. (#13541) 2020-12-07 19:48:36 +00:00
Łukasz Pękalski 3de233c796
Close #12395: Refactor PeepItem to use strong enum (#13311)
* refactor: integrated PEEP_ITEM into SHOP_ITEM

* refactor: converted merged enum to flag

Only former occurrences of PEEP_ITEM

* cleanUp: code cleaned after merging

* refactor: converted ShopItem to strong enum

code reformatting

* refactor: ShopItem enum items renamed

code formatted

* refactor: new getter and setter functions for Item...Flags

* refactor: replaced all occurrences of ItemStandardFlags

with appropriate getter and setter functions.
COMPARE_FIELD macro needs to be commented out or the flag has to stay public.

* refactor: all occurrences of ItemExtraFlags replaced

with proper function calls. COMPARE_FIELD macro issue not resolved.

* refactor: introduced new variable for unified item flags

* refactor: adapted accessor functions

accessor functions were modified to accommodate both standard and extra ShopItem flags

* refactor: ItemExtraFlags accessor functions are replaced

with general functions

* refactor: reverted to original uint32_t flag variables

* refactor: implemented suggested changes

* refactor: integrate additional comments

* refactor: incorporated requested changes

* refactor: incorporated requested changes

added static_cast<PeepThoughtType> in lines 1572 and 1590
2020-12-03 21:15:59 -03:00
Ben Johnston 147daa8f01
Refactor PARK_AWARD to use strong enum (#13017)
* Refactor PARK_AWARD to use strong enum
2020-09-28 21:48:03 -03:00
Matt 38e03ae45d
Use the Formatter for News items 2020-09-17 22:14:36 +03: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
Michael Steenbeek be0123decb
Fix #12611: Bad check for pay-per-ride ability 2020-08-10 18:56:06 +02:00
pizza2004 d217dfa9b9
Refactor NewsItem into namespace and Pascal Case (#12511) 2020-08-02 23:14:00 -03:00