1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-20 21:43:06 +01:00
Commit Graph

54 Commits

Author SHA1 Message Date
Ted John
2ea857a10e Improve IZipArchive so that it is more C++ 2018-05-06 17:46:45 +01:00
Michael Steenbeek
5f9d40be7a Replace tile_element_get_type() with struct method 2018-05-02 19:27:04 +02:00
Michael Steenbeek
ef433df26a Clean up tile element usage, introduce struct methods 2018-05-02 11:58:12 +02:00
oli414
3bff12c081 Seperate surface tile element 2018-05-01 16:33:16 +02:00
Hielke Morsink
30063984e6 Delete unused function arguments or mark them so (#7426)
This aims to make future refactoring easier. The arguments are removed where possible, but kept and marked with C++17's [[maybe_unused]] where they could not be removed (e.g. when they are used as a callback, rather than called directly).

I've skipped the rides/<category>/* and peep/* source files, because the rides source files are mostly generated and have a ton of unused variables, and the peep source files are being refactored.
I've also skipped most of window/* source files, because most of the functions are used as callbacks and will be bulk-renamed at some point.
2018-04-20 13:56:37 +02:00
Michał Janiszewski
cd065d4f41 Reduce includes in common header 2018-03-20 00:27:58 +01:00
Gymnasiast
ddd03fb045 Fix #7284: Rotating a maze track rotates each piece individually 2018-03-15 22:32:33 +01:00
Michael Steenbeek
ac0b18cde5 Replace LocationXY32 2018-02-16 16:16:49 +01:00
Michael Steenbeek
359e9ecf2d Replace LocationXYZ32 2018-02-16 16:16:49 +01:00
Michael Steenbeek
bde913ee16 Rename SmallCoords and BigCoords 2018-02-15 22:26:50 +01:00
Michael Steenbeek
45e892e5b5 Allow passing BigCoordsXY into map_get_surface_element_at() 2018-02-15 22:26:50 +01:00
Hielke Morsink
55979a3fff Remove and replace C typedefs
`typedef struct/union/enum name { ... } name_again;` is not needed whe compiling C++, moving the name at the back to be in front of the object and removing `typedef` makes it usable the very same way.
This also replaces typedefs with the using keyword. They have better readability, especially for function pointer types, and would allow more flexibility when used with templates.
2018-02-14 09:42:26 +01:00
Michael Steenbeek
a408747c4c Use object_entry_get_type() throughout 2018-02-13 16:42:18 +01:00
Ted John
4d8fe051e8 Remove most usages of object_entry_groups 2018-02-12 12:48:41 +00:00
Michael Steenbeek
9bd812c855 Move most of _legacy.c to C++ (#7117) 2018-02-02 23:11:41 +01:00
Michał Janiszewski
7041d0c978 Fix #7085: Track design placement going over buffer 2018-01-31 07:27:34 +00:00
Ted John
ba5bc415c7 Refactor memory handling in window sources 2018-01-21 11:17:40 +00:00
Michał Janiszewski
4eb2ceac47 Fix #7004: Placing track design makes the park disappear 2018-01-18 10:30:34 +01:00
Richard Jenkins
8fb5f5c2be Fix #6993: Inverting track design causes a crash 2018-01-12 15:42:02 +00:00
ZehMatt
84f2917f59 Use const and constexpr whenever possible. 2018-01-11 22:29:08 +01:00
Michael Steenbeek
cd5a1ba888 Compile files in world folder as C++ 2018-01-11 13:25:09 +01:00
Michał Janiszewski
469e142c7b Change casing of header files 2018-01-11 09:30:09 +01:00
Gymnasiast
9f8e3240d3 Fix #6992: Crash when hovering over an RCT1 track design in Track Manager 2018-01-10 21:20:46 +01:00
Michael Steenbeek
6a88d6e04d Move and rename RCT{1,2,12}.h 2018-01-09 13:36:41 +01:00
Michael Steenbeek
755add6c9a Compile localisation folder as C++ 2018-01-06 18:32:25 +01:00
Michael Steenbeek
1fa25739fb Fix #5398: Mini Maze.TD4 causes weird behaviour and crashes 2018-01-06 18:26:28 +01:00
Michał Janiszewski
7f5e3a3a64 Sink some variables 2018-01-02 22:03:10 +01:00
Gymnasiast
23d70a4ac9 Compile ride.c as C++ 2017-12-31 20:43:17 +01:00
Hielke Morsink
3770b46e46 Replace 1 and 0 constants with bool where applicable 2017-12-21 23:47:30 +01:00
Michael Steenbeek
282e70a806 Allow building level crossings without cheats 2017-12-20 18:20:31 +01:00
Michael Steenbeek
1a9975d683 Compile util and cheats as C++ 2017-12-14 10:03:21 +01:00
Michael Steenbeek
60d8865efb Compile game.c and game.h as C++ 2017-12-05 09:10:27 +01:00
Michael Steenbeek
407f1ad148 Create scenery_small_entry_has_flag() 2017-12-04 20:09:38 +01:00
Michael Steenbeek
bf69b2e682 Make terminology use more consistent 2017-11-20 11:20:04 +01:00
platipo
789b47b7bb Refactor slope flags and path type flag 2017-11-18 12:58:27 +01:00
Michael Steenbeek
f448d16707 Add methods for getting and setting track element type 2017-11-17 12:54:47 +01:00
Michael Steenbeek
ab3f42f1f9 Add getters and setters for ride index and maze entry 2017-11-17 12:54:47 +01:00
Christian F. Coors
06afeeda9a Apply some refactoring 2017-11-02 12:22:28 +01:00
Michael Steenbeek
af845beb61 Replace mapElement with tileElement 2017-10-31 19:59:06 +01:00
Michael Steenbeek
ce8d9cc71b Rename map_element to tile_element 2017-10-31 19:59:06 +01:00
Michał Janiszewski
90a14205c8 Compile track_data.c as C++ 2017-10-25 23:53:47 +02:00
Michael Steenbeek
bb01699b7d Compile track.c as C++ 2017-10-17 13:51:47 +02:00
Tomas Dittmann
e393ff1f22 Stop using (void*)-1 for invalid pointers 2017-10-15 15:53:16 +02:00
Michael Steenbeek
7f9c25a7a9 Use constant for LOCATION_NULL, split off location stuff to Location.h 2017-10-13 22:23:07 +02:00
duncanspumpkin
665aac7394 Fix #6413: Draw Maze previews correctly.
Mistake made during refactoring. Apply flag was not being passed to the game command and this meant that only the query to check if a maze element could be placed was called.
2017-10-10 12:43:54 +02:00
Michael Steenbeek
31e1ad43a8 Compile finance.c as C++, clean up 2017-10-07 16:28:35 +02:00
Michael Steenbeek
4224193d68 Clean up ride groups 2017-10-06 10:29:24 +02:00
ZehMatt
bf0bc77dfc Refactor SetParkEntranceFeeAction to use constructor for parameters.
Add RideSetNameAction.
Support of string serialisation.
Check requested status for ride in Query.
Add RideDemolishAction.
2017-10-05 10:42:44 +02:00
Michael Steenbeek
055ecccf36 Clean up more track flags 2017-10-04 17:14:53 +02:00
Olivier Wervers
1de4b2650b Fix #6229: Scenery costs nothing in track designs 2017-09-30 00:11:14 +02:00