mirror of
https://github.com/jimathy/jim-payments.git
synced 2026-08-17 06:16:02 +01:00
Merge pull request #49 from Dude495/patch-2
This commit is contained in:
@@ -3,23 +3,22 @@ local Till = {}
|
|||||||
|
|
||||||
function spawnCustomRegisters()
|
function spawnCustomRegisters()
|
||||||
Wait(1000)
|
Wait(1000)
|
||||||
for k, v in pairs(Config.CustomCashRegisters) do
|
for k, v in pairs(Config.CustomCashRegisters) do
|
||||||
for i = 1, #v do
|
for i = 1, #v do
|
||||||
local job, gang = v[i].gang and nil or k, v[i].gang and k or nil
|
local job, gang = v[i].gang and nil or k, v[i].gang and k or nil
|
||||||
createBoxTarget({"CustomRegister: "..k..i, v[i].coords.xyz, 0.47, 0.34, { name="CustomRegister: "..k..i, heading = v[i].coords[4], debugPoly=debugMode, minZ=v[i].coords.z-0.1, maxZ=v[i].coords.z+0.4}}, {
|
local img = v.img or v[i].img
|
||||||
{
|
createBoxTarget({"CustomRegister: "..k..i, v[i].coords.xyz, 0.47, 0.34, {name="CustomRegister: "..k..i, heading = v[i].coords[4], debugPoly = debugMode, minZ = v[i].coords.z-0.1, maxZ = v[i].coords.z+0.4}}, {
|
||||||
action = function()
|
{
|
||||||
TriggerEvent(getScript()..":client:Charge", { job = job, gang = gang, img = ""})
|
action = function() TriggerEvent(getScript()..":client:Charge", {job = job, gang = gang, img = img}) end,
|
||||||
end,
|
|
||||||
icon = "fas fa-credit-card",
|
icon = "fas fa-credit-card",
|
||||||
label = locale("target", "charge"),
|
label = locale("target","charge"),
|
||||||
job = job,
|
job = job,
|
||||||
gang = gang
|
gang = gang
|
||||||
}
|
}
|
||||||
}, 2.0)
|
}, 2.0)
|
||||||
if v[i].prop then makeProp({prop = "prop_till_03", coords = v[i].coords + vec4(0,0,1.0, 0.0)}, 1, false) end
|
if v[i].prop then makeProp({prop = "prop_till_03", coords = v[i].coords+vec4(0,0,1.0, 0.0)}, 1, false) end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
onPlayerLoaded(function() spawnCustomRegisters() end, true)
|
onPlayerLoaded(function() spawnCustomRegisters() end, true)
|
||||||
@@ -311,4 +310,6 @@ RegisterNetEvent(getScript()..":client:PayPopup", function(amount, biller, billt
|
|||||||
})
|
})
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
end)
|
|
||||||
|
end)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user