1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-27 16:54:52 +01:00
Commit Graph

37 Commits

Author SHA1 Message Date
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
Ted John
3ead0f4289 Finish loading water JSON objects 2018-03-26 21:37:23 +02:00
Ted John
bf7c3931e7 Parse images from JSON 2018-03-26 21:35:44 +02:00
Ted John
f6fd79eca4 Move length calculation to ImageTable.cpp 2018-03-26 21:35:44 +02:00
Ted John
32d588d765 Fix toilets image loading 2018-03-26 21:35:44 +02:00
Michael Steenbeek
d481cca2ed Remove some redundant casts and fix rct_sprite::AsDuck() 2018-02-15 13:04:25 +01:00
Ted John
f031763531 Use rct_gx for g1 2018-02-05 19:04:01 +00:00
Ted John
b8e93177d8 Use std::vector for g2 and csg 2018-02-05 18:56:03 +00:00
Ted John
b0755123fd Fix loading of bad g1.dat 2018-02-05 18:47:40 +00:00
Gymnasiast
778ba466c5 Remove almost every extern C block 2018-02-05 16:20:15 +01:00
Ted John
8304f01aef Fix #5809: Support Steam RCT1 file layout
Checks RCTdeluxe_install sub directory for csg1.1 and csg1i.dat when loading CSG images.
2018-01-23 18:28:33 +01:00
Michał Janiszewski
6a65f791b6 Add const to arguments 2018-01-10 23:58:57 +01:00
Ted John
3dcbebcf68 Refactor drawing.c to C++ 2018-01-05 22:57:57 +01:00
Ted John
02c58a6c5a Remove custom base Exception class 2018-01-05 18:11:47 +00:00
Michał Janiszewski
b2bc974fe7 Use nullptr where possible 2018-01-04 06:58:44 +01:00
Michał Janiszewski
645b36169d Move SSE4.1 code to its own file, detect SSE4.1 in runtime 2018-01-01 23:49:09 +01:00
Michał Janiszewski
c04e720f9f Hide mask_sse4_1 completely on non-SSE builds 2018-01-01 23:49:09 +01:00
Michał Janiszewski
b30fb66878 Add SSE4.1 implementation of masking 2018-01-01 23:49:09 +01:00
Gymnasiast
2a6f2c1763 Fix #6114: Crash when using a non-LL CSG1.DAT
The game will now check for the number of entries in CSG1.DAT. If it's too few, it will now no longer try using its sprites, but print out a warning instead.
2017-12-31 21:03:40 +01:00
Hielke Morsink
b6718d08d4 Remove unnecessary return statements 2017-12-21 23:47:30 +01:00
Michael Steenbeek
1a9975d683 Compile util and cheats as C++ 2017-12-14 10:03:21 +01:00
Ted John
99d7aaa2d6 Remove RCT2 interop 2017-12-04 19:04:06 +00:00
Michał Janiszewski
f46f2d6821 Fix g1 image ID check (#6742) 2017-11-27 22:03:54 +00:00
Ted John
8c53b6a70b Fix #6681: Tons of visual glitches when zooming out
Regression from #6574. Restoring the backup of SPR_TEMP was removed which was necessary as it is the sprite for grass tile zoomed out. Instead make SPR_TEMP a special sprite ID which is not used for anything else apart from temporary sprite drawing.
2017-11-20 13:48:00 +00:00
Ted John
eb98bfaa31 Log invalid g2 access 2017-11-05 21:17:35 +00:00
Ted John
48d1930a6c NULL -> nullptr 2017-11-05 21:12:46 +00:00
Ted John
446f57e43b Fix NO-RCT2 builds 2017-11-03 22:24:04 +00:00
Ted John
4232be9fc2 Remove remaining external uses of g1element 2017-11-03 22:18:10 +00:00
Ted John
444a8c1602 Const protect get_g1_element 2017-11-03 22:18:10 +00:00
Ted John
5a05bd51e5 Use get_g1_element and add null checks 2017-11-03 22:18:10 +00:00
Michał Janiszewski
8fd2266bda Refactor includes (#6512)
* Refactor Intent.h inclusion

* Use forward declaration of ITcpSocket

* Remove unused include

* Forward declare rct_ride_entry

* Remove unused headers

* Forward-declare rct_drawpixelinfo

* Remove unused headers

* Lower header include from header to source file

* Reduce included headers

* Reduce includes
2017-10-19 10:01:05 +02:00
LRFLEW
11cdcea72b Fix RCTC g1.dat rendering issues 2017-09-30 19:18:31 -05:00
LRFLEW
e177811115 Add RCTC g1.dat support 2017-09-29 10:44:23 +02:00
Michał Janiszewski
5ab9f938a7 Update files missed in the great extern "C" cleanup of 2017 2017-09-28 23:29:16 +02:00
ζeh Matt
1f3ccae8b1 Refactor remaining image flag constants to defined G1_* flags. (#6217)
Refactor gUnk9DE568 and gUnk9DE56C to be type of rct_xy16 called gPaintSpritePosition
Rename unk_9ABDA4 to gCurrentColourPalette.
Rename gUnkEDF81C to gCurrentImageType.
Rename sub_679236_679662_679B0D_679FF1 to pixel_is_present.
Remove unused variables _unk9ABDAE, _unk9AC149, unk_9E3CE4, only ever assigned but never read.
Remove unreferenced variable unk_9E3CDC.
Clean up some parts in sub_679236_679662_679B0D_679FF1.
Remove function sub_68371D and references, it assigns variables that are never used.
Add assert determine if unused code.
2017-09-02 14:01:08 +01:00
Michał Janiszewski
4708af474d Fix MinGW builds in release mode 2017-08-31 23:24:47 +02:00
duncanspumpkin
18d082053e Rename cpp files to use TitleCase 2017-08-04 18:12:54 +02:00