Configuration

Configuration

legends_tax uses two configuration files:

  • config.json - Main tax settings (can be edited in-game via admin panel)
  • permissions.lua - Admin access configuration

Non-technical users: Use the in-game admin panel (/taxadmin) to configure most settings without editing files!


General Settings

useCustomNotifications

"general": {
    "useCustomNotifications": true
}

Description: Use ox_lib notifications instead of framework-specific ones.

Type: boolean | Default: true


notificationDuration

"notificationDuration": 20000

Description: How long notifications display (milliseconds).

Type: number | Default: 20000 (20 seconds)


enableDebug

"enableDebug": false

Description: Enable debug prints in server console.

Type: boolean | Default: false


allowNegativeBank

"allowNegativeBank": true

Description: Allow players to go into negative bank balance when auto-pay triggers.

Type: boolean | Default: true


Tax Type Toggles

"enableVehicleTax": true,
"enableBankTax": true,
"enableHouseTax": false
SettingDescription
enableVehicleTaxEnable/disable vehicle taxation
enableBankTaxEnable/disable bank balance taxation
enableHouseTaxEnable/disable property taxation

Bank Tax Settings

"bankTax": {
    "bankTaxRate": 0.05,
    "minBankBalanceForTax": 10000,
    "maxBankBalanceForTax": 1000000
}
PropertyTypeDescription
bankTaxRatenumberPercentage of bank balance to tax (0.05 = 5%)
minBankBalanceForTaxnumberMinimum balance before bank tax applies
maxBankBalanceForTaxnumberMaximum balance to consider for taxation

Example: With 5% rate and $50,000 bank balance:

  • Tax = $50,000 × 0.05 = $2,500

Vehicle Tax Settings

"vehicleTax": {
    "baseVehicleTaxRate": 0.02,
    "extraVehicleTaxRate": 0.02,
    "maxVehicleTaxRate": 0.10,
    "useGlobalVehicleTaxRates": false,
    "categoryRates": {}
}
PropertyTypeDescription
baseVehicleTaxRatenumberBase rate for first vehicle (0.02 = 2%)
extraVehicleTaxRatenumberAdditional rate per extra vehicle
maxVehicleTaxRatenumberMaximum rate cap (0.10 = 10%)
useGlobalVehicleTaxRatesbooleanUse flat rate vs category-based rates
categoryRatesobjectPer-category tax rates

Category-Based Rates

When useGlobalVehicleTaxRates is false, you can set rates per vehicle class:

"categoryRates": {
    "Super": 0.08,
    "Sports": 0.06,
    "Muscle": 0.04,
    "Sedans": 0.02,
    "Compacts": 0.01
}

Property Tax Settings

"propertyTax": {
    "taxPerHouse": false,
    "pricePerHouse": 100000,
    "percentagePerHouse": 0.05
}
PropertyTypeDescription
taxPerHousebooleanFlat amount per house vs percentage
pricePerHousenumberFlat amount if taxPerHouse is true
percentagePerHousenumberPercentage of house value if false

Tax Intervals

Global vs Separate Intervals

"taxIntervals": {
    "useGlobalInterval": false,
    "globalTaxIntervalDays": 7,
    "vehicleTaxIntervalDays": 7,
    "propertyTaxIntervalDays": 14,
    "bankTaxIntervalDays": 3,
    "showCollectionTimer": true
}
PropertyTypeDescription
useGlobalIntervalbooleanUse single interval for all taxes
globalTaxIntervalDaysnumberDays between tax collections (global mode)
vehicleTaxIntervalDaysnumberDays between vehicle tax
propertyTaxIntervalDaysnumberDays between property tax
bankTaxIntervalDaysnumberDays between bank tax
showCollectionTimerbooleanShow countdown in player UI

When useGlobalInterval is true, all taxes are collected together using globalTaxIntervalDays.


Unpaid Tax Settings

"unpaidTax": {
    "taxInterestRate": 0.05,
    "taxInterestIntervalDays": 3,
    "autoPayUnpaidTaxDays": 7,
    "maxTaxInterestRate": 0.5
}
PropertyTypeDescription
taxInterestRatenumberInterest added per interval (0.05 = 5%)
taxInterestIntervalDaysnumberDays between interest applications
autoPayUnpaidTaxDaysnumberDays before auto-pay triggers
maxTaxInterestRatenumberMaximum total interest cap (0.5 = 50%)

Example flow:

  1. Invoice created: $1,000
  2. After 3 days (unpaid): $1,000 + 5% = $1,050
  3. After 6 days: $1,050 + 5% = $1,102.50
  4. After 7 days: Auto-pay from bank

Job Discounts

"jobDiscounts": {
    "police": 15,
    "ambulance": 10,
    "mechanic": 5
}

Format: "jobName": discountPercentage

Players with these jobs receive the specified percentage discount on all taxes.


NPC Settings

"npc": {
    "model": "a_m_y_business_01",
    "coords": { "x": 216.19, "y": -808.77, "z": 30.74 },
    "heading": 90.0,
    "label": "Tax Office",
    "icon": "fa-solid fa-money-bill-wave",
    "useOxTarget": true
}
PropertyTypeDescription
modelstringNPC ped model name
coordsobjectNPC spawn location
headingnumberNPC facing direction
labelstringTarget/interaction label
iconstringFontAwesome icon class
useOxTargetbooleanUse ox_target for interaction

Testing Mode

"testing": {
    "testingMode": false,
    "testingGlobalIntervalSeconds": 10,
    "testingVehicleTaxIntervalSeconds": 10,
    "testingPropertyTaxIntervalSeconds": 15,
    "testingBankTaxIntervalSeconds": 5,
    "testingInterestIntervalSeconds": 20,
    "testingAutoPaySeconds": 145
}
⚠️

Testing Mode: When enabled, all intervals use seconds instead of days. Never enable in production!


Performance Settings

"performance": {
    "taxCycleYieldInterval": 10,
    "adminBulkBatchSize": 10,
    "adminBatchDelayMs": 100,
    "adminQueryTimeoutMs": 10000
}
PropertyDescription
taxCycleYieldIntervalYield every N players during tax cycles
adminBulkBatchSizeBatch size for bulk admin operations
adminBatchDelayMsDelay between batches
adminQueryTimeoutMsTimeout for admin queries

Maintenance Settings

"maintenance": {
    "auditLogRetentionDays": 90,
    "invoiceArchiveAfterDays": 365,
    "maintenanceScheduleHour": 4,
    "maintenanceBatchSize": 1000
}
PropertyDescription
auditLogRetentionDaysDays to keep audit logs
invoiceArchiveAfterDaysDays before archiving paid invoices
maintenanceScheduleHourHour to run maintenance (0-23)
maintenanceBatchSizeRecords per maintenance batch

Permissions Configuration

Location: permissions.lua

Permission Modes

Permissions.UseAcePermissions = true   -- Use ACE permissions
Permissions.UseWhitelist = true        -- Use identifier whitelist
Permissions.RequireBoth = false        -- Require both or just one

ACE Permission

Permissions.AcePermission = "tax.admin"

Add to server.cfg:

add_ace group.admin tax.admin allow

Whitelist

Permissions.Whitelist = {
    "steam:11000010000000",
    "discord:123456789012345678",
    "license:1234567890abcdef1234567890abcdef12345678",
    "fivem:123456",
}

CitizenID Whitelist (Legacy)

Permissions.CitizenIds = {
    "ABC12345",
    "XYZ98765",
}

Discord Webhook

Permissions.UseDiscordLogging = true
Permissions.DiscordWebhook = "https://discord.com/api/webhooks/..."

Example Configurations

Low Tax Server

{
    "bankTax": {
        "bankTaxRate": 0.02,
        "minBankBalanceForTax": 50000
    },
    "vehicleTax": {
        "baseVehicleTaxRate": 0.01
    },
    "unpaidTax": {
        "taxInterestRate": 0.02,
        "autoPayUnpaidTaxDays": 14
    }
}

High Tax Economy Server

{
    "bankTax": {
        "bankTaxRate": 0.10,
        "minBankBalanceForTax": 5000
    },
    "vehicleTax": {
        "baseVehicleTaxRate": 0.05,
        "extraVehicleTaxRate": 0.03
    },
    "unpaidTax": {
        "taxInterestRate": 0.10,
        "autoPayUnpaidTaxDays": 3
    }
}

Need Help?

Join our Discord for support: discord.gg/lgnds (opens in a new tab)


Legends Store - Premium FiveM Scripts