peter1138
100cc6fea7
(svn r4471) - Pools: Add a facility for calling a custom function during pool block clean up.
2006-04-18 18:48:50 +00:00
tron
35e93e451f
(svn r4342) Change the first two parameters of commands - virtual pixel coordinates of the tile to operate on - to a TileIndex
...
Remove DoCommandByTile(), because now it does the same as DoCommand()
2006-04-10 07:15:58 +00:00
celestar
b0b5641639
(svn r4341) -Fix (FS#101) When a player got bankrupt, slots were not cleared, because vehicles got deleted directly by DeleteVehicle
2006-04-09 18:35:24 +00:00
celestar
8cbe98a3fd
(svn r4259) -[multistop] Fix/Feature/Codechange:
...
1) Improved the road vehicle allocation (aka slotting) for multistop. Stops can now accept unlimited, er... 256, vehicles.
2) Removed the "wait for stop" feature, because it did not work in practise.
3) Slotting now ignores unreachable stations. Uses NPF at the moment because the old pathfinder cannot do it (yet)
4) Now matter how many vehicles approach a station, they will always be distributed evenly over existing stops.
5) Hopefully the last fundamental change to multistop
2006-04-03 14:25:32 +00:00
peter1138
39f21f5d85
(svn r4256) - Codechange: Replace lone map access in vehicle.c with its map accessor.
2006-04-03 12:41:31 +00:00
celestar
69e1c716e8
(svn r4249) -Codechange: Replace more occurences of 16 by TILE_SIZE and of 8 by TILE_HEIGHT. Reverted one change from the previous commit because it was faulty
2006-04-03 09:07:21 +00:00
celestar
6443c14ebd
(svn r4246) -Codechange. Replaced about 100 occurences of '16' by TILE_SIZE
2006-04-03 05:32:11 +00:00
bjarni
10358a773e
(svn r4228) -Fix: [autoreplace] allow replacement of wagons even when the engine fails to be replaced
2006-04-01 15:11:30 +00:00
peter1138
98c77c363f
(svn r4227) - Fix: Wagon replace nows checks if the cargo types are the same before seeing if it can refit.
2006-04-01 14:53:38 +00:00
celestar
2ab5b8e666
(svn r4215) -Codechange: Renamed *RoadStation* functions to *RoadStop* and moved them to station_map.h to keep consistency
2006-03-31 19:10:54 +00:00
peter1138
eb15688358
(svn r4201) - Codechange: Do for _engine_info[] what we do for _*_vehicle_info[]; create and use a function to retrieve data, and ensure constness.
2006-03-31 12:59:43 +00:00
bjarni
166465fa4e
(svn r4159) added missing comments about refitting in CmdCloneVehicle
2006-03-29 20:57:17 +00:00
bjarni
1fe0a3241f
(svn r4158) -Fix: [autoreplace] cost for refitting the new vehicle is now added to the cost animation. The player always paid for it, but it was not displayed until now
2006-03-29 20:41:15 +00:00
celestar
6c44bf5012
(svn r4150) -Feature: Merged elrails into trunk. Thanks to Tron for lots of code and proofreading, thanks to peter1138 for another lot of code and ideas.
2006-03-29 16:30:26 +00:00
belugas
ed86c3d818
(svn r4092) CodeChange : Named sprites instead of magic numbers plus create/use helper macro/enum for recoloring scheme
2006-03-24 18:16:39 +00:00
Darkvater
650b1b0c93
(svn r3895) - Add proper SLE(G)_CONDNULL macros for the empty space reservation in savegames and update where used
...
- Also add this capability to settings
2006-03-16 00:20:33 +00:00
tron
eeb5bf41a1
(svn r3831) Add and use GetRailDepotDirection()
2006-03-12 16:13:16 +00:00
tron
25606a2e0b
(svn r3816) Use existing accessors
2006-03-11 09:10:46 +00:00
bjarni
eac8e5e473
(svn r3811) -Fix: [autoreplace]: (FS#67) autoreplacing trains now keep their tile length instead of their pixel length
2006-03-10 10:01:56 +00:00
peter1138
fca5823238
(svn r3805) - [FS#62] Fix doxygen comments to refer to the correct parameter. (sulai)
2006-03-09 20:37:51 +00:00
tron
ab9af3b05d
(svn r3787) Use DirToDiagDir() instead of >> 1
2006-03-08 08:28:48 +00:00
tron
9273d0d2b9
(svn r3784) Add a type and functions to handle direction changes
2006-03-08 07:48:56 +00:00
tron
8cfcdaa733
(svn r3783) Replace further ints and magic numbers by Direction, DiagDirection and friends
2006-03-08 06:55:33 +00:00
tron
332b54d5a6
(svn r3757) -Feature: Delete news items about vehicles, when they get stale
...
This is used to delete
- all news about a vehicle, when it gets deleted
- "vehicle has stopped in depot" news, when it gets started
- "vehicle has invalid orders" news, when the orders get changed
2006-03-04 11:01:35 +00:00
tron
d851781663
(svn r3747) Change HASBIT() to return 0/1 instead of 0/value of tested bit, because the name suggests it does the former and current behavior broke in some places in very subtle ways (for example HASBIT(x, 0) != HASBIT(y, 1) doesn't work, returning a bool after HASBIT(x, 9) neither)
2006-03-03 19:42:09 +00:00
peter1138
058ccfb157
(svn r3717) - [2cc] Add 2cc colour maps and use for newgrf engines requiring them. Currently the second colour is fixed to be the player's colour.
2006-03-01 23:14:03 +00:00
peter1138
5a9f6081dd
(svn r3701) [2cc] move vehicle/engine palette functions out of header file and document the remaining definitions
2006-03-01 17:35:01 +00:00
Darkvater
bf27f0c77b
(svn r3627) - Change all hardcoded 255 max-saveload versions with the define SL_MAX_VERSION
2006-02-20 19:43:26 +00:00
peter1138
b5cd24f05d
(svn r3620) - 2cc: Replace use of macro to determine colour map with a function call for drawing of vehicles.
2006-02-20 09:26:07 +00:00
Darkvater
dac14d4210
(svn r3619) - Codechange: Simplify a NullStruct initialization in the vehicle array (merge the two together to avoid confusion)
2006-02-20 01:36:48 +00:00
truelight
d83711fb2e
(svn r3598) -Fix: suppress invalid warning by assigning value to variable
2006-02-13 21:47:02 +00:00
peter1138
30429dc4fb
(svn r3589) - Rename u.road.unk2 to u.road.blocked_ctr
2006-02-11 10:45:20 +00:00
peter1138
bc0b97ea2f
(svn r3579) v->u.rail.first_engine holds an engine type, not a vehicle index, so use INVALID_ENGINE.
2006-02-08 19:06:46 +00:00
peter1138
96cac20318
(svn r3576) - Allow unused wagons have their ->first set. This fixes the faulty cache warning message, and noticably speeds up depot operations in large games.
2006-02-08 08:18:29 +00:00
peter1138
f874b60636
(svn r3573) - Replace assert(0) with NOT_REACHED(). This commit sponsored by "giving Darkvater credit for the last three".
2006-02-07 19:11:51 +00:00
peter1138
cfdce5213e
(svn r3572) - Rewrite GetFreeUnitNumber() so that only one loop of vehicles is required. Instead a list of used/unused numbers is created and the first unused number is chosen. This significantly improves performance in large games.
2006-02-07 19:01:01 +00:00
peter1138
6bc6c34b5a
(svn r3571) - When loading a game, call TrainConsistChanged() for each train head separately before updating images, as v->first is used extensively in GetTrainImage() for custom graphics. This gives a significant speed improvement on loading a game.
2006-02-07 18:57:16 +00:00
bjarni
c77c99b3c7
(svn r3535) -Feature: [autoreplace] allow autoreplacing of train wagons
...
currently ALL available wagons are displayed in the right menu in the replace window
however the replacement will only be done if the new wagon can be refitted to carry same cargo as the old one is currently carrying
Since the standard vehicles do not have any valid wagon replacements, this feature can only be used when using newgrf sets
2006-02-04 18:25:07 +00:00
tron
1c3e8630fe
(svn r3511) More whitespace ([FS#46] by Rubidium)
2006-02-01 07:36:15 +00:00
tron
9712d6f639
(svn r3510) Fiddle with whitespace and parentheses
2006-02-01 06:32:03 +00:00
tron
ea45799d5b
(svn r3498) Fix the edge case for r3419/r3488: when a vehicle just enters a tile, the height difference can be 8
2006-01-31 19:06:02 +00:00
tron
8529923e01
(svn r3488) Simplify the check in r3419
2006-01-30 16:57:47 +00:00
Darkvater
25c7e1fe34
(svn r3482) - Fix: since multiheaded links are not saved anymore do NOT save them anymore at all, return the extra space. Since Bjarni's fix for this was abominable, the weird situation arises of 2 NULL structs of free space, of which the first isn't usable.
2006-01-29 22:40:51 +00:00
Darkvater
4014e36aec
(svn r3472) - [PBS] Remove from trunk. Anyone interested can still find it in branch/pbs. This reverts revisions r3158, r3140, r3075, r2977, r2674, r2625, r2621, r2529, r2528, r2525, r2524, r2519, r2517, r2516, r2507, r2499. (in conjunction with Tron)
...
- The only change is that the nsignalsw.grf file is kept and that existing nightlies with PBS signals get those signals converted to combo-signals.
2006-01-29 18:57:26 +00:00
Darkvater
ffb8c85b79
(svn r3419) - Fix: [FS#40] (Possible) game crash on removing track/road under bridge. This was caused by a wrong tile-occupancy testing where it was assumed that a vehicle's height is only a multitude of 8 (a single height-difference). This is incorrect as a vehicle on a slope will assume all height levels between the lower-and upper-bounds. The crash is still possible as seen in the Flyspray bugreport but this has a different cause.
2006-01-22 17:17:11 +00:00
bjarni
a4d1725de7
(svn r3403) -Codechange: [multiheaded engines] the references between the front and rear engines are no longer saved
...
instead the pointers are generated on load
2006-01-18 15:05:01 +00:00
peter1138
2222907a40
(svn r3396) - Autoreplace changes:
...
- Change fixed array per player to a single pool. This avoids future problems
with vehicle numbers and decreases savegame size. Engine replacements from
previous savegames will be lost.
- Move engine replacement code from players.c to engine.c.
(thanks to blathijs for rewriting this)
2006-01-12 15:52:18 +00:00
bjarni
8958c8b7b1
(svn r3390) -Fix: [autoreplace] fixed issue where autoreplace failed to attach the cars if the front engine was replaced
...
and the front engine was multiheaded and the first vehicle after it was the rear part of that engine
2006-01-08 12:20:13 +00:00
tron
2053685fb5
(svn r3367) Unify the 4 distinct CMD_CHANGE_{AIRCRAFT,ROADVEH,SHIP,TRAIN}_SERVICE_INT commands into one CMD_CHANGE_SERVICE_INT command.
...
As side effect this is a
-Fix: The default AI tried to change the service intervals of vehicles via the CMD_CHANGE_TRAIN_SERVICE_INT command - regardless of the type of the vehicle - which of course failed for non-trains
2006-01-05 21:35:54 +00:00
tron
318fe153eb
(svn r3365) Staticise 36 functions
2006-01-05 12:40:50 +00:00