Lightning
Full-scene lightning flashes with timing, tint, duration, and audio-aware controls.
Environmental filters change the Scene surface or atmosphere. They can cover the full Scene, be limited to Regions, and be moved within the effect stack.
| Reference | Value |
|---|---|
| Package | FXMaster |
| Effect kind | Filter effect |
| Category | Environmental |
| Runtime type | lightning |
| Exposed parameters | 16 |
Important controls
Section titled “Important controls”- Period: Sets the approximate time between automatic lightning flashes. Higher values create longer gaps between flashes.
- Duration: Sets how long each lightning flash remains visible before fading out.
- Brightness: Controls how strongly each lightning flash brightens the rendered scene.
- Audio Aware: Allows bass-heavy audio peaks to trigger Lightning. Use Audio Channels to choose what it listens to and Audio Bass Threshold to control sensitivity.
Setup notes
Section titled “Setup notes”- Period controls the spacing between automatic events, while Duration controls each flash.
- Audio Aware can trigger from selected audio channels when the bass threshold is met.
- Keep Brightness conservative on already bright maps to avoid washing out large portions of the Scene.
Bundled preset usage
Section titled “Bundled preset usage”| Preset | API name | Availability | Variants |
|---|---|---|---|
| Hurricane | hurricane |
FXMaster, FXMaster+ | Normal, Top Down |
| Thunderstorm | thunderstorm |
FXMaster, FXMaster+ | Normal, Top Down |
Parameters
Section titled “Parameters”The table combines the settings available for this effect in Scene and Region contexts. Scene-only and Region-only badges identify controls limited to one context. Hover or focus an info button to see what the parameter changes on the canvas. Select it to keep the card open. Each card also includes the default, range or choices, context, availability, API key, and control type.
lightning API typeHover or focus an info button to see what the parameter changes on the canvas. Select it to keep the card open. Context badges identify Scene-only and Region-only controls; unbadged parameters are available in both. Hover or focus an availability condition to highlight the parameter that controls it.
| Parameter | Control | Default | Range or choices | Availability |
|---|---|---|---|---|
Below Tokens belowTokens | checkbox | Off | — | Always |
Below Tiles belowTiles | checkbox | Off | — | Always |
Below Foreground belowForeground | checkbox | Off | — | Always |
Levels levelsScene only | scene-levels | All Levels | — | Always |
Tint color | color | #ffffff (disabled) | — | Always |
Sound FX soundFxEnabled | checkbox | Off | — | Always |
Sound FX Sounds soundFxManualSoundIds | multi-select | Rule default | — | |
Period frequency | range | 5000 | 100–30000 · step 100 | |
Duration spark_duration | range | 300 | 100–2000 · step 5 | Always |
Brightness brightness | range | 1.3 | 0–4 · step 0.1 | Always |
Audio Aware audioAware | checkbox | Off | — | Always |
Audio Channels audioChannels | multi-select | Environment | Music, Environment, Interface | |
Audio Bass Threshold audioBassThreshold | range | 0.75 | 0–1 · step 0.01 | |
Darkness Activation darknessActivationEnabled | checkbox | Off | — | Always |
Darkness Activation Range darknessActivationRange | range-dual | {"min":0,"max":1} | 0–1 · step 0.01 | |
Edge Fade % fadePercentRegion only | range | 0 | 0–1 · step 0.01 | Always |
Direct-effect API example
Section titled “Direct-effect API example”The Direct Effect API creates a separate row shown through Manage API Effects. Add a stable apiMacro_…_p or apiMacro_…_f ID when later macro calls need to update or stop the same row.
const created = await FXMASTER.api.effects.play({ filters: [{ "id": "apiMacro_wikilightning_f", "type": "lightning", "options": { "color": { "apply": false, "value": "#ffffff" }, "frequency": 0.5, "spark_duration": 0.5, "brightness": 1 } }],});
await FXMASTER.api.effects.filters.stop(created.filters);For complete API behavior, scene targeting, stack ordering, and toggle groups, see the Direct Effect API guide.