API ReferenceGE Extensionsfreeroam
Freeroam Organizations
Loads and manages organization data used in career mode. Organizations have reputation levels, associated facilities, and delivery capabilities.
Loads and manages organization data used in career mode. Organizations have reputation levels, associated facilities, and delivery capabilities.
Public API
| Function | Signature | Returns | Description |
|---|---|---|---|
M.getOrganizations | () | table | Returns all organizations keyed by ID |
M.getOrganization | (id) | table|nil | Returns a single organization with fresh reputation data |
M.getOrganizationIdOrderAndIcon | (id) | number, string | Returns sort order (7000) and icon ("peopleOutline") |
M.getUIData | () | table | Returns all organizations formatted for UI display |
M.getUIDataForOrg | (orgId) | table|nil | Returns a single organization formatted for UI |
Organization Data Structure
{
id = "orgId",
name = "Organization Name",
visible = true, -- has the player interacted with this org?
attributeKey = "orgIdReputation",
reputation = {
level = 2,
value = 150,
max = 1000, -- from reputation module
min = -1000,
label = "Trusted"
},
reputationLevels = { -- array of level definitions
{ unlocks = { ... } }
},
offersDeliveries = true,
hasUnlocks = true,
associatedFacilities = { ... }
}How It Works
- Loading:
getOrganizations()scansgameplay/organizations/*.organizations.jsonfiles - Enrichment: Each organization gets reputation data from
career_modules_reputationand visibility fromcareer_career.hasInteractedWithOrganization() - UI Data:
getUIDataForOrg()adds min/max/label for reputation, checks delivery capabilities, identifies associated facilities - Delivery Check: Iterates
deliveryProviderfacilities to find those withparcelDeliveryorvehicleDeliverysystems
Usage Examples
-- Get all organizations
local orgs = freeroam_organizations.getOrganizations()
-- Get UI-ready data for a specific org
local uiData = freeroam_organizations.getUIDataForOrg("belasco_corp")
-- Get all organizations sorted for UI
local allUiData = freeroam_organizations.getUIData()
-- Sorted alphabetically by nameNotes
- Organizations are cached after first load
- Reputation data refreshed on each
getOrganization()call - Reputation level labels come from
career_modules_reputation.getLabel() getOrganizationIdOrderAndIconreturns fixed values - all orgs share the same base sort order
See Also
- Freeroam Big Map Markers - Related reference
- Freeroam Big Map Mode - Related reference
- Freeroam Big Map POI Provider - Related reference
- Freeroam Guide - Guide
Freeroam Level Stats
Tracks and persists usage statistics for levels and spawn points. Records spawn counts and timestamps, provides sorted top-level and top-spawn-point queries.
Freeroam Special Triggers
Event-driven system for toggling scene objects (statics, lights) when vehicles enter/exit BeamNGTriggers or site zones. Supports delayed activation, random ordering, nested SimGroups, and Lua command