src/rail_cmd.cpp
changeset 5993 956d341d930e
parent 5991 ec2eebfe86de
child 6106 2898cd9417fd
equal deleted inserted replaced
5992:ab950cd7e7f1 5993:956d341d930e
  1967 		/* make sure a train is not entering the tile from behind */
  1967 		/* make sure a train is not entering the tile from behind */
  1968 		return VETSB_CANNOT_ENTER;
  1968 		return VETSB_CANNOT_ENTER;
  1969 	} else if (_fractcoords_enter[dir] == fract_coord) {
  1969 	} else if (_fractcoords_enter[dir] == fract_coord) {
  1970 		if (DiagDirToDir(ReverseDiagDir(dir)) == v->direction) {
  1970 		if (DiagDirToDir(ReverseDiagDir(dir)) == v->direction) {
  1971 			/* enter the depot */
  1971 			/* enter the depot */
  1972 			v->u.rail.track = TRACK_BIT_SPECIAL,
  1972 			v->u.rail.track = TRACK_BIT_DEPOT,
  1973 			v->vehstatus |= VS_HIDDEN; /* hide it */
  1973 			v->vehstatus |= VS_HIDDEN; /* hide it */
  1974 			v->direction = ReverseDir(v->direction);
  1974 			v->direction = ReverseDir(v->direction);
  1975 			if (v->next == NULL) VehicleEnterDepot(v);
  1975 			if (v->next == NULL) VehicleEnterDepot(v);
  1976 			v->tile = tile;
  1976 			v->tile = tile;
  1977 
  1977