1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-29 17:54:50 +01:00
Commit Graph

586 Commits

Author SHA1 Message Date
zaxcav
269571edcc get_ride_queue_end() fails if any tile in the queue goes up towards the station entry.
In this situation the pathfinding goal is set to the station entry location rather than the queue end location.
2016-09-29 22:02:21 +02:00
Marijn van der Werf
487d6d8f15 Remove unnecessary addresses.h imports 2016-09-17 20:59:55 +01:00
Ted John
7cecdeba3f Integrate addresses from peep.c 2016-09-12 21:12:38 +01:00
Ted John
1511143ea9 Remove commented out RCT2_GLOBALs 2016-09-12 20:57:36 +01:00
Ted John
148e6c3cd1 Remove unused global in staff.c 2016-09-12 20:53:10 +01:00
Michał Janiszewski
84dc29b929 Make sure shifted value is unsigned 2016-09-11 21:20:48 +02:00
Ted John
7edcd11aa7 Integrate entertainer costumes 2016-09-11 00:40:51 +01:00
Ted John
2299b22cbc Integrate staff variables 2016-09-10 15:17:18 +01:00
Ted John
708efdd08c Integrate unknown game variables 2016-09-10 14:46:53 +01:00
Ted John
3b0b8a12d1 Integrate ride count 2016-09-10 13:40:58 +01:00
Ted John
35fd831d57 Remove unread variable 2016-09-04 21:58:25 +01:00
Ted John
a3c14b59dc Integrate _unk_F1AEF0 2016-09-04 21:56:56 +01:00
Ted John
a9f17a5ded Integrate _unk_F1AEF1 2016-09-04 21:55:06 +01:00
Ted John
3d4b938be2 Integrate local in peep_update_fixing_sub_state_9 2016-09-04 21:53:19 +01:00
Ted John
925358134a Integrate locals in get_ride_queue_end 2016-09-04 21:50:41 +01:00
Ted John
2cd16a6fe5 Remove unread variable 2016-09-04 21:47:05 +01:00
Ted John
826585c3fc Integrate _peepRideConsideration 2016-09-04 21:43:37 +01:00
Ted John
147493f85a Integrate distanceThreshold local 2016-09-04 21:39:11 +01:00
Ted John
10cafb479c Integrate _peepRideEntranceExitElement 2016-09-04 21:36:01 +01:00
Ted John
b4d2d27c9a Integrate _unk_F1EE18 2016-09-04 21:33:27 +01:00
Ted John
6a665330c2 Integrate gCommonStringFormatBuffer 2016-09-04 15:55:37 +01:00
Ted John
ae0eb1804c Integrate gParkRatingCasualtyPenalty 2016-09-04 15:44:59 +01:00
Ted John
17b69d257b Merge pull request #4097 from marijnvdwerf/clean/string-ids-2
Continue string ID cleanup
2016-08-28 14:05:13 +01:00
Ted John
76043d4050 Fix peep thoughts crashing on x64 2016-08-28 00:37:10 +01:00
Ted John
8cf7e87b5c Fix many warnings for x64 2016-08-27 23:32:15 +01:00
Duncan
6cf546820a Merge pull request #4326 from zaxcav/queueAsNormalPath
Treat queues not connected to rides as normal paths in the pathfinding.
2016-08-23 18:40:10 +01:00
zaxcav
1a5b1197d3 Treat queues not connected to rides as normal paths in the pathfinding.
Queue path tiles used as normal paths can otherwise cause search loops that the pathfinding does not detect, resulting in pathfinding problems.
2016-08-23 13:03:01 +02:00
zaxcav
02ae6c7c4f Share maxTilesChecked over all search directions.
Previouly, when maxTilesChecked was exceeded before all search directions were checked the search results could cause path finding issues. This ensures all search directions will always be searched.
2016-08-23 12:39:19 +02:00
duncanspumpkin
8ffe0fb4b6 Fix #4320. Ignoring no entry signs caused by refactor when originally implementing function. 2016-08-22 21:08:53 +01:00
Ted John
25328bccc9 Merge pull request #4221 from zaxcav/pathfind
Path finding fixes and optimisations
2016-08-21 21:34:12 +01:00
zaxcav
c3dee036a7 Use memset() to initialise _peepPathFindHistory. 2016-08-21 22:24:56 +02:00
zaxcav
7711ab811e Fix typo affecting Appveyor build. 2016-08-21 22:23:38 +02:00
zaxcav
c1298f3be4 Ignore ride queues when determining 'thin' junctions.
Why? In prinicple, a queue connected to a path should not be seen as causing a junction in that path.  Rather a ride queue should be treated equivalently to ride entrances/exits. For the path finding search this means that maxNumJunctions are not consumed when walking past ride queues (unless there is a legitimate path junction there).

Remove the unused arguement 'dist' from get_ride_queue_end().
2016-08-21 22:23:38 +02:00
zaxcav
e559e2ce68 Generalise peep entrance station selection
Remove gPeepFindAltStationNum replacing it with numEntranceStations, which is much simpler to understand.

For rides with multiple entrance stations that sync with adjacent stations, generalise cycling the station entrance selected by the peep through all of the ride's entrance stations (not limited to only stations 0 and 1) to enable this entrance cycling behaviour for rides with >= 2 entrance stations including rides with split entrance/exit stations (where the entrance stations are not stations 0 & 1).
2016-08-21 22:23:38 +02:00
zaxcav
fa2e16e42a Update path finding logging to use log_information, etc 2016-08-21 22:23:38 +02:00
zaxcav
dd32ed3827 Revert changes to maxNumJunctions in commit 9c5df6c 2016-08-21 22:23:38 +02:00
zaxcav
76974d2d45 Rebalance maxNumJunctions - increase value.
Remove earlier optimisation to heuristic search that was preventing searching for shorter paths once a path to the goal was reached.

Resolve Travis warnings.
2016-08-21 22:23:38 +02:00
zaxcav
9bf5707494 Rebalance maxNumJunctions to avoid exceeding maxTileChecked limit
With the changes to the path finding, a similar search space to the original now corresponds to half the maxNumJunctions value.

Added warning message when maxTilesChecked is exceeded - path finding issues are to be expected in that case.

Removed some commented out code left over in the previous commit.
2016-08-21 22:23:38 +02:00
zaxcav
a768be5e88 Fix the peep path finding
In the heuristic search, tiles in wide path were always being handled as junctions.  Changed to handle junctions according to the path thinning.

There was no search loop detection.  Added loop detection for returning to the starting location and any of the junctions visited in the current search path.

Various other optimisations added.
2016-08-21 22:23:38 +02:00
Marijn van der Werf
3a7fa512a2 Use rct_string_id as type where applicable 2016-08-21 16:33:37 +02:00
Ted John
63eb3580c4 Fix peep invalidation out of range
When a new peep thought was created, the peep window action widget is invalidated. This would only be valid if the first tab is active. Instead just invalidate the whole window.
2016-08-21 15:21:48 +01:00
Marijn van der Werf
9319bee91f Use already integrated data 2016-08-20 22:12:52 +01:00
Marijn van der Werf
b9a4ef86df Integrate litter data
0x0097EF6C
0x0097EFCC
0x0097EFE8
2016-08-16 10:55:38 +01:00
Ted John
6a3853c09f Merge pull request #4287 from marijnvdwerf/clean/data-19
[Clean] Integrate more peep data
2016-08-14 20:43:15 +01:00
Marijn van der Werf
1d883eea2f Integrate data at 0x00992A5C 2016-08-14 21:14:33 +02:00
Marijn van der Werf
5acc9f813b Integrate 0x00992A4C 2016-08-14 21:10:21 +02:00
Marijn van der Werf
a56dae2953 Integrate data at 0x00992A3C 2016-08-14 20:27:12 +02:00
Marijn van der Werf
de1c69d5d9 Integrate 0x009929C8 and 0x009929CA 2016-08-14 18:05:15 +02:00
Ted John
154bb0d475 Integrate guest and park globals
Note: this also fixes loading of landscapes in the editor which did not use the new SC loading code.
2016-08-14 15:50:52 +01:00
Ted John
78b788e660 Merge pull request #4282 from marijnvdwerf/clean/data-15-maze
[Cleanup] Integrate peep maze data
2016-08-14 14:27:19 +01:00