Road and TramTypes and available vehicles
Posted: 11 Jun 2020 23:52
Hello there,
I've experimenting with a RoadType and TramType grf, coding in NML 0.5.2 and I have sorted nearly all the graphics but almost all my defined types end up with empty buy new vehicle lists at the depots. I have looked at RattRoads and Unspooled nml and replicated what they have done with roadtypetable and powered_roadtype_list but it doesn't work for me. What am I missing?
Here is an example of two roadtypes that should have all the vehicles active. The first one is the only roadtype with actual vechicles to be purchased. The second one (and all the others) have none.
I've experimenting with a RoadType and TramType grf, coding in NML 0.5.2 and I have sorted nearly all the graphics but almost all my defined types end up with empty buy new vehicle lists at the depots. I have looked at RattRoads and Unspooled nml and replicated what they have done with roadtypetable and powered_roadtype_list but it doesn't work for me. What am I missing?
Here is an example of two roadtypes that should have all the vehicles active. The first one is the only roadtype with actual vechicles to be purchased. The second one (and all the others) have none.
Code: Select all
roadtypetable{
ROAD, TRAI, MUD0, DIRT, COBB, SETT, FSET, BASP, MASP, EXPR, HWAY
}
// THIS ONE WORKS, HAS VEHICLES TO BE PURCHASED
item (FEAT_ROADTYPES, town_road, 0){
property{
label: "ROAD";
introduction_date: date(0001,01,01);
name: string(STR_ROAD_TOWN);
toolbar_caption: string(STR_ROAD_TOWN_TOOLBAR);
menu_text: string(STR_ROAD_TOWN_MENU);
// powered_roadtype_list: ["ROAD", "TRAI", "MUD0", "DIRT", "COBB", "SETT", "FSET", "BASP", "MASP", "EXPR", "HWAY", "HAUL"];
//introduces_roadtype_list: ["ROAD", "TRAI"];
//alternative_roadtype_list: ?;
roadtype_flags: bitmask(ROADTYPE_FLAG_TOWN_BUILD);
construction_cost: 8; //Default
maintenance_cost: 16; //Default
speed_limit: 81 km/h; //Maximum of 100 km/h
build_window_caption: string(STR_GENERIC_BUILD_VEHICLE);
autoreplace_text: string(STR_GENERIC_AUTOREPLACE);
new_engine_text: string(STR_GENERIC_NEW_ENGINE);
sort_order: 0;
}
graphics{
underlay: sw_town_road_zone;
depots: sw_town_depot_zone;
bridge_surfaces: spset_susp_mono_bridge;
}
}
// THIS ONE DOESN'T, AS ALL THE OTHERS HAVE NO VEHICLES
item (FEAT_ROADTYPES, modern_asphalt_road, 8){
property{
label: "MASP";
introduction_date: date(1960,01,01);
name: string(STR_ROAD_MODERN_ASPHALT);
toolbar_caption: string(STR_ROAD_MODERN_ASPHALT_TOOLBAR);
menu_text: string(STR_ROAD_MODERN_ASPHALT_MENU);
// powered_roadtype_list: ["ROAD", "TRAI", "MUD0", "DIRT", "COBB", "SETT", "FSET", "BASP", "MASP", "EXPR", "HWAY"];
roadtype_flags: bitmask(ROADTYPE_FLAG_TOWN_BUILD);
construction_cost: 12;
maintenance_cost: 16;
speed_limit: 81 km/h;
build_window_caption: string(STR_GENERIC_BUILD_VEHICLE);
autoreplace_text: string(STR_GENERIC_AUTOREPLACE);
new_engine_text: string(STR_GENERIC_NEW_ENGINE);
sort_order: 8;
}
graphics{
underlay: spset_road_modern_asphalt;
depots: spset_depot_modern_asphalt;
gui: spset_gui_modern_asphalt;
bridge_surfaces: spset_bridge_modern_asphalt;
roadstops: spset_roadstop_modern_asphalt;
}
}