Merge branch 'master' into jgrpp
# Conflicts: # .github/workflows/ci-build.yml # .github/workflows/release-linux.yml # .github/workflows/release-macos.yml # .github/workflows/release-windows.yml # .gitignore # COMPILING.md # src/company_gui.cpp # src/date_gui.cpp # src/engine.cpp # src/engine_func.h # src/fileio.cpp # src/linkgraph/linkgraph_gui.h # src/newgrf_debug_gui.cpp # src/newgrf_gui.cpp # src/order_gui.cpp # src/osk_gui.cpp # src/rail_gui.cpp # src/road_gui.cpp # src/script/api/script_event_types.hpp # src/sl/oldloader_sl.cpp # src/smallmap_gui.cpp # src/station_cmd.cpp # src/toolbar_gui.cpp # src/town_gui.cpp # src/transparency_gui.cpp # src/vehicle_gui.cpp # src/widget.cpp # src/widget_type.h # src/widgets/dropdown.cpp # src/widgets/dropdown_func.h # src/widgets/dropdown_type.h # src/widgets/group_widget.h # src/widgets/vehicle_widget.h # src/window.cpp # src/window_gui.h # src/window_type.h
This commit is contained in:
@@ -1812,10 +1812,17 @@ function Regression::Vehicle()
|
||||
print(" GetLastErrorString(): " + AIError.GetLastErrorString());
|
||||
|
||||
local list = AIVehicleList();
|
||||
local in_depot = AIVehicleList(AIVehicle.IsInDepot);
|
||||
local IsType = function(vehicle_id, type) {
|
||||
return AIVehicle.GetVehicleType(vehicle_id) == type;
|
||||
}
|
||||
local rv_list = AIVehicleList(IsType, AIVehicle.VT_ROAD);
|
||||
|
||||
print("");
|
||||
print("--VehicleList--");
|
||||
print(" Count(): " + list.Count());
|
||||
print(" InDepot Count(): " + in_depot.Count());
|
||||
print(" RoadVehicle Count(): " + rv_list.Count());
|
||||
list.Valuate(AIVehicle.GetLocation);
|
||||
print(" Location ListDump:");
|
||||
for (local i = list.Begin(); !list.IsEnd(); i = list.Next()) {
|
||||
|
@@ -9389,6 +9389,8 @@ ERROR: IsEnd() is invalid as Begin() is never called
|
||||
|
||||
--VehicleList--
|
||||
Count(): 5
|
||||
InDepot Count(): 4
|
||||
RoadVehicle Count(): 2
|
||||
Location ListDump:
|
||||
13 => 33417
|
||||
12 => 33417
|
||||
|
Reference in New Issue
Block a user