diff --git a/docs/SpriteIDs.xlsx b/docs/SpriteIDs.xlsx index 37988de3..7a8bca03 100644 Binary files a/docs/SpriteIDs.xlsx and b/docs/SpriteIDs.xlsx differ diff --git a/gfx/Steam/Standard9F.png b/gfx/Steam/Standard9F.png index 334ce9ac..cbf1c29a 100644 Binary files a/gfx/Steam/Standard9F.png and b/gfx/Steam/Standard9F.png differ diff --git a/lang/english.lng b/lang/english.lng index 53e2f69a..c14a9e7c 100644 --- a/lang/english.lng +++ b/lang/english.lng @@ -216,10 +216,10 @@ str_GWRCastle_usage :Express Passenger str_GWRCastle_eos :1923 str_GWRCastle_liveries :GWR Green -STR_NAME_GWRHall :GWR 4-6-0 "Hall" Class -str_GWRHall_usage :Express Passenger -str_GWRHall_eos :1946 -str_GWRHall_liveries :GWR Green, Hogwarts Express +STR_NAME_GWRHall :GWR 4-6-0 "Hall" Class +str_GWRHall_usage :Express Passenger +str_GWRHall_eos :1946 +str_GWRHall_liveries :GWR Green, Hogwarts Express STR_NAME_GNRA1 :GNR Gresley A1 str_GNRA1_usage :Express Passenger @@ -231,6 +231,11 @@ str_LNERA3_usage :Express Passenger str_LNERA3_eos :1959-1966 str_LNERA3_liveries :LNER Green, BR Wartime Black, BR Apple Green, BR Brunswick Green +STR_NAME_Standard9F :BR Standard Class 9F +str_Standard9F_usage :Freight/Mixed Traffic +str_Standard9F_eos :1935 +str_Standard9F_liveries :BR Black, BR Green + STR_NAME_BluePullman_6Car :British Rail 'Blue Pullman' (6 car) STR_NAME_BluePullman_8Car :British Rail 'Blue Pullman' (8 car) str_BluePullman_usage :Express Passenger diff --git a/src/sortpurchase.pnml b/src/sortpurchase.pnml index a9e2ae98..987e3e5c 100644 --- a/src/sortpurchase.pnml +++ b/src/sortpurchase.pnml @@ -6,6 +6,7 @@ sort(FEAT_TRAINS, [ item_GWRHall, item_GNRA1, item_LNERA3, + item_Standard9F, item_BR08, item_BR13, item_BR31, diff --git a/src/templates.pnml b/src/templates.pnml index bcab1702..c7fde0a6 100644 --- a/src/templates.pnml +++ b/src/templates.pnml @@ -37,6 +37,18 @@ template template_train12px(x,y){ [ x+83, y, 12, 12, -5, -7] } +template template_train16px(x,y){ + //left_x, upper_y, width, height, offset_x, offset_y + [ x, y, 8, 17, -3, -11] + [ x+9, y, 14, 13, -6, -9] + [ x+24, y, 16, 12, 0, -7] + [ x+41, y, 14, 13, 1, -5] + [ x+56, y, 8, 17, -3, -5] + [ x+65, y, 14, 13, -14, -5] + [ x+80, y, 16, 12, -15, -8] + [ x+97, y, 14, 13, -7, -10] +} + template template_train20px(x,y){ // Clone to 4view when changed //left_x, upper_y, width, height, offset_x, offset_y [ x, y, 8, 18, -3, -11] @@ -122,11 +134,11 @@ template template_train32px(x,y){ template template_train32px_anim(x,y){ //left_x, upper_y, width, height, offset_x, offset_y - [ x, y, 8, 24, -4, -10, ANIM|NOWHITE] + [ x, y, 8, 24, -3, -12, ANIM|NOWHITE] [ x+9, y, 21, 18, -13, -10, ANIM|NOWHITE] [ x+31, y, 32, 12, -16, -8, ANIM|NOWHITE] [ x+64, y, 21, 18, -7, -11, ANIM|NOWHITE] - [ x+86, y, 8, 24, -4, -10, ANIM|NOWHITE] + [ x+86, y, 8, 24, -3, -12, ANIM|NOWHITE] [ x+95, y, 21, 18, -13, -10, ANIM|NOWHITE] [ x+117, y, 32, 12, -15, -8, ANIM|NOWHITE] [ x+150, y, 21, 18, -7, -11, ANIM|NOWHITE] diff --git a/src/trains/steam/Standard9F.pnml b/src/trains/steam/Standard9F.pnml new file mode 100644 index 00000000..b2e35325 --- /dev/null +++ b/src/trains/steam/Standard9F.pnml @@ -0,0 +1,99 @@ +spriteset(spriteset_Standard9F_Purchase, "gfx/Steam/Standard9F.png") { + template_purchase_anim(0, 0) +} + +spriteset(spriteset_Standard9F_BRBlack, "gfx/Steam/Standard9F.png") { + template_train32px_anim(0, 13) +} +spriteset(spriteset_Standard9FTender_BRBlack, "gfx/Steam/Standard9F.png") { + template_train16px(0, 38) +} + +spriteset(spriteset_Standard9F_BRGreen, "gfx/Steam/Standard9F.png") { + template_train32px_anim(0, 56) +} +spriteset(spriteset_Standard9FTender_BRGreen, "gfx/Steam/Standard9F.png") { + template_train16px(0, 81) +} + +switch(FEAT_TRAINS,SELF, sw_Standard9FLoco,cargo_subtype){ + 0: spriteset_Standard9F_BRBlack; + 1: spriteset_Standard9F_BRGreen; +} + +switch(FEAT_TRAINS,SELF, sw_Standard9FTender,cargo_subtype){ + 0: spriteset_Standard9FTender_BRBlack; + 1: spriteset_Standard9FTender_BRGreen; +} + +switch(FEAT_TRAINS,SELF,sw_Standard9F_cargo_subtype_text,cargo_subtype){ + 0: return string(str_BRBlack); + 1: return string(str_BRGreen); + return CB_RESULT_NO_TEXT; +} + +switch(FEAT_TRAINS, SELF, sw_Standard9F, position_in_articulated_veh){ + 0: sw_Standard9FLoco; + 1: sw_Standard9FTender; +} + +switch(FEAT_TRAINS, SELF, sw_Standard9F_length, position_in_articulated_veh) { + 0: return 8; + 1: return 4; +} + +switch (FEAT_TRAINS, SELF, sw_articulated_Standard9F, extra_callback_info1) { + 1: return item_Standard9F; + return CB_RESULT_NO_MORE_ARTICULATED_PARTS; //stop adding vehicle parts +} + +item (FEAT_TRAINS, item_Standard9F, 587) { + property { + name: string(STR_NAME_Standard9F); + climates_available: ALL_CLIMATES; + introduction_date: date(1954,2,4); + model_life: 2; + retire_early: 1; + vehicle_life: 10; + reliability_decay: 7; + refittable_cargo_classes: 0; + cargo_allow_refit: [GOOD]; + loading_speed: 3; + cost_factor: 26; + running_cost_factor: 30; + sprite_id: SPRITE_ID_NEW_TRAIN; + speed: 90 mph; + misc_flags: TRAIN_FLAG_NO_BREAKDOWN_SMOKE; + refit_cost: 0; + track_type: RAIL; + ai_special_flag: AI_FLAG_CARGO; + power: 2400 hp; + running_cost_base: RUNNING_COST_STEAM; + dual_headed: 0; + default_cargo_type: GOOD; + cargo_capacity: 1; + weight: 139 ton; + engine_class: ENGINE_CLASS_STEAM; + tractive_effort_coefficient: 0.3; + air_drag_coefficient: 0.1; + length: 8; + effect_spawn_model_and_powered: EFFECT_SPAWN_MODEL_STEAM; + extra_weight_per_wagon: 0; + bitmask_vehicle_info: 0; + } + graphics { + additional_text: return(string(str_purchase_loco_with_liveries,string(str_purchase_type_steam),string(str_route_9),string(str_Standard9F_usage),string(str_Standard9F_eos),string(str_Standard9F_liveries))); + can_attach_wagon: CB_RESULT_ATTACH_ALLOW; + cargo_capacity: return 0; + cargo_subtype_text: sw_Standard9F_cargo_subtype_text; + articulated_part: sw_articulated_Standard9F; + default: sw_Standard9F; + purchase: spriteset_Standard9F_Purchase; + colour_mapping: return PALETTE_CC_FIRST; + create_effect: steam_create_visual_effect; + sound_effect: sw_steam_sound; + cost_factor: return(GetAdjustedCost(26)); + running_cost_factor: return(GetAdjustedCost(30)); + length: sw_Standard9F_length; + } +} \ No newline at end of file