Skip to content

Commit

Permalink
Added Class 48 (Class 47 variant)
Browse files Browse the repository at this point in the history
  • Loading branch information
audigex committed Apr 22, 2024
1 parent 68dc132 commit 13df43a
Show file tree
Hide file tree
Showing 5 changed files with 69 additions and 0 deletions.
Binary file modified docs/SpriteIDs.xlsx
Binary file not shown.
1 change: 1 addition & 0 deletions docs/changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
- Added Furness Railway 4-4-0 K2 'Large Seagull'
- Added War Department "Austerity Tank"
- Added LNER P2
- Added Class 48
- Adjusted some purchase dates and model lifespans
- HUGE template/alignment overhaul
- Re-drew Class 70
Expand Down
5 changes: 5 additions & 0 deletions lang/english.lng
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,11 @@ str_BR47_usage :Mixed Traffic
str_BR47_eos :---
str_BR47_liveries :BR Green, BR Blue, BR Large Logo, BR Large Logo (Alternate), Porterbrook, EWS, Anglia, InterCity, West Coast, GWR Green, Virgin, Colas Rail, ONE, Freightliner

STR_NAME_BR48 :BR Class 48 'Type 4' (Experimental)
str_BR48_usage :Mixed Traffic
str_BR48_eos :---
str_BR48_liveries :BR Green, BR Blue

STR_NAME_Kestrel :HS4000 'Kestrel' (Type 5 Prototype)
str_Kestrel_usage :Mixed Traffic
str_Kestrel_eos :---
Expand Down
15 changes: 15 additions & 0 deletions src/trains/_spriteset/Diesel_Sprites/48.pnml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
spriteset(spriteset_BR48_Purchase, "gfx/BR47_BR57.png") {
template_purchase(0, 0)
}

switch(FEAT_TRAINS,SELF, sw_BR48,cargo_subtype){
0: spriteset_BR47_BRGreen;
1: spriteset_BR47_BRBlue;
return CB_RESULT_NO_TEXT;
}

switch(FEAT_TRAINS,SELF,sw_BR48_cargo_subtype_text,cargo_subtype){
0: return string(str_BRGreen);
1: return string(str_BRBlue);
return CB_RESULT_NO_TEXT;
}
48 changes: 48 additions & 0 deletions src/trains/diesel/BR048.pnml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
item (FEAT_TRAINS, item_BR48, 593) {
property {
name: string(STR_NAME_BR48);
climates_available: ALL_CLIMATES;
introduction_date: date(1965,4,21);
model_life: 8;
retire_early: 1;
vehicle_life: 50;
reliability_decay: 7;
refittable_cargo_classes: 0;
cargo_allow_refit: [GOOD, FOOD];
loading_speed: 3;
cost_factor: 45;
running_cost_factor: 41;
sprite_id: SPRITE_ID_NEW_TRAIN;
speed: 95 mph;
misc_flags: TRAIN_FLAG_FLIP;
refit_cost: 0;
track_type: RAIL;
ai_special_flag: AI_FLAG_CARGO;
power: 2650 hp;
running_cost_base: RUNNING_COST_DIESEL;
dual_headed: 0;
default_cargo_type: GOOD;
cargo_capacity: 1;
weight: 112 ton;
engine_class: ENGINE_CLASS_DIESEL;
tractive_effort_coefficient: 0.25;
air_drag_coefficient: 0.05;
length: 8;
effect_spawn_model_and_powered: EFFECT_SPAWN_MODEL_DIESEL;
extra_weight_per_wagon: 0;
bitmask_vehicle_info: 0;
}
graphics {
additional_text: return(string(str_purchase_loco_with_liveries,string(str_purchase_type_diesel),string(str_route_7),string(str_BR48_usage),string(str_BR48_eos),string(str_BR48_liveries)));
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
cargo_capacity: return 0;
cargo_subtype_text: sw_BR48_cargo_subtype_text;
default: sw_BR48;
purchase: spriteset_BR48_Purchase;
colour_mapping: return PALETTE_CC_FIRST;
create_effect: diesel_create_visual_effect;
sound_effect: sw_deltic_sound;
cost_factor: return(GetAdjustedCost(45));
running_cost_factor: return(GetAdjustedCost(41));
}
}

0 comments on commit 13df43a

Please sign in to comment.