Ted John
fd339d29b1
import pointer parts of data for top spin and rotations
2016-07-16 13:06:05 +01:00
Ted John
439220b86e
import SwingingTimeToSpriteMaps data
2016-07-16 13:06:05 +01:00
Ted John
1d8f14715c
import vehicle data for various rides
2016-07-16 13:06:05 +01:00
Duncan
1e1546d87c
Merge pull request #4064 from gDanix/fix-4060
...
Fix #4060 : Block brakes have a different behaviour from RCT2.
2016-07-16 13:04:53 +01:00
Michał Janiszewski
1742ce71ed
Fix handling of signed types
2016-07-15 18:48:22 +01:00
Michał Janiszewski
a6d0e6916e
Fix function definitions to match their declarations
...
This makes sure every function is properly declared, which includes
proper `extern` wrappers.
2016-07-14 14:11:49 +02:00
Marijn van der Werf
5204fb0ce9
Clean up string and sprite ID's ( #3977 )
2016-07-14 14:07:49 +02:00
Daniel Trujillo
8638cf924d
Refactor hill stop site code
2016-07-12 20:33:19 +02:00
Daniel Trujillo
4fba02567f
Add support for cable lift chain to stop train (old behaviour)
2016-07-12 19:47:03 +02:00
Daniel Trujillo
37c4b549d2
Revert block brakes behaviour to the old one (always braking)
...
Anyway, there is possible to swith between different behaviours
through a preprocessor directive
2016-07-12 19:32:53 +02:00
Daniel Trujillo
ac314a4d61
Fix the block-sectioned lift chain not working properly
2016-07-12 19:32:53 +02:00
Daniel Trujillo
8eeb6056a1
Fix grammar issues.
2016-07-10 00:01:55 +02:00
Daniel Trujillo
13f6959ae3
Rector block_brake_closed parameter from apply_block_brakes
...
To remark that is a variable, rather than a constant (closed)
2016-07-09 23:43:04 +02:00
Daniel Trujillo
3e782d9295
Deep splitting and rewriting of the sub_6D... code
2016-07-09 23:43:04 +02:00
Daniel Trujillo
a3661e5842
Swapped if/else at line 5402
...
Applied De Morgan's laws to simplify condition
2016-07-09 23:43:04 +02:00
Daniel Trujillo
453b33a7b7
Move "apply_block_section_stop_site" on top of "check_and_apply...()"
...
To make it callable from "check_and_apply...()"
2016-07-09 23:43:04 +02:00
Daniel Trujillo
3e0754f14d
Rename sub_6DAB4C_chunk_2
2016-07-09 23:43:04 +02:00
Daniel Trujillo
013266c6ae
Add needed calls to the new function
2016-07-09 23:43:04 +02:00
Daniel Trujillo
ed73a9dfe0
Break vehicle-handling code into another function
2016-07-09 23:43:04 +02:00
Daniel Trujillo
efb720326d
Add an implicit "else"
...
After "vehicle->velocity = 0", the sentence:
"vehicle->velocity -= vehicle->velocity >> 3" doesn't have any
effect, so insert an "else" can clarify the code
2016-07-09 23:43:04 +02:00
Daniel Trujillo
95e727d376
Add comments to the code
2016-07-09 23:43:04 +02:00
Daniel Trujillo
92b5e661fb
Break an "else" into pieces
2016-07-09 23:43:04 +02:00
Daniel Trujillo
f56f7065ac
Make more obvious the last "else" previously made with a "return"
2016-07-09 23:43:04 +02:00
Daniel Trujillo
cb4fe669a9
Name constant (1 << 5) -> MAP_ELEMENT_FLAG_BLOCK_BREAK_CLOSED
2016-07-09 23:43:04 +02:00
Sijmen Schoon
d06633331a
Fix the closing of ferris wheels
...
Well, that was anticlimactic
2016-07-08 23:36:59 +02:00
Daniel Trujillo
d731a015ea
Fix bug causing block brakes blocking vehicles in non-block mode
...
A comparison has been added to ensure that, if the ride isn't in a
block-sectioned mode, the block brakes will act as a simple brakes
(with 6 km/h boosters)
2016-07-08 19:03:22 +02:00
Michał Janiszewski
644a36a310
Fixes to -Wall compilation
...
By default, not all warnings are enabled. This change makes sure that
the project compiles correctly with following options turned on:
-Wall -Wno-unused-but-set-variable -Wno-missing-braces \
-Wno-unknown-pragmas -Wno-unused-function
2016-06-20 13:46:27 +01:00
Marijn van der Werf
6050b1d07a
Identify `rct_vehicle:var_D4`
2016-06-19 16:17:23 +02:00
Marijn van der Werf
1534c95f9c
use integrated data for `vehicle_update`
2016-06-18 00:24:53 +02:00
Michał Janiszewski
542828b5d4
Fix wrong vehicle position, nullptr guard
2016-06-16 23:14:38 +02:00
Michał Janiszewski
c2bf4b75e7
Integrate tile map element pointers usage ( #3442 )
2016-06-16 19:05:15 +02:00
Ted John
428724d86c
refactor reset_sprite_spatial_index, integrate gSpriteSpatialIndex
2016-06-03 18:13:00 +01:00
Michał Janiszewski
1508e49a28
Change macro to assert_struct_size
2016-06-03 11:29:50 +02:00
Michał Janiszewski
60630b9ad7
Drop `PACKED` attribute
2016-06-03 10:55:21 +02:00
Michał Janiszewski
df3030e4a9
Provide static_assert for hard-coded struct sizes.
2016-06-03 10:55:21 +02:00
Michał Janiszewski
3907fcd9d2
Explicitly pack structs
2016-06-03 10:55:21 +02:00
Ted John
25ac99e04a
add variable for gS6Info
2016-05-20 23:26:19 +01:00
Ted John
8efe699754
integrate gMapTooltipFormatArgs
2016-05-18 00:02:26 +01:00
Ted John
9ebb7f4931
Merge pull request #3621 from IntelOrca/refactor/common-format-args
2016-05-15 23:47:55 +01:00
Michał Janiszewski
b7f3259779
Guard against crash with synchronised vehicles, fix typo ( #3624 )
2016-05-15 22:49:59 +01:00
Ted John
cbf9a393f1
remove use of get_format_arg
...
Because of strict aliasing, we must use memcpy in some cases.
2016-05-15 22:40:25 +01:00
Ted John
1cc35dfe6e
integrate common format args
2016-05-15 22:03:53 +01:00
Yaroslav Tretyakov
a3469cf073
Fix #3598 : Validate vehicle track movement ( #3612 )
2016-05-15 17:20:46 +01:00
Ted John
3d47f9869f
write get entry methods for scenery and path
2016-05-15 16:09:26 +01:00
janisozaur
b3101dd9b0
Don't crash when vehicles have 0 friction ( #3615 )
2016-05-15 15:59:42 +01:00
janisozaur
3a6978a9aa
Fix comparison highlighted by clang ( #3614 )
2016-05-15 15:20:33 +01:00
Yaroslav Tretyakov
938c498fac
Integrate 0x008B8F30 (gTrackVehicleInfo) ( #3605 )
2016-05-15 10:30:03 +01:00
janisozaur
ca430e1b23
Drop unused variables ( #3586 )
2016-05-13 18:21:58 +01:00
janisozaur
658e877955
Name all the typdef-ed structs ( #3581 )
2016-05-12 22:57:40 +01:00
janisozaur
8d0481deba
Make sure to only update valid vehicles ( #3543 )
...
Lets us load parks like Six Flags Carolina:
http://www.nedesigns.com/park/1571/six-flags-carolina/
2016-05-09 15:52:03 +01:00
Ted John
d2c5501eea
refactor sprite heads and counts
2016-05-09 00:08:03 +01:00
Marijn van der Werf
e3161d66d0
Implement misc_paint
2016-05-06 00:06:52 +02:00
janisozaur
68bad6505c
Add and correct licence headers to all sources ( #3108 )
2016-05-04 18:24:41 +01:00
Ted John
652b1c83db
integrate variables for lightning and toolbar dirty flags
2016-04-24 21:49:09 +01:00
Ted John
98f732aaf7
integrate screen variables ( #3411 )
2016-04-24 00:36:39 +01:00
Ted John
4cdb2df9dc
integrate screen variables
2016-04-23 11:16:46 +01:00
Ted John
467513616d
add global macro: gCurrentTicks
2016-04-23 02:49:24 +01:00
Ted John
b59f5c17ca
add global macros for park...
...
- gParkSize
- gParkEntranceFee
- gNumGuestsInPark
2016-04-23 01:00:00 +01:00
Wirlie
407359e82b
Fix #3318 . Mine/Mouse train now can swing on turns.
2016-04-20 22:32:36 -05:00
Derek Lee
4d1153669e
Refactor peep code
...
Use constants rather than magic numbers and make identifiers consistent
2016-04-18 23:34:11 -07:00
Yaroslav Tretyakov
c3ba519a6e
Integrate audio related variables ( #3322 )
2016-04-17 14:20:26 +01:00
IntelOrca
89ad0cc769
store windows in openrct2 memory and increase max
...
Allocate a bigger window list and viewport list in OpenRCT2 static memory and move over all references from RCT2.
This also removes the 'active' viewport pointer list and instead changes everything to just enumerate the whole viewport list
2016-04-14 23:00:35 +01:00
Duncan
9edd48c4b8
Merge pull request #3231 from marijnvdwerf/use-structs
...
Clean up data use
2016-04-13 12:38:58 +01:00
duncanspumpkin
08de41bdd5
Fix #2710 . Chairlifts no longer crash at large y value stations.
2016-04-12 19:28:27 +01:00
Marijn van der Werf
0fd42f408a
Extract new struct
2016-04-03 14:53:17 +02:00
duncanspumpkin
8c7dfd3097
Revert #3147 and fix construction issue. Revert most of c7c1f86
and rework to prevent issues
2016-03-21 21:21:43 +00:00
Michał Janiszewski
c1a413c298
Fix crash when opening canoes
2016-03-19 00:47:34 +01:00
duncanspumpkin
14c1a88812
Fix #3117 . Golf course crash fixed.
...
Issue caused by implementation mistakes
2016-03-12 07:56:03 +00:00
duncanspumpkin
2431558f84
Fix #3052 . Flying roller coasters now correctly place vehicles.
...
Issue caused by a missing bit of code during implementation.
2016-03-01 21:16:49 +00:00
Ted John
017d7f41f5
Merge pull request #3035 from Gymnasiast/burn-more-flags
...
Remove magic crash protection for Six Flags rides
2016-02-28 11:30:08 +00:00
Gymnasiast
939fa24647
Remove magic crash protection for Six Flags rides
2016-02-28 11:59:43 +01:00
duncanspumpkin
d7459d07f8
Fix jerky vehicles on station platforms. Fixes #3011 .
...
Issue caused by a mistake in implementing the function
2016-02-28 10:52:53 +00:00
IntelOrca
90665c7185
always show number of fatalities news item, no six flags bias
2016-02-28 10:28:09 +00:00
Gymnasiast
0b87cd766c
Don't make empty boats leave the platform on closed boat rides with passengers still on it, fixes #2728
2016-02-27 13:36:14 +01:00
Michał Janiszewski
6b514d1e3a
Fix possible issues highlighted at higher warn levels
...
Mostly possibly uninitialized values and signedness
2016-02-26 12:54:00 +01:00
Ted John
74973a4a97
Merge pull request #2950 from janisozaur/ride-names
...
Rename ride_entry functions and provide better logging
2016-02-25 12:43:19 +00:00
Michał Janiszewski
14bff0c66f
Rename rct_ride_type to rct_ride_entry
2016-02-25 13:33:19 +01:00
IntelOrca
b0887f174b
split sound and music mixing correctly, closes #1270
2016-02-24 22:42:50 +00:00
Michał Janiszewski
eb645cd4f3
Rename ride_entry functions and provide better logging
...
For hacked rides, provide the name of offender in the log.
2016-02-24 22:23:33 +01:00
duncanspumpkin
53df541a39
Relabelled sprite_flags to flags. Relabelled peep/fountain flags
2016-02-23 17:22:19 +00:00
duncanspumpkin
5340af4a12
Refactor sprite_flags
2016-02-23 17:09:53 +00:00
duncanspumpkin
5eb3ca8f36
Label var_1F and var_20
2016-02-22 18:05:59 +00:00
duncanspumpkin
f68fe7d24b
Fix vehicles disobeying gravity when crashing on certain tracks
2016-02-21 09:40:50 +00:00
IntelOrca
caf8b45dc3
remove usages of 0x00F441D2
2016-02-20 15:52:38 +00:00
IntelOrca
edbca479e3
remove old usages of 0x00993CCC and 0x00F441D3
2016-02-20 15:50:05 +00:00
duncanspumpkin
1fb1c69d86
Label more vehicle offsets
2016-02-19 18:15:19 +00:00
duncanspumpkin
884bcd2c8a
Fix #2971 . Monorails now correctly accelerate.
...
Issue was caused by checking the wrong vehicle entry for acceleration speed. This was introduced by a bug fix on the weekend
2016-02-18 22:24:40 +00:00
duncanspumpkin
14231ef24d
Label vehicle offsets
2016-02-18 21:47:24 +00:00
duncanspumpkin
772502309f
Label ride offsets
2016-02-18 20:58:22 +00:00
duncanspumpkin
f267af3356
Fix chairlift bullwheel rotation animation.
...
Issue caused by incorrect check for breakdown
2016-02-18 20:32:04 +00:00
duncanspumpkin
9e391d7e03
Label known offsets
2016-02-17 18:22:38 +00:00
IntelOrca
5cf0c4bd07
remove commented out callproc/funcs
2016-02-16 20:10:24 +00:00
duncanspumpkin
cd2d14fcec
Reload vehicleEntry on change in car to fix special trains.
...
You can have different flags set for different train cars
2016-02-14 19:52:35 +00:00
duncanspumpkin
843b588b15
Remove redundant callproc code / comments.
2016-02-14 09:34:30 +00:00
Wirlie
4e3261decb
One issue fixed with Ferris Wheel
2016-02-13 20:29:41 -06:00
Alexander Overvoorde
8f91375530
Add missing line in ferris wheel rotation code
2016-02-12 22:11:10 +01:00
Alexander Overvoorde
94d73f0c90
Fix ferris wheel rotating one extra time ( fixes #2918 )
2016-02-12 01:19:16 +01:00
duncanspumpkin
c53ce355fa
Fix #2827 . Chairlifts now create vehicles correctly.
...
Issue was caused by incorrectly returning on successfully finding the next track piece. This in turn would cause the chairlift to not realise it was on an end station piece.
2016-02-02 18:52:41 +00:00
duncanspumpkin
c879c1697e
Fix #2110 . Boat hire mode no longer causes a crash with incorrect vehicle type
...
This fixes the crash but you can't at present set the number of cars to 1 so its still not completely possible to do what @webhawk wanted
2016-01-25 18:20:46 +00:00
duncanspumpkin
7cf156a86a
Fix #2771 . Observation towers now spin correctly.
...
Issue was caused by mistyping the variable name
2016-01-24 08:15:10 +00:00