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
ui/ambientSound - Ambient Sound Stream PlayerUI Apps ManagerUI AudioBindings LegendCamera Distance AppConsole (consoleNG)Credits MusicExternal App (WebSocket UI Server)Fade ScreenGame BlurGameplay App ContainersGrid SelectorLivery EditorMessages DebuggerMessages/Tasks App ContainersMission InfoPolice InfoTop BarUI ModsUI Navigation / MapVehicle Paint EditorVehicle Vicinity AppUI Visibility
Vehicle Selector – Details InteractionVehicle Selector – GeneralVehicle Selector – Tile ClusteringVehicle Selector – Tile GroupingVehicle Selector – TilesVehicle Selector – Tile SortingVehicle Selector – Vehicle OperationsVehicle Selector – Vehicle Specifications

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 ExtensionsuivehicleSelector

Vehicle Selector – Tiles

Generates the grouped, clustered, and sorted tile grid for the vehicle selector.

Generates the grouped, clustered, and sorted tile grid for the vehicle selector.


Overview

ui_vehicleSelector_tiles is the tile generation engine for the vehicle selector. It converts filtered vehicle configs into grouped, clustered, sorted tile arrays for the UI grid. Supports two path types: allModels (overview with grouping) and configsForBrandSubModelOrModel (individual configs for a model).

Extension path: lua/ge/extensions/ui/vehicleSelector/tiles.lua Dependencies (require): tileSorting, tileGrouping, tileClustering, tilesModule


Exports (M)

FunctionSignatureDescription
getTiles(path, pathChanged) → groups[]Main entry: returns sorted tile groups for a path.
configToTile(config, fullName) → tileConverts a single config into a tile object.
clusterItems(configs) → clustersClusters configs using current display mode.
overrideDefaultSelectedTile(tile)Forces a specific tile to be pre-selected.
onExtensionLoaded()Creates the tilesModule instance.
emptyProfiler()Returns a no-op profiler instance.

Re-exported from submodules

getClusteredItemsFavouriteIconPercent, getClusteredItemsStats, getSources, sortByNameButOtherAlwaysLast, sortByValue, sortByYears, groupModeFunctions, getConfigOrModelPropValue


Internals

Path Handlers

allModels

  1. Filters all configs through passesFilters.
  2. Groups configs by the current group mode (Type, Brand, etc.) via tileGrouping.
  3. Clusters configs within each group via tileClustering.
  4. Creates tiles from clusters (or directly for unclustered favourites/recent).
  5. Sorts tiles per group (automatic or user-selected mode).
  6. Adds special Favourites/Recent groups with appropriate sorting.

configsForBrandSubModelOrModel

  1. Iterates configs for a specific model.
  2. Filters by submodel, brand, auxiliary, and current filters.
  3. Optionally filters by Favourites/Recent group context.
  4. Converts each matching config to a tile via configToTile.
  5. Sorts and sets default selection.

configToTile

Creates a tile with:

  • key - "modelKey/configKey"
  • name - Configuration name or full name
  • preview, model_key, config_key, configType
  • showDetails / doubleClickDetails - for UI interaction
  • Performance stats, favourite/recent indices, source icons

tilesModule Instance

On onExtensionLoaded, creates a generic tilesModule instance configured with vehicle-specific handlers, clustering, grouping, sorting, data source, and filter functions.


How It Works

  1. UI calls getTiles({keys: ["allModels"]}) or getTiles({keys: ["configsForBrandSubModelOrModel", model, ...]}).
  2. The appropriate path handler filters, groups, clusters, and sorts configs.
  3. Returns an array of group objects, each containing sorted tiles.
  4. The UI renders the tile grid from these groups.

Lua Examples

-- Get tiles for the overview
local groups = extensions.ui_vehicleSelector_tiles.getTiles(
  {keys = {"allModels"}}, true
)

-- Convert a single config to a tile
local tile = extensions.ui_vehicleSelector_tiles.configToTile(myConfig, true)

Hooks

HookWhen
onVehicleSelectorGetTiles (ext)Config path handler starts (with model/sub/brand/group params)

Additional Exports

The following exports are available but not yet documented in detail:

  • M.clusterItems
  • M.configToTile
  • M.emptyProfiler
  • M.getClusteredItemsFavouriteIconPercent
  • M.getClusteredItemsStats
  • M.getConfigOrModelPropValue
  • M.getSources
  • M.getTiles
  • M.groupModeFunctions
  • M.onExtensionLoaded
  • M.overrideDefaultSelectedTile
  • M.sortByNameButOtherAlwaysLast
  • M.sortByValue
  • M.sortByYears

Vehicle Selector – Tile Grouping

Assigns vehicle configs to display groups (Type, Brand, Country, Value, Years, etc.).

Vehicle Selector – Tile Sorting

Sorting functions for vehicle selector tiles by various criteria.

On this page

OverviewExports (M)Re-exported from submodulesInternalsPath HandlersallModelsconfigsForBrandSubModelOrModelconfigToTiletilesModule InstanceHow It WorksLua ExamplesHooksAdditional Exports