Skip to content

Commit

Permalink
Added Caledonian Railway 4-2-2 "Single"
Browse files Browse the repository at this point in the history
  • Loading branch information
audigex committed May 8, 2024
1 parent 3210d1e commit dcaea8e
Show file tree
Hide file tree
Showing 6 changed files with 99 additions and 2 deletions.
Binary file modified docs/SpriteIDs.xlsx
Binary file not shown.
5 changes: 3 additions & 2 deletions docs/changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@
- Re-drew class 66

# v2.8
- Added Furness Railway 0-4-0 'Coppernob'
- Added Furness Railway 4-4-0 K2 'Large Seagull'
- Added Furness Railway 0-4-0 "Coppernob"
- Added Furness Railway 4-4-0 K2 "Large Seagull"
- Added Caledonian Railway 4-2-2 "Single"
- Added War Department "Austerity Tank"
- Added LNER P2
- Added Class 48
Expand Down
Binary file added gfx/Steam/CaledonianSingle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions lang/english.lng
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,11 @@ str_Coppernob_usage :Mixed Traffic
str_Coppernob_eos :1848
str_Coppernob_liveries :Furness Railway Red

STR_NAME_CaledonianSingle :Caledonian Railway 4-2-2 'Single'
str_CaledonianSingle_usage :Mixed Traffic
str_CaledonianSingle_eos :1887
str_CaledonianSingle_liveries :Caledonian Blue

STR_NAME_FurnessK2 :Furness Railway 4-4-0 K2 'Large Seagull'
str_FurnessK2_usage :Mixed Traffic
str_FurnessK2_eos :1892
Expand Down
1 change: 1 addition & 0 deletions src/sortpurchase.pnml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ sort(FEAT_TRAINS, [
item_UtilityTrain32pxOLD,
item_EyeCandy,
item_Coppernob,
item_CaledonianSingle,
item_FurnessK2,
item_LNWRWebb,
item_GreatBear,
Expand Down
90 changes: 90 additions & 0 deletions src/trains/steam/CaledonianSingle.pnml
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
spriteset(spriteset_CaledonianSingle_Purchase, "gfx/Steam/CaledonianSingle.png") {
template_purchase_anim(0, 0)
}

spriteset(spriteset_CaledonianSingle_FurnessRed, "gfx/Steam/CaledonianSingle.png") {
template_train20px(0, 13)
}

spriteset(spriteset_CaledonianSingleT_FurnessRed, "gfx/Steam/CaledonianSingle.png") {
template_train12px(0, 33)
}

switch(FEAT_TRAINS,SELF, sw_CaledonianSingleLoco,cargo_subtype){
0: spriteset_CaledonianSingle_FurnessRed;
}

switch(FEAT_TRAINS,SELF, sw_CaledonianSingleTender,cargo_subtype){
0: spriteset_CaledonianSingleT_FurnessRed;
}

switch(FEAT_TRAINS, SELF, sw_CaledonianSingle, position_in_articulated_veh){
0: sw_CaledonianSingleLoco;
1: sw_CaledonianSingleTender;
}

switch(FEAT_TRAINS, SELF, switch_CaledonianSingle_length, position_in_articulated_veh) {
0: return 5;
1: return 4;
}

switch (FEAT_TRAINS, SELF, switch_articulated_CaledonianSingle, extra_callback_info1) {
1: return item_CaledonianSingle;
return CB_RESULT_NO_MORE_ARTICULATED_PARTS; //stop adding vehicle parts
}

switch(FEAT_TRAINS,SELF,sw_CaledonianSingle_cargo_subtype_text,cargo_subtype){
0: return string(str_FurnessRed);
return CB_RESULT_NO_TEXT;
}

item (FEAT_TRAINS, item_CaledonianSingle, 598) {
property {
name: string(STR_NAME_CaledonianSingle);
climates_available: ALL_CLIMATES;
introduction_date: date(1886,2,1);
model_life: 50;
retire_early: 1;
vehicle_life: 55;
reliability_decay: 7;
refittable_cargo_classes: 0;
cargo_allow_refit: [GOOD, FOOD];
loading_speed: 3;
cost_factor: 10;
running_cost_factor: 10;
sprite_id: SPRITE_ID_NEW_TRAIN;
speed: 60 mph;
misc_flags: TRAIN_FLAG_NO_BREAKDOWN_SMOKE;
refit_cost: 0;
track_type: RAIL;
ai_special_flag: AI_FLAG_CARGO;
power: 800 hp;
running_cost_base: RUNNING_COST_STEAM;
dual_headed: 0;
default_cargo_type: GOOD;
cargo_capacity: 1;
weight: 60 ton;
engine_class: ENGINE_CLASS_STEAM;
tractive_effort_coefficient: 0.37;
air_drag_coefficient: 0.1;
length: 5;
effect_spawn_model_and_powered: EFFECT_SPAWN_MODEL_STEAM;
extra_weight_per_wagon: 0;
bitmask_vehicle_info: 0;
}
graphics {
length: switch_CaledonianSingle_length;
additional_text: return(string(str_purchase_loco_with_liveries,string(str_purchase_type_steam),string(str_route_9),string(str_CaledonianSingle_usage),string(str_CaledonianSingle_eos),string(str_CaledonianSingle_liveries)));
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
cargo_capacity: return 0;
cargo_subtype_text: sw_CaledonianSingle_cargo_subtype_text;
articulated_part: switch_articulated_CaledonianSingle;
default: sw_CaledonianSingle;
purchase: spriteset_CaledonianSingle_Purchase;
colour_mapping: return PALETTE_CC_FIRST;
create_effect: steam_create_visual_effect;
sound_effect: sw_steam_sound;
cost_factor: return(GetAdjustedCost(10));
running_cost_factor: return(GetAdjustedCost(10));
}
}

0 comments on commit dcaea8e

Please sign in to comment.