fiveLib Bank
fiveLib Bank is a comprehensive banking system for FiveM servers, providing a modern UI, ATM interactions, and a unique stock market/share exchange feature.
Overview
- Modern UI: Sleek, glassmorphic design for both banks and ATMs.
- Stock Market: Integrated share exchange system where players can buy and sell stocks in major San Andreas companies.
- Transaction History: Keeps track of the last 30 transactions (deposits, withdrawals, transfers).
- Multi-Location: Supports all major Fleeca and Maze Bank locations by default.
Features
- ATM Support: Players can interact with any ATM object on the map.
- Share Exchange: Real-time price updates for stocks (ticker codes like BOMW, LSC, PDM, etc.).
- Transfers: Send money to other players via their ID or citizenid.
- Blips: Automated blips for all bank locations.
- Optimized: High-performance code with minimal resmon impact.
Requirements
- Framework: QB-Core / Qbox
- Database:
oxmysql - Interactions:
qb-target/ox_target(Optional, supports 3D markers as fallback).
Installation
- Upload: Move the
fiveLib-bankfolder into your server'sresourcesdirectory. - Database: Import the provided SQL file:
# Use your database manager to import:servers/fiveLib-Bank/sql/banking.sql
- Register: Add the following to your
server.cfg:ensure fiveLib-Bank - Configure: Open
config.luato adjust settings before starting the resource. - Restart: Restart your server or run
ensure fiveLib-Bankin the console.
Configuration
Settings are handled in config.lua. Key options include:
Settings
Target: Enable or disable target system (set tofalsefor 3D markers).Key: Interact key (default:38for E).ShareExchange: Toggle the entire stock market system.
Share Market
UpdateInterval: How often stock prices fluctuate (in minutes).List: Configure available stocks, their ticker codes, base prices, and volatility.
Map Blips
Sprite,Color,Scale: Customize how banks appear on the map.
Locations
BankZones: List of coordinates where players can access banking services.ATMObjects: List of ATM models and their corresponding animations.
Framework Support
Currently optimized for QB-Core and Qbox.
Events
fiveLib-bank:client:OpenMenu: Opens the main banking menu.fiveLib-bank:client:OpenATM: Opens the ATM interface.
SQL Setup
This resource requires the following tables in your database (created via banking.sql):
fivelib_bank: Stores player asset ownership.fivelib_share_market: Stores current stock values and changes.bank: Stores transaction history (modified to support sender/target columns).
Usage
- Bank: Walk up to a bank teller or target point and press E (or use target).
- ATM: Approach any ATM on the map and interact.
- Transfers: Use the "Transfer" tab in the UI to send money to other players.
- Stocks: Use the "Exchange" tab to invest your money in companies.