chaser_calculatetuningacc

chaser_calculatetuningacc([string] entryname,[float] currentweight,[string] engineswapname,[table] turbo,[bool] hastransmissionupgrade)

It's a internal function used to consider tuning on the chaser_getpp export, but may be useful for users to also consider tuning in their PP System calibration process.

Example:

RegisterCommand("gettuneacc", function()
    if chaser:chaser_getloadstatus() then
        local ped = PlayerPedId()
        local vehicle = GetVehiclePedIsIn(ped, false)
        local weight = chaser:chaser_getweight()
        local engine = chaser:chaser_getengine()
        local turbodata = chaser:chaser_getturbo()
        local hastransmissionupgrade = GetVehicleMod(vehicle,13) >= 0
        local sendturbodata = {
            compressorsize = turbodata.size, --INT value 
            boosttype = turbodata.typeid, --INT value
            peakturbodecayboost = turbodata.ptdboost, --INT value
            turbodecaypoint = turbodata.tdp, --Float value
            maxtrboostpmax = turbodata.mtbpmax, --Float value
            maxtrboostpmin = turbodata.mtbpmin, --Float value
            maxtrboostpminprct = turbodata.mtbpminprct, --INT value
            maxtrboostpmaxprct = turbodata.mtbpmaxprct,  --INT value
            booststartpoint = turbodata.bsp --Float value
        }
        local tuneacc = chaser:chaser_getpp(chaser:chaser_getvehname(),weight,engine,sendturbodata,hastransmissionupgrade)
        print(tuneacc)
    end
end, false)

Last updated