Big Map Marker
Marker class for the big map view. Renders a floating icon with a column below it, using `BeamNGWorldIconsRenderer`. Handles alpha smoothing, selection/hover states, and multi-POI clustering.
Marker class for the big map view. Renders a floating icon with a column below it, using BeamNGWorldIconsRenderer. Handles alpha smoothing, selection/hover states, and multi-POI clustering.
Class Methods
| Method | Signature | Description |
|---|---|---|
C:init | () | Assigns unique id, creates alpha smoother |
C:setup | (cluster) | Positions marker, creates icon + column in renderer, initializes smoothers |
C:update | (data) | Applies camera-relative positioning, alpha fade, selection/hover scaling |
C:setFullAlphaInstant | () | Sets alpha smoother to 1 immediately |
C:hide | () | Sets visible = false |
C:show | () | Sets visible = true |
C:clearObjects | () | Removes icons from renderer |
Module Functions
| Function | Signature | Returns | Description |
|---|---|---|---|
createMarker | (...) | marker | Creates a new bigmap marker instance |
merge | (pois, idPrefix) | cluster | Merges multiple POIs into a single cluster with count icon |
Internals
Icon Rendering
Uses BeamNGWorldIconsRenderer (singleton markerIconRenderer) with atlas iconAtlas.png. Two icons per marker:
- Main icon: The POI-type icon (e.g.
mission_primary_triangle) - Column icon:
marker_columnrendered below the main icon
Camera-Relative Positioning
Icons are positioned relative to the camera using quaternion rotation from camera axes. This ensures consistent screen placement regardless of camera distance. The resolutionFactor adjusts for vertical resolution differences.
Selection States
self.selected: POI is selected in big mapself.hovered: POI is hovered in big mapself.hoveredListItem: POI is hovered in list- Selected/hovered markers get
customSizeFactor = 1.5
Clustering (merge)
When multiple POIs overlap, merge() averages positions and creates a numbered icon:
- Missions only:
poi_no-XX_round_orange_blue - Mixed/delivery with cargo:
poi_no-XX_round_orange - Default:
poi_no-XX_round_orange_green
Count capped at 9.
Tutorial Bounce
If career_modules_linearTutorial.bounceBigmapIcons is set, icons bounce with a bounce() easing function.
How It Works
setup(cluster)creates icons in the world renderer at the cluster positionupdate(data)each frame: computes camera-relative offset for icons, fades alpha based on bigmap transition state- When bigmap closes, icons smoothly fade out
- Multiple nearby POIs are merged into numbered cluster icons
See Also
- Crawl Marker - Related reference
- Drift Line Marker - Related reference
- Gas Station Marker - Related reference
- Gameplay Systems Guide - Guide
Near Pole Zone
Reference for the near-pole stunt zone class, loaded via `require("gameplay/drift/stuntZones/nearPole")`.
Crawl Marker
Marker class for rock-crawling activity zones. Renders a floating icon at a configurable position, detects sphere-overlap with the vehicle bounding box, and supports activity interaction prompts.