RPSync Banking
RPSync Banking
Section titled “RPSync Banking”A complete, self-contained ESX banking system. No external CDN dependencies, no build step — pure Lua + HTML/CSS/JS, ready to drop into any ESX Legacy server.
✨ Features
Section titled “✨ Features”Core Features
Section titled “Core Features”- RP-first account opening at a configurable flagship branch (short camera + animation sequence), first card free
- Deposit / withdraw / transfer by account number — transfers work even if the recipient is offline
- Transaction history with pagination
- Optional card PIN, required at ATMs
- ATMs (any nearby
prop_*_atm*prop) + physical branches with NPCs and blips, fully configurable inconfig.lua - French and English included — add more by copying
locales/en.lua
Reliability
Section titled “Reliability”- The money itself still lives in the standard ESX
bankaccount, so this resource stays compatible with every other script that already pays into or reads from it (jobs, shops, other scripts usingxPlayer.getAccount) - This resource only adds an ownership/RP layer (account number, PIN, gate)
on top of it — it never touches the existing
userstable schema
🔒 Security
Section titled “🔒 Security”- Client logic (
client/main.lua) and server logic (server/main.lua) are encrypted on publication config.lua,locales/*.lua,html/index.html,html/css/*.cssandsql/*.sqlstay editable- Escrow protection for UI files
📋 Requirements
Section titled “📋 Requirements”Before installing make sure your server has:
- FiveM server running
- ESX Legacy framework
- oxmysql installed
- Basic server knowledge
📦 Installation
Section titled “📦 Installation”Step 1 — Download
Section titled “Step 1 — Download”Download the script from your Tebex purchase.
Extract the archive to:
resources/rpsync_banking
Step 2 — Database
Section titled “Step 2 — Database”Run sql/install.sql against your database. It only adds two new tables —
rpsync_banking_accounts and rpsync_banking_transactions — and never
touches the existing users table schema.
Step 3 — Add to server.cfg
Section titled “Step 3 — Add to server.cfg”setr rpsync_banking:locale "fr" -- or "en"ensure rpsync_bankingStep 4 — Disable your previous banking resource
Section titled “Step 4 — Disable your previous banking resource”Only one banking system should manage the ESX bank account. Comment out
ensure esx_banking (or equivalent) to avoid two systems fighting over the
same account.
Step 5 — Restart server
Section titled “Step 5 — Restart server”Restart the resource:
restart rpsync_banking
or restart the entire server.
Step 6 — Test the script
Section titled “Step 6 — Test the script”Go to the flagship branch (Flagship = true in config.lua, Pacific
Standard by default) and open an account, or walk up to any nearby ATM
prop.
⚙️ Configuration
Section titled “⚙️ Configuration”All configuration is located in:
config.lua
Language
Config.Locale = GetConvar('rpsync_banking:locale', 'en') -- 'en' or 'fr'Set via server.cfg:
setr rpsync_banking:locale "fr"Available languages: en, fr — add more by copying locales/en.lua.
Bank name
Section titled “Bank name”Config.BankName = 'Norevyn Bank' -- Displayed everywhere: UI, card, notificationsAccount opening
Section titled “Account opening”Config.RequireAccountOpening = truetrue— the RP flow: a player cannot deposit / withdraw / transfer / check their balance until they’ve physically opened an account at the flagship branch. Every other branch/ATM redirects them there.false— every player is considered to already have an account, like a normal ESX server.
Config.ReplacementCardPrice = 500 -- price of a *second* card (lost/stolen)Config.OpeningCutsceneDuration = 3500 -- ms, camera + animation before the welcome screenReplacementCardPrice isn’t wired to a command by default — it’s exposed as
an export/event for you to hook into your own item/menu.
Branches (Config.Banks)
Section titled “Branches (Config.Banks)”Exactly one entry must have Flagship = true — the only branch where an
account can be opened. Every entry defines the NPC, the marker position and
an optional blip:
{ Flagship = true, Position = vector4(248.8213, 224.4276, 106.2871, 163.3900), Ped = { Model = `U_M_M_BankMan`, Position = vector4(248.8213, 224.4276, 106.2871, 163.3900), Scenario = 'WORLD_HUMAN_CLIPBOARD' }, Blip = { Enabled = true, Sprite = 108, Color = 45, Scale = 0.9, Label = 'Norevyn Bank — Agence principale' },}Add or remove branches freely — only the Flagship one is special.
Config.EnableAtms = trueConfig.AtmModels = { `prop_fleeca_atm`, `prop_atm_01`, `prop_atm_02`, `prop_atm_03` }Config.AtmInteractionDistance = 2.0No config list needed — the script detects any nearby prop matching one of
AtmModels, which already covers the hundreds scattered around the map.
Config.MarkerDistance = 12.0Config.InteractionDistance = 2.5Limits & PIN
Section titled “Limits & PIN”Config.MinTransactionAmount = 1Config.MaxTransactionAmount = 500000 -- per single deposit/withdraw/transfer, 0 = unlimitedConfig.PinCodeLength = 4The PIN is optional for players, but required at ATMs once set.
Transfers
Section titled “Transfers”Config.PreventSelfTransfer = trueTransfers are made by account number and work whether the recipient is
online or not. Recommended to keep true so players can’t transfer to
their own account number.
History
Section titled “History”Config.HistoryRetentionDays = 60 -- old transactions purged after this many days, 0 = keep foreverConfig.HistoryPageSize = 15 -- rows loaded per page in the "full history" view🐛 Debug
Section titled “🐛 Debug”Config.Debug = falsePrints your live distance to the nearest configured branch in the F8 console every second, client-side. Turn on if a branch/ATM never seems to trigger the interaction prompt — it tells you exactly how far off your configured coordinates are from where the player actually stands.
🔌 For other resources
Section titled “🔌 For other resources”All four exports work whether the target player is online or not:
exports.rpsync_banking:HasAccount(identifier)exports.rpsync_banking:GetBalance(identifier)exports.rpsync_banking:AddMoney(identifier, amount)exports.rpsync_banking:RemoveMoney(identifier, amount)exports.rpsync_banking:GetCardNumber(identifier)🧑💻 Player Usage
Section titled “🧑💻 Player Usage”Players must:
- Go to the flagship branch to open an account (first card is free)
- Use any other branch or a nearby ATM to deposit / withdraw / transfer
- Set a PIN from the UI — required at ATMs once set
- Transfer to another player using their account number, online or not
🐛 Troubleshooting
Section titled “🐛 Troubleshooting”Branch/ATM prompt never appears
Section titled “Branch/ATM prompt never appears”Enable Config.Debug = true and check the F8 console for your live
distance to the nearest configured branch — it tells you exactly how far
off the configured coordinates are.
Two banking systems conflicting
Section titled “Two banking systems conflicting”Make sure your previous banking resource (e.g. esx_banking) is disabled
in server.cfg — only one script should manage the ESX bank account.
Balance not matching other scripts
Section titled “Balance not matching other scripts”The money lives in the standard ESX bank account
(Config.AccountName = 'bank') — any script reading/writing that account
via xPlayer.getAccount stays in sync automatically.
📊 Changelog
Section titled “📊 Changelog”1.0.0
- Initial release
- RP account opening at a configurable flagship branch
- Deposit / withdraw / transfer by account number, online or offline
- Transaction history with pagination
- Optional card PIN, required at ATMs
- Branches with NPCs/blips + automatic ATM prop detection
📞 Support
Section titled “📞 Support”Before requesting support:
- Check documentation
- Check F8 console
- Restart resource
Support channels:
📜 License
Section titled “📜 License”RPSync License
Allowed:
- Use on your server
- Modify configuration
- Modify translations
Not allowed:
- Resell
- Redistribute
- Remove escrow protection