1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-16 19:43:06 +01:00
Commit Graph

167 Commits

Author SHA1 Message Date
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
Silent
3e64a227e5 Fix Object Selection not freeing the object when unhovering
Fixes a double-free on previews.
2021-10-09 21:48:43 +02:00
Hielke Morsink
6de1868ad8 Use (const) references to widgets where possible
Note: The change from `w->widgets[WIDX_ENTRY_PRICE]` to `entryPriceWidget` is intended.
2021-10-01 15:21:00 +02:00
Hielke Morsink
9dd9b27db4 Make WIDGETS_END constexpr 2021-09-26 11:11:42 +02:00
Hielke Morsink
4b4b3333d6 Remove unnecessary else blocks 2021-09-16 18:31:12 +02:00
Gymnasiast
bdab3219cb Modify object loading for JSON-only objects 2021-09-15 11:28:39 +02:00
Michael Steenbeek
6ffb03dde0 Add icon for path railings tab 2021-09-13 09:29:46 +02:00
Ted John
5f853df1fd Remove gS6Info 2021-08-02 20:38:02 +02:00
Michael Steenbeek
1ea9bbbb1b Fix formatting 2021-07-29 13:32:48 +02:00
Kane
dbdca55645 Fix #14316: Closing the Track Designs Manager window causes broken state
When exiting the Track Design Manager window the user was placed into the scenario editor in a broken state.
User is now returned to the main menu when the window is closed.
2021-07-29 12:44:24 +02:00
Hielke Morsink
e54dc7e466 Use consistent left-shift notation for widgets (#14956) 2021-06-26 14:23:15 +02:00
Gymnasiast
b214a9fd97 Show what a stall sells in Object Selection 2021-05-27 19:54:44 +02:00
Gymnasiast
1d693f9751 Fix display of number of items in scenery group 2021-05-27 19:54:44 +02:00
Gymnasiast
f2ac658935 Show tracks list of music styles in Object Selection 2021-05-27 19:53:52 +02:00
Michael Steenbeek
9ee3c81768 Merge pull request #14397 from Gymnasiast/refactor/hardcoded-terrain-constants
Remove hardcoded terrain style constants from RCT1 and MapGen
2021-03-31 20:18:12 +02:00
Tulio Leao
bb8c275df6 Remove raw coords gfx_fill_rect_inset overload 2021-03-29 09:34:11 -03:00
Gymnasiast
b3bbdcbfd5 Remove hardcoded terrain style constants from RCT1 and MapGen 2021-03-27 17:34:10 +01:00
Michael Steenbeek
a5a63f839a Allow passing ImageId into gfx_draw_sprite() 2021-03-23 11:58:09 +01:00
Gymnasiast
7fd049c22e Remove last remnants of gCurrentFontSpriteBase 2021-02-28 00:26:53 +01:00
Gymnasiast
c40701d997 Make gfx_draw_string() take a TextPaint argument 2021-02-28 00:26:20 +01:00
Gymnasiast
3e536e2711 Change gfx_draw_string_*_wrapped() to DrawTextWrapped() 2021-02-28 00:23:01 +01:00
Gymnasiast
e2ebc9d43b Replace gfx_draw_string_left() with DrawTextBasic() 2021-02-28 00:23:00 +01:00
Gymnasiast
4d9c278ebc Unify calls to DrawTextBasic 2021-02-28 00:23:00 +01:00
Gymnasiast
2477933c51 Turn font sprite base into a strong enum 2021-02-28 00:23:00 +01:00
Gymnasiast
44d0e77afb Make all access to RTD table use the bounds checking function 2021-02-26 10:01:00 +01:00
Basssiiie
813b111710 Fix #11912: Update active palette on selection 2021-01-18 21:25:57 +01:00
Tulio Leao
221aa8cece Close #12453: Refactor RCT2_EDITOR_STEP to strong enum 2020-12-23 20:07:53 -03:00
Richard Qian
84d5fde6bb Remove the max limit of 4 rides from the Track Designer 2020-12-20 13:08:36 -06:00
Adam
f09b14ef2b Split actions hpp files into separate h and cpp files (#13548)
* Split up SmallSceneryPlace/Remove

Added undo function for Remove Scenery

* Refactor: Balloon and Banner actions hpp=>h/cpp

* Refactor: rename all action *.hpp files to *.cpp

This is preparation for separation in later commits. Note that without
the complete set of commits in this branch, the code will not build.

* Refactor Clear, Climate, Custom, and Footpath actions hpp=>h/cpp

* VSCode: add src subdirectories to includePath

* Refactor Guest actions hpp=>h/cpp

* Refactor Land actions hpp=>h/cpp

* Refactor LargeScenery actions hpp=>h/cpp

* Refactor Load, Maze, Network actions hpp=>h/cpp

* Refactor Park actions hpp=>h/cpp

* Refactor/style: move private function declarations in actions *.h

Previous action .h files included private function declarations with
private member variables, before public function declarations. This
commit re-orders the header files to the following order:
- public member variables
- private member variables
- public functions
- private functions

* Refactor Pause action hpp=>h/cpp

* Refactor Peep, Place, Player actions hpp=>h/cpp

* Refactor Ride actions hpp=>h/cpp

* Refactor Scenario, Set*, Sign* actions hpp=>h/cpp

* Refactor SmallScenerySetColourAction hpp=>h/cpp

* Refactor Staff actions hpp=>h/cpp

* Refactor Surface, Tile, Track* actions hpp=>h/cpp

* Refactor Wall and Water actions hpp=>h/cpp

* Fix various includes and other compile errors

Update includes for tests.
Move static function declarations to .h files
Add explicit includes to various files that were previously implicit
(the required header was a nested include in an action hpp file, and the
action .h file does not include that header)
Move RideSetStatus string enum to the cpp file to avoid unused imports

* Xcode: modify project file for actions refactor

* Cleanup whitespace and end-of-file newlines

Co-authored-by: duncanspumpkin <duncans_pumpkin@hotmail.co.uk>
2020-12-10 06:39:10 +00:00
Łukasz Pękalski
4adf745237 Close #12403: Refactor FILTER_PALETTE_ID to use strong enum (#13273) 2020-12-05 15:13:59 -03:00
Ted John
517e964975 Fix title screen and object manager text issues 2020-11-27 18:54:58 +00:00
ffrogman
7ed1804e61 Fix #12410: Refactor WINDOW_WIDGET_TYPES to use strong enum (#13453)
* Fix #12410: Refactor WINDOW_WIDGET_TYPES to use strong enum
2020-11-27 00:14:20 -03:00
Łukasz Pękalski
fc4ad82ac1 resolve: integrated changes from comments 2020-11-11 16:08:39 +01:00
Łukasz Pękalski
7648feeba2 Close #12427: Refactor OBJECT_TYPE to use strong enum 2020-11-11 16:07:01 +01:00
Łukasz Pękalski
832fd69822 refactor: changed ObjectType enum to strong enum
code does not compile yet
2020-11-11 16:07:01 +01:00
Łukasz Pękalski
6e5105ab3b refactor: ObjectType to use strong enum
enum renaming complete
2020-11-11 16:07:01 +01:00
Michael Steenbeek
d8a7219c86 Use new identifier for default objects 2020-11-07 20:28:01 +01:00
Michael Steenbeek
58f099a644 Merge pull request #13286 from tupaschoal/research-refactor
Small research releated refactor
2020-11-07 20:18:18 +01:00
Tulio Leao
19ab8f1211 Use ResearchCategory Enum for ResearchItem 2020-11-07 11:14:55 -03:00
pizza2004
2015acd4c0 Refactor UI/Interface Window to Title Case (#13367) 2020-11-04 04:52:23 +00:00
pizza2004
68bd035f12 Refactor Dropdown to TitleCase (#13352)
* Refactor Dropdown Namespace

* Refactor Dropdown to TitleCase
2020-11-03 08:16:06 +00:00
Haven Kim
8a4df108ba Close #12428: Refactor OBJECT_SOURCE_GAME to use strong enum 2020-10-17 22:27:02 +02:00
Vinicius Sa
711dd00cde Close #13000: Refactor ObjectFactory to use unique_ptr
Employs the smart pointer unique_ptr for safer memory management.

Classes involved:
 - ObjectRepository
 - ObjectManager
2020-10-14 21:56:48 +02:00
Duncan
f28907a87d Rework tooltip to be more logical (#13137) 2020-10-10 10:49:56 -03:00
Matt
091145037e Move the audio code into OpenRCT2 namespace 2020-10-07 00:34:42 +03:00
Aaron van Geffen
d27e14f45b Compact, statically initialized syntax for event lists (#12973) 2020-09-28 20:36:15 +02:00
Duncan
4ec10837a6 Remove Formatter::Common where not required (#12972)
* Remove Formatter::Common where not required

* Remove common from Guest window where possible
2020-09-27 21:09:08 -03:00
Michael Steenbeek
4a79e9305f Replace gfx_draw_string_right() with DrawTextBasic (#12966) 2020-09-18 21:39:00 -03:00
Matt
ccde06ab0f Explicitly pass formatter arguments to ShowError and family 2020-09-17 22:14:36 +03:00
Gymnasiast
d140dd72c6 Remove const void* overload from DrawTextEllipsised() 2020-09-10 18:13:13 +02:00