BRB Advanced Banking System

🏦 BRB Advanced Banking System - Installation Guide

This documentation will guide you through installing and configuring the banking system on your RedM server using the VORP framework.


📁 1. Upload the Files

  1. Place the brb-advanced-banking folder into your server's resources directory:

resources/[scripts]/brb-advanced-banking
  1. Add the following line to your server.cfg:

ensure brb-advanced-banking

⚙️ 2. Required Dependencies

Ensure the following scripts are already installed and working:

  • vorp_core

  • vorp_menu

  • vorp_inputs

  • oxmysql (or ghmattimysql)

  • redm_interact (recommended for NPC interaction)


🗃️ 3. SQL Database Setup

Run the following SQL queries in your database to create the necessary tables:


CREATE TABLE IF NOT EXISTS `bank_accounts` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `charidentifier` varchar(50) DEFAULT NULL,
  `account_name` varchar(100) NOT NULL,
  `balance` int(11) DEFAULT 0,
  `is_interest_account` tinyint(1) DEFAULT 0,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=38 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci;

CREATE TABLE IF NOT EXISTS `bank_transactions` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `account_id` int(11) NOT NULL,
  `charidentifier` varchar(50) NOT NULL,
  `player_name` varchar(100) NOT NULL,
  `transaction_type` varchar(50) NOT NULL,
  `amount` int(11) NOT NULL,
  `transaction_date` timestamp NULL DEFAULT current_timestamp(),
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=67 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci;


CREATE TABLE IF NOT EXISTS `business_accounts` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `business_name` varchar(50) NOT NULL DEFAULT '0',
  `balance` double DEFAULT 0,
  `created_at` timestamp NULL DEFAULT current_timestamp(),
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci;


CREATE TABLE IF NOT EXISTS `business_auth` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `business_id` int(11) NOT NULL,
  `charidentifier` varchar(50) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci;


CREATE TABLE IF NOT EXISTS `business_transactions` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `account_id` int(11) NOT NULL,
  `charidentifier` varchar(50) NOT NULL,
  `player_name` varchar(100) NOT NULL,
  `transaction_type` varchar(50) NOT NULL,
  `amount` int(11) NOT NULL,
  `transaction_date` timestamp NULL DEFAULT current_timestamp(),
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=66 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci;

🧩 4. Config Settings (config.lua)

Configure the script behavior through config.lua.



Config = {}

Config.Language = "en"
Config.Ped = "s_m_m_bankclerk_01"  
Config.BusinessOwnerGrade = 3  
Config.TransactionHistoryLimit = 20 
Config.InterestRate = 0.02 
Config.InterestInterval = 43200 
Config.InterestRate = 0.02 
Config.InterestInterval = 43200
Config.Blips = {
    Name = "Bank"
}

Config.AllowedBusinessJobs = {
    doctor = 3,  
    sheriff = 3,
    blacksmith = 2
}


Config.Tax = {
    personal = {
        enabled = true,
        percent = 10
    },
    business = {
        enabled = true,
        percent = 5
    },
    credit = {
        enabled = true,
        percent = 15
    }
}

Config.DailyTax = {
    enabled = true,
    intervalMinutes = 43200,
    personal = {
        enabled = true,
        percent = 3
    },
    business = {
        enabled = true,
        percent = 2
    },
    credit = {
        enabled = true,
        percent = 5
    }
}

Config.Banks = {
    {
        name = "Valentine Bank",
        BankLocation = {x = -308.77, y = 775.31, z = 118.70, heading = 90.0},
        NpcModel = "U_M_M_BwmStablehand_01",
        NpcPosition = {x = -308.1, y = 773.98, z = 118.7, h = 11.75},
        blipAllowed = true,
        distOpen = 2.0
    },
    {
        name = "Saint Denis Bank",
        BankLocation = {x = 2644.93, y = -1292.26, z = 52.25, heading = 180.0},
        NpcModel = "U_M_M_BwmStablehand_01",
        NpcPosition = {x = 2644.93, y = -1292.26, z = 52.25, h = 180.0},
        blipAllowed = true,
        distOpen = 2.0
    }
}

```

💬 5. Language Support (lang.lua)

This system supports multi-language strings via lang.lua. Available translations include:

  • en – English

  • tr – Turkish

You can switch the language from config.lua by changing Config.Language.


👤 6. NPCs and Interaction

  • Customize NPCs and bank locations via Config.Banks.

  • NPCs will automatically appear at the specified coordinates with prompts and animations.

  • Players can interact with them using E.


📈 7. Features Summary

✅ Multi-account support ✅ Interest accounts ✅ Transaction logging ✅ Business banking with role-based access ✅ Configurable tax system (withdrawal, deposit, daily tax) ✅ Blip and NPC integration ✅ Menu-based interface (no UI required) ✅ Multi-language support


❓ FAQ

Q: Can players open multiple interest accounts? A: No, each character can only have one interest account to maintain economic balance.

Q: We use multi-character. Will each character have separate bank data? A: Yes. The system uses charidentifier to store data, ensuring each character has their own unique accounts.


📢 Support

Having issues? Reach out to us via:

  • Discord Support Server

We’re here to help!

Last updated