Commit Graph

104 Commits

Author SHA1 Message Date
Tulio Leao 3b632fcf95 Rename Peep::favourite_ride to FavouriteRide 2020-05-13 23:06:40 -03:00
TomasZilinek 9fde6a74c3
Close #11561: Use ScreenCoordsXY in gfx_draw_string()
* Fix #11572 create gfx_draw_string() overload

created the overload and changed all calls of the old function to the new (using const ScreenCoordsXY&)

...
2020-05-10 09:49:15 -03:00
Gymnasiast f8aeb70398
Apply review requests 2020-05-09 18:07:16 +02:00
Gymnasiast 43556d2dec
Remove ifdefs for LEFT_CLOSEBOX - for now 2020-05-09 18:07:16 +02:00
Gymnasiast 9e4c664944
Replace defines with constexpr 2020-05-09 18:07:16 +02:00
Gymnasiast 96fe3d3b3c
Make WINDOW_SKELETON take a title, height and width 2020-05-09 18:07:16 +02:00
tassaron2 559ede5d14
Add compile option to move close box to the left 2020-05-09 18:07:16 +02:00
Ted John 7b8ffdb865 Refactor peep.intensity into new strict struct 2020-05-09 12:37:51 +01:00
Ted John d34dec9c27 Create ZoomLevel struct to add two new zoom levels 2020-03-23 15:54:03 +00:00
Gymnasiast 7759b54c2f
Make PeepPickupAction *actually* take a CoordsXYZ 2020-03-07 21:34:04 +01:00
Gymnasiast 8883f428ba Clean up window vars 2020-03-05 08:03:38 -03:00
Tulio Leao 724a6d4dcf Make rct_window use ScreenCoordsXY 2020-03-02 20:51:01 -03:00
Tulio Leao 87f724d038 Use Coords objects for viewport_create() 2020-03-02 20:49:59 -03:00
Tulio Leao 9bcd20e0e6 Prefer const ref to send ScreenCoordsXY over 2020-02-29 08:25:48 -03:00
Duncan b8b539c16e
Modify next_x/y/z to become a CoordsXYZ (#10680)
* Modify next_x/y/z to become a CoordsXYZ

Should be further scope for refactoring from this.

* Make suggested changes

* Fix default construct issues
2020-02-11 22:01:14 +00:00
Tulio Leao 201d13577e Use CoordsXY for footpath_get_coordinates_from_pos() 2020-01-12 22:20:29 -03:00
Tulio Leao 47935288d0 Remove raw coordinates overload of get_map_coordinates_from_pos 2019-11-25 17:45:02 -03:00
Tulio Leao fe3d6f6faf Use ScreenCoordsXY for scroll_mouse* functions 2019-11-14 08:40:40 -03:00
Tulio Leao 5e888747de Use mapCoords instead of ScreenCoords 2019-11-12 20:13:14 -03:00
Tulio Leao 892c084cd8 Use ScreenCoordsXY for windows/Footpath 2019-11-11 23:10:51 -03:00
Tulio Leao afc14183e7 Use ScreenCoordsXY for tool_* functions 2019-10-29 19:02:58 -03:00
Matt cc6321048f
Refactor window_invalidate to use rct_window::Invalidate 2019-08-11 17:22:00 +02:00
Matt 2053ecb688
Refactor window_scroll_to_viewport to use rct_window::ScrollToViewport 2019-08-11 17:22:00 +02:00
Ted John 93789b9034
Add nullptr checks for get_ride in libopenrct2ui (#9795) 2019-08-09 08:06:25 +01:00
Ted John 414b53b56d Remove ride classifications 2019-08-04 16:43:50 +01:00
Ted John a3fe00f0a3 Refactor ride list to a manager with iterator 2019-08-04 16:43:50 +01:00
Ted John 40d49b93d3 Do not use user strings for peep names 2019-07-29 19:18:16 +01:00
Ted John 3f45976009 Fix openrct2ui errors 2019-07-29 19:18:16 +01:00
Ted John 3155c661fa Refactor format peep action 2019-07-29 19:18:16 +01:00
Ted John 6fff2079f9 Refactor ride name to dynamic args and std::string 2019-07-29 19:18:16 +01:00
Ted John 5733d666b3 Do not store park name as a user string 2019-07-21 11:33:15 +02:00
duncanspumpkin b896f07687 Add PeepPickupAction
Move Guest and Staff pickup to the new game action. Rework the game
action so that only one game action is required for the two game
commands. Remove the final game command with a callback.
2019-06-20 19:34:02 +01:00
nexgenration 46889b5381 Implement #9231: Add sprite_index to Guest Debug Tab 2019-05-27 22:39:03 +02:00
nexgenration 6b232f7e53 Fix#9197: Peep insert new thought (#9230)
Improve the readability of the codebase by moving functions into the relevant structures.
- Change name of peep_insert_new_thought to InsertNewThought.
- Update InsertNewThought definition to Guest::InsertNewThought.
2019-05-18 09:47:25 +01:00
Ted John a22f0a53fb Use localised strings for guest debug tab 2019-05-04 21:48:02 +00:00
Ted John f50695fc9b Refactor guest window resize 2019-05-04 16:23:29 +00:00
Ted John a90a86562d Refactor guest widget lists 2019-05-04 15:01:51 +00:00
Ted John 7c2708746e Re-draw debug tab every tick 2019-05-04 14:53:25 +00:00
Ted John c13bd04954 Refactor invalidate methods 2019-05-04 14:40:45 +00:00
Ted John 1d296242b4 Improve text colour 2019-05-04 14:09:15 +00:00
Ted John b4a2a94520 Fix build 2019-05-04 14:08:37 +00:00
Richard Fine 480f19c0c6 Add parens to fix operator precedence issue
I missed one... thankfully the CI did not.
2019-05-04 14:08:37 +00:00
Richard Fine 9bb68a7151 Pull window width into temporary variable
As suggested in review, it's a little easier to read this way.
2019-05-04 14:08:37 +00:00
Richard Fine b714f7b0e2 Use constexpr instead of const
For a static constant integer value, it's stylistically clearer to use constexpr instead of const. The resulting variable is implicitly const, but is also guaranteed to have a compile-time-computable value.
2019-05-04 14:08:37 +00:00
Richard Fine 97bcc53637 Eliminate itoa and use correct format specifiers
Use snprintf instead of _itoa as it's not available on all platforms. Also change the format specifies for unsigned variables to %u instead of %i, to be more correct...
2019-05-04 14:08:37 +00:00
Richard Fine 397b044588 Use safe_strcat instead of strcat_s
strcat_s is not available on all platforms, and we have a utility in the codebase that does basically the same thing already.
2019-05-04 14:08:37 +00:00
Richard Fine cfda3fb8f7 Use sizeof(buffer) instead of hardcoded size
Use sizeof(buffer) instead of repeating 4096 in a bunch of places. Also, 4096 was maybe a bit overkill, drop it down to 512 instead.
2019-05-04 14:08:37 +00:00
Richard Fine 8bf72ceadb More peep pathing info
Show more peep debug data in the Guest debug tab, mostly to help with understanding pathfinding behaviour.
2019-05-04 14:08:37 +00:00
Richard Fine 7300a38ce6 Show peep coordinates in debug tab
As a first debug stat to show, display a peep's current coordinates in the debug tab
2019-05-04 14:08:37 +00:00
Richard Fine 70c61d5ac6 Fix guest window width for debugging tab
Introduce a named constant for the width of a tab in the Guest window, and touch the places that set the window width to add it to the minimum window width when the debugging tab is enabled, so that the tab doesn't render off the side of the window.
2019-05-04 14:08:37 +00:00