1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-17 20:13:07 +01:00
Commit Graph

118 Commits

Author SHA1 Message Date
Gymnasiast
eb2b0c1537 Move platform_update_palette() to Drawing.cpp 2022-01-16 13:17:54 +01:00
ζeh Matt
16635b9192 Implement custom BitSet and replace std::bitset 2021-12-12 23:47:17 +02:00
Gymnasiast
5e8a204365 Move ride_get_total_length() to method 2021-12-12 13:00:28 +01:00
Gymnasiast
aa34f0f760 Drop the N postfix 2021-12-11 00:39:39 +01:00
Michael Steenbeek
2d1af0ec42 Replace many GetType() calls with GetTypeN() 2021-12-10 22:43:17 +01:00
ζeh Matt
9f23449ffb Move Staff/Guest/Peep to entity 2021-11-26 18:26:19 +02:00
Duncan
275d565e52 Start splitting up ride.h (#16011)
* Start splitting up ride.h

* Use cstdint instead of common.h
2021-11-26 15:03:14 +00:00
ζeh Matt
7c726e2a0c Fix includes 2021-11-24 16:48:33 +02:00
Cory Sanin
68ee0a7804 Use .park file extension for save_park or autosave (#15957)
Use correct file extension when saving from the console or when performing an autosave. Otherwise .park files are generated with the old .sv6 extension.
2021-11-22 09:41:44 +00:00
IntelOrca
34128dc262 Add new .park save format
Co-authored-by: Gymnasiast <Gymnasiast@users.noreply.github.com>
Co-authored-by: duncanspumpkin <duncanspumpkin@users.noreply.github.com>
Co-authored-by: ZehMatt <Zehmatt@users.noreply.github.com>
Co-authored-by: Broxzier <Broxzier@users.noreply.github.com>
2021-11-21 22:43:22 +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
ζeh Matt
74e8988dd8 Remove scenario ticks and adjust export/import
Co-authored-by: Ted John <ted@brambles.org>
2021-09-23 21:49:09 +03:00
Hielke Morsink
4b4b3333d6 Remove unnecessary else blocks 2021-09-16 18:31:12 +02:00
duncanspumpkin
cdf1c3b1b8 Move s6 into rct2 header 2021-08-26 12:44:26 +01:00
Ted John
5f853df1fd Remove gS6Info 2021-08-02 20:38:02 +02:00
Ted John
70d9c1438e Change most things and formatting to money64 2021-08-01 15:14:42 +02:00
Michael Steenbeek
ba6407f649 Fix #5465: improper types in Objective::CheckGuestsBy() 2021-07-26 21:23:41 +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
duncanspumpkin
98f9f24909 Remove sprite.h includes where possible 2021-05-29 08:54:33 +01:00
Duncan
39fcc5d078 Split up Sprite header (#14764)
* Remove fields from rct_sprite union

* more header fun

* Fix guest include
2021-05-29 06:01:32 +01:00
duncanspumpkin
c345396765 Move duck method into class 2021-05-13 16:09:26 +02:00
Michael Steenbeek
7344b7fbfd Use 16-bit ride_id_t thoughout and raise RIDE_ID_NULL (#14411)
* Replace RIDE_ENTRY_INDEX_NULL with OBJECT_ENTRY_INDEX_NULL

Ride entries are objects like any other, so there is little point having separate constants.

* Use ride_id_t in many more places

* Change RIDE_ID_NULL to 0xFFFF

* Increment network version

* Update replays

Co-authored-by: duncanspumpkin <duncans_pumpkin@hotmail.co.uk>
2021-04-01 16:02:57 +01:00
Maximilian Bottin
6f28914f61 Fix #14296: Allow early scenario completion in multiplayer 2021-03-18 20:30:11 +01:00
Michael Steenbeek
bc2df33b0a Fix #14225: Desync when “allow early scenario completion” is enabled 2021-03-08 20:16:21 +01:00
Michael Steenbeek
b595370648 Fix #13257: Rides w/ exactly the minimum objective length not counted (#13446) 2020-11-23 19:22:16 -03:00
maksimdrachov
1815a094bb Fix #13426: Typo in "repay loan" 2020-11-19 19:45:40 +01:00
Łukasz Pękalski
6e5105ab3b refactor: ObjectType to use strong enum
enum renaming complete
2020-11-11 16:07:01 +01:00
Hielke Morsink
257ada4617 Introduce constant for ticks per month (#13253) 2020-10-20 21:05:27 -03:00
Richard Fine
a1222fa4ca Staff code cleanup (#12907)
* Make UpdateFixing*() methods use const where possible

To make it clearer which steps actually modify the ride being fixed and which do not, pass const Ride* instead of Ride* where possible.

* Extract maximum litter search distance to a constant

* Make peep_update_*() methods return bool

* Use Direction type and helpers where applicable

* Const correctness and other cleanup

Make many functions take a const Peep* / const Staff* to clarify that they do not modify the peep being passed in. Also use the Direction type for some return values, and simplify staff_is_location_on_patrol_edge.

* Use clearer expression of constant value

Co-authored-by: Michael Steenbeek <m.o.steenbeek@gmail.com>

* Convert staff functions to members

* Remove AsStaff const overload

* Use As<Staff>() instead of static_cast

* Simplify direction selection code

* Clean up use of magic constants

Co-authored-by: Michael Steenbeek <m.o.steenbeek@gmail.com>
2020-09-27 21:07:09 -03:00
Matt
38e03ae45d Use the Formatter for News items 2020-09-17 22:14:36 +03:00
Gymnasiast
e23089d255 Make scenario check into member functions 2020-09-09 15:39:07 +02:00
Gymnasiast
6e22eade67 Create Objective struct and use it for global objective 2020-09-09 15:38:03 +02:00
Tulio Leao
efdb7e1a2d Change gDateMonthsElapsed type to int32_t 2020-08-25 19:06:38 -03:00
Michael Steenbeek
68ce06e833 Refactor objective handling in Scenario Editor
This moves some knowledge out of the window and into the main code and also cleans up the window a bit.

This also allows setting the "x guests by the end of year y" goal for no money scenarios, which was not the case previously.
2020-08-12 22:10:47 +02:00
pizza2004
d217dfa9b9 Refactor NewsItem into namespace and Pascal Case (#12511) 2020-08-02 23:14:00 -03:00
pizza2004
cee7f8d34c Close #12397: Refactor NEWS_ITEM_* to use strong enum 2020-07-28 12:54:18 -06:00
Gymnasiast
682add27dd Change ObjectEntryIndex null value to 0xFFFF 2020-07-23 12:45:42 +02:00
Aaron van Geffen
7b5087f057 Update copyright year to 2020 2020-07-21 15:04:34 +02:00
Tulio Leao
2b68610473 Fix #11331: Create constant for failure on ScenarioCompletedCompanyValue (#11332) 2020-04-18 13:46:18 +02:00
Tulio Leao
116bcb5ccb Use named casts on openrct2/(util|windows|scenario|title) (#11146) 2020-04-17 19:45:19 +02:00
Michael Steenbeek
81c6bb26e9 Prepare guest counters for more than 32767 guests (#10989) 2020-03-26 20:02:15 +01:00
Aaron van Geffen
a2f8e8c72b Automatically reset speed to normal upon scenario completion. (#10998) 2020-03-22 23:22:28 +01:00
Gymnasiast
1e6efa6eb4 Extend BannerIndex to 16 bits 2020-02-15 10:37:34 +01:00
Matt
52ee9c6896 Use enum class for ExpenditureType 2019-12-22 20:51:55 +01:00
Matt
07f401baa2 Use unsigned type for scenario_rand results 2019-10-20 00:21:19 +02:00
Matt
365c7c6f51 Use better variable name 2019-10-20 00:21:19 +02:00
Matt
70d37fe8f9 Fix ducks asserting due to invalid position 2019-10-20 00:21:18 +02:00
Matt
7fa41bb82d Implement 'Create Ducks' cheat 2019-10-20 00:21:18 +02:00
ζeh Matt
0b95dcd0d0 Fix #8584: Duck spawn search now uses entire map (#9743) 2019-10-02 22:14:56 +02:00
Michael Steenbeek
a11762b11a Remove old C functions that only call their equivalent
* Remove old C functions that only call their equivalent

* fix formatting
2019-09-22 14:12:49 +02:00