grf {
    grfid: "test";
    name: string(STR_REGRESSION_NAME);
    desc: string(STR_REGRESSION_DESC);
    version: 0;
    min_compatible_version: 0;
}

/*
 * Turbo train engine (arctic)
 * Livery override for passenger wagon
 * Graphics by DanMacK, adopted from OpenGFX+ for testing purposes
 */
spriteset(turbotrain_engine_set, "opengfx_trains_start.pcx") {
    [142,112,  8,22,   -3,-10]
    [158,112, 21,15,  -14, -7]
    [190,112, 31,12,  -16, -8]
    [238,112, 21,16,   -6, -7]
    [270,112,  8,24,   -3,-10]
    [286,112, 21,16,  -15, -6]
    [318,112, 32,12,  -16, -8]
    [366,112, 21,15,   -6, -7]
}
spritegroup turbotrain_engine_group {
    loading: turbotrain_engine_set;
    loaded: turbotrain_engine_set;
}

spriteset(normal_passenger_set, "arctic_railwagons.pcx") {
    [  0,  0,  8,24,   -3,-12]
    [ 16,  0, 22,17,  -14, -9]
    [ 48,  0, 32,12,  -16, -8]
    [ 96,  0, 22,17,   -6, -9]
    [  0,  0,  8,24,   -3,-12]
    [ 16,  0, 22,17,  -14, -9]
    [ 48,  0, 32,12,  -16, -8]
    [ 96,  0, 22,17,   -6, -9]
}
spritegroup normal_passenger_group {
    loading: normal_passenger_set;
    loaded: normal_passenger_set;
}

spriteset(turbotrain_passenger_set, "opengfx_trains_start.pcx") {
    [142,139,  8,21,   -3,-10]
    [158,139, 20,15,  -13, -7]
    [190,139, 28,10,  -12, -6]
    [238,139, 20,16,   -6, -7]
    [270,139,  8,21,   -3,-10]
    [286,139, 20,15,  -15, -6]
    [318,139, 28,10,  -16, -6]
    [366,139, 20,16,   -6, -7]
}
spritegroup turbotrain_passenger_group {
    loading: turbotrain_passenger_set;
    loaded: turbotrain_passenger_set;
}

// Turbotrain engine:
item(FEAT_TRAINS, turbotrain, 20) {
    property {
        sprite_id:                    SPRITE_ID_NEW_TRAIN;    // We have our own sprites
        misc_flags:                   bitmask(TRAIN_FLAG_MU); // We use special sprites for passenger and mail wagons
    }
    graphics {
        turbotrain_engine_group;
    }
    livery_override(passenger_wagon) { 
        turbotrain_passenger_group;
    }
}

item(FEAT_TRAINS, passenger_wagon, 27) {
    property {
        sprite_id:                    SPRITE_ID_NEW_TRAIN;    // We have our own sprites
        misc_flags:                   bitmask(TRAIN_FLAG_MU); // We use special sprites for passenger and mail wagons
        refittable_cargo_classes:     bitmask(CC_PASSENGERS); // Allow passengers (and tourists)
        non_refittable_cargo_classes: NO_CARGO_CLASS;         // Disallow other cargos
    }
    graphics {
        normal_passenger_group;
    }
}