Configuration
All configuration for legends_raceessentials is done in the config/config.lua file. Each feature can be enabled or disabled independently.
Configuration File Structure
Location: config/config.lua
Config = {}
Config.Services = { ... }
Config.SpeedLimitService = { ... }
Config.Slipstream = { ... }
Config.FallenEntitiesCleanup = { ... }Anti-Exploit Services
Config.Services
Config.Services = {
DisableDoubleClutching = true,
DisableCurbBoosting = true,
DisableAirControl = true,
}DisableDoubleClutching
Description: Prevents the "double clutching" exploit where players rapidly shift gears to gain excessive speed.
Type: boolean
Default: true
How it works:
- Monitors gear changes and RPM values
- When exploit conditions are detected (low gear, max RPM, high speed), it temporarily reduces RPM
- Allows normal driving but prevents the exploit-based speed gains
DisableCurbBoosting
Description: Reduces unintended speed boosts when driving over curbs and bumps.
Type: boolean
Default: true
How it works:
- Monitors acceleration and vertical displacement simultaneously
- When sudden acceleration coincides with vertical movement (curb hit), briefly reduces power
- Natural driving over bumps is unaffected
DisableAirControl
Description: Prevents players from manipulating vehicle rotation while airborne.
Type: boolean
Default: true
How it works:
- Uses advanced wheel-tracking system to detect when wheels leave the ground
- Limits aerial control without affecting normal turning physics
- Vehicles behave realistically when airborne
Speed Limiter
Config.SpeedLimitService
Config.SpeedLimitService = {
EnableSpeedLimitter = true,
metric = "kmh",
categorization = true,
maxSpeed = 210,
Categories = { ... }
}EnableSpeedLimitter
Description: Master toggle for the speed limiting system.
Type: boolean
Default: true
metric
Description: Speed unit for all speed values.
Type: string
Default: "kmh"
Options:
| Value | Unit |
|---|---|
"kmh" | Kilometers per hour |
"mph" | Miles per hour |
categorization
Description: Whether to use per-vehicle-class speed limits.
Type: boolean
Default: true
| Value | Behavior |
|---|---|
true | Each vehicle class uses its own speed limit from Categories |
false | All vehicles use the global maxSpeed value |
maxSpeed
Description: Global maximum speed used when categorization = false.
Type: number
Default: 210 (in the configured metric)
Categories
Description: Per-vehicle-class speed limits.
Type: table
Categories = {
[0] = 205, -- Compacts
[1] = 208, -- Sedans
[2] = 208, -- SUVs
[3] = 208, -- Coupes
[4] = 220, -- Muscle
[5] = 208, -- Sports Classics
[6] = 230, -- Sports
[7] = 240, -- Super
[8] = 230, -- Motorcycles
[9] = 208, -- Off-road
[10] = 208, -- Industrial
[11] = 208, -- Utility
[12] = 208, -- Vans
[13] = 230, -- Cycles
[14] = 208, -- Boats
[15] = nil, -- Helicopters (DO NOT MODIFY)
[16] = nil, -- Planes (DO NOT MODIFY)
[17] = 208, -- Service
[18] = 250, -- Emergency
[19] = 208, -- Military
[20] = 208, -- Commercial
[21] = 208, -- Trains
[22] = 208 -- Open Wheel
}Do not modify classes 15 and 16 (Helicopters and Planes). These should remain nil to avoid issues with aircraft physics.
Vehicle Class Reference:
| Class | Type | Default Speed |
|---|---|---|
| 0 | Compacts | 205 |
| 1 | Sedans | 208 |
| 2 | SUVs | 208 |
| 3 | Coupes | 208 |
| 4 | Muscle | 220 |
| 5 | Sports Classics | 208 |
| 6 | Sports | 230 |
| 7 | Super | 240 |
| 8 | Motorcycles | 230 |
| 18 | Emergency | 250 |
| 22 | Open Wheel | 208 |
Slipstream System
Config.Slipstream
Config.Slipstream = {
Enable = true,
PowerMultiplier = 1.5,
VisualEffects = true
}Enable
Description: Master toggle for the slipstream/drafting system.
Type: boolean
Default: true
PowerMultiplier
Description: How much power boost to apply when drafting behind another vehicle.
Type: number
Default: 1.5
| Value | Effect |
|---|---|
1.0 | No boost (drafting disabled effectively) |
1.5 | 50% power increase |
2.0 | 100% power increase |
3.0 | 200% power increase |
The boost only applies while you're in another vehicle's slipstream. It resets to normal when you leave the draft zone.
VisualEffects
Description: Shows air trail particle effects when in slipstream.
Type: boolean
Default: true
Creates wind trail effects on both sides of the vehicle while drafting.
Fallen Entities Cleanup
Config.FallenEntitiesCleanup
Config.FallenEntitiesCleanup = {
Enable = true,
CleanupProcessWaitTime = 250,
WhiteListedProps = { ... }
}Enable
Description: Enables automatic cleanup of fallen/displaced props.
Type: boolean
Default: true
CleanupProcessWaitTime
Description: Delay in milliseconds between cleanup iterations.
Type: number
Default: 250
Lower values = more responsive cleanup but slightly higher CPU usage.
WhiteListedProps
Description: Props that should never be cleaned up.
Type: table
The whitelist includes essential props organized by category:
- Security & Police items
- Doors & Gates (bank vaults, prison gates, etc.)
- Vending Machines & ATMs
- Gas Pumps
- Air Conditioners
- Office & Electronics
- Transportation (bus stops, phone booths)
- Waste Management (dumpsters, bins)
- Structures & Buildings
The default whitelist is extensive. Only add props if you notice them being incorrectly removed.
Adding a prop to whitelist:
WhiteListedProps = {
-- Using hash directly
[1234567890] = true,
-- Using backtick notation
[`prop_my_custom_prop`] = true,
}Example Configurations
Racing Server (Competitive)
Config.Services = {
DisableDoubleClutching = true,
DisableCurbBoosting = true,
DisableAirControl = true,
}
Config.SpeedLimitService = {
EnableSpeedLimitter = false, -- No speed limits for racing
}
Config.Slipstream = {
Enable = true,
PowerMultiplier = 1.3, -- Moderate slipstream boost
VisualEffects = true
}Roleplay Server (Realistic)
Config.Services = {
DisableDoubleClutching = true,
DisableCurbBoosting = true,
DisableAirControl = true,
}
Config.SpeedLimitService = {
EnableSpeedLimitter = true,
metric = "kmh",
categorization = true, -- Per-class limits
}
Config.Slipstream = {
Enable = false, -- Disabled for realism
}Need Help?
Join our Discord for support: discord.gg/lgnds (opens in a new tab)