(svn r16391) -Codechange: use Train instead of Vehicle where appropriate.

This commit is contained in:
rubidium
2009-05-22 22:22:46 +00:00
parent 7a37220881
commit 80e94b9bb1
33 changed files with 429 additions and 387 deletions

View File

@@ -7,8 +7,8 @@
#include "station_map.h"
#include "tunnelbridge_map.h"
#include "vehicle_func.h"
#include "vehicle_base.h"
#include "functions.h"
#include "train.h"
/** these are the maximums used for updating signal blocks */
@@ -185,7 +185,7 @@ static SmallSet<DiagDirection, SIG_GLOB_SIZE> _globset("_globset"); ///< set of
/** Check whether there is a train on rail, not in a depot */
static Vehicle *TrainOnTileEnum(Vehicle *v, void *)
{
if (v->type != VEH_TRAIN || v->u.rail.track == TRACK_BIT_DEPOT) return NULL;
if (v->type != VEH_TRAIN || ((Train *)v)->u.rail.track == TRACK_BIT_DEPOT) return NULL;
return v;
}