Skip to content

Commit

Permalink
BR378 - Added fake aventra and 5 car celebration liveries
Browse files Browse the repository at this point in the history
  • Loading branch information
audigex committed Sep 13, 2021
1 parent 26235b1 commit 5f1a71c
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 10 deletions.
Binary file modified gfx/Electrostar_v2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion lang/english.lng
Original file line number Diff line number Diff line change
Expand Up @@ -1260,7 +1260,8 @@ str_OneChapelf : (One 'Chapelfield')
str_OneGhost : (One 'Ghost White')
str_OneTrans : (One - Transitional)
str_overground : (London Overground)
str_overground5 : (London Overground 5-Car Celebration)
str_overgroundAventra : (LO - Fake Aventra)
str_overground5 : (LO - 5-Car Celebration)
str_Police : (Police (Advert))
str_Purple : (Potterbrook Purple)
str_Pullman : (Blue Pullman)
Expand Down
48 changes: 39 additions & 9 deletions src/trains/emu/BR378.pnml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,23 @@ spriteset(spriteset_BR378d_overground, "gfx/Electrostar_v2.png") {
template_train32px(0, 375)
}

spriteset(spriteset_BR378_LOunwrapped, "gfx/Electrostar_v2.png") {
template_train32px(200, 350)
}

spriteset(spriteset_BR378a_Aventra, "gfx/Electrostar_v2.png") {
template_train32px(0, 1700)
}
spriteset(spriteset_BR378b_Aventra, "gfx/Electrostar_v2.png") {
template_train32px(0, 1725)
}
spriteset(spriteset_BR378c_Aventra, "gfx/Electrostar_v2.png") {
template_train32px(0, 1750)
}
spriteset(spriteset_BR378d_Aventra, "gfx/Electrostar_v2.png") {
template_train32px(0, 1775)
}

spriteset(spriteset_BR378a_overground5, "gfx/Electrostar_v2.png") {
template_train32px(0, 300)
}
Expand All @@ -31,21 +48,31 @@ spriteset(spriteset_BR378d_overground5, "gfx/Electrostar_v2.png") {
switch(FEAT_TRAINS,SELF, sw_BR378a,cargo_subtype){
0: spriteset_BR378a_overground;
1: spriteset_BR378a_overground5;
2: spriteset_BR378a_Aventra;
}

switch(FEAT_TRAINS,SELF, sw_BR378b,cargo_subtype){
0: spriteset_BR378b_overground;
1: spriteset_BR378b_overground5;
2: spriteset_BR378b_Aventra;
}

switch(FEAT_TRAINS,SELF, sw_BR378c,cargo_subtype){
0: spriteset_BR378c_overground;
1: spriteset_BR378c_overground5;
2: spriteset_BR378c_Aventra;
}

switch(FEAT_TRAINS, SELF, switch_378_special_livery, position_in_consist)
{
2: spriteset_BR378_LOunwrapped;
spriteset_BR378d_overground5;
}

switch(FEAT_TRAINS,SELF, sw_BR378d,cargo_subtype){
0: spriteset_BR378d_overground;
1: spriteset_BR378d_overground5;
1: switch_378_special_livery;
2: spriteset_BR378d_Aventra;
}

switch (FEAT_TRAINS, SELF, switch_articulated_BR378_3dv, extra_callback_info1) {
Expand Down Expand Up @@ -85,13 +112,19 @@ switch (FEAT_TRAINS, SELF, switch_articulated_BR378_5dv, extra_callback_info1) {
}

switch(FEAT_TRAINS,SELF,sw_BR378_3_cargo_subtype_text,cargo_subtype){
0: return string(str_overground);
0: return string(str_overground);
return CB_RESULT_NO_TEXT;
}

switch(FEAT_TRAINS,SELF,sw_BR378_4_cargo_subtype_text,cargo_subtype){
0: return string(str_overground);
return CB_RESULT_NO_TEXT;
}

switch(FEAT_TRAINS,SELF,sw_BR378_5_cargo_subtype_text,cargo_subtype){
0: return string(str_overground);
1: return string(str_overground5);
2: return string(str_overgroundAventra);
return CB_RESULT_NO_TEXT;
}

Expand Down Expand Up @@ -182,7 +215,7 @@ item (FEAT_TRAINS, item_BR378_4, 226) {
graphics {
additional_text: return(string(str_purchase_loco_with_liveries,string(str_purchase_type_emu),string(str_route_2),string(str_BR378_4_usage),string(str_BR378_4_eos),string(str_BR378_4_liveries)));
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
cargo_subtype_text: sw_BR378_3_cargo_subtype_text;
cargo_subtype_text: sw_BR378_4_cargo_subtype_text;
articulated_part: switch_articulated_BR378_4;
default: sw_BR378a;
purchase: spriteset_BR378_Purchase;
Expand Down Expand Up @@ -378,8 +411,7 @@ item (FEAT_TRAINS, item_BR378b, 231) {
}
graphics {
additional_text: return(string(str_purchase_loco_with_liveries,string(str_purchase_type_emu),string(str_route_2),string(str_BR378_4_usage),string(str_BR378_4_eos),string(str_BR378_4_liveries)));
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
cargo_subtype_text: sw_BR378_3_cargo_subtype_text;
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
default: sw_BR378b;
colour_mapping: return PALETTE_CC_FIRST;
create_effect: electric_create_visual_effect;
Expand Down Expand Up @@ -424,8 +456,7 @@ item (FEAT_TRAINS, item_BR378c, 232) {
}
graphics {
additional_text: return(string(str_purchase_loco_with_liveries,string(str_purchase_type_emu),string(str_route_2),string(str_BR378_4_usage),string(str_BR378_4_eos),string(str_BR378_4_liveries)));
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
cargo_subtype_text: sw_BR378_3_cargo_subtype_text;
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
default: sw_BR378c;
colour_mapping: return PALETTE_CC_FIRST;
create_effect: electric_create_visual_effect;
Expand Down Expand Up @@ -470,8 +501,7 @@ item (FEAT_TRAINS, item_BR378d, 233) {
}
graphics {
additional_text: return(string(str_purchase_loco_with_liveries,string(str_purchase_type_emu),string(str_route_2),string(str_BR378_4_usage),string(str_BR378_4_eos),string(str_BR378_4_liveries)));
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
cargo_subtype_text: sw_BR378_3_cargo_subtype_text;
can_attach_wagon: CB_RESULT_ATTACH_ALLOW;
default: sw_BR378d;
colour_mapping: return PALETTE_CC_FIRST;
sound_effect: sw_electrostar_sound;
Expand Down

0 comments on commit 5f1a71c

Please sign in to comment.