Skip to content

Commit

Permalink
refactor: more descriptive config name
Browse files Browse the repository at this point in the history
Fixed the typos in the config and client main for removal of lockpick
  • Loading branch information
dusan01 authored Nov 18, 2023
1 parent a79a0bd commit 0009616
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions client/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -409,11 +409,11 @@ function LockpickFinishCallback(success)
end

if usingAdvanced then
if chance <= Config.removeLockpickAdvanced[GetVehicleClass(vehicle)] then
if chance <= Config.removeAdvancedLockpickChance[GetVehicleClass(vehicle)] then
TriggerServerEvent("qb-vehiclekeys:server:breakLockpick", "advancedlockpick")
end
else
if chance <= Config.removeLockpickNormal[GetVehicleClass(vehicle)] then
if chance <= Config.removeNormalLockpickChance[GetVehicleClass(vehicle)] then
TriggerServerEvent("qb-vehiclekeys:server:breakLockpick", "lockpick")
end
end
Expand Down
2 changes: 1 addition & 1 deletion config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Config = {
[21] = 0.5, -- Trains
[22] = 0.5, -- Open Wheel
},
removeLockpickAdvanced = { -- Chance to remove advanced lockpick on fail by vehicle class
removeAdvancedLockpickChance = { -- Chance to remove advanced lockpick on fail by vehicle class
[0] = 0.5, -- Compacts
[1] = 0.5, -- Sedans
[2] = 0.5, -- SUVs
Expand Down

0 comments on commit 0009616

Please sign in to comment.