mirror of
https://github.com/jimathy/jim-payments.git
synced 2026-08-16 22:06:02 +01:00
Add files via upload
This commit is contained in:
414
README.md
414
README.md
@@ -1,208 +1,208 @@
|
||||
# jim-payments
|
||||
- QBCore based payment system
|
||||
- Enchanced QB-Input payment system from my other scripts now free on its own
|
||||
|
||||
### If you need support I have a discord server available, it helps me keep track of issues and give better support.
|
||||
## https://discord.gg/xKgQZ6wZvS
|
||||
|
||||
### We also have Documentation over on Gitbook, feel free to check it out
|
||||
## https://jixelpatterns.gitbook.io/jixelpatterns-script-guide/overview/who-we-are
|
||||
|
||||
### If you think I did a good job here, consider donating as it keeps by lights on and my cat fat/floofy:
|
||||
## https://ko-fi.com/jixelpatterns
|
||||
|
||||
---
|
||||
|
||||
- If you use a different phone/invoice system let me know and I will add support for it as best I can!
|
||||
- Currently supported are:
|
||||
- qb-phone
|
||||
- gks-phone
|
||||
- qs-smartphone - Leave the setting as "qb"
|
||||
|
||||
---
|
||||
# Installation
|
||||
---
|
||||
- I always recommend starting my scripts AFTER `[qb]` not inside it as it can mess with any dependancies on server load
|
||||
- I have a separate folder called `[jim]` (that is also in the resources folder) that starts WAY after everything else.
|
||||
- This ensure's it has everything it requires before trying to load
|
||||
- Example of my load order:
|
||||
```CSS
|
||||
# QBCore & Extra stuff
|
||||
ensure qb-core
|
||||
ensure [qb]
|
||||
ensure [standalone]
|
||||
ensure [voice]
|
||||
ensure [defaultmaps]
|
||||
ensure [vehicles]
|
||||
#Extra Jim Stuff
|
||||
ensure [jim]
|
||||
```
|
||||
|
||||
---
|
||||
## BZZ Terminal Instructions
|
||||
Free Package https://bzzz.tebex.io/package/5551076
|
||||
|
||||
Stream the prop and add the emote that is provided to rpemotes or dpemotes
|
||||
```lua
|
||||
['terminal'] = {['name'] = 'terminal', ['label'] = 'Wireless Terminal', ['weight'] = 5000, ["type"] = "item", ["image"] = 'terminal.png', ['unique'] = true, ['useable'] = true, ["shouldClose"] = true, ["combinable"] = nil, ['description'] = ''},
|
||||
```
|
||||
|
||||
---
|
||||
## Item installation
|
||||
- To make use of the ticket reward system for workers you need to add the ticket item to your shared items lua
|
||||
- Naviage to `[qb] > qb-core / shared / items.lua` and add this line
|
||||
```lua
|
||||
payticket = { name = "payticket", label = "Receipt", weight = 10, type = "item", image = "ticket.png", unique = false, useable = false, shouldClose = false, description = "Cash these in at the bank!" },
|
||||
```
|
||||
|
||||
- Add the ticket image to your inventory script:
|
||||
- Naviage to `[qb] > qb-inventory > html > images` and add this line
|
||||
|
||||

|
||||
|
||||
---
|
||||
## Phone Setup
|
||||
- There are two modes in the script, one that uses the phone for invoices/bank charges
|
||||
- The script supports many features like pay tickets, commission payments etc.
|
||||
- If you want to use phone systems for these then you need to add the event for when a payment is accepted:
|
||||
- REMINDER: IF using phone invoices, the money being added to the society accounts is handled `BY THE PHONE`, not by my script. If money isn't going to the account its the phone system or bossmenu script.
|
||||
|
||||
#### QB-Phone:
|
||||
- Go to `[qb] > qb-phone > client > main.lua`
|
||||
- Search for the event `RegisterNUICallback('PayInvoice', function(data, cb)` and look for the line:
|
||||
```lua
|
||||
TriggerServerEvent('qb-phone:server:BillingEmail', data, true)
|
||||
```
|
||||
|
||||
- Directly *above* this line add:
|
||||
```lua
|
||||
TriggerServerEvent('jim-payments:Tickets:Give', data)
|
||||
```
|
||||
- The phone should now be integrated with jim-payments
|
||||
|
||||
#### GKS-Phone:
|
||||
- Go to `gks-phone > server > serverapi.lua`
|
||||
- Search for the event: `gksphone:faturapayBill` and search for this line:
|
||||
```lua
|
||||
Ply.Functions.RemoveMoney('bank', data[1].amount, "paid-invoice")
|
||||
```
|
||||
|
||||
- Directly under this line add this event:
|
||||
```lua
|
||||
TriggerEvent('jim-payments:Tickets:Give', { sender = Ply.PlayerData.charinfo.firstname, senderCitizenId = data[1].sendercitizenid, society = data[1].society, amount = data[1].amount })
|
||||
```
|
||||
- The phone should now be integrated with jim-payments
|
||||
|
||||
#### Renewed QB-Phone:
|
||||
- Go to `qb-phone > server > invoices.lua`
|
||||
- Search for the event: `qb-phone:server:PayMyInvoice` and search for this line:
|
||||
```lua
|
||||
TriggerEvent("qb-phone:server:InvoiceHandler", true, amount, src, resource)
|
||||
```
|
||||
|
||||
- Directly under this line add this event:
|
||||
```lua
|
||||
TriggerEvent('jim-payments:Tickets:Give', { amount = amount, senderCitizenId = sendercitizenid, sender = SenderPly.PlayerData.charinfo.firstname, society = society }, SenderPly)
|
||||
```
|
||||
- When invoices are paid, they should now be integrated with jim-payments
|
||||
|
||||
# Setup/Config
|
||||
|
||||
## Custom Locations
|
||||
|
||||
- You can make of this payment system for a job script that wasn't created by me
|
||||
- All you need to do is add the job, grab a `vector4` (vector3 + heading) and set if you need a to spawn prop or not
|
||||
- For example:
|
||||
```lua
|
||||
CustomCashRegisters = { -- Located in the config.lua
|
||||
["burgershot"] = { -- Player job role restriction
|
||||
{ coords = vector4(-1185.5, -878.54, 13.91, 305.53), prop = true, }, -- vector4 to place the till and the way it faces
|
||||
{ coords = vector4(-1184.34, -880.51, 13.93, 302.04), prop = true, }, -- "prop = true" spawns a prop at the coords
|
||||
},
|
||||
},
|
||||
```
|
||||
### This does not need to be done for MY job scripts, they already have built in support
|
||||
---
|
||||
## PayTickets
|
||||

|
||||
- This script has a built in ticket reward system
|
||||
- On successful sale, the employees will be handed a ticket if they are clocked in
|
||||
- This can then be handed in to the bank to receive payment
|
||||
- Works as a reward and incentive for turning up to do work
|
||||
- The values are set per job in `Config.Jobs`
|
||||
- `TicketSystem` Enable this if you want to use the ticket system false
|
||||
- `TicketSystemAll` Enable this to give tickets to all workers clocked in
|
||||
---
|
||||
## Commission System
|
||||
- Support for commission to be paid as a reward for each successful payment
|
||||
- Very customisable with the config.lua
|
||||
- `Commission` Choose wether people get commission from every sale
|
||||
- `CommissionAll` Choose if **EVERY** worker gets Commission that is on duty
|
||||
- `CommissionDouble` Choose if Commission is limited by `MinAmountForTicket`
|
||||
- `CommissionLimit` Choose if the worker charging the customer gets double commission
|
||||
|
||||
---
|
||||
## Multiple Job and Gang Role support
|
||||
- The script supports adding job roles to the config so they can get rewards for successful payments
|
||||
- This includes Gang roles for stores/bars owned by a gang allowing them to get ticket rewards and commission
|
||||
- Examples of adding jobs / gangs to config.lua:
|
||||
```lua
|
||||
Jobs = {
|
||||
['mechanic'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['lostmc'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, gang = true, },
|
||||
},
|
||||
```
|
||||
- `MinAmountforTicket` is the amount required in a charge before they can get a ticket
|
||||
- `PayPerTicket` is the amount paid per ticket at the bank for the job role
|
||||
- I personally recommend this being lower than `MinAmountforTicket`, being too high makes it exploitable
|
||||
- `Commission` is the amount of commission given to players on successful payments (0.10 = 10%)
|
||||
- `gang = true` add this if the added role is a gang role
|
||||
---
|
||||
## /cashgive
|
||||

|
||||
- Alternative to /givecash
|
||||
- A simple command built in to send cash to a `nearby player`
|
||||
- Shows a list of names and id's of people nearby to select from rather
|
||||
- Better experience than trying to figure out their ID and entering it manually
|
||||
---
|
||||
## /cashregister
|
||||

|
||||
- This command is mean't as a portable cash register alternative
|
||||
- For example:
|
||||
- When a person is devliering food they can do `/cashregister` and the payment will still be sent to the society account
|
||||
- Doesn't utilize the ticket reward system unfortunately
|
||||
---
|
||||
## /polcharge
|
||||
- This script supports a customisable "police billing"
|
||||
- This is the ability for selected jobroles to charge a nearby player
|
||||
- Depending on how you've set it up, this can take money directly from the players bank to the job's society account
|
||||
- This is by default enabled for `police` and `ambulance`
|
||||
- This also supports giving the player a cut of the payment as `commission`
|
||||
- Default Config:
|
||||
```lua
|
||||
FineJobs = {
|
||||
['police'] = { Commission = 0.25, },
|
||||
['ambulance'] = { Commission = 0.25, },
|
||||
},
|
||||
FineJobConfirmation = false, -- "true" makes it so fines need confirmation, "false" skips this ands just removes the money
|
||||
FineJobList = true, -- "true" to use nearby player list feature in the cash registers, "false" for manual id entry
|
||||
```
|
||||
---
|
||||
## Banking
|
||||

|
||||
- This script has simple banking systems built in
|
||||
- Works as a basic replacement for qb-banking and qb-atms
|
||||
- Adjust the options in config.lua:
|
||||
- `useATM` Choose wether to make atm's usable
|
||||
- `useBanks` Choose wether to make bank desks/teller's usable
|
||||
- `BankBlips` Enable this if you disabled qb-banking and need bank locations
|
||||
- `ATMBlips` Enable this if you are a pyscho and need every ATM to be on the map too
|
||||
- `Gabz` Enable to change to Gabz Bank locations, this corrects the ATM/Bank Cashier + Ticket Cash in
|
||||
---
|
||||
|
||||
### Renewed's qb-phone
|
||||
- Simply leave the Config.PhoneType as `"qb"`
|
||||
|
||||
### AP-Goverment
|
||||
- Support for AP-Goverment Tax on payments
|
||||
# jim-payments
|
||||
- QBCore based payment system
|
||||
- Enchanced QB-Input payment system from my other scripts now free on its own
|
||||
|
||||
### If you need support I have a discord server available, it helps me keep track of issues and give better support.
|
||||
## https://discord.gg/xKgQZ6wZvS
|
||||
|
||||
### We also have Documentation over on Gitbook, feel free to check it out
|
||||
## https://jixelpatterns.gitbook.io/jixelpatterns-script-guide/overview/who-we-are
|
||||
|
||||
### If you think I did a good job here, consider donating as it keeps by lights on and my cat fat/floofy:
|
||||
## https://ko-fi.com/jixelpatterns
|
||||
|
||||
---
|
||||
|
||||
- If you use a different phone/invoice system let me know and I will add support for it as best I can!
|
||||
- Currently supported are:
|
||||
- qb-phone
|
||||
- gks-phone
|
||||
- qs-smartphone - Leave the setting as "qb"
|
||||
|
||||
---
|
||||
# Installation
|
||||
---
|
||||
- I always recommend starting my scripts AFTER `[qb]` not inside it as it can mess with any dependancies on server load
|
||||
- I have a separate folder called `[jim]` (that is also in the resources folder) that starts WAY after everything else.
|
||||
- This ensure's it has everything it requires before trying to load
|
||||
- Example of my load order:
|
||||
```CSS
|
||||
# QBCore & Extra stuff
|
||||
ensure qb-core
|
||||
ensure [qb]
|
||||
ensure [standalone]
|
||||
ensure [voice]
|
||||
ensure [defaultmaps]
|
||||
ensure [vehicles]
|
||||
#Extra Jim Stuff
|
||||
ensure [jim]
|
||||
```
|
||||
|
||||
---
|
||||
## BZZ Terminal Instructions
|
||||
Free Package https://bzzz.tebex.io/package/5551076
|
||||
|
||||
Stream the prop and add the emote that is provided to rpemotes or dpemotes
|
||||
```lua
|
||||
['terminal'] = {['name'] = 'terminal', ['label'] = 'Wireless Terminal', ['weight'] = 5000, ["type"] = "item", ["image"] = 'terminal.png', ['unique'] = true, ['useable'] = true, ["shouldClose"] = true, ["combinable"] = nil, ['description'] = ''},
|
||||
```
|
||||
|
||||
---
|
||||
## Item installation
|
||||
- To make use of the ticket reward system for workers you need to add the ticket item to your shared items lua
|
||||
- Naviage to `[qb] > qb-core / shared / items.lua` and add this line
|
||||
```lua
|
||||
payticket = { name = "payticket", label = "Receipt", weight = 10, type = "item", image = "ticket.png", unique = false, useable = false, shouldClose = false, description = "Cash these in at the bank!" },
|
||||
```
|
||||
|
||||
- Add the ticket image to your inventory script:
|
||||
- Naviage to `[qb] > qb-inventory > html > images` and add this line
|
||||
|
||||

|
||||
|
||||
---
|
||||
## Phone Setup
|
||||
- There are two modes in the script, one that uses the phone for invoices/bank charges
|
||||
- The script supports many features like pay tickets, commission payments etc.
|
||||
- If you want to use phone systems for these then you need to add the event for when a payment is accepted:
|
||||
- REMINDER: IF using phone invoices, the money being added to the society accounts is handled `BY THE PHONE`, not by my script. If money isn't going to the account its the phone system or bossmenu script.
|
||||
|
||||
#### QB-Phone:
|
||||
- Go to `[qb] > qb-phone > client > main.lua`
|
||||
- Search for the event `RegisterNUICallback('PayInvoice', function(data, cb)` and look for the line:
|
||||
```lua
|
||||
TriggerServerEvent('qb-phone:server:BillingEmail', data, true)
|
||||
```
|
||||
|
||||
- Directly *above* this line add:
|
||||
```lua
|
||||
TriggerServerEvent('jim-payments:Tickets:Give', data)
|
||||
```
|
||||
- The phone should now be integrated with jim-payments
|
||||
|
||||
#### GKS-Phone:
|
||||
- Go to `gks-phone > server > serverapi.lua`
|
||||
- Search for the event: `gksphone:faturapayBill` and search for this line:
|
||||
```lua
|
||||
Ply.Functions.RemoveMoney('bank', data[1].amount, "paid-invoice")
|
||||
```
|
||||
|
||||
- Directly under this line add this event:
|
||||
```lua
|
||||
TriggerEvent('jim-payments:Tickets:Give', { sender = Ply.PlayerData.charinfo.firstname, senderCitizenId = data[1].sendercitizenid, society = data[1].society, amount = data[1].amount })
|
||||
```
|
||||
- The phone should now be integrated with jim-payments
|
||||
|
||||
#### Renewed QB-Phone:
|
||||
- Go to `qb-phone > server > invoices.lua`
|
||||
- Search for the event: `qb-phone:server:PayMyInvoice` and search for this line:
|
||||
```lua
|
||||
TriggerEvent("qb-phone:server:InvoiceHandler", true, amount, src, resource)
|
||||
```
|
||||
|
||||
- Directly under this line add this event:
|
||||
```lua
|
||||
TriggerEvent('jim-payments:Tickets:Give', { amount = amount, senderCitizenId = sendercitizenid, sender = SenderPly.PlayerData.charinfo.firstname, society = society }, SenderPly)
|
||||
```
|
||||
- When invoices are paid, they should now be integrated with jim-payments
|
||||
|
||||
# Setup/Config
|
||||
|
||||
## Custom Locations
|
||||
|
||||
- You can make of this payment system for a job script that wasn't created by me
|
||||
- All you need to do is add the job, grab a `vector4` (vector3 + heading) and set if you need a to spawn prop or not
|
||||
- For example:
|
||||
```lua
|
||||
CustomCashRegisters = { -- Located in the config.lua
|
||||
["burgershot"] = { -- Player job role restriction
|
||||
{ coords = vector4(-1185.5, -878.54, 13.91, 305.53), prop = true, }, -- vector4 to place the till and the way it faces
|
||||
{ coords = vector4(-1184.34, -880.51, 13.93, 302.04), prop = true, }, -- "prop = true" spawns a prop at the coords
|
||||
},
|
||||
},
|
||||
```
|
||||
### This does not need to be done for MY job scripts, they already have built in support
|
||||
---
|
||||
## PayTickets
|
||||

|
||||
- This script has a built in ticket reward system
|
||||
- On successful sale, the employees will be handed a ticket if they are clocked in
|
||||
- This can then be handed in to the bank to receive payment
|
||||
- Works as a reward and incentive for turning up to do work
|
||||
- The values are set per job in `Config.Jobs`
|
||||
- `TicketSystem` Enable this if you want to use the ticket system false
|
||||
- `TicketSystemAll` Enable this to give tickets to all workers clocked in
|
||||
---
|
||||
## Commission System
|
||||
- Support for commission to be paid as a reward for each successful payment
|
||||
- Very customisable with the config.lua
|
||||
- `Commission` Choose wether people get commission from every sale
|
||||
- `CommissionAll` Choose if **EVERY** worker gets Commission that is on duty
|
||||
- `CommissionDouble` Choose if Commission is limited by `MinAmountForTicket`
|
||||
- `CommissionLimit` Choose if the worker charging the customer gets double commission
|
||||
|
||||
---
|
||||
## Multiple Job and Gang Role support
|
||||
- The script supports adding job roles to the config so they can get rewards for successful payments
|
||||
- This includes Gang roles for stores/bars owned by a gang allowing them to get ticket rewards and commission
|
||||
- Examples of adding jobs / gangs to config.lua:
|
||||
```lua
|
||||
Jobs = {
|
||||
['mechanic'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['lostmc'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, gang = true, },
|
||||
},
|
||||
```
|
||||
- `MinAmountforTicket` is the amount required in a charge before they can get a ticket
|
||||
- `PayPerTicket` is the amount paid per ticket at the bank for the job role
|
||||
- I personally recommend this being lower than `MinAmountforTicket`, being too high makes it exploitable
|
||||
- `Commission` is the amount of commission given to players on successful payments (0.10 = 10%)
|
||||
- `gang = true` add this if the added role is a gang role
|
||||
---
|
||||
## /cashgive
|
||||

|
||||
- Alternative to /givecash
|
||||
- A simple command built in to send cash to a `nearby player`
|
||||
- Shows a list of names and id's of people nearby to select from rather
|
||||
- Better experience than trying to figure out their ID and entering it manually
|
||||
---
|
||||
## /cashregister
|
||||

|
||||
- This command is mean't as a portable cash register alternative
|
||||
- For example:
|
||||
- When a person is devliering food they can do `/cashregister` and the payment will still be sent to the society account
|
||||
- Doesn't utilize the ticket reward system unfortunately
|
||||
---
|
||||
## /polcharge
|
||||
- This script supports a customisable "police billing"
|
||||
- This is the ability for selected jobroles to charge a nearby player
|
||||
- Depending on how you've set it up, this can take money directly from the players bank to the job's society account
|
||||
- This is by default enabled for `police` and `ambulance`
|
||||
- This also supports giving the player a cut of the payment as `commission`
|
||||
- Default Config:
|
||||
```lua
|
||||
FineJobs = {
|
||||
['police'] = { Commission = 0.25, },
|
||||
['ambulance'] = { Commission = 0.25, },
|
||||
},
|
||||
FineJobConfirmation = false, -- "true" makes it so fines need confirmation, "false" skips this ands just removes the money
|
||||
FineJobList = true, -- "true" to use nearby player list feature in the cash registers, "false" for manual id entry
|
||||
```
|
||||
---
|
||||
## Banking
|
||||

|
||||
- This script has simple banking systems built in
|
||||
- Works as a basic replacement for qb-banking and qb-atms
|
||||
- Adjust the options in config.lua:
|
||||
- `useATM` Choose wether to make atm's usable
|
||||
- `useBanks` Choose wether to make bank desks/teller's usable
|
||||
- `BankBlips` Enable this if you disabled qb-banking and need bank locations
|
||||
- `ATMBlips` Enable this if you are a pyscho and need every ATM to be on the map too
|
||||
- `Gabz` Enable to change to Gabz Bank locations, this corrects the ATM/Bank Cashier + Ticket Cash in
|
||||
---
|
||||
|
||||
### Renewed's qb-phone
|
||||
- Simply leave the Config.PhoneType as `"qb"`
|
||||
|
||||
### AP-Goverment
|
||||
- Support for AP-Goverment Tax on payments
|
||||
- Toggle `ApGov` in the config.lua to enable this
|
||||
@@ -109,3 +109,62 @@ function atmWithdrawl(info)
|
||||
end
|
||||
end
|
||||
|
||||
RegisterNetEvent(getScript()..":client:ATM:give", function()
|
||||
|
||||
local newinputs = {} -- Begin qb-input creation here.
|
||||
local nearbyList = {}
|
||||
if Config.General.List then -- If nearby player list is wanted:
|
||||
--Retrieve a list of nearby players from server
|
||||
local onlineList = triggerCallback(getScript()..":MakePlayerList")
|
||||
--Convert list of players nearby into one qb-input understands + add distance info
|
||||
local playerCoords = GetEntityCoords(PlayerPedId())
|
||||
|
||||
for _, v in ipairs(GetPlayersFromCoords(playerCoords, Config.General.PaymentRadius)) do
|
||||
local ped = GetPlayerPed(v)
|
||||
local dist = #(GetEntityCoords(ped) - playerCoords)
|
||||
for i = 1, #onlineList do
|
||||
if onlineList[i].value == GetPlayerServerId(v) then
|
||||
if v ~= PlayerId() or debugMode then
|
||||
nearbyList[#nearbyList+1] = {
|
||||
value = onlineList[i].value,
|
||||
label = onlineList[i].text .. ' (' .. math.floor(dist+0.05) .. 'm)',
|
||||
text = onlineList[i].text .. ' (' .. math.floor(dist+0.05) .. 'm)'
|
||||
}
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
--If list is empty(no one nearby) show error and stop
|
||||
if not nearbyList[1] then triggerNotify(nil, locale("error" ,"no_one"), "error") return end
|
||||
else -- If Config.List is false, create input text box for ID's
|
||||
newinputs[#newinputs+1] = { type = 'text', isRequired = true, required = true, name = 'citizen', label = locale("menu" ,"person_id"), text = locale("menu" ,"person_id") }
|
||||
end
|
||||
|
||||
if Config.General.List then
|
||||
newinputs[#newinputs+1] = { type = "select", text = locale("menu" ,"cus_id"), name = "citizen", label = locale("menu" ,"cus_id"), default = 1, options = nearbyList }
|
||||
else
|
||||
newinputs[#newinputs+1] = { type = 'text', isRequired = true, name = 'citizen', text = locale("menu" ,"cus_id") }
|
||||
end
|
||||
newinputs[#newinputs+1] = {
|
||||
type = 'select',
|
||||
name = 'billtype',
|
||||
text = locale("menu" ,"type"),
|
||||
default = billPrev,
|
||||
options = {
|
||||
{ value = "cash", text = locale("menu" ,"cash"), label = locale("menu" ,"cash") },
|
||||
}
|
||||
}
|
||||
newinputs[#newinputs+1] = { type = 'number', isRequired = true, name = 'price', text = locale("menu" ,"amount_charge") }
|
||||
|
||||
local dialog = createInput(locale("menu", "give_cash"), newinputs)
|
||||
|
||||
if dialog then
|
||||
if dialog[1] then
|
||||
dialog.citizen = dialog[1]
|
||||
dialog.billtype = dialog[2]
|
||||
dialog.price = dialog[3]
|
||||
end
|
||||
billPrev = dialog.billtype
|
||||
TriggerServerEvent('jim-payments:server:ATM:give', dialog.citizen, dialog.price)
|
||||
end
|
||||
end)
|
||||
@@ -103,7 +103,7 @@ RegisterNetEvent(getScript()..":Client:Bank", function(data) local setheader = n
|
||||
bankTransaction(info, bankinfo)
|
||||
end,
|
||||
}
|
||||
if isStarted(QBExport) then
|
||||
if isStarted(QBExport) then -- only supports qbcore account transfers
|
||||
Menu[#Menu+1] = {
|
||||
header = locale("target", "soc_trans"),
|
||||
txt = Jobs[info.job].label or "Error",
|
||||
|
||||
@@ -5,8 +5,8 @@ function spawnCustomRegisters()
|
||||
for k, v in pairs(Config.CustomCashRegisters) do
|
||||
for i = 1, #v do
|
||||
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=Config.Debug, minZ=v[i].coords.z-0.1, maxZ=v[i].coords.z+0.4}}, {
|
||||
{ onSelect = function() TriggerEvent(getScript()..":client:Charge", { job = job, gang = gang, img = ""}) end, icon = "fas fa-credit-card", label = Loc[Config.Lan].target["charge"], }
|
||||
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}}, {
|
||||
{ onSelect = function() TriggerEvent(getScript()..":client:Charge", { job = job, gang = gang, img = ""}) end, icon = "fas fa-credit-card", label = locale("target", "charge"), }
|
||||
}, 2.0)
|
||||
if v[i].prop then makeProp({prop = "prop_till_03", coords = v[i].coords}, 1, false) end
|
||||
end
|
||||
@@ -17,50 +17,57 @@ onPlayerLoaded(function() spawnCustomRegisters() end, true)
|
||||
|
||||
local billPrev = "cash"
|
||||
RegisterNetEvent(getScript()..":client:Charge", function(data, outside)
|
||||
--Check if player is using /cashregister command
|
||||
local dialog
|
||||
--if not outside and not onDuty and data.gang == nil then triggerNotify(nil, Loc[Config.Lan].error["not_onduty"], "error") return end
|
||||
--if not outside and not onDuty and data.gang == nil then triggerNotify(nil, locale("error", "not_onduty") return end
|
||||
local newinputs = {} -- Begin qb-input creation here.
|
||||
local nearbyList = {}
|
||||
if Config.General.List then -- If nearby player list is wanted:
|
||||
--Retrieve a list of nearby players from server
|
||||
local onlineList = triggerCallback(getScript()..":MakePlayerList")
|
||||
--Convert list of players nearby into one qb-input understands + add distance info
|
||||
for _, v in pairs(Core.Functions.GetPlayersFromCoords(GetEntityCoords(PlayerPedId()), Config.General.PaymentRadius)) do
|
||||
local dist = #(GetEntityCoords(GetPlayerPed(v)) - GetEntityCoords(PlayerPedId()))
|
||||
for i = 1, #onlineList do
|
||||
if onlineList[i].value == GetPlayerServerId(v) then
|
||||
if v ~= PlayerId() or debugMode then
|
||||
nearbyList[#nearbyList+1] = { value = onlineList[i].value, label = onlineList[i].text..' ('..math.floor(dist+0.05)..'m)', text = onlineList[i].text..' ('..math.floor(dist+0.05)..'m)' }
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
local playerCoords = GetEntityCoords(PlayerPedId())
|
||||
|
||||
for _, v in ipairs(GetPlayersFromCoords(playerCoords, Config.General.PaymentRadius)) do
|
||||
local ped = GetPlayerPed(v)
|
||||
local dist = #(GetEntityCoords(ped) - playerCoords)
|
||||
for i = 1, #onlineList do
|
||||
if onlineList[i].value == GetPlayerServerId(v) then
|
||||
if v ~= PlayerId() or debugMode then
|
||||
nearbyList[#nearbyList+1] = {
|
||||
value = onlineList[i].value,
|
||||
label = onlineList[i].text .. ' (' .. math.floor(dist+0.05) .. 'm)',
|
||||
text = onlineList[i].text .. ' (' .. math.floor(dist+0.05) .. 'm)'
|
||||
}
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
--If list is empty(no one nearby) show error and stop
|
||||
if not nearbyList[1] then triggerNotify(nil, Loc[Config.Lan].error["no_one"], "error") return end
|
||||
if not nearbyList[1] then triggerNotify(nil, locale("error" ,"no_one"), "error") return end
|
||||
else -- If Config.List is false, create input text box for ID's
|
||||
newinputs[#newinputs+1] = { type = 'text', isRequired = true, required = true, name = 'citizen', label = Loc[Config.Lan].menu["person_id"], text = Loc[Config.Lan].menu["person_id"] }
|
||||
newinputs[#newinputs+1] = { type = 'text', isRequired = true, required = true, name = 'citizen', label = locale("menu" ,"person_id"), text = locale("menu" ,"person_id") }
|
||||
end
|
||||
--Check if image was given when opening the regsiter
|
||||
local img = Config.System.Menu == "qb" and "<center><img src="..(data.img and data.img or "").." width=200px></center>" or ""
|
||||
|
||||
--Grab Player Job name or Gang Name if needed
|
||||
local label = data.gang and PlayerGang.label or PlayerJob.label
|
||||
local getInfo = getPlayer()
|
||||
--Check if image was given when opening the regsiter
|
||||
local img = data.img ~= nil and (Config.System.Menu == "qb" and "<center><img src="..(data.img).." width=200px></center>") or Jobs[getInfo.job].label
|
||||
|
||||
if Config.General.List then
|
||||
newinputs[#newinputs+1] = { type = "select", text = Loc[Config.Lan].menu["cus_id"], name = "citizen", label = Loc[Config.Lan].menu["cus_id"], default = 1, options = nearbyList }
|
||||
newinputs[#newinputs+1] = { type = "select", text = locale("menu" ,"cus_id"), name = "citizen", label = locale("menu" ,"cus_id"), default = 1, options = nearbyList }
|
||||
else
|
||||
newinputs[#newinputs+1] = { type = 'text', isRequired = true, name = 'citizen', text = Loc[Config.Lan].menu["cus_id"] }
|
||||
newinputs[#newinputs+1] = { type = 'text', isRequired = true, name = 'citizen', text = locale("menu" ,"cus_id") }
|
||||
end
|
||||
newinputs[#newinputs+1] = {
|
||||
type = 'select',
|
||||
name = 'billtype',
|
||||
text = Loc[Config.Lan].menu["type"],
|
||||
text = locale("menu" ,"type"),
|
||||
default = billPrev,
|
||||
options = {
|
||||
{ value = "cash", text = Loc[Config.Lan].menu["cash"], label = Loc[Config.Lan].menu["cash"] },
|
||||
{ value = "bank", text = Loc[Config.Lan].menu["card"], label = Loc[Config.Lan].menu["card"] }
|
||||
{ value = "cash", text = locale("menu" ,"cash"), label = locale("menu" ,"cash") },
|
||||
{ value = "bank", text = locale("menu" ,"card"), label = locale("menu" ,"card") }
|
||||
}
|
||||
}
|
||||
newinputs[#newinputs+1] = { type = 'number', isRequired = true, name = 'price', text = Loc[Config.Lan].menu["amount_charge"] }
|
||||
newinputs[#newinputs+1] = { type = 'number', isRequired = true, name = 'price', text = locale("menu" ,"amount_charge") }
|
||||
|
||||
local dialog = createInput(img, newinputs)
|
||||
|
||||
@@ -77,26 +84,31 @@ end)
|
||||
|
||||
RegisterNetEvent(getScript()..":client:PayPopup", function(amount, biller, billtype, img, billerjob, gang, outside)
|
||||
local setimage = ""
|
||||
if Config.System.Menu == "qb" then
|
||||
setimage = "<center><img src="..(img and img or "").." width=200px></center>"
|
||||
elseif Config.System.Menu == "ox" then
|
||||
setimage = '..')'
|
||||
print(billerjob)
|
||||
if not img then
|
||||
setimage = billerjob
|
||||
else
|
||||
if Config.System.Menu == "qb" then
|
||||
setimage = "<center><img src="..(img and img or "").." width=200px></center>"
|
||||
elseif Config.System.Menu == "ox" then
|
||||
setimage = '..')'
|
||||
end
|
||||
end
|
||||
|
||||
local Menu = {}
|
||||
Menu[#Menu+1] = {
|
||||
isMenuHeader = true,
|
||||
header = "🧾 "..billerjob..Loc[Config.Lan].menu["payment"],
|
||||
txt = Loc[Config.Lan].menu["accept_payment"]
|
||||
header = "🧾 "..locale("menu" ,"payment"),
|
||||
txt = locale("menu" ,"accept_payment")
|
||||
}
|
||||
Menu[#Menu+1] = {
|
||||
isMenuHeader = true,
|
||||
header = "",
|
||||
txt = billtype:gsub("^%l", string.upper)..Loc[Config.Lan].menu["payment_amount"]..amount
|
||||
txt = billtype:gsub("^%l", string.upper)..locale("menu" ,"payment_amount")..amount
|
||||
}
|
||||
Menu[#Menu+1] = {
|
||||
icon = "fas fa-circle-check",
|
||||
header = Loc[Config.Lan].menu["yes"],
|
||||
header = locale("menu" ,"yes"),
|
||||
txt = "",
|
||||
onSelect = function()
|
||||
TriggerServerEvent(getScript()..":server:PayPopup", {
|
||||
@@ -110,7 +122,7 @@ RegisterNetEvent(getScript()..":client:PayPopup", function(amount, biller, billt
|
||||
}
|
||||
Menu[#Menu+1] = {
|
||||
icon = "fas fa-circle-xmark",
|
||||
header = Loc[Config.Lan].menu["no"],
|
||||
header = locale("menu" ,"no"),
|
||||
onSelect = function()
|
||||
TriggerServerEvent(getScript()..":server:PayPopup", {
|
||||
accept = false,
|
||||
@@ -121,6 +133,7 @@ RegisterNetEvent(getScript()..":client:PayPopup", function(amount, biller, billt
|
||||
})
|
||||
end,
|
||||
}
|
||||
debugPrint(setimage)
|
||||
openMenu(Menu, {
|
||||
header = setimage,
|
||||
onExit = function()
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
RegisterNetEvent(getScript()..":client:PolCharge", function()
|
||||
local Playerinfo = getPlayer()
|
||||
--Check if player is allowed to use /cashregister command
|
||||
local allowed = false
|
||||
for k in pairs(Config.PolCharge.FineJobs) do if k == PlayerJob.name then allowed = true end end
|
||||
if not allowed then triggerNotify(nil, Loc[Config.Lan].error["no_job"], "error") return end
|
||||
for k in pairs(Config.PolCharge.FineJobs) do if k == Playerinfo.job then allowed = true end end
|
||||
if not allowed then triggerNotify(nil, locale("error", "no_job"), "error") return end
|
||||
|
||||
local newinputs = {} -- Begin qb-input creation here.
|
||||
local nearbyList = {}
|
||||
@@ -21,17 +22,17 @@ RegisterNetEvent(getScript()..":client:PolCharge", function()
|
||||
end
|
||||
end
|
||||
--If list is empty(no one nearby) show error and stop
|
||||
if not nearbyList[1] then triggerNotify(nil, Loc[Config.Lan].error["no_one"], "error") return end
|
||||
if not nearbyList[1] then triggerNotify(nil, locale("error" ,"no_one"), "error") return end
|
||||
end
|
||||
|
||||
if Config.PolCharge.FineJobList then
|
||||
newinputs[#newinputs+1] = { type = "select", text = Loc[Config.Lan].menu["cus_id"], name = "citizen", label = Loc[Config.Lan].menu["cus_id"], default = 1, options = nearbyList }
|
||||
newinputs[#newinputs+1] = { type = "select", text = locale("menu" ,"cus_id"), name = "citizen", label = locale("menu" ,"cus_id"), default = 1, options = nearbyList }
|
||||
else
|
||||
newinputs[#newinputs+1] = { type = 'text', isRequired = true, name = 'citizen', text = Loc[Config.Lan].menu["cus_id"] }
|
||||
newinputs[#newinputs+1] = { type = 'text', isRequired = true, name = 'citizen', text = locale("menu" ,"cus_id") }
|
||||
end
|
||||
newinputs[#newinputs+1] = { type = 'number', isRequired = true, name = 'price', text = Loc[Config.Lan].menu["amount_charge"] }
|
||||
newinputs[#newinputs+1] = { type = 'number', isRequired = true, name = 'price', text = locale("menu" ,"amount_charge") }
|
||||
|
||||
local dialog = createInput(img, newinputs)
|
||||
local dialog = createInput(Jobs[Playerinfo.job].label, newinputs)
|
||||
if dialog then
|
||||
if dialog[1] then
|
||||
dialog.citizen = dialog[1]
|
||||
@@ -43,10 +44,10 @@ end)
|
||||
|
||||
RegisterNetEvent(getScript()..":client:PolPopup", function(amount, biller, billerjob)
|
||||
local Menu = {}
|
||||
Menu[#Menu+1] = { isMenuHeader = true, header = "", txt = Loc[Config.Lan].menu["bank_charge"]..amount }
|
||||
Menu[#Menu+1] = { isMenuHeader = true, header = "", txt = locale("menu" ,"bank_charge")..amount }
|
||||
Menu[#Menu+1] = {
|
||||
icon = "fas fa-circle-check",
|
||||
header = Loc[Config.Lan].menu["yes"],
|
||||
header = locale("menu" ,"yes"),
|
||||
txt = "",
|
||||
onSelect = function()
|
||||
TriggerServerEvent(getScript()..":server:PolPopup", {
|
||||
@@ -58,7 +59,7 @@ RegisterNetEvent(getScript()..":client:PolPopup", function(amount, biller, bille
|
||||
}
|
||||
Menu[#Menu+1] = {
|
||||
icon = "fas fa-circle-xmark",
|
||||
header = Loc[Config.Lan].menu["no"],
|
||||
header = locale("menu" ,"no"),
|
||||
onSelect = function()
|
||||
TriggerServerEvent(getScript()..":server:PolPopup", {
|
||||
accept = false,
|
||||
@@ -68,8 +69,8 @@ RegisterNetEvent(getScript()..":client:PolPopup", function(amount, biller, bille
|
||||
end,
|
||||
}
|
||||
openMenu(Menu, {
|
||||
header = "🧾 "..billerjob..Loc[Config.Lan].menu["payment"],
|
||||
headertxt = Loc[Config.Lan].menu["accept_payment"],
|
||||
header = "🧾 "..billerjob..locale("menu" ,"payment"),
|
||||
headertxt = locale("menu" ,"accept_payment"),
|
||||
onExit = function()
|
||||
TriggerServerEvent(getScript()..":server:PolPopup", {
|
||||
accept = false,
|
||||
|
||||
@@ -1,23 +1,27 @@
|
||||
RegisterNetEvent(getScript()..":Tickets:Menu", function(data)
|
||||
local PlayerInfo = getPlayer()
|
||||
local hasItem, hasTable = hasItem("payticket", 1)
|
||||
if not hasItem then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["no_ticket"], "error")
|
||||
triggerNotify(nil, locale("error" ,"no_ticket"), "error")
|
||||
return
|
||||
end
|
||||
local amount, sellable, name, label = hasTable["payticket"].count, false, "", ""
|
||||
for k, v in pairs(Config.Receipts.Jobs) do
|
||||
sellable = (data.gang and v.gang and k == PlayerGang.name) or (not data.gang and not v.gang and k == PlayerJob.name)
|
||||
if sellable then name, label = k, (data.gang and PlayerGang.label) or (not data.gang and PlayerJob.label) break end
|
||||
sellable = (data.gang and v.gang and k == PlayerInfo.gang) or (not data.gang and not v.gang and k == PlayerInfo.job)
|
||||
if sellable then name, label = k, (data.gang and Gangs[PlayerInfo.gang].label) or (not data.gang and Jobs[PlayerInfo.job].label) break end
|
||||
end
|
||||
if sellable then local Menu = {}
|
||||
Menu[#Menu+1] = {
|
||||
isMenuHeader = true,
|
||||
txt = Loc[Config.Lan].menu["ticket_amount"]..amount..Loc[Config.Lan].menu["total_pay"]..(Config.Receipts.Jobs[name].PayPerTicket * amount)
|
||||
txt = locale("menu" ,"ticket_amount")..amount..locale("menu" ,"total_pay")..(Config.Receipts.Jobs[name].PayPerTicket * amount)
|
||||
}
|
||||
Menu[#Menu+1] = {
|
||||
icon = "fas fa-circle-check", header = Loc[Config.Lan].menu["yes"],
|
||||
onSelect = function() TriggerServerEvent(getScript()..":Tickets:Sell") end,
|
||||
icon = "fas fa-circle-check", header = locale("menu" ,"yes"),
|
||||
onSelect = function()
|
||||
TriggerServerEvent(getScript()..":Tickets:Sell")
|
||||
playAnim("pickup_object", "putdown_low", 2000, 1)
|
||||
end,
|
||||
}
|
||||
openMenu(Menu, { header = "🧾 "..label..Loc[Config.Lan].menu["receipt"], headertxt = Loc[Config.Lan].menu["trade_confirm"], canClose = true, })
|
||||
openMenu(Menu, { header = "🧾 "..label..locale("menu" ,"receipt"), headertxt = locale("menu" ,"trade_confirm"), canClose = true, })
|
||||
end
|
||||
end)
|
||||
328
config.lua
328
config.lua
@@ -1,166 +1,164 @@
|
||||
print("^2Jim^7-^2Payments ^7v^4"..GetResourceMetadata(GetCurrentResourceName(), 'version', nil):gsub("%.", "^7.^4").."^7 - ^2Payments Script by ^1Jimathy^7")
|
||||
|
||||
-- If you need support I now have a discord available, it helps me keep track of issues and give better support.
|
||||
|
||||
-- https://discord.gg/xKgQZ6wZvS
|
||||
|
||||
Config = {
|
||||
Lan = "en",
|
||||
System = {
|
||||
Debug = false,
|
||||
EventDebug = false,
|
||||
|
||||
Menu = "qb", -- "qb", "ox", "gta"
|
||||
Notify = "qb", -- "qb", "ox", "gta", "esx"
|
||||
ProgressBar = "qb", -- "qb", "ox", "gta", "esx"
|
||||
},
|
||||
|
||||
Crafting = {
|
||||
craftCam = true,
|
||||
MultiCraft = true,
|
||||
MultiCraftAmounts = { [1], [5], [10] },
|
||||
showItemBox = true,
|
||||
},
|
||||
|
||||
General = {
|
||||
ApGov = false, -- Toggle support for AP-Goverment Tax
|
||||
|
||||
List = true, -- "true" to use nearby player list feature in the cash registers, "false" for manual id entry
|
||||
PaymentRadius = 15, -- This is how far the playerlist will check for nearby players (based on the person charging)
|
||||
|
||||
Usebzzz = false, -- enable if you're using the prop from bzzz
|
||||
|
||||
Enablecommand = true, -- Enables the /cashregister command
|
||||
|
||||
PhoneBank = false, -- Set this to false to use the popup payment system FOR CARD/BANK PAYMENTS instead of using phone invoices
|
||||
-- This doesn't affect Cash payments as they by default use a confirmation window
|
||||
-- This is helpful for phones that don't support invoices well
|
||||
|
||||
Peds = true, -- "true" to enable peds spawning in banks
|
||||
PedPool = { -- If Peds is true, use this pool of ped models to pick from
|
||||
"IG_Bankman",
|
||||
"U_M_M_BankMan",
|
||||
"S_F_M_Shop_HIGH",
|
||||
"S_M_M_HighSec_02",
|
||||
"S_M_M_HighSec_03",
|
||||
"S_M_M_HighSec_04",
|
||||
"A_F_Y_Business_01",
|
||||
"A_F_Y_Business_02",
|
||||
"A_F_Y_Business_03",
|
||||
"A_F_Y_Business_04",
|
||||
"A_M_M_Business_01",
|
||||
"A_M_Y_Business_02",
|
||||
"A_M_Y_Business_03",
|
||||
"U_F_M_CasinoShop_01",
|
||||
},
|
||||
|
||||
PhoneType = "qb", -- Change this setting to make invoices work with your phone script [still testing this currently]
|
||||
-- "qb" for qb-phone
|
||||
-- "gks" for GKSPhone
|
||||
|
||||
|
||||
Gabz = false, -- "true" to enable Gabz Bank locations
|
||||
-- this corrects the ATM/Bank Cashier + Ticket Cash in locations
|
||||
|
||||
menuLogo = "https://static.wikia.nocookie.net/gtawiki/images/b/bd/Fleeca-GTAV-Logo.png",
|
||||
|
||||
},
|
||||
|
||||
ATMs = {
|
||||
enable = true, -- Enable this if wanting to use jim-payments atm systems
|
||||
showBlips = true,
|
||||
|
||||
ATMModels = { `prop_atm_01`, `prop_atm_02`, `prop_atm_03`, `prop_fleeca_atm`, `gabz_sm_pb_atmframe` },
|
||||
|
||||
},
|
||||
|
||||
Banks = {
|
||||
enable = true, -- Enable this if wanting to use jim-payments banking systems
|
||||
showBlips = true,
|
||||
|
||||
},
|
||||
|
||||
CustomCashRegisters = {
|
||||
-- ["jobname"] = { -- Player job role restriction
|
||||
-- { coords = vector4(0, 0, 0, 0), }, -- vector4 to place the till and the way it faces
|
||||
-- { coords = vector4(0, 0, 0, 0), prop = true, }, -- "prop = true" spawns a prop at the coords
|
||||
-- },
|
||||
},
|
||||
|
||||
Receipts = {
|
||||
TicketSystem = true, -- Enable this if you want to use the ticket system false
|
||||
TicketSystemAll = true, -- Enable this to give tickets to all workers clocked in
|
||||
|
||||
Commission = true, -- Set this to true to enable Commissions and give the person charging a percentage of the total
|
||||
CommissionAll = false, -- Set this to true to give commission to workers clocked in
|
||||
CommissionDouble = false, -- Set this to true if you want the person charging to get double Commission
|
||||
CommissionLimit = false, -- If true, this limits the Commission to only be given if over the "MinAmountForTicket".
|
||||
-- If false, Commission will be given for any amount
|
||||
|
||||
CashInLocations = {
|
||||
vec4(252.23, 223.11, 106.29, 159.2), -- Default Third Window along in Pacific Bank
|
||||
},
|
||||
|
||||
CashInAnywhere = true, -- enable this to add cash ticket option to any banking location
|
||||
|
||||
-- MinAmountforTicket should be your cheapest item
|
||||
-- PayPerTicket should never be higher than MinAmountforTicket
|
||||
-- Commission is a percentage eg "0.10" becomes 10%
|
||||
Jobs = {
|
||||
-- Jim Businesses | https://jimathy666.tebex.io/
|
||||
['bakery'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['beanmachine'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['burgershot'] = { MinAmountforTicket = 50, PayPerTicket = 50 , Commission = 0.10, },
|
||||
['catcafe'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['henhouse'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['pizzathis'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['popsdiner'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['tequilala'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['vanilla'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['upnatom'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['hornys'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
|
||||
-- JixelTay Businesses | https://jixeltay.tebex.io/
|
||||
['cigarbar'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['cluckinbell'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['smokeshop'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['pearls'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['kois'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['whitewidow'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['bestbuds'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
|
||||
-- Jim Mechanic | https://jimathy666.tebex.io/
|
||||
['mechanic'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['tuners'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['ottos'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['lscustoms'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['bennys'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
|
||||
-- Gangs | Example of a gang being supported
|
||||
['lostmc'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, gang = true, },
|
||||
},
|
||||
|
||||
},
|
||||
PolCharge = {
|
||||
-- The /polcharge command requires specific jobs to be set
|
||||
-- No tickets for these, it's just commission (0.25 = 25%)
|
||||
FineJobs = {
|
||||
['police'] = { Commission = 0.25, },
|
||||
['ambulance'] = { Commission = 0.25, },
|
||||
},
|
||||
FineJobConfirmation = false, --"true" makes it so fines need confirmation, "false" skips this ands just removes the money
|
||||
FineJobList = true, -- "true" to use nearby player list feature in the cash registers, "false" for manual id entry
|
||||
},
|
||||
}
|
||||
|
||||
PlayerGang, PlayerJob, onDuty = {}, {}, nil
|
||||
|
||||
-- Test function for locales
|
||||
function locale(section, string)
|
||||
if not Config.Lan or Config.Lan == "" then return print("Error, no langauge set") end
|
||||
local localTable = Loc[Config.Lan]
|
||||
if not localTable then return "Locale Table Not Found" end
|
||||
if not localTable[section] then return "["..section.."] Invalid" end
|
||||
if not localTable[section][string] then return "["..string.."] Invalid" end
|
||||
return localTable[section][string]
|
||||
-- If you need support I now have a discord available, it helps me keep track of issues and give better support.
|
||||
|
||||
-- https://discord.gg/xKgQZ6wZvS
|
||||
|
||||
Config = {
|
||||
Lan = "en",
|
||||
System = {
|
||||
Debug = false,
|
||||
EventDebug = false,
|
||||
|
||||
Menu = "qb", -- "qb", "ox", "gta"
|
||||
Notify = "qb", -- "qb", "ox", "gta", "esx"
|
||||
ProgressBar = "qb", -- "qb", "ox", "gta", "esx"
|
||||
},
|
||||
|
||||
Crafting = {
|
||||
craftCam = true,
|
||||
MultiCraft = true,
|
||||
MultiCraftAmounts = { [1], [5], [10] },
|
||||
showItemBox = true,
|
||||
},
|
||||
|
||||
General = {
|
||||
ApGov = false, -- Toggle support for AP-Goverment Tax
|
||||
|
||||
List = true, -- "true" to use nearby player list feature in the cash registers, "false" for manual id entry
|
||||
PaymentRadius = 15, -- This is how far the playerlist will check for nearby players (based on the person charging)
|
||||
|
||||
Usebzzz = false, -- enable if you're using the prop from bzzz
|
||||
|
||||
Enablecommand = true, -- Enables the /cashregister command
|
||||
|
||||
PhoneBank = false, -- Set this to false to use the popup payment system FOR CARD/BANK PAYMENTS instead of using phone invoices
|
||||
-- This doesn't affect Cash payments as they by default use a confirmation window
|
||||
-- This is helpful for phones that don't support invoices well
|
||||
|
||||
Peds = true, -- "true" to enable peds spawning in banks
|
||||
PedPool = { -- If Peds is true, use this pool of ped models to pick from
|
||||
"IG_Bankman",
|
||||
"U_M_M_BankMan",
|
||||
"S_F_M_Shop_HIGH",
|
||||
"S_M_M_HighSec_02",
|
||||
"S_M_M_HighSec_03",
|
||||
"S_M_M_HighSec_04",
|
||||
"A_F_Y_Business_01",
|
||||
"A_F_Y_Business_02",
|
||||
"A_F_Y_Business_03",
|
||||
"A_F_Y_Business_04",
|
||||
"A_M_M_Business_01",
|
||||
"A_M_Y_Business_02",
|
||||
"A_M_Y_Business_03",
|
||||
"U_F_M_CasinoShop_01",
|
||||
},
|
||||
|
||||
PhoneType = "qb", -- Change this setting to make invoices work with your phone script [still testing this currently]
|
||||
-- "qb" for qb-phone
|
||||
-- "gks" for GKSPhone
|
||||
|
||||
|
||||
Gabz = false, -- "true" to enable Gabz Bank locations
|
||||
-- this corrects the ATM/Bank Cashier + Ticket Cash in locations
|
||||
|
||||
menuLogo = "https://static.wikia.nocookie.net/gtawiki/images/b/bd/Fleeca-GTAV-Logo.png",
|
||||
|
||||
},
|
||||
|
||||
ATMs = {
|
||||
enable = true, -- Enable this if wanting to use jim-payments atm systems
|
||||
showBlips = true,
|
||||
|
||||
ATMModels = { `prop_atm_01`, `prop_atm_02`, `prop_atm_03`, `prop_fleeca_atm`, `gabz_sm_pb_atmframe` },
|
||||
|
||||
},
|
||||
|
||||
Banks = {
|
||||
enable = true, -- Enable this if wanting to use jim-payments banking systems
|
||||
showBlips = true,
|
||||
|
||||
},
|
||||
|
||||
CustomCashRegisters = {
|
||||
-- ["jobname"] = { -- Player job role restriction
|
||||
-- { coords = vector4(0, 0, 0, 0), }, -- vector4 to place the till and the way it faces
|
||||
-- { coords = vector4(0, 0, 0, 0), prop = true, }, -- "prop = true" spawns a prop at the coords
|
||||
-- },
|
||||
},
|
||||
|
||||
Receipts = {
|
||||
TicketSystem = true, -- Enable this if you want to use the ticket system false
|
||||
TicketSystemAll = true, -- Enable this to give tickets to all workers clocked in
|
||||
|
||||
Commission = true, -- Set this to true to enable Commissions and give the person charging a percentage of the total
|
||||
CommissionAll = false, -- Set this to true to give commission to workers clocked in
|
||||
CommissionDouble = false, -- Set this to true if you want the person charging to get double Commission
|
||||
CommissionLimit = false, -- If true, this limits the Commission to only be given if over the "MinAmountForTicket".
|
||||
-- If false, Commission will be given for any amount
|
||||
|
||||
CashInLocations = {
|
||||
vec4(252.23, 223.11, 106.29, 159.2), -- Default Third Window along in Pacific Bank
|
||||
},
|
||||
|
||||
CashInAnywhere = true, -- enable this to add cash ticket option to any banking location
|
||||
|
||||
-- MinAmountforTicket should be your cheapest item
|
||||
-- PayPerTicket should never be higher than MinAmountforTicket
|
||||
-- Commission is a percentage eg "0.10" becomes 10%
|
||||
Jobs = {
|
||||
-- Jim Businesses | https://jimathy666.tebex.io/
|
||||
['bakery'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['beanmachine'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['burgershot'] = { MinAmountforTicket = 50, PayPerTicket = 50 , Commission = 0.10, },
|
||||
['catcafe'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['henhouse'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['pizzathis'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['popsdiner'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['tequilala'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['vanilla'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['upnatom'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['hornys'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
|
||||
-- JixelTay Businesses | https://jixeltay.tebex.io/
|
||||
['cigarbar'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['cluckinbell'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['smokeshop'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['pearls'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['kois'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['whitewidow'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
['bestbuds'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
|
||||
|
||||
-- Jim Mechanic | https://jimathy666.tebex.io/
|
||||
['mechanic'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['tuners'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['ottos'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['lscustoms'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
['bennys'] = { MinAmountforTicket = 1000, PayPerTicket = 500, Commission = 0.10, },
|
||||
|
||||
-- Gangs | Example of a gang being supported
|
||||
['lostmc'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, gang = true, },
|
||||
},
|
||||
|
||||
},
|
||||
PolCharge = {
|
||||
-- The /polcharge command requires specific jobs to be set
|
||||
-- No tickets for these, it's just commission (0.25 = 25%)
|
||||
FineJobs = {
|
||||
['police'] = { Commission = 0.25, },
|
||||
['ambulance'] = { Commission = 0.25, },
|
||||
},
|
||||
FineJobConfirmation = false, --"true" makes it so fines need confirmation, "false" skips this ands just removes the money
|
||||
FineJobList = true, -- "true" to use nearby player list feature in the cash registers, "false" for manual id entry
|
||||
},
|
||||
}
|
||||
|
||||
PlayerGang, PlayerJob, onDuty = {}, {}, nil
|
||||
|
||||
-- Test function for locales
|
||||
function locale(section, string)
|
||||
if not Config.Lan or Config.Lan == "" then return print("Error, no langauge set") end
|
||||
local localTable = Loc[Config.Lan]
|
||||
if not localTable then return "Locale Table Not Found" end
|
||||
if not localTable[section] then return "["..section.."] Invalid" end
|
||||
if not localTable[section][string] then return "["..string.."] Invalid" end
|
||||
return localTable[section][string]
|
||||
end
|
||||
270
locales/da.lua
270
locales/da.lua
@@ -1,136 +1,136 @@
|
||||
-- Provided by iplayer1337fivem on Github
|
||||
Loc = Loc or {}
|
||||
|
||||
Loc["da"] = {
|
||||
error = {
|
||||
["cancel"] = "Afbestilt",
|
||||
["no_one"] = "Ingen i nærheden at opkræve",
|
||||
["not_onduty"] = "Ikke logget ind!",
|
||||
["no_job"] = "Du har ikke det påkrævede job",
|
||||
["no_ticket"] = "Du har ingen billetter at handle med",
|
||||
["bank_low"] = "Bankbalance for lav",
|
||||
["no_cash"] = "Ikke nok kontanter",
|
||||
["saving_low"] = "Savings balance for lav",
|
||||
["soc_low"] = "Society balance for lav",
|
||||
["nomoney_bank"] = "Ikke nok penge på din bankkonto",
|
||||
["error_start"] = "Fejl: Konto '",
|
||||
["error_end"] = "' ikke fundet",
|
||||
["not_enough"] = "Du har ikke nok kontanter til at give",
|
||||
["zero"] = "Du kan ikke give DKK0",
|
||||
["charge_zero"] = "Du kan ikke opkræve 0 DKK",
|
||||
["no_ticket_to"] = "Ingen billetter at handle med",
|
||||
["customer_nocash"] = "Kunden har ikke nok kontanter til at betale",
|
||||
["you_nocash"] = "Du har ikke nok kontanter til at betale",
|
||||
["decline_pay"] = " afslog DKK",
|
||||
["declined_payment"] = "Du afslog betalingen",
|
||||
},
|
||||
success = {
|
||||
["draw"] = "Hævet DKK",
|
||||
["from_bank"] = " fra banken",
|
||||
["deposited"] = "Indsat DKK",
|
||||
["into_bank"] = " på bankkontoen",
|
||||
["draw_save"] = " Trukket fra opsparingskontoen til bankkontoen",
|
||||
["depos_save"] = " Indsat fra bankkontoen til opsparingen",
|
||||
["fromthe"] = " fra ",
|
||||
["into"] = " til ",
|
||||
["account"] = " konto",
|
||||
["sent"] = "Sendt DKK",
|
||||
["recieved"] = "Modtaget DKK",
|
||||
["to"] = " til ",
|
||||
["from"] = " fra ",
|
||||
["you_gave"] = "Du gav ",
|
||||
["you_got"] = "Du fik DKK",
|
||||
["invoice_start"] = " Betalte deres DKK",
|
||||
["invoice_end"] = " faktura",
|
||||
["rec_rec"] = "Kvittering modtaget",
|
||||
["commission"] = " i provision",
|
||||
["trade_ticket_start"] = "Billetter handlet: ",
|
||||
["trade_ticket_end"] = " I alt: DKK",
|
||||
["inv_succ"] = "Faktura sendt med succes",
|
||||
["inv_recieved"] = "Ny faktura modtaget",
|
||||
["declined"] = "Du afslog betalingen",
|
||||
["accepted_pay"] = " accepterede DKK",
|
||||
["payment"] = " betaling",
|
||||
["charged"] = " blev opkrævet for DKK",
|
||||
["you_charged"] = "Du blev opkrævet for DKK",
|
||||
["charge_end"] = " opkrævning",
|
||||
},
|
||||
blip = {
|
||||
["blip_atm"] = "Hæveautomat",
|
||||
["blip_bank"] = "Bank",
|
||||
},
|
||||
command = {
|
||||
["pay_user"] = "Betal en bruger i nærheden",
|
||||
["cash_reg"] = "Brug mobil kontantregister",
|
||||
["charge"] = "Opkræv en anden person",
|
||||
},
|
||||
target = {
|
||||
["atm"] = "Brug hæveautomat",
|
||||
["bank"] = "Brug bank",
|
||||
["transfer"] = "Overfør penge",
|
||||
["saving"] = "Adgang til opsparing",
|
||||
["soc_saving"] = "Adgang til society-konto",
|
||||
["soc_trans"] = "Society pengetransfer",
|
||||
["gang_acct"] = "Gang Society-konto",
|
||||
["gang_trans"] = "Gang pengetransfer",
|
||||
["charge"] = "Opkræv kunde",
|
||||
["cashin_boss"] = "Indbetal jobkvitteringer",
|
||||
["cashin_gang"] = "Indbetal gangkvitteringer",
|
||||
},
|
||||
menu = {
|
||||
["close"] = "Luk",
|
||||
["withdraw"] = "Hæv",
|
||||
["deposit"] = "Indsæt",
|
||||
["transfer"] = "Overfør",
|
||||
["transfer_money"] = "Overfør penge",
|
||||
["header_atm"] = "💵 Hæveautomat Bank 💵",
|
||||
["header_trans_amount"] = "💵 Beløb at overføre",
|
||||
["header_bank"] = "🏦 Bankvæsen 🏦",
|
||||
["header_trans"] = "🔀 Overførselsservice 🔀",
|
||||
["header_account_no"] = "🏦 Kontonr.",
|
||||
["header_saving"] = "💰 Opsparing 💰",
|
||||
["acc_atm"] = "Adgang til hæveautomat",
|
||||
["acc_bank"] = "Adgang til bank",
|
||||
["acc_trans"] = "Adgang til overførsler",
|
||||
["acc_saving"] = "Adgang til opsparing",
|
||||
["acc_boss"] = "Adgang til society-konto",
|
||||
["acc_boss_trans"] = "Adgang til society-overførsler",
|
||||
["acc_gang"] = "Adgang til gang-society-konto",
|
||||
["acc_gang_trans"] = "Adgang til gangoverførsler",
|
||||
["header_soc"] = "- Society-konto -",
|
||||
["header_soc_bank"] = "🏢 Society Bank 🏢",
|
||||
["amount_pay"] = "💵 Beløb at betale",
|
||||
["give_cash"] = "Giv nogen kontanter",
|
||||
["give"] = "Giv",
|
||||
["welcome"] = "Velkommen tilbage, ",
|
||||
["citizenid"] = "- Borger-ID -",
|
||||
["header_acc"] = "- Konto -",
|
||||
["header_info"] = "- Kontoinformation -Opsparings-ID: ",
|
||||
["header_balance_bank"] = "- Balancer -🏦Bank - DKK",
|
||||
["header_option"] = "- Valg -",
|
||||
["cash_balance"] = "💵Kontanter - DKK",
|
||||
["bank_balance"] = "🏦Bank - DKK",
|
||||
["saving_balance"] = "- Balancer -💰Opsparing - DKK",
|
||||
["cus_id"] = "# Kundens ID #",
|
||||
["type"] = "Betalingstype",
|
||||
["amount_charge"] = "💵 Beløb at opkræve",
|
||||
["cash_reg"] = "Kontantregister",
|
||||
["person_id"] = "# Personens ID #",
|
||||
["charge"] = "Opkræv",
|
||||
["send"] = "Send",
|
||||
["receipt"] = "Kvitteringer 🧾",
|
||||
["payment"] = " Betaling 🧾",
|
||||
["trade_confirm"] = "Vil du bytte dine kvitteringer til betaling?",
|
||||
["accept_payment"] = "Vil du acceptere betalingen?",
|
||||
["accept_charge"] = "Vil du acceptere opkrævningen?",
|
||||
["ticket_amount"] = "Antal billetter: ",
|
||||
["total_pay"] = "Total betaling: DKK",
|
||||
["confirm"] = "Ja",
|
||||
["yes"] = "Ja",
|
||||
["no"] = "Nej",
|
||||
["cash"] = "Kontanter",
|
||||
["card"] = "Kort",
|
||||
["payment_amount"] = " Betaling: DKK",
|
||||
["bank_charge"] = "Bankgebyr: DKK",
|
||||
},
|
||||
-- Provided by iplayer1337fivem on Github
|
||||
Loc = Loc or {}
|
||||
|
||||
Loc["da"] = {
|
||||
error = {
|
||||
["cancel"] = "Afbestilt",
|
||||
["no_one"] = "Ingen i nærheden at opkræve",
|
||||
["not_onduty"] = "Ikke logget ind!",
|
||||
["no_job"] = "Du har ikke det påkrævede job",
|
||||
["no_ticket"] = "Du har ingen billetter at handle med",
|
||||
["bank_low"] = "Bankbalance for lav",
|
||||
["no_cash"] = "Ikke nok kontanter",
|
||||
["saving_low"] = "Savings balance for lav",
|
||||
["soc_low"] = "Society balance for lav",
|
||||
["nomoney_bank"] = "Ikke nok penge på din bankkonto",
|
||||
["error_start"] = "Fejl: Konto '",
|
||||
["error_end"] = "' ikke fundet",
|
||||
["not_enough"] = "Du har ikke nok kontanter til at give",
|
||||
["zero"] = "Du kan ikke give DKK0",
|
||||
["charge_zero"] = "Du kan ikke opkræve 0 DKK",
|
||||
["no_ticket_to"] = "Ingen billetter at handle med",
|
||||
["customer_nocash"] = "Kunden har ikke nok kontanter til at betale",
|
||||
["you_nocash"] = "Du har ikke nok kontanter til at betale",
|
||||
["decline_pay"] = " afslog DKK",
|
||||
["declined_payment"] = "Du afslog betalingen",
|
||||
},
|
||||
success = {
|
||||
["draw"] = "Hævet DKK",
|
||||
["from_bank"] = " fra banken",
|
||||
["deposited"] = "Indsat DKK",
|
||||
["into_bank"] = " på bankkontoen",
|
||||
["draw_save"] = " Trukket fra opsparingskontoen til bankkontoen",
|
||||
["depos_save"] = " Indsat fra bankkontoen til opsparingen",
|
||||
["fromthe"] = " fra ",
|
||||
["into"] = " til ",
|
||||
["account"] = " konto",
|
||||
["sent"] = "Sendt DKK",
|
||||
["recieved"] = "Modtaget DKK",
|
||||
["to"] = " til ",
|
||||
["from"] = " fra ",
|
||||
["you_gave"] = "Du gav ",
|
||||
["you_got"] = "Du fik DKK",
|
||||
["invoice_start"] = " Betalte deres DKK",
|
||||
["invoice_end"] = " faktura",
|
||||
["rec_rec"] = "Kvittering modtaget",
|
||||
["commission"] = " i provision",
|
||||
["trade_ticket_start"] = "Billetter handlet: ",
|
||||
["trade_ticket_end"] = " I alt: DKK",
|
||||
["inv_succ"] = "Faktura sendt med succes",
|
||||
["inv_recieved"] = "Ny faktura modtaget",
|
||||
["declined"] = "Du afslog betalingen",
|
||||
["accepted_pay"] = " accepterede DKK",
|
||||
["payment"] = " betaling",
|
||||
["charged"] = " blev opkrævet for DKK",
|
||||
["you_charged"] = "Du blev opkrævet for DKK",
|
||||
["charge_end"] = " opkrævning",
|
||||
},
|
||||
blip = {
|
||||
["blip_atm"] = "Hæveautomat",
|
||||
["blip_bank"] = "Bank",
|
||||
},
|
||||
command = {
|
||||
["pay_user"] = "Betal en bruger i nærheden",
|
||||
["cash_reg"] = "Brug mobil kontantregister",
|
||||
["charge"] = "Opkræv en anden person",
|
||||
},
|
||||
target = {
|
||||
["atm"] = "Brug hæveautomat",
|
||||
["bank"] = "Brug bank",
|
||||
["transfer"] = "Overfør penge",
|
||||
["saving"] = "Adgang til opsparing",
|
||||
["soc_saving"] = "Adgang til society-konto",
|
||||
["soc_trans"] = "Society pengetransfer",
|
||||
["gang_acct"] = "Gang Society-konto",
|
||||
["gang_trans"] = "Gang pengetransfer",
|
||||
["charge"] = "Opkræv kunde",
|
||||
["cashin_boss"] = "Indbetal jobkvitteringer",
|
||||
["cashin_gang"] = "Indbetal gangkvitteringer",
|
||||
},
|
||||
menu = {
|
||||
["close"] = "Luk",
|
||||
["withdraw"] = "Hæv",
|
||||
["deposit"] = "Indsæt",
|
||||
["transfer"] = "Overfør",
|
||||
["transfer_money"] = "Overfør penge",
|
||||
["header_atm"] = "💵 Hæveautomat Bank 💵",
|
||||
["header_trans_amount"] = "💵 Beløb at overføre",
|
||||
["header_bank"] = "🏦 Bankvæsen 🏦",
|
||||
["header_trans"] = "🔀 Overførselsservice 🔀",
|
||||
["header_account_no"] = "🏦 Kontonr.",
|
||||
["header_saving"] = "💰 Opsparing 💰",
|
||||
["acc_atm"] = "Adgang til hæveautomat",
|
||||
["acc_bank"] = "Adgang til bank",
|
||||
["acc_trans"] = "Adgang til overførsler",
|
||||
["acc_saving"] = "Adgang til opsparing",
|
||||
["acc_boss"] = "Adgang til society-konto",
|
||||
["acc_boss_trans"] = "Adgang til society-overførsler",
|
||||
["acc_gang"] = "Adgang til gang-society-konto",
|
||||
["acc_gang_trans"] = "Adgang til gangoverførsler",
|
||||
["header_soc"] = "- Society-konto -",
|
||||
["header_soc_bank"] = "🏢 Society Bank 🏢",
|
||||
["amount_pay"] = "💵 Beløb at betale",
|
||||
["give_cash"] = "Giv nogen kontanter",
|
||||
["give"] = "Giv",
|
||||
["welcome"] = "Velkommen tilbage, ",
|
||||
["citizenid"] = "- Borger-ID -",
|
||||
["header_acc"] = "- Konto -",
|
||||
["header_info"] = "- Kontoinformation -Opsparings-ID: ",
|
||||
["header_balance_bank"] = "- Balancer -🏦Bank - DKK",
|
||||
["header_option"] = "- Valg -",
|
||||
["cash_balance"] = "💵Kontanter - DKK",
|
||||
["bank_balance"] = "🏦Bank - DKK",
|
||||
["saving_balance"] = "- Balancer -💰Opsparing - DKK",
|
||||
["cus_id"] = "# Kundens ID #",
|
||||
["type"] = "Betalingstype",
|
||||
["amount_charge"] = "💵 Beløb at opkræve",
|
||||
["cash_reg"] = "Kontantregister",
|
||||
["person_id"] = "# Personens ID #",
|
||||
["charge"] = "Opkræv",
|
||||
["send"] = "Send",
|
||||
["receipt"] = "Kvitteringer 🧾",
|
||||
["payment"] = " Betaling 🧾",
|
||||
["trade_confirm"] = "Vil du bytte dine kvitteringer til betaling?",
|
||||
["accept_payment"] = "Vil du acceptere betalingen?",
|
||||
["accept_charge"] = "Vil du acceptere opkrævningen?",
|
||||
["ticket_amount"] = "Antal billetter: ",
|
||||
["total_pay"] = "Total betaling: DKK",
|
||||
["confirm"] = "Ja",
|
||||
["yes"] = "Ja",
|
||||
["no"] = "Nej",
|
||||
["cash"] = "Kontanter",
|
||||
["card"] = "Kort",
|
||||
["payment_amount"] = " Betaling: DKK",
|
||||
["bank_charge"] = "Bankgebyr: DKK",
|
||||
},
|
||||
}
|
||||
270
locales/de.lua
270
locales/de.lua
@@ -1,135 +1,135 @@
|
||||
Loc = Loc or {}
|
||||
|
||||
Loc["de"] = {
|
||||
error = {
|
||||
["cancel"] = "Abgebrochen",
|
||||
["no_one"] = "Keiner in der Nähe zum Aufladen",
|
||||
["not_onduty"] = "Nicht eingestempelt!",
|
||||
["no_job"] = "Sie haben nicht den gewünschten Beruf",
|
||||
["no_ticket"] = "Sie haben keine Tickets zum Tauschen",
|
||||
["bank_low"] = "Kontostand zu niedrig",
|
||||
["no_cash"] = "Nicht genug Bargeld",
|
||||
["saving_low"] = "Sparguthaben zu niedrig",
|
||||
["soc_low"] = "Firmenkontoguthaben zu niedrig",
|
||||
["nomoney_bank"] = "Nicht genug Geld auf Ihrer Bank",
|
||||
["error_start"] = "Fehler: Konto '",
|
||||
["error_end"] = "' nicht gefunden",
|
||||
["not_enough"] = "Sie haben nicht genug Geld zum übergeben",
|
||||
["zero"] = "Sie können nicht 0$ geben",
|
||||
["charge_zero"] = "Sie können keine $0 berechnen",
|
||||
["no_ticket_to"] = "Keine Tickets zum Tauschen",
|
||||
["customer_nocash"] = "Der Kunde hat nicht genug Bargeld, um zu bezahlen",
|
||||
["you_nocash"] = "Sie haben nicht genug Geld, um zu bezahlen",
|
||||
["decline_pay"] = " lehnte die $ ab",
|
||||
["declined_payment"] = "Sie haben die Zahlung abgelehnt",
|
||||
},
|
||||
success = {
|
||||
["draw"] = "Abgehoben $",
|
||||
["from_bank"] = " von der Bank",
|
||||
["deposited"] = "Eingezahlt $",
|
||||
["into_bank"] = " in die Bank",
|
||||
["draw_save"] = " Abhebung von Ersparnissen auf ein Bankkonto",
|
||||
["depos_save"] = " Vom Bankkonto auf das Sparkonto eingezahlt",
|
||||
["fromthe"] = " von der ",
|
||||
["into"] = " in die ",
|
||||
["account"] = " Konto",
|
||||
["sent"] = "Gesendet $",
|
||||
["recieved"] = "Empfangen $",
|
||||
["to"] = " zu ",
|
||||
["from"] = " von ",
|
||||
["you_gave"] = "Sie gaben ",
|
||||
["you_got"] = "Sie haben $",
|
||||
["invoice_start"] = " Bezahlten ihre $",
|
||||
["invoice_end"] = " Rechnung",
|
||||
["rec_rec"] = "Erhaltene Quittung",
|
||||
["commission"] = " in der Kommission",
|
||||
["trade_ticket_start"] = "Gehandelte Tickets: ",
|
||||
["trade_ticket_end"] = " Total: $",
|
||||
["inv_succ"] = "Rechnung erfolgreich gesendet",
|
||||
["inv_recieved"] = "Neue Rechnung erhalten",
|
||||
["declined"] = "Sie haben die Zahlung abgelehnt",
|
||||
["accepted_pay"] = " akzeptierte die $",
|
||||
["payment"] = " Zahlung",
|
||||
["charged"] = " wurde berechnet für $",
|
||||
["you_charged"] = "Sie wurden berechnet für $",
|
||||
["charge_end"] = " Gebühr",
|
||||
},
|
||||
blip = {
|
||||
["blip_atm"] = "ATM",
|
||||
["blip_bank"] = "Bank",
|
||||
},
|
||||
command = {
|
||||
["pay_user"] = "Einen Bürger in der Nähe bezahlen",
|
||||
["cash_reg"] = "Mobile Registrierkasse verwenden",
|
||||
["charge"] = "Eine andere Person belasten",
|
||||
},
|
||||
target = {
|
||||
["atm"] = "ATM benutzen",
|
||||
["bank"] = "Bank benutzen",
|
||||
["transfer"] = "Geld überweisen",
|
||||
["saving"] = "Zugang Ersparnisse",
|
||||
["soc_saving"] = "Zugang Firmenkonto",
|
||||
["soc_trans"] = "Firmenkonto Geldüberweisung",
|
||||
["gang_acct"] = "Gang Konto",
|
||||
["gang_trans"] = "Gang Geldtransfer",
|
||||
["charge"] = "Gebühr für den Kunden",
|
||||
["cashin_boss"] = "Bargeld in Job-Einnahmen",
|
||||
["cashin_gang"] = "Bargeld in Bandeneinnahmen",
|
||||
},
|
||||
menu = {
|
||||
["close"] = "Schließen",
|
||||
["withdraw"] = "Abheben",
|
||||
["deposit"] = "Einzahlen",
|
||||
["transfer"] = "Überweißen",
|
||||
["transfer_money"] = "Geld überweisen",
|
||||
["header_atm"] = "💵 ATM Banking 💵",
|
||||
["header_trans_amount"] = "💵 Überweisungsbetrag",
|
||||
["header_bank"] = "🏦 Banking 🏦",
|
||||
["header_trans"] = "🔀 Transferdienste 🔀",
|
||||
["header_account_no"] = "🏦 Kontonummer.",
|
||||
["header_saving"] = "💰 Ersparnisse 💰",
|
||||
["acc_atm"] = "Zugang zu ATM",
|
||||
["acc_bank"] = "Zugang Bank",
|
||||
["acc_trans"] = "Zugriff auf Überweisungen",
|
||||
["acc_saving"] = "Zugang zu Ersparnissen",
|
||||
["acc_boss"] = "Zugriff auf das Firmenkonto",
|
||||
["acc_boss_trans"] = "Zugang zu Firmenkontotransfers",
|
||||
["acc_gang"] = "Zugriff auf das Gangkonto",
|
||||
["acc_gang_trans"] = "Zugang zu Gangkontotransfers",
|
||||
["header_soc"] = "- Firmenkonto -",
|
||||
["header_soc_bank"] = "🏢 Firmen Banking 🏢",
|
||||
["amount_pay"] = "💵 Zu zahlender Betrag'",
|
||||
["give_cash"] = "Jemandem Bargeld geben",
|
||||
["give"] = "Geben",
|
||||
["welcome"] = "Willkommen zurück, ",
|
||||
["citizenid"] = "- Ausweisnummer -",
|
||||
["header_acc"] = "- Konto -",
|
||||
["header_info"] = "- Konto Info -Ersparnis-ID: ",
|
||||
["header_balance_bank"] = "- Kontostand -🏦Bank - $",
|
||||
["header_option"] = "- Optionen -",
|
||||
["cash_balance"] = "💵Bargeld - $",
|
||||
["bank_balance"] = "🏦Bank - $",
|
||||
["saving_balance"] = "- Kontostand -💰Ersparnisses - $",
|
||||
["cus_id"] = "# Kunden ID #",
|
||||
["type"] = "Zahlungsart",
|
||||
["amount_charge"] = "💵 Zu berechnender Betrag",
|
||||
["cash_reg"] = " Registrierkasse",
|
||||
["person_id"] = "# Bürger ID #",
|
||||
["charge"] = " Laden Sie",
|
||||
["send"] = "Send",
|
||||
["receipt"] = " Quittungen 🧾",
|
||||
["payment"] = " Zahlung 🧾",
|
||||
["trade_confirm"] = "Möchten Sie Ihre Quittungen gegen Bezahlung eintauschen??",
|
||||
["accept_payment"] = "Möchten Sie die Zahlung akzeptieren?",
|
||||
["accept_charge"] = "Möchten Sie die Gebühr akzeptieren?",
|
||||
["ticket_amount"] = "Anzahl der Tickets: ",
|
||||
["total_pay"] = "Gesamte Zahlung: $",
|
||||
["confirm"] = "Ja",
|
||||
["yes"] = "Ja",
|
||||
["no"] = "Nein",
|
||||
["cash"] = "Bargeld",
|
||||
["card"] = "Karte",
|
||||
["payment_amount"] = " Zahlung: $",
|
||||
["bank_charge"] = "Bankgebühr: $",
|
||||
},
|
||||
}
|
||||
Loc = Loc or {}
|
||||
|
||||
Loc["de"] = {
|
||||
error = {
|
||||
["cancel"] = "Abgebrochen",
|
||||
["no_one"] = "Keiner in der Nähe zum Aufladen",
|
||||
["not_onduty"] = "Nicht eingestempelt!",
|
||||
["no_job"] = "Sie haben nicht den gewünschten Beruf",
|
||||
["no_ticket"] = "Sie haben keine Tickets zum Tauschen",
|
||||
["bank_low"] = "Kontostand zu niedrig",
|
||||
["no_cash"] = "Nicht genug Bargeld",
|
||||
["saving_low"] = "Sparguthaben zu niedrig",
|
||||
["soc_low"] = "Firmenkontoguthaben zu niedrig",
|
||||
["nomoney_bank"] = "Nicht genug Geld auf Ihrer Bank",
|
||||
["error_start"] = "Fehler: Konto '",
|
||||
["error_end"] = "' nicht gefunden",
|
||||
["not_enough"] = "Sie haben nicht genug Geld zum übergeben",
|
||||
["zero"] = "Sie können nicht 0$ geben",
|
||||
["charge_zero"] = "Sie können keine $0 berechnen",
|
||||
["no_ticket_to"] = "Keine Tickets zum Tauschen",
|
||||
["customer_nocash"] = "Der Kunde hat nicht genug Bargeld, um zu bezahlen",
|
||||
["you_nocash"] = "Sie haben nicht genug Geld, um zu bezahlen",
|
||||
["decline_pay"] = " lehnte die $ ab",
|
||||
["declined_payment"] = "Sie haben die Zahlung abgelehnt",
|
||||
},
|
||||
success = {
|
||||
["draw"] = "Abgehoben $",
|
||||
["from_bank"] = " von der Bank",
|
||||
["deposited"] = "Eingezahlt $",
|
||||
["into_bank"] = " in die Bank",
|
||||
["draw_save"] = " Abhebung von Ersparnissen auf ein Bankkonto",
|
||||
["depos_save"] = " Vom Bankkonto auf das Sparkonto eingezahlt",
|
||||
["fromthe"] = " von der ",
|
||||
["into"] = " in die ",
|
||||
["account"] = " Konto",
|
||||
["sent"] = "Gesendet $",
|
||||
["recieved"] = "Empfangen $",
|
||||
["to"] = " zu ",
|
||||
["from"] = " von ",
|
||||
["you_gave"] = "Sie gaben ",
|
||||
["you_got"] = "Sie haben $",
|
||||
["invoice_start"] = " Bezahlten ihre $",
|
||||
["invoice_end"] = " Rechnung",
|
||||
["rec_rec"] = "Erhaltene Quittung",
|
||||
["commission"] = " in der Kommission",
|
||||
["trade_ticket_start"] = "Gehandelte Tickets: ",
|
||||
["trade_ticket_end"] = " Total: $",
|
||||
["inv_succ"] = "Rechnung erfolgreich gesendet",
|
||||
["inv_recieved"] = "Neue Rechnung erhalten",
|
||||
["declined"] = "Sie haben die Zahlung abgelehnt",
|
||||
["accepted_pay"] = " akzeptierte die $",
|
||||
["payment"] = " Zahlung",
|
||||
["charged"] = " wurde berechnet für $",
|
||||
["you_charged"] = "Sie wurden berechnet für $",
|
||||
["charge_end"] = " Gebühr",
|
||||
},
|
||||
blip = {
|
||||
["blip_atm"] = "ATM",
|
||||
["blip_bank"] = "Bank",
|
||||
},
|
||||
command = {
|
||||
["pay_user"] = "Einen Bürger in der Nähe bezahlen",
|
||||
["cash_reg"] = "Mobile Registrierkasse verwenden",
|
||||
["charge"] = "Eine andere Person belasten",
|
||||
},
|
||||
target = {
|
||||
["atm"] = "ATM benutzen",
|
||||
["bank"] = "Bank benutzen",
|
||||
["transfer"] = "Geld überweisen",
|
||||
["saving"] = "Zugang Ersparnisse",
|
||||
["soc_saving"] = "Zugang Firmenkonto",
|
||||
["soc_trans"] = "Firmenkonto Geldüberweisung",
|
||||
["gang_acct"] = "Gang Konto",
|
||||
["gang_trans"] = "Gang Geldtransfer",
|
||||
["charge"] = "Gebühr für den Kunden",
|
||||
["cashin_boss"] = "Bargeld in Job-Einnahmen",
|
||||
["cashin_gang"] = "Bargeld in Bandeneinnahmen",
|
||||
},
|
||||
menu = {
|
||||
["close"] = "Schließen",
|
||||
["withdraw"] = "Abheben",
|
||||
["deposit"] = "Einzahlen",
|
||||
["transfer"] = "Überweißen",
|
||||
["transfer_money"] = "Geld überweisen",
|
||||
["header_atm"] = "💵 ATM Banking 💵",
|
||||
["header_trans_amount"] = "💵 Überweisungsbetrag",
|
||||
["header_bank"] = "🏦 Banking 🏦",
|
||||
["header_trans"] = "🔀 Transferdienste 🔀",
|
||||
["header_account_no"] = "🏦 Kontonummer.",
|
||||
["header_saving"] = "💰 Ersparnisse 💰",
|
||||
["acc_atm"] = "Zugang zu ATM",
|
||||
["acc_bank"] = "Zugang Bank",
|
||||
["acc_trans"] = "Zugriff auf Überweisungen",
|
||||
["acc_saving"] = "Zugang zu Ersparnissen",
|
||||
["acc_boss"] = "Zugriff auf das Firmenkonto",
|
||||
["acc_boss_trans"] = "Zugang zu Firmenkontotransfers",
|
||||
["acc_gang"] = "Zugriff auf das Gangkonto",
|
||||
["acc_gang_trans"] = "Zugang zu Gangkontotransfers",
|
||||
["header_soc"] = "- Firmenkonto -",
|
||||
["header_soc_bank"] = "🏢 Firmen Banking 🏢",
|
||||
["amount_pay"] = "💵 Zu zahlender Betrag'",
|
||||
["give_cash"] = "Jemandem Bargeld geben",
|
||||
["give"] = "Geben",
|
||||
["welcome"] = "Willkommen zurück, ",
|
||||
["citizenid"] = "- Ausweisnummer -",
|
||||
["header_acc"] = "- Konto -",
|
||||
["header_info"] = "- Konto Info -Ersparnis-ID: ",
|
||||
["header_balance_bank"] = "- Kontostand -🏦Bank - $",
|
||||
["header_option"] = "- Optionen -",
|
||||
["cash_balance"] = "💵Bargeld - $",
|
||||
["bank_balance"] = "🏦Bank - $",
|
||||
["saving_balance"] = "- Kontostand -💰Ersparnisses - $",
|
||||
["cus_id"] = "# Kunden ID #",
|
||||
["type"] = "Zahlungsart",
|
||||
["amount_charge"] = "💵 Zu berechnender Betrag",
|
||||
["cash_reg"] = " Registrierkasse",
|
||||
["person_id"] = "# Bürger ID #",
|
||||
["charge"] = " Laden Sie",
|
||||
["send"] = "Send",
|
||||
["receipt"] = " Quittungen 🧾",
|
||||
["payment"] = " Zahlung 🧾",
|
||||
["trade_confirm"] = "Möchten Sie Ihre Quittungen gegen Bezahlung eintauschen??",
|
||||
["accept_payment"] = "Möchten Sie die Zahlung akzeptieren?",
|
||||
["accept_charge"] = "Möchten Sie die Gebühr akzeptieren?",
|
||||
["ticket_amount"] = "Anzahl der Tickets: ",
|
||||
["total_pay"] = "Gesamte Zahlung: $",
|
||||
["confirm"] = "Ja",
|
||||
["yes"] = "Ja",
|
||||
["no"] = "Nein",
|
||||
["cash"] = "Bargeld",
|
||||
["card"] = "Karte",
|
||||
["payment_amount"] = " Zahlung: $",
|
||||
["bank_charge"] = "Bankgebühr: $",
|
||||
},
|
||||
}
|
||||
|
||||
268
locales/en.lua
268
locales/en.lua
@@ -1,135 +1,135 @@
|
||||
Loc = Loc or {}
|
||||
|
||||
Loc["en"] = {
|
||||
error = {
|
||||
["cancel"] = "Cancelled",
|
||||
["no_one"] = "No one near by to charge",
|
||||
["not_onduty"] = "Not Clocked in!",
|
||||
["no_job"] = "You don't have the required job",
|
||||
["no_ticket"] = "You don't have any tickets to trade",
|
||||
["bank_low"] = "Bank Balance too low",
|
||||
["no_cash"] = "Not enough cash",
|
||||
["saving_low"] = "Savings Balance too low",
|
||||
["soc_low"] = "Society balance too low",
|
||||
["nomoney_bank"] = "Not enough money in your bank",
|
||||
["error_start"] = "Error: Account '",
|
||||
["error_end"] = "' not found",
|
||||
["not_enough"] = "You don't have enough cash to give",
|
||||
["zero"] = "You can't give $0",
|
||||
["charge_zero"] = "You can't charge $0",
|
||||
["no_ticket_to"] = "No tickets to trade",
|
||||
["customer_nocash"] = "Customer doesn't have enough cash to pay",
|
||||
["you_nocash"] = "You don't have enough cash to pay",
|
||||
["decline_pay"] = " declined the $",
|
||||
["declined_payment"] = "You declined the payment",
|
||||
},
|
||||
success = {
|
||||
["draw"] = "Withdrew $",
|
||||
["from_bank"] = " from the bank",
|
||||
["deposited"] = "Deposited $",
|
||||
["into_bank"] = " into the Bank",
|
||||
["draw_save"] = " Withdrawn from savings into bank account",
|
||||
["depos_save"] = " Deposited from bank account into savings",
|
||||
["fromthe"] = " from the ",
|
||||
["into"] = " into the ",
|
||||
["account"] = " account",
|
||||
["sent"] = "Sent $",
|
||||
["recieved"] = "Recieved $",
|
||||
["to"] = " to ",
|
||||
["from"] = " from ",
|
||||
["you_gave"] = "You gave ",
|
||||
["you_got"] = "You got $",
|
||||
["invoice_start"] = " Paid their $",
|
||||
["invoice_end"] = " invoice",
|
||||
["rec_rec"] = "Receipt received",
|
||||
["commission"] = " in Commission",
|
||||
["trade_ticket_start"] = "Tickets traded: ",
|
||||
["trade_ticket_end"] = " Total: $",
|
||||
["inv_succ"] = "Invoice Successfully Sent",
|
||||
["inv_recieved"] = "New Invoice Received",
|
||||
["declined"] = "You declined the payment",
|
||||
["accepted_pay"] = " accepted the $",
|
||||
["payment"] = " payment",
|
||||
["charged"] = " was charged for $",
|
||||
["you_charged"] = "You were charged for $",
|
||||
["charge_end"] = " charge",
|
||||
},
|
||||
blip = {
|
||||
["blip_atm"] = "ATM",
|
||||
["blip_bank"] = "Bank",
|
||||
},
|
||||
command = {
|
||||
["pay_user"] = "Pay a user nearby",
|
||||
["cash_reg"] = "Use mobile cash register",
|
||||
["charge"] = "Charge another person",
|
||||
},
|
||||
target = {
|
||||
["atm"] = "Use ATM",
|
||||
["bank"] = "Use Bank",
|
||||
["transfer"] = "Transfer Money",
|
||||
["saving"] = "Access Savings",
|
||||
["soc_saving"] = "Access Society Account",
|
||||
["soc_trans"] = "Society Money Transfer",
|
||||
["gang_acct"] = "Gang Society Account",
|
||||
["gang_trans"] = "Gang Money Transfer",
|
||||
["charge"] = "Charge Customer",
|
||||
["cashin_boss"] = "Cash in Job Receipts",
|
||||
["cashin_gang"] = "Cash in Gang Receipts",
|
||||
},
|
||||
menu = {
|
||||
["close"] = "Close",
|
||||
["withdraw"] = "Withdrawal",
|
||||
["deposit"] = "Deposit",
|
||||
["transfer"] = "Transfer",
|
||||
["transfer_money"] = "Transfer Money",
|
||||
["header_atm"] = "💵 ATM Banking 💵",
|
||||
["header_trans_amount"] = "💵 Amount to transfer",
|
||||
["header_bank"] = "🏦 Banking 🏦",
|
||||
["header_trans"] = "🔀 Transfer Services 🔀",
|
||||
["header_account_no"] = "🏦 Account no.",
|
||||
["header_saving"] = "💰 Savings 💰",
|
||||
["acc_atm"] = "Accessing ATM",
|
||||
["acc_bank"] = "Accessing Bank",
|
||||
["acc_trans"] = "Accessing Transfers",
|
||||
["acc_saving"] = "Accessing Savings",
|
||||
["acc_boss"] = "Accessing Society Account",
|
||||
["acc_boss_trans"] = "Accessing Society Transfers",
|
||||
["acc_gang"] = "Accessing Gang Society Account",
|
||||
["acc_gang_trans"] = "Accessing Gang Transfers",
|
||||
["header_soc"] = "Society Account -",
|
||||
["header_soc_bank"] = "Society Banking",
|
||||
["amount_pay"] = "💵 Amount to Pay'",
|
||||
["give_cash"] = "Give someone cash",
|
||||
["give"] = "Give",
|
||||
["welcome"] = "Welcome back, ",
|
||||
["citizenid"] = "Citizen ID -",
|
||||
["header_acc"] = "Account -",
|
||||
["header_info"] = "Account Info - Savings ID: ",
|
||||
["header_balance"] = "Balances -",
|
||||
["header_option"] = "Options -",
|
||||
["cash_balance"] = "💵Cash - $",
|
||||
["bank_balance"] = "🏦Bank - $",
|
||||
["saving_balance"] = "💰Savings - $",
|
||||
["cus_id"] = "# Customer ID #",
|
||||
["type"] = "Payment Type",
|
||||
["amount_charge"] = "💵 Amount to Charge",
|
||||
["cash_reg"] = " Cash Register",
|
||||
["person_id"] = "# Person's ID #",
|
||||
["charge"] = " Charge",
|
||||
["send"] = "Send",
|
||||
["receipt"] = " Receipts 🧾",
|
||||
["payment"] = " Payment 🧾",
|
||||
["trade_confirm"] = "Do you want trade your receipts for payment?",
|
||||
["accept_payment"] = "Do you want accept the payment?",
|
||||
["accept_charge"] = "Do you want accept the charge?",
|
||||
["ticket_amount"] = "Amount of Tickets: ",
|
||||
["total_pay"] = "<br>Total Payment: $",
|
||||
["confirm"] = "Confirm",
|
||||
["yes"] = "Yes",
|
||||
["no"] = "No",
|
||||
["cash"] = "Cash",
|
||||
["card"] = "Card",
|
||||
["payment_amount"] = " Payment: $",
|
||||
["bank_charge"] = "Bank Charge: $",
|
||||
},
|
||||
Loc = Loc or {}
|
||||
|
||||
Loc["en"] = {
|
||||
error = {
|
||||
["cancel"] = "Cancelled",
|
||||
["no_one"] = "No one near by to charge",
|
||||
["not_onduty"] = "Not Clocked in!",
|
||||
["no_job"] = "You don't have the required job",
|
||||
["no_ticket"] = "You don't have any tickets to trade",
|
||||
["bank_low"] = "Bank Balance too low",
|
||||
["no_cash"] = "Not enough cash",
|
||||
["saving_low"] = "Savings Balance too low",
|
||||
["soc_low"] = "Society balance too low",
|
||||
["nomoney_bank"] = "Not enough money in your bank",
|
||||
["error_start"] = "Error: Account '",
|
||||
["error_end"] = "' not found",
|
||||
["not_enough"] = "You don't have enough cash to give",
|
||||
["zero"] = "You can't give $0",
|
||||
["charge_zero"] = "You can't charge $0",
|
||||
["no_ticket_to"] = "No tickets to trade",
|
||||
["customer_nocash"] = "Customer doesn't have enough cash to pay",
|
||||
["you_nocash"] = "You don't have enough cash to pay",
|
||||
["decline_pay"] = " declined the $",
|
||||
["declined_payment"] = "You declined the payment",
|
||||
},
|
||||
success = {
|
||||
["draw"] = "Withdrew $",
|
||||
["from_bank"] = " from the bank",
|
||||
["deposited"] = "Deposited $",
|
||||
["into_bank"] = " into the Bank",
|
||||
["draw_save"] = " Withdrawn from savings into bank account",
|
||||
["depos_save"] = " Deposited from bank account into savings",
|
||||
["fromthe"] = " from the ",
|
||||
["into"] = " into the ",
|
||||
["account"] = " account",
|
||||
["sent"] = "Sent $",
|
||||
["recieved"] = "Recieved $",
|
||||
["to"] = " to ",
|
||||
["from"] = " from ",
|
||||
["you_gave"] = "You gave ",
|
||||
["you_got"] = "You got $",
|
||||
["invoice_start"] = " Paid their $",
|
||||
["invoice_end"] = " invoice",
|
||||
["rec_rec"] = "Receipt received",
|
||||
["commission"] = " in Commission",
|
||||
["trade_ticket_start"] = "Tickets traded: ",
|
||||
["trade_ticket_end"] = " Total: $",
|
||||
["inv_succ"] = "Invoice Successfully Sent",
|
||||
["inv_recieved"] = "New Invoice Received",
|
||||
["declined"] = "You declined the payment",
|
||||
["accepted_pay"] = " accepted the $",
|
||||
["payment"] = " payment",
|
||||
["charged"] = " was charged for $",
|
||||
["you_charged"] = "You were charged for $",
|
||||
["charge_end"] = " charge",
|
||||
},
|
||||
blip = {
|
||||
["blip_atm"] = "ATM",
|
||||
["blip_bank"] = "Bank",
|
||||
},
|
||||
command = {
|
||||
["pay_user"] = "Pay a user nearby",
|
||||
["cash_reg"] = "Use mobile cash register",
|
||||
["charge"] = "Charge another person",
|
||||
},
|
||||
target = {
|
||||
["atm"] = "Use ATM",
|
||||
["bank"] = "Use Bank",
|
||||
["transfer"] = "Transfer Money",
|
||||
["saving"] = "Access Savings",
|
||||
["soc_saving"] = "Access Society Account",
|
||||
["soc_trans"] = "Society Money Transfer",
|
||||
["gang_acct"] = "Gang Society Account",
|
||||
["gang_trans"] = "Gang Money Transfer",
|
||||
["charge"] = "Charge Customer",
|
||||
["cashin_boss"] = "Cash in Job Receipts",
|
||||
["cashin_gang"] = "Cash in Gang Receipts",
|
||||
},
|
||||
menu = {
|
||||
["close"] = "Close",
|
||||
["withdraw"] = "Withdrawal",
|
||||
["deposit"] = "Deposit",
|
||||
["transfer"] = "Transfer",
|
||||
["transfer_money"] = "Transfer Money",
|
||||
["header_atm"] = "💵 ATM Banking 💵",
|
||||
["header_trans_amount"] = "💵 Amount to transfer",
|
||||
["header_bank"] = "🏦 Banking 🏦",
|
||||
["header_trans"] = "🔀 Transfer Services 🔀",
|
||||
["header_account_no"] = "🏦 Account no.",
|
||||
["header_saving"] = "💰 Savings 💰",
|
||||
["acc_atm"] = "Accessing ATM",
|
||||
["acc_bank"] = "Accessing Bank",
|
||||
["acc_trans"] = "Accessing Transfers",
|
||||
["acc_saving"] = "Accessing Savings",
|
||||
["acc_boss"] = "Accessing Society Account",
|
||||
["acc_boss_trans"] = "Accessing Society Transfers",
|
||||
["acc_gang"] = "Accessing Gang Society Account",
|
||||
["acc_gang_trans"] = "Accessing Gang Transfers",
|
||||
["header_soc"] = "Society Account -",
|
||||
["header_soc_bank"] = "Society Banking",
|
||||
["amount_pay"] = "💵 Amount to Pay'",
|
||||
["give_cash"] = "Give someone cash",
|
||||
["give"] = "Give",
|
||||
["welcome"] = "Welcome back, ",
|
||||
["citizenid"] = "Citizen ID -",
|
||||
["header_acc"] = "Account -",
|
||||
["header_info"] = "Account Info - Savings ID: ",
|
||||
["header_balance"] = "Balances -",
|
||||
["header_option"] = "Options -",
|
||||
["cash_balance"] = "💵Cash - $",
|
||||
["bank_balance"] = "🏦Bank - $",
|
||||
["saving_balance"] = "💰Savings - $",
|
||||
["cus_id"] = "# Customer ID #",
|
||||
["type"] = "Payment Type",
|
||||
["amount_charge"] = "💵 Amount to Charge",
|
||||
["cash_reg"] = " Cash Register",
|
||||
["person_id"] = "# Person's ID #",
|
||||
["charge"] = " Charge",
|
||||
["send"] = "Send",
|
||||
["receipt"] = " Receipts 🧾",
|
||||
["payment"] = " Payment 🧾",
|
||||
["trade_confirm"] = "Do you want trade your receipts for payment?",
|
||||
["accept_payment"] = "Do you want accept the payment?",
|
||||
["accept_charge"] = "Do you want accept the charge?",
|
||||
["ticket_amount"] = "Amount of Tickets: ",
|
||||
["total_pay"] = "<br>Total Payment: $",
|
||||
["confirm"] = "Confirm",
|
||||
["yes"] = "Yes",
|
||||
["no"] = "No",
|
||||
["cash"] = "Cash",
|
||||
["card"] = "Card",
|
||||
["payment_amount"] = " Payment: $",
|
||||
["bank_charge"] = "Bank Charge: $",
|
||||
},
|
||||
}
|
||||
@@ -1,13 +1,11 @@
|
||||
Core.Commands.Add("cashgive",
|
||||
Loc[Config.Lan].command["pay_user"], {}, false, function(source) TriggerClientEvent(getScript()..":client:ATM:give", source) end)
|
||||
|
||||
registerCommand("polcharge", {
|
||||
Loc[Config.Lan].command["pay_user"], {}, false,
|
||||
registerCommand("cashgive", {
|
||||
locale("command" , "pay_user"), {}, false,
|
||||
function(source)
|
||||
TriggerClientEvent(getScript()..":client:ATM:give", source)
|
||||
end
|
||||
})
|
||||
|
||||
|
||||
RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, baccount, account, society, gsociety)
|
||||
local src = source
|
||||
local Player = getPlayer(src)
|
||||
@@ -18,19 +16,19 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
if account == "bank" or account == "atm" then
|
||||
if billtype == "withdraw" then
|
||||
if Player.bank < amount then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["bank_low"], "error", src)
|
||||
triggerNotify(nil, locale("error" ,"bank_low"), "error", src)
|
||||
elseif Player.bank >= tonumber(amount) then
|
||||
triggerNotify(nil, Loc[Config.Lan].success["draw"]..cv(amount)..Loc[Config.Lan].success["from_bank"], "success") -- Don't really need this as phone gets notified when money is withdrawn
|
||||
triggerNotify(nil, locale("success" ,"draw")..cv(amount)..locale("success" ,"from_bank"), "success") -- Don't really need this as phone gets notified when money is withdrawn
|
||||
chargePlayer(amount, "bank", src) Wait(1500)
|
||||
fundPlayer(amount, "cash", src)
|
||||
end
|
||||
elseif billtype == "deposit" then
|
||||
if Player.cash < amount then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["no_cash"], "error", src)
|
||||
triggerNotify(nil, locale("error" ,"no_cash"), "error", src)
|
||||
elseif Player.cash >= amount then
|
||||
chargePlayer(amount, "cash", src) Wait(1500)
|
||||
fundPlayer(amount, "bank", src)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["deposited"]..cv(amount)..Loc[Config.Lan].success["into_bank"], "success", src)
|
||||
triggerNotify(nil, locale("success" ,"deposited")..cv(amount)..locale("success" ,"into_bank"), "success", src)
|
||||
end
|
||||
end
|
||||
-- Transfers from bank to savings account --
|
||||
@@ -42,29 +40,29 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
if savbal >= amount then
|
||||
savbal -= amount
|
||||
fundPlayer(amount, "cash", src)
|
||||
triggerNotify(nil, "$"..cv(amount)..Loc[Config.Lan].success["draw_save"], "success", src)
|
||||
MySQL.Async.execute('UPDATE bank_accounts SET account_balance = ? WHERE citizenid = ?', { savbal, Player.citizenId}, function(success)
|
||||
triggerNotify(nil, "$"..cv(amount)..locale("success" ,"draw_save"), "success", src)
|
||||
MySQL.Async.execute('UPDATE bank_accounts SET account_balance = ? WHERE citizenid = ?', { savbal, Player.citizenId }, function(success)
|
||||
if success then return true else return false end
|
||||
end)
|
||||
elseif savbal < amount then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["saving_low"], "error")
|
||||
triggerNotify(nil, locale("error" ,"saving_low"), "error")
|
||||
end
|
||||
elseif billtype == "deposit" then
|
||||
if amount < Player.bank then
|
||||
savbal += amount
|
||||
chargePlayer(amount, "bank", src)
|
||||
triggerNotify(nil, "$"..cv(amount)..Loc[Config.Lan].success["depos_save"], "success", src)
|
||||
triggerNotify(nil, "$"..cv(amount)..locale("success", "depos_save"), "success", src)
|
||||
MySQL.Async.execute('UPDATE bank_accounts SET account_balance = ? WHERE citizenid = ?', { savbal, Player.citizenId}, function(success)
|
||||
if success then return true else return false end
|
||||
end)
|
||||
else triggerNotify(nil, Loc[Config.Lan].error["bank_low"], "error", src)
|
||||
else triggerNotify(nil, locale("error" ,"bank_low"), "error", src)
|
||||
end
|
||||
end
|
||||
--Simple transfers from society account to bank --
|
||||
elseif account == "society" then
|
||||
if billtype == "withdraw" then
|
||||
if tonumber(society) < amount then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["soc_low"], "error", src)
|
||||
triggerNotify(nil, locale("error" ,"soc_low"), "error", src)
|
||||
elseif tonumber(society) >= amount then
|
||||
|
||||
if isStarted("Renewed-Banking") then
|
||||
@@ -87,10 +85,10 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
|
||||
fundPlayer(amount, "bank", src)
|
||||
debugPrint("^5Debug^7: ^3"..bankScript.."^7(^3Job^7): ^2Removing ^7$"..amount.." ^2from account ^7'^6"..Player.job.."^7' ($"..newAmount..")")
|
||||
triggerNotify(nil, Loc[Config.Lan].success["draw"]..cv(amount)..Loc[Config.Lan].success["fromthe"]..Jobs[Player.job].label..Loc[Config.Lan].success["account"], "success", src)
|
||||
triggerNotify(nil, locale("success", "draw")..cv(amount)..locale("success", "fromthe")..Jobs[Player.job].label..locale("success" ,"account"), "success", src)
|
||||
end
|
||||
elseif billtype == "deposit" then
|
||||
if Player.bank < amount then triggerNotify(nil, Loc[Config.Lan].error["nomoney_bank"], "error", src)
|
||||
if Player.bank < amount then triggerNotify(nil, locale("error", "nomoney_bank"), "error", src)
|
||||
elseif Player.bank >= amount then
|
||||
if isStarted("Renewed-Banking") then
|
||||
bankScript = "Renewed-Banking"
|
||||
@@ -112,7 +110,7 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
end
|
||||
chargePlayer(amount, "bank", src) Wait(1500)
|
||||
debugPrint("^5Debug^7: ^3"..bankScript.."^7(^3Job^7): ^2Adding ^7$"..amount.." ^2to account ^7'^6"..Player.job.."^7' ($"..newAmount..")")
|
||||
triggerNotify(nil, Loc[Config.Lan].success["deposited"]..cv(amount)..Loc[Config.Lan].success["into"]..Jobs[Player.job].label..Loc[Config.Lan].success["account"], "success", src)
|
||||
triggerNotify(nil, locale("success", "deposited")..cv(amount)..locale("success", "into")..Jobs[Player.job].label..locale("success", "account"), "success", src)
|
||||
end
|
||||
end
|
||||
-- Transfer from boss account to players --
|
||||
@@ -145,14 +143,14 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
end
|
||||
if Reciever then
|
||||
Reciever.Functions.AddMoney('bank', amount)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["sent"]..amount..Loc[Config.Lan].success["to"]..Reciever.PlayerData.charinfo.firstname.." "..Reciever.PlayerData.charinfo.lastname, "success", src)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["recieved"]..cv(amount)..Loc[Config.Lan].success["from"]..tostring(Player.PlayerData.job.label)..Loc[Config.Lan].success["account"], "success", Reciever.PlayerData.source)
|
||||
triggerNotify(nil, locale("success" ,"sent"]..amount..locale("success" ,"to"]..Reciever.PlayerData.charinfo.firstname.." "..Reciever.PlayerData.charinfo.lastname, "success", src)
|
||||
triggerNotify(nil, locale("success" ,"recieved"]..cv(amount)..locale("success" ,"from"]..tostring(Player.PlayerData.job.label)..locale("success" ,"account"], "success", Reciever.PlayerData.source)
|
||||
else
|
||||
local RecieverMoney = json.decode(result[1].money)
|
||||
RecieverMoney.bank += amount
|
||||
MySQL.Async.execute('UPDATE players SET money = ? WHERE citizenid = ?', {json.encode(RecieverMoney), result[1].citizenid})
|
||||
end
|
||||
elseif not result[1] then triggerNotify(nil, Loc[Config.Lan].error["error_start"]..baccount..Loc[Config.Lan].error["error_end"], "error", src)
|
||||
elseif not result[1] then triggerNotify(nil, locale("error" ,"error_start"]..baccount..locale("error" ,"error_end"], "error", src)
|
||||
end
|
||||
end]]
|
||||
|
||||
@@ -160,7 +158,7 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
elseif account == "gang" then
|
||||
if billtype == "withdraw" then
|
||||
if tonumber(gsociety) < amount then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["soc_low"], "error", src)
|
||||
triggerNotify(nil, locale("error" ,"soc_low"), "error", src)
|
||||
elseif tonumber(gsociety) >= amount then
|
||||
if isStarted("Renewed-Banking") then
|
||||
exports['Renewed-Banking']:removeAccountMoney(Player.gang, amount)
|
||||
@@ -174,11 +172,11 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
end
|
||||
|
||||
fundPlayer(amount, "bank", src)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["draw"]..cv(amount)..Loc[Config.Lan].success["fromthe"]..Gangs[Player.gang].label..Loc[Config.Lan].success["account"], "success", src)
|
||||
triggerNotify(nil, locale("success" ,"draw")..cv(amount)..locale("success" ,"fromthe")..Gangs[Player.gang].label..locale("success" ,"account"), "success", src)
|
||||
|
||||
elseif billtype == "deposit" then
|
||||
if Player.bank < amount then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["nomoney_bank"], "error", src)
|
||||
triggerNotify(nil, locale("error" ,"nomoney_bank"), "error", src)
|
||||
elseif Player.bank >= amount then
|
||||
if isStarted("Renewed-Banking") then
|
||||
exports['Renewed-Banking']:addAccountMoney(Player.gang, amount)
|
||||
@@ -190,7 +188,7 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
exports["okokBanking"]:AddMoney(Player.gang, amount)
|
||||
end
|
||||
Player.Functions.RemoveMoney('bank', amount) Wait(1500)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["deposited"]..cv(amount)..Loc[Config.Lan].success["into"]..Gangs[Player.gang].label..Loc[Config.Lan].success["account"], "success", src)
|
||||
triggerNotify(nil, locale("success" ,"deposited")..cv(amount)..locale("success" ,"into")..Gangs[Player.gang].label..locale("success" ,"account"), "success", src)
|
||||
end
|
||||
end
|
||||
-- Transfer from gang account to players --
|
||||
@@ -217,14 +215,14 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
elseif Config.Banking == "fd" then exports.fd_banking:RemoveGangMoney(tostring(Player.PlayerData.gang.name), amount) end
|
||||
if not Reciever then
|
||||
Reciever.Functions.AddMoney('bank', amount)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["sent"]..amount..Loc[Config.Lan].success["to"]..Reciever.PlayerData.charinfo.firstname.." "..Reciever.PlayerData.charinfo.lastname, "success", src)
|
||||
triggerNotify(nil, Reciever.PlayerData.source, Loc[Config.Lan].success["recieved"]..cv(amount)..Loc[Config.Lan].success["from"]..tostring(Player.PlayerData.gang.label)..Loc[Config.Lan].success["account"], "success", Reciever.PlayerData.source)
|
||||
triggerNotify(nil, locale("success" ,"sent")..amount..locale("success" ,"to")..Reciever.PlayerData.charinfo.firstname.." "..Reciever.PlayerData.charinfo.lastname, "success", src)
|
||||
triggerNotify(nil, Reciever.PlayerData.source, locale("success" ,"recieved")..cv(amount)..locale("success" ,"from")..tostring(Player.PlayerData.gang.label)..locale("success" ,"account"), "success", Reciever.PlayerData.source)
|
||||
else
|
||||
local RecieverMoney = json.decode(result[1].money)
|
||||
RecieverMoney.bank += amount
|
||||
MySQL.Async.execute('UPDATE players SET money = ? WHERE citizenid = ?', {json.encode(RecieverMoney), result[1].citizenid})
|
||||
end
|
||||
elseif not result[1] then triggerNotify(nil, Loc[Config.Lan].error["error_start"]..baccount..Loc[Config.Lan].error["error_end"], "error", src)
|
||||
elseif not result[1] then triggerNotify(nil, locale("error" ,"error_start")..baccount..locale("error" ,"error_end"), "error", src)
|
||||
|
||||
end
|
||||
end
|
||||
@@ -249,15 +247,15 @@ RegisterServerEvent(getScript()..":server:ATM:use", function(amount, billtype, b
|
||||
Player.Functions.RemoveMoney('bank', amount)
|
||||
if Reciever then
|
||||
Reciever.Functions.AddMoney('bank', amount)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["sent"]..cv(amount)..Loc[Config.Lan].success["to"]..Reciever.PlayerData.charinfo.firstname.." "..Reciever.PlayerData.charinfo.lastname, "success", src)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["recieved"]..cv(amount)..Loc[Config.Lan].success["from"]..Player.PlayerData.charinfo.firstname.." "..Player.PlayerData.charinfo.lastname, "success", Reciever.PlayerData.source)
|
||||
triggerNotify(nil, locale("success" ,"sent")..cv(amount)..locale("success" ,"to")..Reciever.PlayerData.charinfo.firstname.." "..Reciever.PlayerData.charinfo.lastname, "success", src)
|
||||
triggerNotify(nil, locale("success" ,"recieved")..cv(amount)..locale("success" ,"from")..Player.PlayerData.charinfo.firstname.." "..Player.PlayerData.charinfo.lastname, "success", Reciever.PlayerData.source)
|
||||
else
|
||||
local RecieverMoney = json.decode(result[1].money)
|
||||
RecieverMoney.bank += amount
|
||||
MySQL.Async.execute('UPDATE players SET money = ? WHERE citizenid = ?', {json.encode(RecieverMoney), result[1].citizenid})
|
||||
end
|
||||
elseif not result[1] then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["error_start"]..baccount..Loc[Config.Lan].error["error_end"], "error", src)
|
||||
triggerNotify(nil, locale("error" ,"error_start")..baccount..locale("error" ,"error_end"), "error", src)
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -299,17 +297,20 @@ createCallback(getScript()..":GetInfo", function(source)
|
||||
end
|
||||
end
|
||||
|
||||
-- Savings account is only QBCore for now
|
||||
if isStarted(QBExport) then
|
||||
-- Grab Savings account info
|
||||
local result = MySQL.Sync.fetchAll('SELECT * FROM bank_accounts WHERE citizenid = ? AND account_name = ?', { Player.citizenId, 'Savings_'..Player.citizenId, })
|
||||
if result[1] then
|
||||
accountID = result[1].citizenid
|
||||
savingBalance = result[1].account_balance
|
||||
else
|
||||
MySQL.Async.insert('INSERT INTO bank_accounts (citizenid, account_name, account_balance) VALUES (?, ?, ?)', { Player.citizenId, 'Savings_'..Player.citizenId, 0}, function() completed = true end) repeat Wait(0) until completed == true
|
||||
local result = MySQL.Sync.fetchAll('SELECT * FROM bank_accounts WHERE citizenid = ? AND account_name = ?', { Player.citizenId, 'Savings_'..Player.citizenId, })
|
||||
accountID = result[1].citizenid
|
||||
savingBalance = result[1].account_balance
|
||||
end
|
||||
if result[1] then
|
||||
accountID = result[1].citizenid
|
||||
savingBalance = result[1].account_balance
|
||||
else
|
||||
MySQL.Async.insert('INSERT INTO bank_accounts (citizenid, account_name, account_balance) VALUES (?, ?, ?)', { Player.citizenId, 'Savings_'..Player.citizenId, 0}, function() completed = true end) repeat Wait(0) until completed == true
|
||||
local result = MySQL.Sync.fetchAll('SELECT * FROM bank_accounts WHERE citizenid = ? AND account_name = ?', { Player.citizenId, 'Savings_'..Player.citizenId, })
|
||||
accountID = result[1].citizenid
|
||||
savingBalance = result[1].account_balance
|
||||
end
|
||||
end
|
||||
local retTable = {
|
||||
name = Player.firstname..' '..Player.lastname,
|
||||
cash = Player.cash,
|
||||
@@ -326,20 +327,20 @@ createCallback(getScript()..":GetInfo", function(source)
|
||||
end)
|
||||
|
||||
RegisterServerEvent(getScript()..":server:ATM:give", function(citizen, price)
|
||||
local Player = Core.Functions.GetPlayer(source)
|
||||
local Reciever = Core.Functions.GetPlayer(tonumber(citizen))
|
||||
local Player = getPlayer(source)
|
||||
local Reciever = getPlayer(tonumber(citizen))
|
||||
local amount = tonumber(price)
|
||||
local balance = Player.Functions.GetMoney("cash")
|
||||
local balance = Player.cash
|
||||
|
||||
if amount and amount > 0 then
|
||||
if balance >= amount then
|
||||
Player.Functions.RemoveMoney('cash', amount)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["you_gave"]..Reciever.PlayerData.charinfo.firstname.." $"..cv(amount), "success", source)
|
||||
Reciever.Functions.AddMoney('cash', amount)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["you_got"]..cv(amount)..Loc[Config.Lan].success["from"]..Player.PlayerData.charinfo.firstname, "success", tonumber(citizen))
|
||||
chargePlayer(amount, "cash", source)
|
||||
triggerNotify(nil, locale("success" ,"you_gave")..Reciever.name.." $"..cv(amount), "success", source)
|
||||
fundPlayer(amount, "cash", Reciever.source)
|
||||
triggerNotify(nil, locale("success" ,"you_got")..cv(amount)..locale("success" ,"from")..Player.name, "success", tonumber(citizen))
|
||||
elseif balance < amount then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["not_enough"], "error", source)
|
||||
triggerNotify(nil, locale("error" ,"not_enough"), "error", source)
|
||||
end
|
||||
else triggerNotify(nil, Loc[Config.Lan].error["zero"], 'error', source) end
|
||||
else triggerNotify(nil, locale("error" ,"zero"), 'error', source) end
|
||||
end)
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ onResourceStart(function()
|
||||
end, true)
|
||||
|
||||
registerCommand("cashregister", {
|
||||
Loc[Config.Lan].command["cash_reg"], {}, false,
|
||||
locale("command", "cash_reg"), {}, false,
|
||||
function(source)
|
||||
TriggerClientEvent(getScript()..":client:Charge", source, {}, true)
|
||||
end
|
||||
@@ -22,10 +22,7 @@ createCallback(getScript()..":MakePlayerList", function(source)
|
||||
local onlineList = {}
|
||||
for _, v in pairs(GetPlayers()) do
|
||||
local Player = getPlayer(v)
|
||||
onlineList[#onlineList+1] = {
|
||||
value = tonumber(v),
|
||||
text = "["..v.."] - "..Player.name
|
||||
}
|
||||
onlineList[#onlineList+1] = { value = tonumber(v), text = "["..v.."] - "..Player.name }
|
||||
end
|
||||
return onlineList
|
||||
end)
|
||||
@@ -38,8 +35,8 @@ RegisterServerEvent(getScript()..":server:Charge", function(citizen, price, bill
|
||||
local balance = billed[billtype]
|
||||
if amount and amount > 0 then
|
||||
if balance < amount then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["customer_nocash"], "error", src)
|
||||
triggerNotify(nil, Loc[Config.Lan].error["you_nocash"], "error", tonumber(citizen))
|
||||
triggerNotify(nil, locale("error", "customer_nocash"), "error", src)
|
||||
triggerNotify(nil, locale("error", "you_nocash"), "error", tonumber(citizen))
|
||||
return
|
||||
end
|
||||
local label = gang == true and Gangs[biller.gang].label or Jobs[biller.job].label
|
||||
@@ -64,13 +61,13 @@ RegisterServerEvent(getScript()..":server:Charge", function(citizen, price, bill
|
||||
['@sendercitizenid'] = biller.citizenid,
|
||||
['@label'] = label,
|
||||
})
|
||||
TriggerClientEvent('gksphone:notifi', src, {title = 'Billing', message = Loc[Config.Lan].success["inv_succ"], img= '/html/static/img/icons/logo.png' })
|
||||
TriggerClientEvent('gksphone:notifi', billed.source, {title = 'Billing', message = Loc[Config.Lan].success["inv_recieved"], img= '/html/static/img/icons/logo.png' })
|
||||
TriggerClientEvent('gksphone:notifi', src, {title = 'Billing', message = locale("success", "inv_succ"), img= '/html/static/img/icons/logo.png' })
|
||||
TriggerClientEvent('gksphone:notifi', billed.source, {title = 'Billing', message = locale("success", "inv_recieved"), img= '/html/static/img/icons/logo.png' })
|
||||
end
|
||||
triggerNotify(nil, Loc[Config.Lan].success["inv_succ"], 'success', src)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["inv_recieved"], nil, billed.source)
|
||||
triggerNotify(nil, locale("success", "inv_succ"), 'success', src)
|
||||
triggerNotify(nil, locale("success", "inv_recieved"), nil, billed.source)
|
||||
end
|
||||
else triggerNotify(nil, Loc[Config.Lan].error["charge_zero"], 'error', source) return end
|
||||
else triggerNotify(nil, locale("error", "charge_zero"), 'error', source) return end
|
||||
end)
|
||||
|
||||
RegisterServerEvent(getScript()..":server:PayPopup", function(data)
|
||||
@@ -88,10 +85,10 @@ RegisterServerEvent(getScript()..":server:PayPopup", function(data)
|
||||
exports['ap-government']:chargeCityTax(billed.source, "Item", data.amount)
|
||||
end
|
||||
TriggerEvent(getScript()..":Tickets:Give", newdata, biller, data.gang)
|
||||
triggerNotify(nil, billed.firstname..Loc[Config.Lan].success["accepted_pay"]..data.amount..Loc[Config.Lan].success["payment"], "success", data.biller)
|
||||
triggerNotify(nil, billed.firstname..locale("success", "accepted_pay")..data.amount..locale("success", "payment"), "success", data.biller)
|
||||
elseif not data.accept then
|
||||
triggerNotify(nil, Loc[Config.Lan].success["declined"], "error", src)
|
||||
triggerNotify(nil, billed.firstname..Loc[Config.Lan].error["decline_pay"]..data.amount..Loc[Config.Lan].success["payment"], "error", data.biller)
|
||||
triggerNotify(nil, locale("success", "declined"), "error", src)
|
||||
triggerNotify(nil, billed.firstname..locale("error", "decline_pay")..data.amount..locale("success", "payment"), "error", data.biller)
|
||||
end
|
||||
end)
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
registerCommand("polcharge", {
|
||||
Loc[Config.Lan].command["charge"], {}, false,
|
||||
locale("command", "charge"), {}, false,
|
||||
function(source)
|
||||
TriggerClientEvent(getScript()..":client:PolCharge", source)
|
||||
end
|
||||
@@ -31,12 +31,12 @@ RegisterServerEvent(getScript()..":server:PolCharge", function(citizen, price)
|
||||
amountChange = (price - commission)
|
||||
})
|
||||
|
||||
triggerNotify(nil, billed.firstname..Loc[Config.Lan].success["charged"]..(price - commission), "success", src)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["you_charged"]..(price - commission), nil, billed.source)
|
||||
triggerNotify(nil, billed.firstname..locale("success", "charged")..(price - commission), "success", src)
|
||||
triggerNotify(nil, locale("success", "you_charged")..(price - commission), nil, billed.source)
|
||||
else
|
||||
TriggerClientEvent(getScript()..":client:PolPopup", billed.source, price, src, biller.job, commPercent)
|
||||
end
|
||||
else triggerNotify(nil, Loc[Config.Lan].error["charge_zero"], 'error', source) return end
|
||||
else triggerNotify(nil, locale("error", "charge_zero"), 'error', source) return end
|
||||
end)
|
||||
|
||||
RegisterServerEvent(getScript()..":server:PolPopup", function(data)
|
||||
@@ -55,8 +55,8 @@ RegisterServerEvent(getScript()..":server:PolPopup", function(data)
|
||||
amountChange = (price - commission)
|
||||
})
|
||||
elseif not data.accept then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["declined_payment"], nil, src)
|
||||
triggerNotify(nil, billed.PlayerData.charinfo.firstname.." declined the $"..data.amount..Loc[Config.Lan].success["charge_end"], "error", data.biller)
|
||||
triggerNotify(nil, locale("error", "declined_payment"), nil, src)
|
||||
triggerNotify(nil, billed.PlayerData.charinfo.firstname.." declined the $"..data.amount..locale("success", "charge_end"), "error", data.biller)
|
||||
end
|
||||
end)
|
||||
|
||||
|
||||
@@ -1,120 +1,120 @@
|
||||
RegisterServerEvent(getScript()..":Tickets:Give", function(data, biller, gang)
|
||||
local src = source
|
||||
local activePlayers = GetPlayers()
|
||||
local commPercent = 0
|
||||
jsonPrint(data)
|
||||
if Config.Receipts.Jobs[data.society] then
|
||||
commPercent = Config.Receipts.Jobs[data.society].Commission
|
||||
else commPercent = 0.25
|
||||
print("^1Error^7: ^2Can't find job in ^7'^3Config^7.^3Receipts^7.^3Jobs^7', ^2defaulting to 0.25 (25% commission)^7")
|
||||
end
|
||||
local takecomm = math.floor(data.amount * commPercent)
|
||||
|
||||
if biller ~= nil then -- If this is found, it ISN'T a phone payment, so add money to society here
|
||||
local amountChange, newAmount = (data.amount - takecomm), 0
|
||||
local society = gang and tostring(biller.gang) or tostring(biller.job)
|
||||
local bankScript = nil
|
||||
if isStarted("Renewed-Banking") then
|
||||
bankScript = "Renewed-Banking"
|
||||
exports["Renewed-Banking"]:addAccountMoney(society, amountChange)
|
||||
newAmount = exports["Renewed-Banking"]:getAccountMoney(society)
|
||||
|
||||
elseif isStarted("qb-banking") then
|
||||
bankScript = "qb-banking"
|
||||
exports["qb-banking"]:AddMoney(society, amountChange, "Cash Register Payment")
|
||||
newAmount = exports["qb-banking"]:GetAccountBalance(society)
|
||||
|
||||
elseif isStarted("fd_banking") then
|
||||
bankScript = "fd_banking"
|
||||
if gang then
|
||||
exports["fd_banking"]:AddGangMoney(society, amountChange)
|
||||
newAmount = exports["fd_banking"]:GetGangAccount(society)
|
||||
else
|
||||
exports["fd_banking"]:AddMoney(society, amountChange)
|
||||
newAmount = exports["fd_banking"]:GetAccount(society)
|
||||
end
|
||||
elseif isStarted("okokBanking") then
|
||||
bankScript = "okokBanking"
|
||||
exports['okokBanking']:AddMoney(society, amountChange)
|
||||
newAmount = exports['okokBanking']:GetAccount(society)
|
||||
end
|
||||
|
||||
debugPrint("^5Debug^7: ^3"..bankScript.."^7(^3"..(gang and "Gang" or "Job").."^7): ^2Adding ^7$"..amountChange.." ^2to account ^7'^6"..society.."^7' ($"..newAmount..")")
|
||||
elseif not biller then --Find the biller from their citizenid
|
||||
for _, v in pairs(activePlayers) do
|
||||
local Player = getPlayer(v)
|
||||
if Player.citizenid == data.senderCitizenId then
|
||||
biller = Player
|
||||
end
|
||||
end
|
||||
triggerNotify(nil, data.sender..Loc[Config.Lan].success["invoice_start"]..data.amount..Loc[Config.Lan].success["invoice_end"], "success", biller.source)
|
||||
end
|
||||
|
||||
-- If ticket system enabled, do this
|
||||
if (biller.onDuty or gang) and Config.Receipts.TicketSystem then
|
||||
if data.amount >= Config.Receipts.Jobs[data.society].MinAmountforTicket then
|
||||
if Config.Receipts.TicketSystemAll then
|
||||
for _, v in pairs(activePlayers) do
|
||||
local Player = getPlayer(v)
|
||||
if v ~= src then
|
||||
if gang then
|
||||
if Player.gang == data.society then
|
||||
addItem("payticket", 1, nil, Player.source)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["rec_rec"], 'success', Player.source)
|
||||
end
|
||||
else
|
||||
print("player found")
|
||||
if Player.job == data.society and Player.onDuty then
|
||||
print("player on duty, giving tickets")
|
||||
addItem("payticket", 1, nil, Player.source)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["rec_rec"], 'success', Player.source)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
else
|
||||
addItem("payticket", 1, nil, biller.source)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["rec_rec"], 'success', biller.source)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-- Commission section, does each config option separately
|
||||
local comm = tonumber(Config.Receipts.Jobs[data.society].Commission)
|
||||
if Config.Receipts.Commission and comm ~= 0 then
|
||||
if Config.Receipts.CommissionLimit and data.amount < Config.Receipts.Jobs[data.society].MinAmountforTicket then return end
|
||||
if Config.Receipts.CommissionDouble then
|
||||
fundPlayer(math.floor(tonumber(data.amount) * (comm *2)), "bank", biller.source)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["recieved"]..math.floor(tonumber(data.amount) * (comm *2))..Loc[Config.Lan].success["commission"], "success", biller.source)
|
||||
else
|
||||
fundPlayer(math.floor(tonumber(data.amount) *comm), "bank", biller.source)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["recieved"]..math.floor(tonumber(data.amount) * comm)..Loc[Config.Lan].success["commission"], "success", biller.source)
|
||||
end
|
||||
if Config.Receipts.CommissionAll then
|
||||
for _, v in pairs(activePlayers) do
|
||||
local Player = getPlayer(v)
|
||||
if v ~= biller.source then
|
||||
if Player.job == data.society and Player.onDuty then
|
||||
fundPlayer(math.floor(tonumber(data.amount) * comm), "bank", Player.source)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["recieved"]..math.floor(tonumber(data.amount) * comm)..Loc[Config.Lan].success["commission"], "success", Player.source)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
RegisterServerEvent(getScript()..":Tickets:Sell", function() local src = source
|
||||
local Player = getPlayer(src)
|
||||
local hasItem, hasTable = hasItem("payticket", 1, src)
|
||||
if not hasItem then
|
||||
triggerNotify(nil, Loc[Config.Lan].error["no_ticket_to"], 'error', src)
|
||||
return
|
||||
else
|
||||
local tickets = hasTable["payticket"].count
|
||||
removeItem("payticket", tickets, src)
|
||||
local pay = (tickets * Config.Receipts.Jobs[Player.job].PayPerTicket)
|
||||
fundPlayer(pay, "bank", src)
|
||||
triggerNotify(nil, Loc[Config.Lan].success["trade_ticket_start"]..tickets..Loc[Config.Lan].success["trade_ticket_end"]..cv(pay), 'success', src)
|
||||
end
|
||||
RegisterServerEvent(getScript()..":Tickets:Give", function(data, biller, gang)
|
||||
local src = source
|
||||
local activePlayers = GetPlayers()
|
||||
local commPercent = 0
|
||||
jsonPrint(data)
|
||||
if Config.Receipts.Jobs[data.society] then
|
||||
commPercent = Config.Receipts.Jobs[data.society].Commission
|
||||
else commPercent = 0.25
|
||||
print("^1Error^7: ^2Can't find job in ^7'^3Config^7.^3Receipts^7.^3Jobs^7', ^2defaulting to 0.25 (25% commission)^7")
|
||||
end
|
||||
local takecomm = math.floor(data.amount * commPercent)
|
||||
|
||||
if biller ~= nil then -- If this is found, it ISN'T a phone payment, so add money to society here
|
||||
local amountChange, newAmount = (data.amount - takecomm), 0
|
||||
local society = gang and tostring(biller.gang) or tostring(biller.job)
|
||||
local bankScript = nil
|
||||
if isStarted("Renewed-Banking") then
|
||||
bankScript = "Renewed-Banking"
|
||||
exports["Renewed-Banking"]:addAccountMoney(society, amountChange)
|
||||
newAmount = exports["Renewed-Banking"]:getAccountMoney(society)
|
||||
|
||||
elseif isStarted("qb-banking") then
|
||||
bankScript = "qb-banking"
|
||||
exports["qb-banking"]:AddMoney(society, amountChange, "Cash Register Payment")
|
||||
newAmount = exports["qb-banking"]:GetAccountBalance(society)
|
||||
|
||||
elseif isStarted("fd_banking") then
|
||||
bankScript = "fd_banking"
|
||||
if gang then
|
||||
exports["fd_banking"]:AddGangMoney(society, amountChange)
|
||||
newAmount = exports["fd_banking"]:GetGangAccount(society)
|
||||
else
|
||||
exports["fd_banking"]:AddMoney(society, amountChange)
|
||||
newAmount = exports["fd_banking"]:GetAccount(society)
|
||||
end
|
||||
elseif isStarted("okokBanking") then
|
||||
bankScript = "okokBanking"
|
||||
exports['okokBanking']:AddMoney(society, amountChange)
|
||||
newAmount = exports['okokBanking']:GetAccount(society)
|
||||
end
|
||||
|
||||
debugPrint("^5Debug^7: ^3"..bankScript.."^7(^3"..(gang and "Gang" or "Job").."^7): ^2Adding ^7$"..amountChange.." ^2to account ^7'^6"..society.."^7' ($"..newAmount..")")
|
||||
elseif not biller then --Find the biller from their citizenid
|
||||
for _, v in pairs(activePlayers) do
|
||||
local Player = getPlayer(v)
|
||||
if Player.citizenid == data.senderCitizenId then
|
||||
biller = Player
|
||||
end
|
||||
end
|
||||
triggerNotify(nil, data.sender..locale("success", "invoice_start")..data.amount..locale("success", "invoice_end"), "success", biller.source)
|
||||
end
|
||||
|
||||
-- If ticket system enabled, do this
|
||||
if (biller.onDuty or gang) and Config.Receipts.TicketSystem then
|
||||
if data.amount >= Config.Receipts.Jobs[data.society].MinAmountforTicket then
|
||||
if Config.Receipts.TicketSystemAll then
|
||||
for _, v in pairs(activePlayers) do
|
||||
local Player = getPlayer(v)
|
||||
if v ~= src then
|
||||
if gang then
|
||||
if Player.gang == data.society then
|
||||
addItem("payticket", 1, nil, Player.source)
|
||||
triggerNotify(nil, locale("success", "rec_rec"), 'success', Player.source)
|
||||
end
|
||||
else
|
||||
print("player found")
|
||||
if Player.job == data.society and Player.onDuty then
|
||||
print("player on duty, giving tickets")
|
||||
addItem("payticket", 1, nil, Player.source)
|
||||
triggerNotify(nil, locale("success", "rec_rec"), 'success', Player.source)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
else
|
||||
addItem("payticket", 1, nil, biller.source)
|
||||
triggerNotify(nil, locale("success", "rec_rec"), 'success', biller.source)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-- Commission section, does each config option separately
|
||||
local comm = tonumber(Config.Receipts.Jobs[data.society].Commission)
|
||||
if Config.Receipts.Commission and comm ~= 0 then
|
||||
if Config.Receipts.CommissionLimit and data.amount < Config.Receipts.Jobs[data.society].MinAmountforTicket then return end
|
||||
if Config.Receipts.CommissionDouble then
|
||||
fundPlayer(math.floor(tonumber(data.amount) * (comm *2)), "bank", biller.source)
|
||||
triggerNotify(nil, locale("success", "recieved")..math.floor(tonumber(data.amount) * (comm *2))..locale("success", "commission"), "success", biller.source)
|
||||
else
|
||||
fundPlayer(math.floor(tonumber(data.amount) *comm), "bank", biller.source)
|
||||
triggerNotify(nil, locale("success", "recieved")..math.floor(tonumber(data.amount) * comm)..locale("success", "commission"), "success", biller.source)
|
||||
end
|
||||
if Config.Receipts.CommissionAll then
|
||||
for _, v in pairs(activePlayers) do
|
||||
local Player = getPlayer(v)
|
||||
if v ~= biller.source then
|
||||
if Player.job == data.society and Player.onDuty then
|
||||
fundPlayer(math.floor(tonumber(data.amount) * comm), "bank", Player.source)
|
||||
triggerNotify(nil, locale("success", "recieved")..math.floor(tonumber(data.amount) * comm)..locale("success", "commission"), "success", Player.source)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
RegisterServerEvent(getScript()..":Tickets:Sell", function() local src = source
|
||||
local Player = getPlayer(src)
|
||||
local hasItem, hasTable = hasItem("payticket", 1, src)
|
||||
if not hasItem then
|
||||
triggerNotify(nil, locale("error", "no_ticket_to"), 'error', src)
|
||||
return
|
||||
else
|
||||
local tickets = hasTable["payticket"].count
|
||||
removeItem("payticket", tickets, src)
|
||||
local pay = (tickets * Config.Receipts.Jobs[Player.job].PayPerTicket)
|
||||
fundPlayer(pay, "bank", src)
|
||||
triggerNotify(nil, locale("success", "trade_ticket_start")..tickets..locale("success", "trade_ticket_end")..cv(pay), 'success', src)
|
||||
end
|
||||
end)
|
||||
Reference in New Issue
Block a user