bjarni
4a1d9a4775
(svn r2167) -fix: [autoreplace] trains now get the default cargo type if the engine
...
replaced from did not have cargo capacity (instead of refitting to passengers)
2005-04-08 15:40:44 +00:00
truelight
6a341663cc
(svn r2156) -Fix: in revision 2104 someone forgot to add a very important check in
...
GetPrevVehicleInChain; this caused some nasty bugs in depots, like
wagons without engines complain about not being stopped, and stuff like
that. Hopefully this fixes those problems. With a big tnx to BJH for his
perfect demo!
2005-04-06 15:39:18 +00:00
bjarni
19b87abd56
(svn r2139) -fix: "[ 1146215 ] Engine power not updated w/auto replace" autoreplace now forces an update of the cache. It should not affect gameplay as the
...
cache is updated each time the train starts moving, it's just an instant update of the detail window
2005-04-03 09:38:13 +00:00
truelight
4c9f0eefb4
(svn r2109) -Fix: use FindVehicleOnTileZ(tile, 0) over FindVehicleBetween(tile, tile, 0)
2005-03-30 09:25:20 +00:00
celestar
58a72bf483
(svn r2105) -Codechange: Added a cache for the first vehicle of a chain to increase performance, especially with many long trains
2005-03-29 11:19:10 +00:00
tron
e39cb78b73
(svn r2104) Simplify implementation of Get{First,Prev}VehicleInChain() and remove a pointless check
2005-03-29 08:37:44 +00:00
truelight
d1e158d6f7
(svn r2046) -Codechange: moved all waypoint code to waypoint.c/waypoint.h
...
-Codechange: rewrote some functions while moving waypoint-stuff
-Add: added support for 64k waypoints
-Fix: made the waypoint struct a bit more logic (no bit-fucking)
2005-03-24 17:03:37 +00:00
truelight
625d041e99
(svn r2045) -Fix: hopefully fixed the desync problem. Please all test this revision!!
...
(with tnx to Celestar, Hackykid, dp-_ and Tron)
2005-03-24 15:15:06 +00:00
truelight
49d69f6fa3
(svn r2041) -Fix: not all vehicles did get a day_proc call (because of rounding errors)
2005-03-24 13:59:44 +00:00
bjarni
e5abf58461
(svn r2024) -Fix: [autoreplace] reverted all changes involving v->set_for_replacement as they caused desyncs.
...
The bad sideeffect of this is that now no vehicle will automatically go to a depot anymore just
because it is set to be autoreplaced. We will have to find a better way to solve this problem.
Revisions reverted: 1640, 1707, 1709, 1710, 1712(but not the cheat prevention in this one)
2005-03-19 21:16:22 +00:00
tron
eea2dc6c78
(svn r1979) Const correctness
2005-03-09 21:54:52 +00:00
tron
a370af76d2
(svn r1898) Remove some unused macros from macros.h and move some others to more appropriate headers
2005-02-22 12:48:03 +00:00
tron
391cd5658f
(svn r1875) Effect vehicle overhaul: enumerate sprites, descriptive names for functions and miscellaneous improvements
2005-02-14 20:34:31 +00:00
tron
2b4b935351
(svn r1869) Fix some bugs in the bulldozer movement implementation.
...
Now they move in a sane pattern.
2005-02-13 11:31:35 +00:00
tron
8391c96fac
(svn r1868) Improve readability of the bulldozer movement code
2005-02-13 11:27:41 +00:00
tron
6d2b9d2c3a
(svn r1863) Give the effect vehicle type enums more descriptive names and use the enum as parameter type for CreateEffectVehicle*()
...
-Fix: [1116619] Generate the correct smoke type for diesel trains
2005-02-12 15:53:32 +00:00
tron
7cd19fe07a
(svn r1853) Move spritecache function declarations into a header of their own and use SpriteID as parameter type where appropriate
2005-02-10 05:43:30 +00:00
tron
6984d6cd31
(svn r1832) Next byte -> char iteration: custom names
2005-02-06 20:53:31 +00:00
truelight
bd7f37d592
(svn r1817) -Codechange: Moved depot-functions to depot.c
...
-Codechange: Added wrappers around depot-access (GetDepot no exists)
-Codechange: Made depot-functions a bit more logic (no longer
GetDepotByTile crashes your game when you request it on a non-depot tile)
-Add: made depots dynamic (yes, 64k depots are possible now)
2005-02-06 10:18:47 +00:00
truelight
99f3fe4c07
(svn r1786) -Fix: unitnumber is increased to 16bit, so now you can have up to 5000
...
trains in one game (instead of the 240 which was the current value).
Default max allowed vehicles per type is changed:
Trains: 500 (old 80)
Road: 500 (old 80)
Ships: 200 (old 40)
Aicraft: 300 (old 50)
(Tnx to Celestar and Darkvater for checking the patch)
2005-02-04 14:24:23 +00:00
truelight
f183ca5cc2
(svn r1783) -Add: Dynamic vehicles (now up to 64k of vehicles)
2005-02-04 13:23:29 +00:00
truelight
0668a6b485
(svn r1770) -Fix: Hopefully last pieces of code that are containing a station-id
...
(and should be an uint16, not uint8)
2005-02-02 16:16:43 +00:00
bjarni
7d967ad12a
(svn r1741) - Fix: added IsVehicleIndex() so it's possible to protect GetVehicle() from reading an invalid vehicle index
...
- Fix: added check for v->type in some commands, which expects v to be a specific type
Checks like this is needed to protect network servers from people, who hack their clients to either cheat or crash the server
NOTE: if I made a mistake here it can make a function unreachable when it should be used. Here is one place to look if something weird happens
2005-01-30 20:50:06 +00:00
celestar
3c82a2b3c7
(svn r1721) -Feature: It is now possible to build multiple road stations (up to 8) on
...
a single station.
Thanks to: Truelight for the saveload code, Darkvater and Hackykid for
network testing and Tron for proof-reading 1500 lines of diff.
2005-01-29 19:41:44 +00:00
tron
38587b60f7
(svn r1718) Use the enum TileType as parameter/return type for [GS]etTileType() instead of plain int.
...
This makes it necessary to rename TileType() to GetTileType() because a type and a function may not share the same name.
2005-01-29 15:12:40 +00:00
tron
39858e696b
(svn r1713) Split off several functions which query/set information about a single tile from map.h and put them into a seperate file tile.h
2005-01-29 12:19:05 +00:00
tron
372b9cb827
(svn r1696) Use GetTileSlope() instead of FindLandscapeHeightByTile() where it is sufficient. FindLandscapeHeightByTile() uses GetTileSlope() internally and adds some more info, which is discarded in these cases.
...
While touching the code make a bit more clear how GetBridgeHeight() works.
2005-01-27 12:52:20 +00:00
bjarni
7b242e2ea9
(svn r1690) - Fix: [autoreplace] Cheaters can no longer exploit autoreplace to get vehicles, that's not invented yet
...
- Fix: [autoreplace] Fixed a stupid bug introduced in r1687, that made a crash if anybody tried to autoreplace anything but an aircraft
2005-01-26 19:43:22 +00:00
bjarni
1d4de01a63
(svn r1687) - Feature: [autoreplace] server now checks for plane<->helicopter replacement and reject replacement if needed
2005-01-26 19:03:01 +00:00
tron
07cb3068ae
(svn r1676) Increase the size of TileIndex and TileIndexDiff to 32bits and adapt the save/load data and some other parts of the code to that change
...
WARNING: If i made any mistake here it WILL lead to corrupted savegames!
2005-01-25 21:43:57 +00:00
bjarni
879ca66041
(svn r1640) fix: now helicopters will use a hangar in schedule to be replaced in, even if they are only set to service there. Since helicopters are serviced at helipads, they will only go there if they needs to be replaced or renewed.
2005-01-24 18:21:23 +00:00
bjarni
cf862380fc
(svn r1629) added a counter to tell how many engines you have of each type to the autoreplace vehicle windows and made them show only the vehicles you actually have in the left list.
...
this also fixes some window updates issues when autoreplacing
2005-01-23 22:01:51 +00:00
truelight
b586a890f7
(svn r1612) -Fix: made sure that ->next pointers are set to NULL
2005-01-23 13:30:02 +00:00
tron
81ee2d931b
(svn r1610) Remove trailing whitespace (last time ever, i hope)
2005-01-23 13:09:35 +00:00
tron
94d5aeabb2
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
2005-01-22 20:23:18 +00:00
darkvater
0d43eb3ab8
(svn r1583) -Fix: You should no longer be able to delete bridges on any type of underground when there is a vehicle on it
2005-01-21 19:52:32 +00:00
darkvater
ada9fc873e
(svn r1569) -Fix: signed/unsigned mismatch
2005-01-19 19:32:33 +00:00
bjarni
467e4b82bf
(svn r1568) made an enum of train subtypes to make the code more readable
2005-01-19 19:15:03 +00:00
tron
654d75f795
(svn r1564) ISO C90 forbids mixed declarations and code (bad bjarni, no cookie)
2005-01-19 05:55:30 +00:00
bjarni
75863ee5cd
(svn r1563) fix: autoreplaced trains now sets wagon override properly
2005-01-19 01:18:29 +00:00
bjarni
5f549396f4
(svn r1561) Fix: autoreplacing a singleheaded engine into a dualheaded engine now adds the the rear engine
...
autoreplacing a dualheaded engine into a singleheaded engine now sells the rear engine
as a sideeffect of this, the price for replacing both engines are now added and displayed once from the depot(instead of two identical numbers written on top of each other, looking like one)
fix: cost for autorenew dualheaded engines were doubled and their value where doubled too
2005-01-18 23:27:06 +00:00
tron
0d85b92e43
(svn r1559) Use IsTileType() instead of bit shifting and comparisons
2005-01-18 17:19:34 +00:00
darkvater
0fc9b656e2
(svn r1538) -Feature: [988816] Disable servicing when breakdowns set to none (jaguar7)
2005-01-16 12:29:52 +00:00
tron
61a6bc544d
(svn r1536) Move GET_TILEHEIGHT, GET_TILETYPE and IS_TILETYPE to map.h, turn them into inline functions and add some asserts
2005-01-16 11:24:58 +00:00
truelight
7cafdf3b0b
(svn r1525) -Codechange: rewrote the _order_array, now it can be made dynamic.
...
-Codechange: renamed all 'schedule' stuff to 'order(list)'
-Codechange: moved all order-stuff to order_cmd.c / order.h
-Codechange: vehicles that share orders are now linked to eachother
with next_shared/prev_shared in Vehicle
Developers: please use AssignOrder to assign data to an order. If not,
you _WILL_ make the save-routine to assert!
2005-01-15 19:06:22 +00:00
truelight
3e84b9781f
(svn r1448) -Fix: The current_order of a vehicle is now correctly saved (caused
...
massive desyncs)
Warning: savegames which are made with the nightly of 08-01-2005 will
NO LONGER work!!
2005-01-09 18:49:18 +00:00
truelight
95a879fb7d
(svn r1429) Change: bumped savegame to revision 5.
...
- Now orders are bigger
- Now _map2 is official 16 bits
2005-01-08 12:47:26 +00:00
bjarni
4068eba111
(svn r1427) fixed issue where the wrong sprite could be used if autoreplacing between single and multiheaded trains
2005-01-08 10:38:07 +00:00
truelight
1d9d128f65
(svn r1426) -Codechange: cleaned up the reference code in the saveload routines
...
-Codechange: removed next_in_chain_old, and saved ->next for Vehicles
(and bumped savegame revision for that to version 4.4)
-Codechange: Added _sl.full_version, which has both major and minor version
2005-01-08 09:48:08 +00:00
bjarni
2b6e6a3846
(svn r1421) improved autoreplace multiheaded trains. It now remembers the current heading for an engine instead of turning all of them like the first one and the last the other way
2005-01-08 01:05:24 +00:00