{
"fleetjt_engine_v8_5.5": {
    "information":{
        "authors":"BeamNG",
        "name":"5.7L Diesel V8 Engine",
        "value":7900,
    },
    "slotType" : "fleetjt_engine",
    "slots": [
        ["type", "default", "description"],
        ["fleetjt_enginemounts","fleetjt_enginemounts", "Engine Mounts", {"coreSlot":true}],
        ["pickup_oilpan_v8","pickup_oilpan_v8", "Oil Pan", {"coreSlot":true, "nodeMove":{"x":0.0,"y":0.0,"z":-0.14}}],
        ["fleetjt_intake","fleetjt_intake_stock", "Intake", {"coreSlot":true}],
        ["fleetjt_header","fleetjt_exhmanifold", "Exhaust Manifolds", {"coreSlot":true}],
        ["pickup_engine_v8_ecu","pickup_engine_v8_ecu", "Engine Management", {"coreSlot":true}],
        ["n2o_system","", "Nitrous Oxide System"],
        ["pickup_engine_v8_internals","pickup_engine_v8_internals", "Engine Long Block", {"coreSlot":true}],
        ["fleetjt_transmission","fleetjt_transmission_4A", "Transmission"],
    ],
    "powertrain" : [
        ["type", "name", "inputName", "inputIndex"],
        ["combustionEngine", "mainEngine", "dummy", 0],
    ],
    "mainEngine": {
        "torque":[
            ["rpm", "torque"],
            [0, 0],
            [500, 315],
            [1000, 395],
            [2000, 336],
            [3000, 275],
            [4000, 135],
            [5000, 38],
            [6000, 27],
        ],

        //engine performance
        "idleRPM":600,
        //max physically capable
        "maxRPM":4500,
        "inertia":0.29,
        "friction":19,
        "dynamicFriction":0.035,
        "engineBrakeTorque":52,
        //"burnEfficiency":0.32,
        "burnEfficiency":[
            [0, 0.38],
            [0.05, 0.39],
            [0.4, 0.38],
            [0.7, 0.35],
            [1, 0.30],
        ],
        //fuel system
        "energyStorage": "mainTank"
        "requiredEnergyType":"diesel",

        //exhaust
        "instantAfterFireSound": "event:>Vehicle>Afterfire>01_Single_EQ1",
        "sustainedAfterFireSound": "event:>Vehicle>Afterfire>01_Multi_EQ1",
        "shiftAfterFireSound": "event:>Vehicle>Afterfire>01_Shift_EQ1",
        "particulates":0.15,
        "instantAfterFireCoef": 0.5,
        "sustainedAfterFireCoef": 0.5,

        //cooling and oil system
        "thermalsEnabled":true,
        "engineBlockMaterial":"aluminum",
        "oilVolume":8,
        "engineBlockAirCoolingEfficiency":38,

        //engine durability
        "cylinderWallTemperatureDamageThreshold":150,
        "headGasketDamageThreshold":1500000,
        "pistonRingDamageThreshold":1500000,
        "connectingRodDamageThreshold":2000000,
        "maxTorqueRating": 590,
        "maxOverTorqueDamage": 500,

        //node beam interface
        "torqueReactionNodes:":["e1l","e2l","e4r"],
        "waterDamage": {"[engineGroup]:":["engine_intake"]},
        "radiator": {"[engineGroup]:":["radiator"]},
        "engineBlock": {"[engineGroup]:":["engine_block"]},
        "breakTriggerBeam":"engine",
        "uiName":"Engine",
        "soundConfig": "soundConfig",
        "soundConfigExhaust": "soundConfigExhaust",

        //starter motor
        "starterSample":"event:>Engine>Starter>v8diesel_12500cc_01_1990_eng",
        "starterSampleExhaust":"event:>Engine>Starter>v8diesel_12500cc_01_1990_exh",
        "shutOffSampleEngine":"event:>Engine>Shutoff>v8_20xy_eng",
        "shutOffSampleExhaust":"event:>Engine>Shutoff>v8_20xy_exh",
        "starterVolume":0.86,
        "starterVolumeExhaust":0.96,
        "shutOffVolumeEngine":0.76,
        "shutOffVolumeExhaust":0.76,
        "starterThrottleKillTime":0.34,
        "idleRPMStartRate":3.05,
        "idleRPMStartCoef":0.5,

        //engine deform groups
        "deformGroups":["mainEngine", "mainEngine_intake", "mainEngine_accessories"]
        "deformGroups_oilPan":["oilpan_damage"]
    },
    "soundConfig": {
        "sampleName": "V8D_1990_12500cc_commercial_01_engine",
        "intakeMuffling": 1.5,

        "mainGain": -5,
        "onLoadGain":1,
        "offLoadGain":0.67,

        "maxLoadMix": 1.0,
        "minLoadMix": 0,

        "lowShelfGain":6,
        "lowShelfFreq":120,

        "highShelfGain":0,
        "highShelfFreq":6000,

        "eqLowGain": 0,
        "eqLowFreq": 150,
        "eqLowWidth": 0.2,

        "eqHighGain": 0,
        "eqHighFreq": 2500,
        "eqHighWidth": 0.2,

        "fundamentalFrequencyCylinderCount":8,
        "eqFundamentalGain": -2,
    },
    "soundConfigExhaust": {
        "sampleName": "V8D_1990_12500cc_commercial_01_exhaust",

        "mainGain": 1.5,
        "onLoadGain":1,
        "offLoadGain":0.68,

        "maxLoadMix": 1.0,
        "minLoadMix": 0,

        "lowShelfGain":-12,
        "lowShelfFreq":90,

        "highShelfGain":3,
        "highShelfFreq":3000,

        "eqLowGain": 2,
        "eqLowFreq": 150,
        "eqLowWidth": 0.2,

        "eqHighGain": 0,
        "eqHighFreq": 2500,
        "eqHighWidth": 0.2,

        "fundamentalFrequencyCylinderCount":8,
        "eqFundamentalGain": -2,
    },
    "vehicleController": {
        "clutchLaunchStartRPM":1200,
        "clutchLaunchTargetRPM":1600,
        //**highShiftDown can be overwritten by automatic transmissions**
        "highShiftDownRPM":[0,0,0,2600,2950,3150,3400,3400],
        //**highShiftUp can be overwritten by intake modifications**
        "highShiftUpRPM":3700,
    },
    "flexbodies": [
        ["mesh", "[group]:", "nonFlexMaterials"],
        ["fleetjt_v8_engine", ["fleetjt_engine"]],
        {"deformGroup":"engbay_break", "deformMaterialBase":"fleetjt", "deformMaterialDamaged":"invis"},
        ["gavril_v8_fleetjt_radhose", ["fleetjt_engine", "fleetjt_radiator"]],
        {"deformGroup":"", "deformMaterialBase":"", "deformMaterialDamaged":""},
    ],
    "props": [
        ["func",            "mesh",                   "idRef:", "idX:", "idY:", "baseRotation",          "rotation",            "translation",         "min", "max", "offset", "multiplier"],
        ["rpmspin",             "gavril_v8_fleetjt_pulley1",      "e3l","e3r","e4l",     {"x":-90, "y":0, "z":0}, {"x":0, "y":1, "z":0}, {"x":0, "y":0, "z":0}, -360,  360,   0,        1],
        ["rpmspin",             "gavril_v8_fleetjt_pulley2",      "e3l","e3r","e4l",     {"x":-90, "y":0, "z":0}, {"x":0, "y":1, "z":0}, {"x":0, "y":0, "z":0}, -360,  360,   0,        -1],
        ["rpmspin",             "gavril_v8_fleetjt_pulley3",      "e3l","e3r","e4l",     {"x":-90, "y":0, "z":0}, {"x":0, "y":1, "z":0}, {"x":0, "y":0, "z":0}, -360,  360,   0,        1],
        ["rpmspin",             "gavril_v8_fleetjt_pulley4",      "e3l","e3r","e4l",     {"x":-90, "y":0, "z":0}, {"x":0, "y":1, "z":0}, {"x":0, "y":0, "z":0}, -360,  360,   0,        1],
        ["rpmspin",             "gavril_v8_fleetjt_pulley5",      "e3l","e3r","e4l",     {"x":-90, "y":0, "z":0}, {"x":0, "y":1, "z":0}, {"x":0, "y":0, "z":0}, -360,  360,   0,        1],
        ["rpmspin",             "gavril_v8_fleetjt_pulley6",      "e3l","e3r","e4l",     {"x":-90, "y":0, "z":0}, {"x":0, "y":1, "z":0}, {"x":0, "y":0, "z":0}, -360,  360,   0,        1],
    ],
    "nodes": [
         ["id", "posX", "posY", "posZ"],
         //5.5L V8 Engine
         {"frictionCoef":0.5},
         {"nodeMaterial":"|NM_METAL"},
         {"selfCollision":false},
         {"collision":true},
         {"group":"fleetjt_engine"},
         {"nodeWeight":30},
         {"engineGroup":"engine_block"},
         ["e1r", -0.13, -1.15, 0.32, {"chemEnergy":1000,"burnRate":0.39,"flashPoint":700,"specHeat": 0.1,"selfIgnitionCoef":false,"smokePoint":650,"baseTemp":"thermals","conductionRadius":0.2}],
         ["e1l", 0.13, -1.15, 0.32, {"chemEnergy":1000,"burnRate":0.39,"flashPoint":700,"specHeat": 0.1,"selfIgnitionCoef":false,"smokePoint":650,"baseTemp":"thermals","conductionRadius":0.2}],
         ["e2r", -0.13, -1.74, 0.32, {"isExhaust":"mainEngine"}],
         ["e2l", 0.13, -1.74, 0.32],
         {"engineGroup":["engine_block","engine_intake"]},
         {"group":["fleetjt_engine","fleetjt_engine_intake"]},
         ["e3r", -0.32, -1.15, 0.74],
         ["e3l", 0.32, -1.15, 0.74],
         ["e4r", -0.32, -1.74, 0.74],
         ["e4l", 0.32, -1.74, 0.74],
         {"chemEnergy":false,"burnRate":false,"flashPoint":false,"specHeat":false,"smokePoint":false,"selfIgnitionCoef":false,"baseTemp":false,"conductionRadius":false},
         {"engineGroup":""},
         {"group":""},
         //engine mount nodes
         ["em1r", -0.27, -1.5, 0.5, {"nodeWeight":1.85}],
         ["em1l", 0.27, -1.5, 0.5, {"nodeWeight":1.85}],
    ],
    "beams": [
          ["id1:", "id2:"],
          {"beamPrecompression":1, "beamType":"|NORMAL", "beamLongBound":1.0, "beamShortBound":1.0},
          //--ENGINE CUBE--
          {"beamSpring":18800940,"beamDamp":470},
          {"beamDeform":315000,"beamStrength":"FLT_MAX"},
          {"deformGroup":"mainEngine", "deformationTriggerRatio":0.001}
          ["e1r","e1l"],
          ["e1r","e2r"],
          ["e1r","e2l"],
          ["e1r","e3r"],
          ["e1r","e3l"],
          ["e1r","e4r"],
          ["e1r","e4l"],
          ["e1l","e2r"],
          ["e1l","e2l"],
          ["e1l","e3r"],
          ["e1l","e3l"],
          ["e1l","e4r"],
          ["e1l","e4l"],
          ["e2r","e2l", {"isExhaust":"mainEngine"}],
          ["e2r","e3r"],
          ["e2r","e3l"],
          ["e2r","e4r"],
          ["e2r","e4l"],
          ["e2l","e3r"],
          ["e2l","e3l"],
          ["e2l","e4r"],
          ["e2l","e4l"],
          ["e3r","e3l"],
          ["e3r","e4r"],
          ["e3r","e4l"],
          ["e3l","e4r"],
          ["e3l","e4l"],
          ["e4r","e4l"],

          //engine mount nodes
          {"beamSpring":2956300,"beamDamp":130.43},
          {"beamDeform":63000,"beamStrength":"FLT_MAX"},
          ["em1r","e3l"],
          ["em1r","e3r"],
          ["em1r","e4l"],
          ["em1r","e4r"],
          ["em1r", "e1r"],
          ["em1r", "e1l"],
          ["em1r", "e2l"],
          ["em1r", "e2r"],

          ["em1l","e3l"],
          ["em1l","e3r"],
          ["em1l","e4l"],
          ["em1l","e4r"],
          ["em1l", "e1r"],
          ["em1l", "e1l"],
          ["em1l", "e2l"],
          ["em1l", "e2r"],
          {"deformGroup":""},

          //mesh break beams
          {"beamPrecompression":0.8, "beamType":"|SUPPORT","beamLongBound":0.8},
          {"beamSpring":9400,"beamDamp":0},
          {"beamDeform":350,"beamStrength":700},
          {"deformGroup":"engbay_break","deformationTriggerRatio":0.01},
          {"optional":true},
          ["e2r","rad2"],
          ["e2l","rad2"],
          ["e4r","rad2"],
          ["e4l","rad2"],
          {"optional":false},
          {"deformGroup":""},
          {"beamPrecompression":1, "beamType":"|NORMAL", "beamLongBound":1.0, "beamShortBound":1.0},
    ],
},
}