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

82 Commits

Author SHA1 Message Date
Michał Janiszewski
6d6f9f3c23 Refactor rides to be only accessible with getters
This changes how rides are accessed from macros to getter functions.
2016-01-23 01:13:36 +01:00
Hielke Morsink
0b445ab1a5 Fix #2747 map sprite issue. 2016-01-19 00:05:14 +01:00
Marijn van der Werf
98b5ad1bf4 Replace known addresses with constants 2016-01-15 21:01:34 +01:00
IntelOrca
f0adf90660 integrate variable: gInputFlags 2016-01-04 22:53:03 +00:00
Jonathan Haas
4d26e4c4a1 Refactor peep code
Name various fields and constants related to peeps. This includes:
  - Flags for flashing peeps in map window
  - Animation frames for picked up peeps
  - Function checking if peep should start to fall
  - Special sprite handling for slide boards and lawn mowers
  - Created array for peep sprite entries, renamed some variables and constants
2015-12-31 13:57:06 +01:00
Michał Janiszewski
8a5d066efe Fix strict aliasing violations
Compiler only guarantees proper accesses to variables when using
variable's native type or `char` (i.e. single byte type) [1].

This commit fixes violations of this rule. In most cases changing code
to a simple cast was enough, some required a bit deeper modifications.

This fixes #2596.

[1] http://blog.qt.io/blog/2011/06/10/type-punning-and-strict-aliasing/
2015-12-31 13:27:26 +01:00
IntelOrca
c6b023df86 fix warnings 2015-12-29 11:39:06 +00:00
Michał Janiszewski
e3f5ea25ae Map unknown elem type to corrupt, update tile inspector
In map view, all unknown types are mapped to MAP_ELEMENT_TYPE_CORRUPT,
the type that prevents rendering of all following elements on given
tile.

Tile inspector now displays element type (numeric value) for unknown
types.
2015-12-27 10:34:02 +01:00
Michał Janiszewski
53970c2d77 Add tile type for corrupt element
Fixes #2558
2015-12-26 13:36:32 +01:00
Michał Janiszewski
79e5bb758d Add an assert for getting proper mapElementType 2015-12-26 13:16:03 +01:00
Aaron van Geffen
9232a9906f Inventarised instances of RCT2_ADDRESS_COMMON_FORMAT_ARGS 2015-12-26 18:24:36 +09:00
IntelOrca
db18fa8f14 finally fix #1619: Can't place any path
RCT2_ADDRESS_TOOL_WIDGETINDEX was being read as an int32 sometimes
2015-12-21 22:28:34 +00:00
Kyle Kirby
caf07c2064 Clean up the comments a litte
• Make comment heads be /**
• Make rct2 addresses be double spaced indented
• Make there be a space afte rct2: and the address
• Make single-line rct2 addresses be full block comments
• Move description of method to top of comment
2015-12-11 16:19:46 -06:00
Dom Light
bb62b7561a Replace some uses of play_sound_panned with play_sound_at_location 2015-11-18 00:03:15 +00:00
Dom Light
e9b7e41635 Refactor audio_sound_play_planned 2015-11-17 23:05:24 +00:00
Dom Light
3a8b25a0ee Sanitize audio.h 2015-11-17 01:05:14 +00:00
Michał Janiszewski
075b98e209 Minor cleanups
Mostly just setting variables to better define game state, with one
minor update of decompilation where an `or` instruction was used in
place of `mov` (in `sub_6CBCE2`).
2015-11-12 12:19:40 +01:00
duncanspumpkin
d5688cdc4e Fix #2189. Map owned area not shown correctly.
Issue was caused by doubling up a bit of code and combining it with the next line when implementing it.
2015-11-03 18:19:23 +00:00
Michał Janiszewski
c0e2a5c7be Add get_current_rotation function and DEBUG_LEVEL macros 2015-11-02 22:58:15 +01:00
Alexander Overvoorde
01793e11b7 Replace RCT2_GLOBAL magic numbers with address identifiers and string ids 2015-10-29 09:44:46 +01:00
Gymnasiast
9504f3f10d Replace missed occurrence of magic numbers with defines 2015-10-26 13:53:26 +01:00
Gymnasiast
61444c8518 Display the visible/practical map size instead of the technical size, fixes #2133 2015-10-26 10:21:04 +01:00
Michał Janiszewski
7d0ce00bab Strip all whitespace 2015-10-20 20:48:51 +02:00
duncanspumpkin
9017e5ff86 Fix #1899. Prevent mountain tool from being possible for land ownership tool. 2015-10-04 20:44:17 +01:00
Gymnasiast
4d7a81bfe0 Remove unnecessary duplicate address, use more string constants 2015-08-27 16:44:18 +02:00
medsouz
7071bd9353 Document more addresses
Created defines for all the memory addresses I could find in peep/staff.c
and updated everywhere they're being used.
2015-08-16 18:25:17 -04:00
medsouz
ca1a1e0ddd Document various memory addresses 2015-08-16 13:05:49 -04:00
Gymnasiast
6ec3838b0b Refactor map window 2015-08-12 14:23:13 +02:00
IntelOrca
d228d13918 implement utf8, part 23 (bug fixes) 2015-08-01 16:40:15 +01:00
IntelOrca
fbd402eb67 implement remaining screen_get_map_xy... functions 2015-07-11 18:23:59 +01:00
IntelOrca
d5ffaefdf0 add better disable clearance cheat 2015-07-10 21:32:11 +01:00
IntelOrca
f906391c9d remove registers from window events and changed to typed signatures 2015-07-10 01:39:16 +01:00
IntelOrca
46178bb44f implement finish-map-window part 6 2015-07-02 17:00:39 +01:00
IntelOrca
55c509590f implement finish-map-window part 5 2015-07-02 01:50:13 +01:00
IntelOrca
6de7a38f53 implement finish-map-window part 4 2015-07-02 00:37:55 +01:00
IntelOrca
693e6127da implement finish-map-window part 3 2015-07-01 19:06:42 +01:00
IntelOrca
c441ee2d1b implement finish-map-window part 2 2015-07-01 15:17:25 +01:00
IntelOrca
7be91a5fac implement finish-map-window part 1 2015-07-01 00:58:13 +01:00
rd3k
628a586ea2 Tidy window flags 2015-06-13 22:16:14 +01:00
Gymnasiast
7ed434a804 Rework land ownership cheat into sandbox mode 2015-06-09 17:19:05 +02:00
IntelOrca
dc3fe2a6c8 remove commented out CALLPROCs and CALLFUNCs 2015-06-09 15:09:45 +01:00
Gymnasiast
c15da4370a Added cheat to edit land ownership settings in-game 2015-06-07 12:45:55 +02:00
Duncan Frost
cd753e13e4 Fix #1213 once and for all.
Forgot to check that the tool in use was the set land rights tool.
2015-06-04 20:15:23 +01:00
Duncan Frost
9dfa9b1461 Fix #1161
In the editor map window the string displaying the current tool size was not checking to make sure the tool was active before displaying the size.
2015-06-03 19:04:13 +01:00
Robert Jordan
765bf976ee Renamed Colour Schemes to Themes
Themes window now opens to settings/presets tab so it's less confusing
for others.
Can no longer change default presets, you get a warning when you try.
now stores themes in themes folder.
Now clips theme names.
2015-06-01 11:02:09 -04:00
Robert Jordan
41171aa304 Resolved Merge Conflicts 2015-05-30 16:00:13 -04:00
Robert Jordan
dc1e38180e Starting work on colour schemes config settings 2015-05-29 12:04:53 -04:00
IntelOrca
101fed0dd9 refactor g1Elements pointer and implement sub_68371D 2015-05-28 00:17:22 +01:00
IntelOrca
6426adb45d remove asm for set scroll size and add gCurrentAwards 2015-05-26 19:28:56 +01:00
Robert Jordan
a8ec43f065 Select size strings now use args 2015-05-13 11:38:44 -04:00