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
Insurance HistoryInsurance SystemRepair Screen

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 Extensionscareermodulesinsurance

Insurance History

Tracks the player's insurance and repair history. Stores a chronological list of claims, renewals, coverage changes, and private repairs with their financial effects.

Tracks the player's insurance and repair history. Stores a chronological list of claims, renewals, coverage changes, and private repairs with their financial effects.


Public API

FunctionSignatureDescription
M.addToPlHistory(data)Adds a new entry with type, title, effects, concernedInsuranceName, overrideText, other, auto-stamps time
M.buildPlHistory() → tableReturns deep-copied history sorted newest-first, with formatted date strings
M.getPlHistory() → tableReturns raw history table reference
M.setPlHistory(history)Replaces history (used during save load)
M.initPlHistory()Clears history to empty table
M.getInsuranceClaimsCount() → numberCount of insuranceRepairClaim entries
M.getNonInsuranceRepairsCount() → numberCount of privateRepair entries
M.getTotalPremiumPaid() → numberSum of money spent on insuranceRenewed + insuranceChanged
M.getTotalInsuranceRepairDeductiblesPaid() → numberSum of all deductibles from repair claims
M.getTotalPrivateRepairsPaid() → numberSum of money spent on private repairs
M.getDamageCostCoveredByInsurance() → numberSum of all vehDamagePrice from insurance claims

History Entry Structure

{
  type = "insuranceRepairClaim",  -- or "privateRepair", "insuranceRenewed", etc.
  title = "Insurance repair claim",
  effects = {
    {type = "money", label = "Money", changedBy = -500, newValue = 12000},
    {type = "driverScore", label = "Driver score", changedBy = -1, newValue = 63}
  },
  concernedInsuranceName = "SafeDrive Insurance",
  overrideText = nil,  -- optional display override
  other = {            -- type-specific extra data
    vehDamagePrice = 2500,
    deductible = 500
  },
  time = 1700000000    -- os.time() timestamp
}

Known History Types

TypeDescription
insuranceRepairClaimVehicle repaired through insurance
privateRepairVehicle repaired out-of-pocket
insuranceRenewedInsurance policy auto-renewed
insuranceChangedSwitched insurance provider
testDriveClaimDamaged a test drive vehicle
freeRepairAccident forgiveness gesture
driverScoreIncreaseSafe driving bonus
driverScoreResetPaid to reset driver score
insuranceCoverageChangedModified coverage options

See Also

  • insurance - Main insurance system (uses history for tracking)
  • milestones/insurance - Milestones based on claim count

Delivery Vehicle Tasks

M.dependencies = {"util_stepHandler"}

Insurance System

M.dependencies = {'career_career', 'career_modules_payment', 'career_modules_playerAttributes', 'career_modules_insurance_history'}

On this page

Public APIHistory Entry StructureKnown History TypesSee Also