Aaron van Geffen
7b5087f057
Update copyright year to 2020
2020-07-21 15:04:34 +02:00
Tulio Leao
d10b615eb3
Remove assert on ScreenLine ( #12333 )
...
Code is not always constructing a valid line
2020-07-20 18:49:15 -03:00
Helio Santos
b0a4f2a97e
Part of #12159 : updated get_station_platform to use CoordsXYRangedZ
...
Updated get_station_platform function to use CoordsXYRangedZ. Updated caller(s) accordingly. Implemented constructor for CoordsXYRangedZ that takes a CoordsXYZ as argument.
2020-07-10 10:59:52 -07:00
Tulio Leao
f725fff2da
Clarify CoordsRange-derived interface methods ( #12127 )
2020-07-06 14:42:11 +02:00
Tulio Leao
99b39f04e7
Do not try to force dimensions of a rectangle ( #12115 )
2020-07-03 09:28:30 +02:00
Tulio Leao
b5195f77c4
Reuse Rectangle definitions for ScreenRect and MapRange
2020-06-30 09:44:28 -03:00
Tulio Leao
a86a60cbf5
Extract ScreenRect from Graph for reusability
2020-06-30 09:32:22 -03:00
Tulio Leao
5ce65eb7dc
Create ScreenLine struct
2020-06-30 09:26:42 -03:00
Tulio Leao
70e245a1c3
Add Coords constructor to Map and CoordsRange
2020-06-30 09:12:14 -03:00
Tulio Leao
701f7f6d67
Extract base CoordsRange class from MapRange
...
Enforce MapRange to be rectangle shaped
2020-06-30 09:00:20 -03:00
Michael Steenbeek
511a300251
Some cleanup in Vehicle.cpp ( #11742 )
2020-05-13 11:51:38 +02:00
Duncan
79dda7260a
Fix #11695 . Mechanics walking to 0,0 on entrance only ( #11704 )
...
Mistake made when refactoring that meant that null locations were converted into tile 0, 0. I've fixed the general case but it is preferred to try avoid using null states for coordinates if at all possible.
2020-05-11 20:28:40 +02:00
Michael Steenbeek
d7637cd70f
Replace many C-style casts ( #11720 )
2020-05-11 14:32:56 +02:00
Ted John
096de3ccc8
Implement list view
2020-05-09 17:24:15 +01:00
duncanspumpkin
54a058ca6c
Fix boat location import/export/update.
...
After a refactoring to split off the boat location the import/export functions meant incorrect information could be loaded into the s6 file for boats that had not left the station. Boats that had left the station had other fields clobbered for the same reason
2020-04-07 20:19:26 +01:00
Gymnasiast
bdf681f440
Clean up many other coordinates
2020-03-13 12:03:43 +01:00
Michael Steenbeek
e1427df59f
Fix #10899 : Position of money animation is incorrect ( #10903 )
2020-03-09 15:00:13 +01:00
Michael Steenbeek
be13c1fc87
Refactor more TileCoords
2020-03-07 21:07:18 +01:00
Tulio Leao
8b36cce37c
Make _lastMainViewport 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
Michael Steenbeek
61175a4fbf
Confine use of LocationXY8 to RCT12 load/save code ( #10698 )
2020-03-01 21:16:10 +01:00
Michael Steenbeek
f41f878581
Replace some usages of LocationXY(Z)16 ( #10699 )
2020-02-18 22:42:38 +01:00
Tulio Leao
0c4623a39f
Replace typedef aliasing by using ( #10712 )
2020-02-17 11:43:47 +01:00
Matt
758a7e432f
Use const reference instead of copy for location structures
2020-02-13 11:53:14 +01: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
7cf03d3e41
Use CoordsXY on footpath_remove_edges_at()
2020-01-11 11:13:04 -03:00
Gymnasiast
1133a8c81c
Remove sLocationXY8
2019-12-30 23:03:13 +01:00
Michael Steenbeek
77494bbc73
Create definitions for some coords related stuff ( #10456 )
...
* Create definitions for some coords related stuff
* Use constexpr; add define for Z step
2019-12-30 15:03:51 +00:00
Michael Steenbeek
4b0dff92aa
Name word_981D6C ( #10471 )
2019-12-30 12:29:08 +01:00
Tulio Leao
98110c0544
Make Map::map_invalidate*() use CoordsXY ( #10437 )
...
* Make Map::map_invalidate_element() use CoordsXY
* Make Map::map_invalidate_tile_full() use CoordsXY
* Make Map::map_invalidate_tile_zoom0() use CoordsXY
* Make Map::map_invalidate_tile_zoom1() use CoordsXY
* Make Map::map_invalidate_tile() use CoordsXY
* Use CoordsXYRangedZ for map invalidation
* Fix vehicle tile invalidation use Z instead of Y coord
* Fix BannerRemoveAction sending Z TileCoords to invalidate tile
* Fix wrong tile invalidation on peep_update_walking_break_scenery
* Prefer ToTileStart over bitwise and
2019-12-28 08:44:33 +00:00
Michael Steenbeek
d0744df22f
Merge pull request #10443 from tupaschoal/reduce-locationxy
...
Remove LocationXY usage on windows and actions
2019-12-27 15:58:26 +01:00
Michael Steenbeek
64f7cac6d6
Create getters for station height and start ( #10453 )
2019-12-27 15:57:40 +01:00
Tulio Leao
109a90269c
Prefer setNull/isNull on TopToolbar over LOCATION_NULL
2019-12-27 09:52:31 -03:00
Tulio Leao
6c998d7b4d
Make Map::map_get_track_element_at() use CoordsXYZ
2019-12-24 11:19:03 -03:00
Tulio Leao
a2c7ecc6e5
Make Map::map_get_first_element_at() use CoordsXY ( #10413 )
...
* Make Map::map_get_first_element_at() use CoordsXY
* Fix clang-format on ClearAction.hpp
* Prefer TileDIrectionDelta over hardcoded delta on RideConstruction
* Use named Direction constants
* Make Compat::map_get_first_element_at() use CoordsXY
2019-12-23 07:35:41 +00:00
Duncan
96ff8fe7a1
Change value of COORDS_NULL to a less likely to collide value. ( #10423 )
...
It will also now match LOCATION_NULL. As this change should only affect in memory coords there should be no save, replay, network issues.
2019-12-22 14:03:32 +01:00
Michael Steenbeek
c2565bfe1c
Merge pull request #10407 from duncanspumpkin/refactor_stations
...
Fixing COORDS_NULL: Refactor stations
2019-12-21 16:13:48 +01:00
Gymnasiast
dcc720c1ec
Remove MakeXY16()
2019-12-21 13:51:59 +01:00
duncanspumpkin
b3dafc64c3
Refactor to improve readability as per suggestions
2019-12-21 12:12:10 +00:00
duncanspumpkin
45403ac2d3
Move station_starts to TileCoordsXY
2019-12-21 11:48:13 +00:00
Michael Steenbeek
a2b9598341
Modify code using Location8 to use isNull()/setNull() ( #10403 )
2019-12-21 11:34:46 +01:00
Tulio Leao
780e3265d1
Standardize Coords and TileCoords objects
2019-12-20 08:29:42 -03:00
Michael Steenbeek
6ede67d50a
Merge pull request #10371 from tupaschoal/coords-for-get-surface-element-at
...
Make map_get_surface_element_at only accept Coords objects
2019-12-19 13:24:17 +01:00
Michael Steenbeek
f59f5d9b1f
Merge pull request #10375 from tupaschoal/coords-for-map-entrance-exit
...
Make map entrance/exit fetching functions use Coords objects
2019-12-19 11:39:37 +01:00
Tulio Leao
aea755bd70
Allow TileCoordsXYZD to generate CoordsXYZD equivalent
2019-12-19 00:11:26 -03:00
Tulio Leao
5c657bde9f
Remove map_get_surface_element_at operating with TileCoordsXY
2019-12-18 23:47:17 -03:00
Tulio Leao
af281817c3
Use CoordsXYZD on map_get_wall_element_at() ( #10374 )
...
* Use CoordsXYZD on map_get_wall_element_at()
* Add CoordsXYZ::ToTileStart()
2019-12-18 11:23:53 +01:00
Tulio Leao
4f615c5802
Make const some methods of location objects ( #10392 )
2019-12-18 11:21:16 +01:00
duncanspumpkin
63b8f83f4f
Make suggested changes
2019-12-15 08:23:21 +00:00
Tulio Leao
2ff4c28cb5
Use CoordsXY on action rotation ( #10332 )
...
* Use CoordsXY on action rotation
* Don't use intermediate CoordsXY variable just for Rotating it next
* Standardize operations on Coords and Rotated Coords
* Remove unwanted linebreak addition
2019-12-12 08:09:46 +00:00