Shared Scripts
The built-in rr/shared pack ships a handful of ready-made Relay scripts that any pack can reuse instead of writing its own. rr/shared always loads before every other pack, so these are safe to depend on without listing rr/shared explicitly.
Script components
Section titled “Script components”Attach these via a Script component’s scriptAsset field.
| Script | Purpose |
|---|---|
rr/EnableComponentsPropertyEquals | Enables/disables a set of components based on whether a property equals a given value. See Toggleable Components. |
rr/PaintMapRendererGroup | Drives a RendererGroup’s paint-map material from the car’s resolved style. See Paint Maps. |
rr/PaintMapDecal | Drives one or more image Decals (e.g. heralds) from the car’s resolved style. See Paint Maps. |
Importable helpers
Section titled “Importable helpers”Import these with from "rr/<name>" import <function> and call the function directly, rather than attaching them as a component.
rr/PaintMap
Section titled “rr/PaintMap”Low-level paint-map helpers used internally by rr/PaintMapRendererGroup and rr/PaintMapDecal. Only import this directly if you need to coordinate multiple paint-map layers yourself; see Paint Maps.
applyPaint(group, style)— drives a RendererGroup component’s paint-map shader from a resolved style.applyPaintMapDecal(decal, style)— drives a decal’s paint-map material from a resolved style.
© 2026 Giraffe Lab LLC. All rights reserved.