1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-22 22:34:33 +01:00
Commit Graph

15345 Commits

Author SHA1 Message Date
Michael Steenbeek
fb2f907414 Merge pull request #10363 from duncanspumpkin/refactor
Refactor to reduce LocationXY usage
2019-12-21 16:24:24 +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
Michael Steenbeek
ef4e494532 Merge pull request #10412 from Gymnasiast/refactor/lesslocationxy
Remove MakeXY16
2019-12-21 15:34:40 +01:00
Tulio Leao
5fcfc6af00 Rename map_set_tile_elements to singular 2019-12-21 10:28:52 -03:00
Tulio Leao
d7efe4de90 Make Map::map_set_tile_elements() use TileCoordsXY 2019-12-21 10:28:33 -03:00
Tulio Leao
9b1395bfb8 Make Map::map_get_banner_element_at() use CoordsXYZ (#10408) 2019-12-21 14:15:40 +01:00
Duncan
228205a199 Fix crash in dev builds due to sign issues (#10405) 2019-12-21 14:08:57 +01:00
Tulio Leao
5cd6c67abd Make Map::map_get_small_scenery_element_at() receive CoordsXY (#10406) 2019-12-21 14:08:18 +01:00
Tulio Leao
38cf4728ef Make Map::map_get_nth_element_at() use CoordsXY (#10411) 2019-12-21 14:04:00 +01:00
Gymnasiast
11cc07a2b8 Replace hard-coded index with constant 2019-12-21 14:00:45 +01:00
Gymnasiast
dcc720c1ec Remove MakeXY16() 2019-12-21 13:51:59 +01:00
duncanspumpkin
64656cdc0e Fix mistake made by auto complete 2019-12-21 12:43:13 +00:00
duncanspumpkin
521e5db4c2 Make constant values more explicit.
Fix mistake in z coordinate conversion
2019-12-21 12:22:59 +00:00
duncanspumpkin
f346e439fc Change type of map selection a and b 2019-12-21 12:18:34 +00:00
duncanspumpkin
1f80dee4df Refactor footpath.cpp to remove LocationXY and use CoordsXY 2019-12-21 12:18:34 +00:00
duncanspumpkin
6b72b0992d Removal of LocationXY and simplify 2019-12-21 12:18:34 +00:00
duncanspumpkin
df2393c3f0 Fix clang format 2019-12-21 12:17:57 +00:00
Michael Steenbeek
6b5be4765d Merge pull request #10399 from duncanspumpkin/refactor_map_animation
Refactor MapAnimation to use CoordsXYZ
2019-12-21 13:12:11 +01:00
duncanspumpkin
b3dafc64c3 Refactor to improve readability as per suggestions 2019-12-21 12:12:10 +00:00
duncanspumpkin
21128c5389 Undo clang format mistakes 2019-12-21 11:52:32 +00:00
duncanspumpkin
45403ac2d3 Move station_starts to TileCoordsXY 2019-12-21 11:48:13 +00:00
duncanspumpkin
7297125cae Refactor stations ready for TileCoordsXY 2019-12-21 11:26:37 +00:00
Michael Steenbeek
a2b9598341 Modify code using Location8 to use isNull()/setNull() (#10403) 2019-12-21 11:34:46 +01:00
duncanspumpkin
f64563e0a7 Make suggested changes 2019-12-21 09:07:34 +00:00
NuclearFej
da49d98b8b Android: fix Gradle, CMake, asset copying; upgrade to AndroidX
Gradle now pulls from the main OpenRCT2 /bin/data folder to insert the assets into the APK. MainActivity now properly copies assets from within the APK. Dependencies have been updated and the support library has been upgraded to AndroidX. CMake libraries now link properly. Network (multiplayer), Discord, and HTTP_Twitch were disabled, in addition to the already-disabled HTTP, OpenGL, and Twitch, due to compile-time errors. Revision number incremented.
2019-12-20 19:44:45 -05:00
Tulio Leao
780e3265d1 Standardize Coords and TileCoords objects 2019-12-20 08:29:42 -03:00
Duncan
3be7d824ac Merge pull request #10397 from duncanspumpkin/refactor_gcommand
Remove gCommandPosition. Use GameActionRes instead.
2019-12-19 20:48:20 +00:00
duncanspumpkin
86cc7e9734 Add temporary variable to clear up shifting.
Fix clang format.
Simplify compare
2019-12-19 18:58:33 +00:00
duncanspumpkin
ee206546bf Refactor MapAnimation to use CoordsXYZ 2019-12-19 18:38:46 +00:00
nia
1f220f2d62 Simplify OS-specific FileStream code (#10270)
Define ftello/fseeko to ftello64/fseeko64 only on Linux,
these functions are Linux-specific extensions.

Define ftello/fseeko to _ftelli64/_fseeki64 on MSC.

Otherwise, just use the standardized ftello/fseeko, and avoid
duplicating code for different names of the same function.

This allows this code to be reused on e.g. NetBSD without piling
on additional #ifdefs for any other POSIX operating systems.
2019-12-19 18:34:31 +01:00
Tulio Leao
918624e090 Fix #10396: Function returning TileCoordsXYZD'z coord in a CoordsXYZD object (#10398) 2019-12-19 15:41:22 +01: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
Tulio Leao
7e7b4029a9 Simplified conversions from TileCoordsXYZ to CoordsXY 2019-12-19 08:12:42 -03: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
Duncan
08bf0a6807 Merge pull request #10391 from tupaschoal/mouse-diff-coords
Save mouse differential coords using ScreenCoordsXY
2019-12-19 08:02:32 +00:00
Tulio Leao
aea755bd70 Allow TileCoordsXYZD to generate CoordsXYZD equivalent 2019-12-19 00:11:26 -03:00
Tulio Leao
a5065e95c6 Simplify MouseInput differential coords calculation 2019-12-18 23:57:57 -03:00
Tulio Leao
5c657bde9f Remove map_get_surface_element_at operating with TileCoordsXY 2019-12-18 23:47:17 -03:00
Tulio Leao
7c75db2b2d Make map_get_surface_element_at only accept Coords objects 2019-12-18 23:46:50 -03:00
Duncan
099404b505 Merge pull request #10381 from tupaschoal/cursorsate-store-coords
Make CursorState store a ScreenCoordsXY object
2019-12-18 20:10:51 +00: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
Tulio Leao
52d09171ba Remove usage of LocationXY on TrackDesign (#10383) 2019-12-18 11:20:51 +01:00
Tulio Leao
c71c4284d0 Make map entrance/exit fetching functions use only CoordsXY objects 2019-12-17 23:55:46 -03:00
Tulio Leao
8613edee4a Use ScreenCoordsXY::operator- to improve readability 2019-12-17 23:33:07 -03:00
Tulio Leao
972a8735e8 Fix arithmetic error in Scenery::window_scenery_update() 2019-12-17 23:32:34 -03:00
Tulio Leao
502a15512b Save mouse differential coords using ScreenCoordsXY 2019-12-17 23:21:12 -03:00
Ted John
b2c0787c2d Fix #10389: Invalid read in vehicle_update_travelling (#10390) 2019-12-17 21:48:38 +01:00
Tulio Leao
c2c40fa951 Create ScreenCoordsXY on UIContext mouse/finger functions (#10382) 2019-12-17 18:46:28 +01:00
Tulio Leao
6b06b2c578 Use ScreenCoordsXY for Mouse Drag storage (#10380) 2019-12-17 18:38:20 +01:00