For those that want to change between the first and last option on the MFD (or viceversa), go to screens/multi_function_display_hud.lua and replace the function that starts in line 824 with this one:
I could also take a look into implementing the Course Map or even the Torque Distribution, but if the latter is not possible it could be adapted into the turbo intensity gauge.
function listenToUIInputs()
if not CONTROL_MODE or not GAMEPAD_INDEX then
return
end
local keyLeft = CFGControls.data[CONTROL_MODE]['MFD_LEFT']
local keyRight = CFGControls.data[CONTROL_MODE]['MFD_RIGHT']
if keyLeft == '' then keyLeft = nil end
if keyRight == '' then keyRight = nil end
if keyLeft and keyRight and CONTROL_MODE == 'X360' then
if ac.isGamepadButtonPressed(GAMEPAD_INDEX, GamepadNames[keyLeft][1]) then
debounceValues(function(page)
if page <= 1 then
MFD_PAGE = #MFD_MODULES
else
MFD_PAGE = page - 1
end
end, 200, MFD_PAGE)
end
if ac.isGamepadButtonPressed(GAMEPAD_INDEX, GamepadNames[keyRight][1]) then
debounceValues(function(page)
if page >= #MFD_MODULES then
MFD_PAGE = 1
else
MFD_PAGE = page + 1
end
end, 200, MFD_PAGE)
end
end
if keyLeft and keyRight and CONTROL_MODE == 'WHEEL' then
local numberLeft = tonumber(keyLeft)
local numberRight = tonumber(keyRight)
if numberLeft == 0 or numberLeft == 9000 or numberLeft == 18000 or numberLeft == 27000 then
if tonumber(ac.getJoystickDpadValue(WHEEL_INDEX, 0)) == numberLeft then
debounceValues(function(page)
if page <= 1 then
MFD_PAGE = #MFD_MODULES
else
MFD_PAGE = page - 1
end
end, 300, MFD_PAGE)
end
else
if ac.isJoystickButtonPressed(WHEEL_INDEX, numberLeft) then
debounceValues(function(page)
if page <= 1 then
MFD_PAGE = #MFD_MODULES
else
MFD_PAGE = page - 1
end
end, 200, MFD_PAGE)
end
end
if numberRight == 0 or numberRight == 9000 or numberRight == 18000 or numberRight == 27000 then
if tonumber(ac.getJoystickDpadValue(WHEEL_INDEX, 0)) == numberRight then
debounceValues(function(page)
if page >= #MFD_MODULES then
MFD_PAGE = 1
else
MFD_PAGE = page + 1
end
end, 300, MFD_PAGE)
end
else
if ac.isJoystickButtonPressed(WHEEL_INDEX, numberRight) then
debounceValues(function(page)
if page >= #MFD_MODULES then
MFD_PAGE = 1
else
MFD_PAGE = page + 1
end
end, 200, MFD_PAGE)
end
end
end
if keyLeft and keyRight and CONTROL_MODE == 'KEYBOARD' then
if ac.isKeyDown(keyLeft) then
debounceValues(function(page)
if page <= 1 then
MFD_PAGE = #MFD_MODULES
else
MFD_PAGE = page - 1
end
end, 200, MFD_PAGE)
end
if ac.isKeyDown(keyRight) then
debounceValues(function(page)
if page >= #MFD_MODULES then
MFD_PAGE = 1
else
MFD_PAGE = page + 1
end
end, 200, MFD_PAGE)
end
end
if ui.mouseClicked(ui.MouseButton.Left) then
local norm_pos = ui.mousePos() - ui.windowPos()
if FixedBtnLeft.y < norm_pos.y and
norm_pos.y < FixedBtnLeft.y + FixedBtnLeft.h and
FixedBtnLeft.x < norm_pos.x and
norm_pos.x < FixedBtnLeft.x + FixedBtnLeft.w then
debounceValues(function(page)
if page <= 1 then
MFD_PAGE = #MFD_MODULES
else
MFD_PAGE = page - 1
end
end, 10, MFD_PAGE)
end
if FixedBtnRight.y < norm_pos.y and
norm_pos.y < FixedBtnRight.y + FixedBtnRight.h and
FixedBtnRight.x < norm_pos.x and
norm_pos.x < FixedBtnRight.x + FixedBtnRight.w then
debounceValues(function(page)
if page >= #MFD_MODULES then
MFD_PAGE = 1
else
MFD_PAGE = page + 1
end
end, 10, MFD_PAGE)
end
end
end
I could also take a look into implementing the Course Map or even the Torque Distribution, but if the latter is not possible it could be adapted into the turbo intensity gauge.