RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

server/commands - Camera & Input Commandsge_utils - Game Engine Utility Functionsmain.lua - GE Lua Entry Point & Game Loopmap.lua - Navigation Graph (AI Road Map)screenshot.lua - Screenshot Systemserver/server - Level Loading & Game ServerserverConnection - Client-Server Connection Manager`setSpawnpoint` - Default Spawn Point Persistence`simTimeAuthority` - Simulation Time & Bullet Time Control`spawn` - Vehicle Spawning & Safe Placement`suspensionFrequencyTester` - Suspension Natural Frequency Analysis
Career BranchesCareer System CoreCareer Save System
Career Computer MenuCareer Fuel SystemInspect VehicleVehicle InventoryLinear TutorialLoaner VehiclesCareer LogLogbookMarketplaceMission WrapperCareer Painting ModuleCareer Part Inventory ModuleCareer Part Shopping ModuleCareer Payment ModuleCareer Permissions ModuleCareer Playbook Writer ModuleCareer Player Abstract ModuleCareer Player Attributes ModuleCareer Player Driving ModuleCareer Quick Travel ModuleCareer Rentals ModuleCareer Reputation ModuleCareer Spawn Points ModuleCareer Speed Traps ModuleCareer Test Drive ModuleCareer Tether ModuleCareer Tuning ModuleCareer UI Utils ModuleCareer Unlock Flags ModuleCareer Value Calculator ModuleVehicle Class GroupingVehicle Deletion ServiceVehicle PerformanceVehicle Shopping

UI

Resources

BeamNG Game Engine Lua Cheat SheetGE Developer RecipesMCP Server Setup

// RLS.STUDIOS=true

Premium Mods for BeamNG.drive. Career systems, custom vehicles, and immersive gameplay experiences.

Index

HomeProjectsPatreon

Socials

DiscordPatreon (RLS)Patreon (Vehicles)

© 2026 RLS Studios. All rights reserved.

Modding since 2024

API ReferenceGE Extensionscareermodules

Career Payment Module

M.dependencies = {'career_career'}

Dependencies

M.dependencies = {'career_career'}

Thin payment gateway for career mode. Validates multi-currency affordability and deducts amounts via playerAttributes.


Public API

FunctionSignatureDescription
M.canPay(price) → boolChecks if player can afford the price across all currencies
M.pay(price, reason) → boolDeducts price from player attributes; returns false if insufficient funds

Dependencies

  • career_career (required)
  • career_modules_playerAttributes - attribute value queries and mutations

Price Format

Price is a table keyed by currency name. Each entry has amount and optional canBeNegative:

local price = {
  money = {amount = 500, canBeNegative = false},
  -- can include other currencies:
  -- someOrgReputation = {amount = 10, canBeNegative = true},
}

When canBeNegative is true (or absent), the check is skipped for that currency-allowing the balance to go negative.

Usage Example

local price = {money = {amount = 1500, canBeNegative = false}}

if career_modules_payment.canPay(price) then
  career_modules_payment.pay(price, {
    label = "Bought new engine",
    tags = {"partsBought", "buying"}
  })
end

Internal Flow

  1. canPay iterates each currency key in price
  2. Skips check if canBeNegative is true or amount ≤ 0
  3. Compares against playerAttributes.getAttributeValue(currency)
  4. pay calls playerAttributes.addAttributes with negated amounts

See Also

  • playerAttributes - Underlying attribute storage
  • partShopping - Uses payment for part purchases
  • painting - Uses payment for paint jobs

Career Part Shopping Module

Interactive part shop UI for buying, swapping, and removing vehicle parts at garage computers. Maintains a preview vehicle, shopping cart with 7% sales tax, and inventory-part reuse. Uses a tether sys

Career Permissions Module

Centralized permission system for career actions. Other modules hook into `onCheckPermission` to grant or restrict actions based on active gameplay state (e.g., missions, deliveries, tutorials).

On this page

DependenciesPublic APIDependenciesPrice FormatUsage ExampleInternal FlowSee Also