Age | Commit message (Collapse) | Author |
|
|
|
-Codechange: Completely rewritten the slot assignment system. It now consumes less CPU cycles and memory
-Codechange: Increased maximum number of roadstops to 16.
-Fix: Several conditions where a slot becomes unliked from a vehicle
-Codechange: ClearSlot now only takes one parameter, the vehicle
-Feature: Console command 'clearslots' to clear ALL currently assinged slots. debug usage only
-Feature: vehicles that cannot get a slot now wait on the road instead of planlessly blocking stops or circling around
-Codechange: Adjusted debug levels
TODO: Make the slot finder compatible with (a) pathfinder(s).
|
|
This fixes an assert introduced in r3663. Also fix the return type of GetRoadStopType().
|
|
instead of a station's first road stop. This only has effect with road vehicle queuing disabled.
|
|
road pieces
|
|
status field and had the sensible name 'b'; instead directly use the road stop status field
|
|
|
|
use INVALID_VEHICLE instead of nonsense INVALID_SLOT.
|
|
add consts, reduce indentation level by short-circuit logic, convert if cascades to switch, whitespace, bracing, plus some minor stuff
|
|
|
|
vehicle orders by something remotly comprehensible
|
|
- Don't treat non-booleans as booleans
- Reduce variable scope
- Bracing
- Use DeMorgan's law to make conditionals easier to read
- if cascade -> switch
- Replace some magic numbers by symbolic names
- Avoid assignments within other statements
|
|
newgrf_engine.[ch], and add the new files to project files.
|
|
|
|
|
|
|
|
|
|
|
|
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.
|
|
due to not being able to build a vehicle. Triggered when cloning a retired design
|
|
operation while overtaking in a curve (tnx to guru3, Tron and peter1138)
-Codechange: while at that, removed a local variable (more pretty :))
|
|
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
|
|
|
|
|
|
blocks to allow use of Random() instead of InteractiveRandom(), which will alleviate some possible network desyncs.
|
|
Revisions in detail: 2542, 3226 (partial), 3229, 3231, 3232, 3238, 3242-3245, 3251, 3253, 3260, 3263, 3265, 3266, 3269, 3277, 3278, 3279, 3283 (partial), 3304, 3305, 3306
|
|
|
|
|
|
-Add: added several hooks (event-callbacks) for road-related-stuff
|
|
unnecessary use of pointers and using the *BIT() macros.
|
|
avoiding function declarations in .c files and unnecessary indirection
|
|
- CHANCE*() instead of mumbling strange numbers
|
|
|
|
when nothing was changed
due to the FOR_ALL_VEHICLES(), redrawing those windows are slow
|
|
line 378
running MaybeReplaceVehicle() is now delayed until after the loop in CallVehicleTicks()
This avoids selling the vehicle the loop currently works with (and continues to work with afterwards)
|
|
this var works like _new_train_id and the rest of that kind of vars, except it is set each time a vehicle is build, nomatter what type
this is a nice tool to code vehicle independent code, which in turn can reduce code duplication
Right now it's used in ReplaceVehicle() and CmdCloneVehicle()
|
|
this is a complete rewrite, that makes use of existing commands like build and sell
this means that multiheaded train engines are replaced correctly
|
|
vehicles using the cargo type and not a magic engine number
|
|
- const, whitespace, indentation, bracing, GB/SB, pointless casts
- use the trinary operator where appropriate
- data types (uint[] -> AcceptedCargo, ...)
- if cascade -> switch
- if (ptr) -> if (ptr != NULL)
- DeMorgan's Law
- Fix some comments
- 0 -> '\0', change magic numbers to symbolic constants
|
|
|
|
proper types or just removing them
|
|
plus some related changes (mostly casts)
|
|
references to our (new) original engine/vehicle tables.
|
|
strings more explicit
|
|
inconsistencies while trying to locate bug 1244167
|
|
|
|
|
|
|
|
signed/unsigned warnings
|
|
|