1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-26 08:14:38 +01:00
Commit Graph

127 Commits

Author SHA1 Message Date
Michael Steenbeek
3f473ec3f0 Fix #6123: Cannot build some track designs with 4 stations (#11031) 2020-03-25 14:20:29 +01:00
Gymnasiast
0f8fec1413 Fix #10631: Assertion fails when modifying copied station pieces 2020-03-21 18:43:34 +01:00
Gymnasiast
2f7a26e8da Refactor station index a bit 2020-03-21 17:05:16 +01:00
Michael Steenbeek
fd91c41a76 Name remaining ride type flags (#10947) 2020-03-16 22:52:06 +01:00
Michael Steenbeek
ba49850195 Fix errors and apply requests 2020-03-08 11:23:20 +01:00
Gymnasiast
27af60f062 More CoordsXYZ(D) conversion 2020-03-07 22:14:29 +01:00
Gymnasiast
ad91654a3d Use big Z in more places 2020-03-07 21:54:47 +01:00
Michael Steenbeek
4f86d0115c Merge pull request #10866 from Gymnasiast/refactor/more-tile-element-prep
Refactor/more tile element prep
2020-03-06 09:25:32 +01:00
Gymnasiast
2eb967b30d Change station start to CoordsXY 2020-03-05 12:29:02 +01:00
Gymnasiast
c9afcaa5b3 Fix errors 2020-03-05 00:09:39 +01:00
Gymnasiast
3ed7694495 Move tile element-specific flags 2020-03-04 22:01:09 +01:00
Gymnasiast
93926d5e5d Move all the ride type-specific track categories to regular ones 2020-02-22 23:20:12 +01:00
Michael Steenbeek
1690361b36 Increase size of ride_id_t to 16 bits 2020-02-16 22:21:17 +01:00
duncanspumpkin
a5ef8d6240 Rename rct_vehicle 2020-01-19 17:14:56 +00: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
64f7cac6d6 Create getters for station height and start (#10453) 2019-12-27 15:57:40 +01:00
Tulio Leao
81647b3dd8 Make Map::map_get_track_element_at_with_direction_from_ride() use CoordsXYZD 2019-12-24 11:19:06 -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
Michael Steenbeek
a2b9598341 Modify code using Location8 to use isNull()/setNull() (#10403) 2019-12-21 11:34:46 +01:00
Tulio Leao
b793d7e79a Avoid dereferencing map_get_first_element_at nullptr on libopenrct2 (#10013)
* Avoid dereferencing map_get_first_element_at nullptr on Map.cpp

* Avoid dereferencing map_get_first_element_at nullptr on MapAnimation.cpp

Returning true or internal control variable, based on what was seen on `map_animation_invalidate_track_onridephoto`

* Avoid dereferencing map_get_first_element_at nullptr on Park.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Scenery.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Sprite.cpp

* Avoid dereferencing map_get_first_element_at nullptr on TileInspector.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Wall.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Fountain.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Footpath.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Entrance.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Banner.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Vehicle.cpp

* Avoid dereferencing map_get_first_element_at nullptr on TrackDesignSave.cpp

* Avoid dereferencing map_get_first_element_at nullptr on TrackDesign.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Track.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Station.cpp

* Avoid dereferencing map_get_first_element_at nullptr on RideRatings.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Ride.cpp

* Avoid dereferencing map_get_first_element_at nullptr on S4Importer.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Staff.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Peep.cpp

* Avoid dereferencing map_get_first_element_at nullptr on GuestPathfinding.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Guest.cpp

* Avoid dereferencing map_get_first_element_at nullptr on VirtualFloor.cpp

* Avoid dereferencing map_get_first_element_at nullptr on Paint.TileElement.cpp

* Fix issues raised on review

* Fix remaining review issues.

* Early exit on loops if tileElement is nullptr

* Fix clang-format issues
2019-10-09 15:02:21 +01:00
Gymnasiast
bb73dd0dfb Refactor track element to use 16 bytes 2019-08-31 13:14:19 +02:00
Gymnasiast
169d2980ca Properly export tile elements to S6 2019-08-18 18:20:56 +02:00
Ted John
93789b9034 Add nullptr checks for get_ride in libopenrct2ui (#9795) 2019-08-09 08:06:25 +01:00
Ted John
ab7b17fc4e Add nullptr checks for get_ride in libopenrct2 (#9788) 2019-08-08 22:58:56 +01:00
Gymnasiast
2ea1fcc69d Remove unused declarations and functions 2019-05-13 22:16:14 +02:00
Nazey
9cbc308c40 Remove gTrackGroundFlags by returning it within GameActionResult (#8930)
Fix #8726
2019-03-24 19:48:37 +00:00
Michael Steenbeek
1c570c8eec Move some ride functions to struct methods 2019-03-20 20:05:25 +01:00
Aaron van Geffen
2af13904c5 Update copyright notices for 2019. (#8903) 2019-03-17 07:16:15 +00:00
duncanspumpkin
539c12b41a Remove old game command 2019-03-11 19:11:54 +00:00
duncanspumpkin
92cdbfb0a8 Use Is/Set Indestructible 2019-02-27 10:49:48 +00:00
duncanspumpkin
354cce71eb Introduce new functions to stop direct access 2019-02-27 10:49:48 +00:00
duncanspumpkin
737c308e4e Use IsGhost() to access ghost state
Added set and clear ghost to further prevent direct access to flags
2019-02-25 15:12:35 +00:00
duncanspumpkin
e8b2c0f16f Add TrackRemoveAction 2019-02-21 16:00:31 +00:00
duncanspumpkin
77b25714ff Move callbacks into GameActionCallbacks
Remove remaining references to game command
2019-02-19 12:30:42 +00:00
duncanspumpkin
650e8291d0 Start moving track place into GameAction framework 2019-02-19 12:30:33 +00:00
Ted John
ba445cb6ef Pass Ride* instead of ride_id_t 2019-02-13 20:16:42 +00:00
Michael Steenbeek
3d9702dfd4 Fix #8141: Attempting to build entrance/exit on station 2 does not work 2019-01-27 10:38:47 +01:00
Michael Steenbeek
b4bef2fe7d Merge pull request #8560 from richard-fine/directions
Begin cleanup of direction handling
2019-01-18 19:09:39 +01:00
Ted John
92412d4bab Store ride index inside ride struct 2019-01-18 11:46:18 +01:00
Ted John
8701286772 Use new ride_id_t typedef (#8561) 2019-01-12 10:11:55 +00:00
Richard Fine
e90e9dd73f Introduce many uses of direction_reverse
Change many of the places doing the ^2 trick to use direction_reverse instead, for improved readability.
2019-01-05 15:41:46 +00:00
Hielke Morsink
53ae48ffca Merge pull request #8550 from janisozaur/fallthroughs
Fix implicit fallthroughs
2019-01-04 23:27:02 +01:00
Hielke Morsink
5ef5e4153d Fix some more implicit and conditional fallthroughs 2019-01-04 22:26:56 +01:00
Ted John
37f76d1687 Move station fields into new station struct 2019-01-01 02:26:14 +00:00
Michael Steenbeek
d4801e139d Import tile elements from SV6 using new methods 2018-11-05 11:55:33 +01:00
Michael Steenbeek
f8add7f62e Rename rct_tile_element to TileElement 2018-11-01 13:53:50 +01:00
Michael Steenbeek
15490010e1 Revert "Fix #8064: Prohibited high construction error is sometimes shown as (undefined string)"
This reverts commit a8e46f5eec.
2018-10-23 14:52:51 +02:00
Michael Steenbeek
ed7aed405b Revert "Fix #8064: Check clearance height before alignment on correct z. (#8135)"
This reverts commit 45381b0997.
2018-10-23 14:52:30 +02:00
ζeh Matt
45381b0997 Fix #8064: Check clearance height before alignment on correct z. (#8135) 2018-10-22 18:51:36 +02:00
ζeh Matt
a8e46f5eec Fix #8064: Prohibited high construction error is sometimes shown as (undefined string) 2018-10-21 20:51:41 +02:00