Tulio Leao
335cbc900e
Rename Peep::current_car to CurrentCar
2020-06-08 17:36:34 -03:00
Michael Steenbeek
9ef8d6da42
Convert most remaining C-style casts to C++-style ones ( #11867 )
2020-06-07 23:18:11 +02:00
Ted John
d3f7ec4844
Create new PaletteMap type to replace byte pointers
2020-05-28 20:00:23 +01:00
Michael Steenbeek
d7637cd70f
Replace many C-style casts ( #11720 )
2020-05-11 14:32:56 +02:00
Michał Janiszewski
2323cc1596
Use named casts instead of old-style casts
...
Change prepared with clang-tidy and google-readability-casting check
2020-04-22 17:09:29 +02:00
Aaron van Geffen
34d8572d85
Patch GCC9 in more places.
2020-03-23 17:42:16 +01:00
Ted John
bd0265f1bc
Fix GCC9
2020-03-23 16:37:18 +00:00
Ted John
6e7a7c23c9
Fix odd issues at certain positions of the map
2020-03-23 15:54:03 +00:00
Ted John
d34dec9c27
Create ZoomLevel struct to add two new zoom levels
2020-03-23 15:54:03 +00:00
Michael Steenbeek
8351a0477d
Merge pull request #10854 from tupaschoal/coords-3
...
Increase usage of ScreenCoordsXY on viewport functions and structs
2020-03-05 12:21:04 +01:00
Michael Steenbeek
5e2b1180f8
Fix Viewport.cpp copyright header ( #10874 )
2020-03-05 12:15:51 +01:00
Tulio Leao
d0717c2748
Remove padding from rct_window
2020-03-05 08:03:33 -03:00
Tulio Leao
724a6d4dcf
Make rct_window use ScreenCoordsXY
2020-03-02 20:51:01 -03:00
Tulio Leao
2cfac98342
Make gSavedView use ScreenCoordsXY
2020-03-02 20:51:01 -03:00
Tulio Leao
09fad0ef7f
Change rct_viewport to use ScreenCoordsXY
2020-03-02 20:50:58 -03:00
Tulio Leao
87f724d038
Use Coords objects for viewport_create()
2020-03-02 20:49:59 -03:00
Michael Steenbeek
d395d67b95
Merge pull request #10846 from tupaschoal/const-ref-screencoords
...
Prefer const ref to send ScreenCoordsXY over
2020-03-01 14:17:51 +01:00
Tulio Leao
91c4735917
Revert to copy instead of const-ref for functions that edit content
2020-03-01 00:49:00 -03:00
Tulio Leao
9bcd20e0e6
Prefer const ref to send ScreenCoordsXY over
2020-02-29 08:25:48 -03:00
Tulio Leao
98781e7596
Revert change to commented line
2020-02-23 09:19:45 -03:00
Tulio Leao
1b3f0e9a44
Create ScreenCoordsXY gSavedView from separate x,y variables
2020-02-22 16:01:21 -03:00
ζeh Matt
1272c0c043
Crash using benchspritesort with dimensions not divisible by 32 ( #10743 )
...
Fixes #10740
2020-02-19 21:50:13 +01:00
Matt
0f50697ceb
Fix unused variable warning
2020-02-16 15:50:35 +01:00
Matt
c440b8f918
Fix #10705 : Apply multithreaded rendering to all viewports
2020-02-16 14:06:08 +01:00
Matt
758a7e432f
Use const reference instead of copy for location structures
2020-02-13 11:53:14 +01:00
Michał Janiszewski
1b7639238a
Fix #9559 : benchspritesort is broken after #8481 ( #9590 )
...
* Fix #9559 : benchspritesort is broken after #8481
This takes multithreading into account as well
* Apply review fixes
* Fix detection of newer Google Benchmark (>= 1.5.0)
* Review fix
2020-02-12 22:18:00 +01:00
Michael Steenbeek
d16fbb0cd2
Change ride->overall_view to CoordsXY ( #10673 )
2020-02-08 17:19:59 +01:00
Duncan
d486ac4d3b
Reduce direct usage of LOCATION_NULL ( #10480 )
...
* Reduce direct usage of Location_Null
Ideally we want to refactor these out to use std::optional as much as possible but for now move to using the standard interfaces.
* Remove incorrect AND with LOCATION_NULL
In the original this was a simple comparison to check for negative. Unsure how it ended up as an AND with the negative bit.
2019-12-31 09:01:17 +01:00
Duncan
7a64eb4402
Fix #10470 . Mistake caused by reusing variable names for different functions. ( #10476 )
...
Added in comments to clarify why function is required. Renamed variables again to clarify what they are used for
2019-12-30 12:26:58 +01:00
Tulio Leao
9ec25e85cb
Coords for map_get_tile* ( #10440 )
...
* Make Map::map_get_tile_side() use CoordsXY
* Make Map::map_get_tile_quadrant() use CoordsXY
2019-12-27 12:36:47 +01:00
Duncan
e61401e48c
Fix #10410 : Tile Inspector does not hightlight tile correctly
...
Mistake made when refactoring not passing the error up through the chain and silently working.
2019-12-22 13:59:24 +01:00
Michael Steenbeek
d012c8141b
Merge pull request #10316 from duncanspumpkin/light_fx
...
Make lights work for all rotations.
2019-12-04 14:11:26 +01:00
duncanspumpkin
f964d38e7d
Renable light occlusion
2019-12-01 14:51:14 +00:00
duncanspumpkin
0c6e062d5a
Refactor return value of screen_coord_to_viewport_cord
2019-12-01 09:15:07 +00:00
Tulio Leao
1532ee2b23
Create CoordsXY::ToTileStart() and CoordsXY::ToTileCentre()
2019-11-30 16:47:23 +01:00
Tulio Leao
4537c061d9
Prefer std::optional over LOCATION_NULL on Viewport ( #10297 )
2019-11-29 17:17:01 +01:00
Duncan
b316f447a4
Merge pull request #10285 from tupaschoal/useCoords-get-map-coords
...
Remove raw coordinates overload of get_map_coordinates_from_pos
2019-11-29 09:20:12 +00:00
Tulio Leao
47935288d0
Remove raw coordinates overload of get_map_coordinates_from_pos
2019-11-25 17:45:02 -03:00
duncanspumpkin
0c4fffb2ec
Refactor viewport_adjust_for_map_height to use CoordsXYZ.
2019-11-24 21:37:35 +00:00
Duncan
966ba6b018
Merge pull request #10269 from duncanspumpkin/centre_2d
...
Refactor centre_2d_coordinates to use screenCoords.
2019-11-24 14:28:18 +00:00
duncanspumpkin
d4c15cd774
Refactor centre_2d_coordinates to use screenCoords.
2019-11-20 18:44:03 +00:00
Tulio Leao
f94970b059
Use CoordsXY/ScreenCoordsXY for viewport*_with_z
...
Closes #10268
2019-11-19 18:33:40 -03:00
duncanspumpkin
3b8bf56b71
Use helper function
2019-11-19 11:20:59 +00:00
duncanspumpkin
421107436f
Refactor helper function to take screen coords
2019-11-19 11:20:59 +00:00
duncanspumpkin
1d6a923298
Refactor screen_get_map_xy_with_z to use CoordsXY structs
2019-11-19 11:20:58 +00:00
duncanspumpkin
e4ee91f5ff
Refactor get_map_coordiantes to enforce Coords struct
2019-11-14 20:28:54 +00:00
Duncan
8eb42867dd
Merge pull request #10223 from duncanspumpkin/viewport_refactor
...
Remove global variables from get_map_coordinates_from_pos_window
2019-11-14 20:27:39 +00:00
Tulio Leao
30815f0886
Fix clang-format
2019-11-13 18:28:03 -03:00
Tulio Leao
054bc8e4ca
Receive ScreenCoordsXY and return CoordsXY in Viewport
2019-11-13 18:27:59 -03:00
duncanspumpkin
0af10781f1
Remove unused globals
2019-11-13 19:04:01 +00:00