Commit Graph

201 Commits

Author SHA1 Message Date
truelight
65f5ec13f6 (svn r6142) -Codechange: added WaypointID (sorry DV, couldn't splits it anymore)
-Codechange: introduced DestinationID, which is in fact an union of several types
  Used in Order struct, so no longer StationID is abused for all targets.
  Hangars are a big exception, as they use a station-id with GOTO_DEPOT (go figure)
2006-08-26 16:34:03 +00:00
truelight
213c71be3f (svn r6053) -Codechange: renamed all IsXXXIndex to IsValidXXXID
-Codechange: IsValidXXXID now also checks if XXX is really valid, not if the number is within range
  Both changes again in preperation of the new mem-pool system, which requires this.
  IsValidXXXID is not a bit less pretty, but that will be cleaned up after the new mem-pool system
2006-08-22 18:15:17 +00:00
truelight
bdc1d681a7 (svn r6052) -Codechange: change OrderType (order->type) in a typedef
-Codechange: renamed DeleteDestinationFromVehicleOrder to RemoveOrderFromAllVehicles to reflect his function better
-Codechange: changed the params of RemoveOrderFromAllVehicles, to avoid unneeded variable-creation
2006-08-22 17:13:49 +00:00
rubidium
908d3bcfe6 (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct. 2006-08-22 14:38:37 +00:00
rubidium
db397d5a75 (svn r6002) -Cleanup: remove the now redundant BASE_YEAR constant. 2006-08-20 19:05:28 +00:00
rubidium
e87e065e41 (svn r5926) -Codechange: make _cur_year contain the full year, instead of the offset since 1920
-Codechange: store all year related variables that are _not_ stored in a savegame/transported over the network in the same format as _cur_year
2006-08-16 11:39:55 +00:00
Darkvater
8152d0a223 (svn r5899) - Fix [FS#242]: Multistop not working when using NPF (r5033) (mart3p) 2006-08-14 23:11:59 +00:00
rubidium
9fc837ad85 (svn r5887) -Cleanup: move date related functions, defines and variables to date.[ch]
-Cleanup: fix whitespace related coding style issues in date.[ch]
-Cleanup: make original comments doxygen compatible and remove/change outdated comments
2006-08-14 14:21:15 +00:00
peter1138
8048e8c5bd (svn r5822) - NewGRF: add support for callback 31, vehicle start/stop check. This allows a set to disallow a vehicle from being started, i.e. to not be able to leave the depot. This is almost a partner to callback 1D. 2006-08-09 21:11:45 +00:00
peter1138
53d2650d9b (svn r5819) - NewGRF: add support for refit costs specified in NewGRF. This may affect the default refit costs for the default rail vehicles. 2006-08-09 20:44:23 +00:00
tron
86e3804dad (svn r5617) if cascade -> switch 2006-07-26 10:50:46 +00:00
tron
4ad467cbce (svn r5607) -Regression [r3597]: Let a road vehicle only overtake if there is no vehicle close except the two involved 2006-07-25 19:18:31 +00:00
peter1138
34e18cbdfe (svn r5427) - Codechange: testing for "== true" is redundant. 2006-06-29 08:58:08 +00:00
tron
772fbda3e3 (svn r5391) Miscellaneous, mostly bracing and whitespace, nothing spectacular 2006-06-27 21:25:53 +00:00
peter1138
67ce8b9ea0 (svn r5191) - NewGRF: add cargo refit support for road vehicles 2006-06-09 07:45:26 +00:00
tron
7fd88e5798 (svn r5155) - Remove the bridge branch merge (revision r5070) 2006-06-07 19:35:21 +00:00
tron
d26e40ca7e (svn r5118) Add IsRoadVehInDepot{Stopped,}() 2006-06-05 10:23:18 +00:00
tron
5dd68173c8 (svn r5117) Remove a redundant check: If a road vehicle is in the state 'in depot', don't test if it's a road depot 2006-06-05 09:54:58 +00:00
tron
9ee944cabb (svn r5094) Remove _new_{aircraft,roadveh,ship,train,wagon}_id. _new_vehicle_id is enough. 2006-06-04 09:28:33 +00:00
KUDr
6b1f0d610c (svn r5093) -CodeChange: [YAPF] min. debug level changed from 1 to 3 and 4 for frequent debug messages (performance stats) 2006-06-04 09:13:59 +00:00
KUDr
01aecb8416 (svn r5080) -Fix: RVs can enter other player's depot or roadstop (introduced by YAPF related change of GetTileTrackStatus() - r4419) 2006-06-02 19:29:11 +00:00
celestar
b618b75c9b (svn r5070) Merged the bridge branch
-Feature: Bridges can now be placed above:
	Any railway track combination (excluding depots and waypoints)
	Any road combination (excluding depots)
	Clear tiles (duh), including fields
	Tunnel entrances
	Bridge heads

Thanks to Tron for idea and implementation, KUDr for the yapf synchronization and many others for hours of testing

There are still a number of visual problems remaining, especially when electric railways are on or under the bridge.
DO NOT REPORT THOSE BUGS FOR THE TIME BEING please.
2006-06-02 13:05:41 +00:00
KUDr
af1b942906 (svn r5033) -CodeChange: [YAPF] RoadFindPathToStop() can now use YAPF for multistop handling. 2006-05-30 10:53:27 +00:00
KUDr
308f27a3de (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing. 2006-05-27 16:12:16 +00:00
peter1138
70306b544f (svn r4910) - NewGRF: add and initialize cargo subtype for vehicle visual variations 2006-05-19 10:04:03 +00:00
bjarni
f17a23e06a (svn r4826) -Fix: [autoreplace] fixed possible problem when autoreplacing and was number of vehicles (of a type, not total) was reached
now the new vehicle gets the same number as the old one, completely removing the problem where we could run out of numbers
	since we don't have to find free numbers for the new vehicles, autoreplace should be somewhat faster, specially in late games
	NOTE: in CmdBuildRailVehicle(), bit 0 and 1 in p2 have been switched to make the meaning of bit 0 consistent with the other build commands. CmdCloneVehicle() is modified to follow this as well
2006-05-11 13:31:14 +00:00
rubidium
2a337ab009 (svn r4789) - Codechange: rename RoadType to RoadTileType and ROAD_{NORMAL,CROSSING,DEPOT} to ROAD_TILE_* for consistency 2006-05-09 08:25:31 +00:00
tron
6dbc9c9ced (svn r4554) Replace magic numbers by TILE_{HEIGHT,SIZE} 2006-04-23 19:35:36 +00:00
Darkvater
0a0b8f22aa (svn r4529) - Codechange: Use proper naming for hex numbers in debug prints eg. 0xF3A6. Use fixed lengths where applicable (newgrf). Unfortunately '%#X' is unusable since it gives 0XFF3 and '%#x' gives 0xff3 while we want 0xFF3 :P 2006-04-22 13:56:16 +00:00
celestar
78f95ecdeb (svn r4507) Just a comment 2006-04-21 20:10:53 +00:00
celestar
dd3a3adbbd (svn r4506) -Fix: (FS#95) Use the tile hash when pathfinding to a depot. Eats a tiny bit of performance, but the likelihood that the depot is found is greatly increased 2006-04-21 20:08:25 +00:00
Darkvater
fd8e02119c (svn r4435) - Fix: an assertion triggered when trying to remove a bridge with the remove-tool (r4348 surfaced this). In CmdRemoveRoad tiletype was not checked for ownership. Intorudce IsLevelCrossingTile() which checks if a tile is a crossing without knowing the type. Suggested by peter1138 and Tron. 2006-04-15 20:07:42 +00:00
belugas
fbf6dd2cb9 (svn r4359) MSV6 Release mode now compiles (problem of UINT_MAX. stdafx.h should be the first include). Thanks to KUDr for solution and testing 2006-04-11 15:18:22 +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
tron
d68d287708 (svn r4326) Only reduce the slot age of a vehicle if it has a slot assigned 2006-04-08 14:18:39 +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
celestar
6443c14ebd (svn r4246) -Codechange. Replaced about 100 occurences of '16' by TILE_SIZE 2006-04-03 05:32:11 +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
tron
c40740e058 (svn r4120) Use the new station functions where appropriate 2006-03-26 19:20:15 +00:00
tron
f6285a659c (svn r4079) Add GetSation{Index,ByTile}() to get the station index resp. the station from a tile 2006-03-24 08:55:08 +00:00
celestar
d0908375f4 (svn r3909) [multistop]
-Codechange: No longer hijack the VS_STOPPED flag when waiting for a slot.
-Fix: Vehicles waiting for slots can still be controlled (sent to depot, orders modified, ...)
-Fix: Vehicles no longer stop on crossings and during overtake operations
2006-03-16 16:47:39 +00:00
tron
00cf5c9acf (svn r3832) Replace some magic numbers by (Diag)Direction enums 2006-03-12 17:42:04 +00:00
tron
0100871412 (svn r3830) Move IsTunnelTile() from tile.h to tunnel_map.h and add IsTunnel(), which just checks for a tunnel, but not the tile type as IsTunnelTile() does 2006-03-12 15:04:03 +00:00
tron
7803f259e2 (svn r3798) Fix typo in r3795 2006-03-08 20:25:28 +00:00
tron
cf7b94254e (svn r3796) When unmagicfying code, do it Right(tm) and also give the variables sensible names. I flipped a 'b' and a 'd' in r3785 2006-03-08 19:47:18 +00:00
tron
86550c94bc (svn r3795) Add a function to request the orientation of a depot 2006-03-08 15:29:23 +00:00
tron
ab9af3b05d (svn r3787) Use DirToDiagDir() instead of >> 1 2006-03-08 08:28:48 +00:00
tron
fa6632ec32 (svn r3786) More work for DirDiff 2006-03-08 08:16:31 +00:00
tron
f0d82204e0 (svn r3785) Replace some if-magic to determine the turning direction for road vehicles with the new DirDiff stuff 2006-03-08 07:50:26 +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