Tidy up the double check for commPercent

Left in the old code for commission calculation

I don't think it was making a difference but it wasn't needed
This commit is contained in:
Jim Shield
2025-05-14 20:24:47 +01:00
parent f869c682c1
commit e73520a10c
2 changed files with 4 additions and 11 deletions

View File

@@ -14,12 +14,7 @@ RegisterServerEvent(getScript()..":server:PolCharge", function(citizen, price)
local price = math.floor(tonumber(price))
local commPercent = Config.PolCharge.FineJobs[biller.job] and Config.PolCharge.FineJobs[biller.job].Commission or 0.25
if Config.PolCharge.FineJobs[biller.job] then
commPercent = Config.PolCharge.FineJobs[biller.job].Commission
else
commPercent = 0.25
print("^3Warning^7: ^2Can't find player's job in ^7'Config.Polcharge.FineJobs', ^2defaulting to 0.25 (25% commission)^7")
end
local commission = math.floor(price * commPercent)
if price > 0 then