diff --git a/client/main.lua b/client/main.lua index 82828b6..0a6154a 100644 --- a/client/main.lua +++ b/client/main.lua @@ -335,8 +335,10 @@ local function openVehicleSellMenu() arrow = true } if config.shops[insideShop].type == 'free-use' then - options = { - { + options = {} + + if config.enableTestDrive then + options[#options + 1] = { title = Lang:t('menus.test_header'), description = Lang:t('menus.freeuse_test_txt'), event = 'qbx_vehicleshop:client:testDrive', @@ -344,7 +346,7 @@ local function openVehicleSellMenu() vehicle = vehicle } } - } + end if config.enableFreeUseBuy then options[#options + 1] = { @@ -370,13 +372,6 @@ local function openVehicleSellMenu() options[#options + 1] = swapOption else options = { - { - title = Lang:t('menus.test_header'), - description = Lang:t('menus.managed_test_txt'), - onSelect = function() - startTestDrive(vehicle) - end, - }, { title = Lang:t('menus.managed_sell_header'), description = Lang:t('menus.managed_sell_txt'), @@ -386,6 +381,16 @@ local function openVehicleSellMenu() } } + if config.enableTestDrive then + options[#options + 1] = { + title = Lang:t('menus.test_header'), + description = Lang:t('menus.managed_test_txt'), + onSelect = function() + startTestDrive(vehicle) + end + } + end + if config.finance.enable then options[#options + 1] = { title = Lang:t('menus.finance_header'), diff --git a/config/client.lua b/config/client.lua index 192d24a..092bb77 100644 --- a/config/client.lua +++ b/config/client.lua @@ -2,7 +2,8 @@ return { useTarget = false, debugPoly = false, enableFreeUseBuy = true, -- Allows players to buy from NPC shops - + enableTestDrive = true, + finance = { enable = true, -- Enables the financing system. Turning this off does not affect already financed vehicles commissionRate = 0.05, -- Percent that goes to sales person from a finance sale 5% @@ -1778,4 +1779,4 @@ return { shop = 'pdm', }, }, -} \ No newline at end of file +}