src/ai/api/ai_vehiclelist.cpp
branchnoai
changeset 9745 fb2454d70f37
parent 9740 a98f20bce404
child 9746 e4ab7ea8d897
equal deleted inserted replaced
9744:7297fcf46e03 9745:fb2454d70f37
    10 	FOR_ALL_VEHICLES(v) {
    10 	FOR_ALL_VEHICLES(v) {
    11 		if (v->owner == _current_player && v->IsPrimaryVehicle()) this->AddItem(v->index);
    11 		if (v->owner == _current_player && v->IsPrimaryVehicle()) this->AddItem(v->index);
    12 	}
    12 	}
    13 }
    13 }
    14 
    14 
    15 AIStationVehicleList::AIStationVehicleList(StationID station_id)
    15 AIVehicleList_Station::AIVehicleList_Station(StationID station_id)
    16 {
    16 {
       
    17 	this->Clear();
    17 	if (!AIStation::IsValidStation(station_id)) return;
    18 	if (!AIStation::IsValidStation(station_id)) return;
    18 
    19 
    19 	Vehicle *v;
    20 	Vehicle *v;
    20 
    21 
    21 	FOR_ALL_VEHICLES(v) {
    22 	FOR_ALL_VEHICLES(v) {