-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GENIUS PUSHPULL BECAUSE I AM A GENIUS (No I will not use a profession…
…al commit message, I'm too chuffed with this)
- Loading branch information
Showing
10 changed files
with
227 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
Push-pull combinations in the format | ||
Trailer: Power units | ||
|
||
? indicates assumed combinations. 33 is 7 length, everything else is 8 length | ||
|
||
TPO PCV: 47, 57? | ||
|
||
Mk2 DBSO: 47, 57?, 37 | ||
|
||
Mk3 DVT: 86, 87, 90, 67, 68, 47, 57?, 69? | ||
|
||
Mk4 DVT: 67, 89, 90, 91 | ||
|
||
Mk5 DVT: 68 | ||
|
||
438 TC: 33, 73, 71 (& 74 converted from 71), 4-REP (432). Maybe 47 (unconfirmed if push-pull or just hauled for a railtour) |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
/* | ||
|
||
Switches in this file are mirrors of their respective DVT or locomotive for pushpull operations | ||
Changes to the locomotive should be mirrored here or strange things might happen | ||
It is recommended to always include a default... | ||
|
||
*/ | ||
|
||
// Mirror of Mk4DVT | ||
switch(FEAT_TRAINS, PARENT, sw_PUSHPULL_LocomotiveAsMk4DVT, [STORE_TEMP(num_vehs_in_consist - 1, 0x10F), var[0x61, 0, 0x0000FFFF, 0xF2]]){ | ||
0: spriteset_BR91_IntercitySwallow; | ||
1: spriteset_BR91_NatEx; | ||
2: spriteset_BR91_GNER; | ||
3: spriteset_BR91_EastCoast; | ||
4: spriteset_BR91_VirginEC; | ||
5: spriteset_BR91_LNER; | ||
spriteset_BR91_IntercitySwallow; | ||
} | ||
|
||
// Mirror of BR89 | ||
switch(FEAT_TRAINS, PARENT, sw_PUSHPULL_DVTasBR89, [STORE_TEMP(0 - position_in_articulated_veh, 0x10F), var[0x61, 0, 0x0000FFFF, 0xF2]]){ | ||
0: spriteset_BR89_IntercitySwallow; | ||
1: spriteset_BR89_GNER; | ||
2: spriteset_BR89_Intercity; | ||
spriteset_BR89_IntercitySwallow; | ||
} | ||
|
||
// Mirror of BR90 | ||
switch(FEAT_TRAINS, PARENT, sw_PUSHPULL_DVTasBR90, [STORE_TEMP(0 - position_in_articulated_veh, 0x10F), var[0x61, 0, 0x0000FFFF, 0xF2]]){ | ||
0: spriteset_BR90_IntercitySwallow; | ||
1: spriteset_BR90_FLGrey; | ||
2: spriteset_BR90_EWS; | ||
3: spriteset_BR90_DB; | ||
4: spriteset_BR90_FLGreen; | ||
5: spriteset_BR90_FLPowerhaul; | ||
6: spriteset_BR90_ONE; | ||
7: spriteset_BR90_GreaterAnglia; | ||
8: spriteset_BR90_GreaterAnglia2; | ||
9: spriteset_BR90_Virgin; | ||
10: spriteset_BR90_REX; | ||
11: spriteset_BR90_FirstScotrail; | ||
12: spriteset_BR90_GNER; | ||
return CB_RESULT_NO_TEXT; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,83 @@ | ||
spriteset(spriteset_BRMK4DVT_IntercitySwallow, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_purchase, "gfx/BR91.png") { | ||
template_purchase(256, 0) | ||
} | ||
|
||
spriteset(spriteset_BRMk4DVT_IntercitySwallow, "gfx/BR91.png") { | ||
template_train32px(0, 113) | ||
} | ||
spriteset(spriteset_BRMK4DVT_IntercitySwallowr, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_IntercitySwallowr, "gfx/BR91.png") { | ||
template_train32px(172, 113) | ||
} | ||
|
||
spriteset(spriteset_BRMK4DVT_NatEx, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_NatEx, "gfx/BR91.png") { | ||
template_train32px(0, 238) | ||
} | ||
spriteset(spriteset_BRMK4DVT_NatExr, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_NatExr, "gfx/BR91.png") { | ||
template_train32px(172, 238) | ||
} | ||
|
||
spriteset(spriteset_BRMK4DVT_GNER, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_GNER, "gfx/BR91.png") { | ||
template_train32px(0, 363) | ||
} | ||
spriteset(spriteset_BRMK4DVT_GNERr, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_GNERr, "gfx/BR91.png") { | ||
template_train32px(172, 363) | ||
} | ||
|
||
spriteset(spriteset_BRMK4DVT_EastCoast, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_EastCoast, "gfx/BR91.png") { | ||
template_train32px(0, 488) | ||
} | ||
spriteset(spriteset_BRMK4DVT_EastCoastr, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_EastCoastr, "gfx/BR91.png") { | ||
template_train32px(172, 488) | ||
} | ||
|
||
spriteset(spriteset_BRMK4DVT_VirginEC, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_VirginEC, "gfx/BR91.png") { | ||
template_train32px(0, 613) | ||
} | ||
spriteset(spriteset_BRMK4DVT_VirginECr, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_VirginECr, "gfx/BR91.png") { | ||
template_train32px(172, 613) | ||
} | ||
|
||
spriteset(spriteset_BRMK4DVT_LNER, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_LNER, "gfx/BR91.png") { | ||
template_train32px(0, 738) | ||
} | ||
spriteset(spriteset_BRMK4DVT_LNERr, "gfx/BR91.png") { | ||
spriteset(spriteset_BRMk4DVT_LNERr, "gfx/BR91.png") { | ||
template_train32px(172, 738) | ||
} | ||
|
||
switch(FEAT_TRAINS,SELF,sw_BRMk4DVT_cargo_subtype_text,cargo_subtype){ | ||
0: return string(str_IntercitySwallow); | ||
1: return string(str_NatEx); | ||
2: return string(str_GNER); | ||
3: return string(str_EastCoast); | ||
4: return string(str_VirginECLNER); | ||
5: return string(str_LNER); | ||
return CB_RESULT_NO_TEXT; | ||
} | ||
|
||
// Show own graphics when facing forward | ||
// WARNING: If editing this, also edit PushPull.pnml in the Spritesets folder | ||
switch(FEAT_TRAINS,SELF, sw_BRMk4DVT,cargo_subtype){ | ||
0: spriteset_BRMk4DVT_IntercitySwallow; | ||
1: spriteset_BRMk4DVT_NatEx; | ||
2: spriteset_BRMk4DVT_GNER; | ||
3: spriteset_BRMk4DVT_EastCoast; | ||
4: spriteset_BRMk4DVT_VirginEC; | ||
5: spriteset_BRMk4DVT_LNER; | ||
} | ||
|
||
// If the front of this consist is a compatible locomotive, call that locomotive's remote sprite call switch | ||
switch(FEAT_TRAINS, PARENT, sw_BRMk4DVT_PushPUll, [STORE_TEMP(0 - position_in_articulated_veh, 0x10F), var[0x61, 0, 0x0000FFFF, 0xC6]]) { | ||
418: sw_PUSHPULL_DVTasBR89; // Class 89 | ||
543: sw_PUSHPULL_DVTasBR90; // Class 90 | ||
sw_BRMk4DVT; // No compatible locomotive found, show normal sprites | ||
} | ||
|
||
switch(FEAT_TRAINS,PARENT,sw_Mk4DVT_CheckPosition, position_in_articulated_veh_from_end){ | ||
0: sw_BRMk4DVT_PushPUll; // Attempt push pull | ||
sw_BRMk4DVT; // We aren't at the back of theconsist, show normal sprites | ||
} | ||
|
||
switch(FEAT_TRAINS,PARENT,sw_BRMk4DVT_Sprites ,vehicle_is_reversed){ | ||
0: sw_BRMk4DVT; // We're heading foward, show normal sprites | ||
1: sw_Mk4DVT_CheckPosition; // Attempt push pull (skipping check position for now for testing) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
item (FEAT_TRAINS, item_BRMk4DVT, 585) { | ||
property { | ||
name: string(STR_NAME_BRMk4DVT); | ||
climates_available: ALL_CLIMATES; | ||
refittable_cargo_classes: CC_PASSENGERS; | ||
introduction_date: date(1989,1,1); | ||
cargo_allow_refit: [MAIL]; | ||
loading_speed: 14; | ||
cost_factor: 30; | ||
running_cost_factor: 12; | ||
sprite_id: SPRITE_ID_NEW_TRAIN; | ||
refit_cost: 0; | ||
track_type: RAIL; | ||
speed: 140 mph; | ||
power: 0; | ||
running_cost_base: RUNNING_COST_STEAM; | ||
dual_headed: 0; | ||
default_cargo_type: MAIL; | ||
cargo_capacity: 1; | ||
weight: 43 ton; | ||
tractive_effort_coefficient: 0; | ||
air_drag_coefficient: 0; | ||
length: 8; | ||
effect_spawn_model_and_powered: EFFECT_SPAWN_MODEL_NONE; | ||
extra_weight_per_wagon: 0; | ||
bitmask_vehicle_info: 0; | ||
cargo_age_period: 185; | ||
} | ||
graphics { | ||
can_attach_wagon: CB_RESULT_ATTACH_ALLOW; | ||
default: sw_BRMk4DVT_Sprites; | ||
colour_mapping: return PALETTE_CC_FIRST; | ||
cargo_subtype_text: sw_BR91_cargo_subtype_text; | ||
purchase: spriteset_BRMk4DVT_purchase; | ||
speed: 160; | ||
cargo_capacity: return(0); | ||
cost_factor: return(GetAdjustedCost(52)); | ||
running_cost_factor: return(GetAdjustedCost(17)); | ||
} | ||
} | ||
|
||
|
||
/* switch(FEAT_TRAINS, SELF, test, [STORE_TEMP(0 - pos_in_articulated_veh, 0x10F), var[0x61, 0, 0x0000FFFF, 0xC6]]) { | ||
1: do something if other train's ID is 1 | ||
} | ||
|
||
0xC6 vehicle ID | ||
0xF2 cargo_subtype | ||
|
||
[STORE_TEMP(position_in_consist_from_end , 0x10F), | ||
|
||
TEMP[0x10F] var(0x61, param=0xF2, shift=0, and=0xFF) | ||
|
||
*/ |