bolt
set 0× in templates and rigs
A lightning bolt cast along a path or at a node: a bundle of filaments whose strike front lands in `travel`, gutters through `hold` and blows out in `fade`.
bolt(beads=1 branch-angle=1 branch-dim=1)
Attributes
beadsnumberHow many beads the residual channel breaks into (default 26).0×branch-anglenumberDegrees the forks leave the channel at, give or take a third (default 38).0×branch-dimnumber0×branch-lengthnumberMultiplier on how long the forks run, 15-40% of the span at 1 (default 1).0×branch-levelnumberFork brightness as a fraction of the channel's (default 0.5).0×branch-widthnumberFork width as a fraction of the channel's (default 0.55).0×branchesnumberForks leaving the main channel, fading toward their tips (default 0, at most 16). Any of the attributes below also holds the channel still and makes it one filament with bigger kinks.0×channeltext`live` keeps the crawl and `restrike` re-rolls on top of the attributes above; the default is `fixed` once any of them is on.0×color-corecolour #rrggbb0×color-halocolour #rrggbb0×color-icecolour #rrggbbThe ice's tint (default #a8dcff).0×color-innercolour #rrggbb0×color-outercolour #rrggbb0×color-rimecolour #rrggbbIts frost and highlights (default #dff1ff).0×color-trappedcolour #rrggbbThe light inside it (default `color-outer`).0×convergenumber0×core-sharpnumber0×core-widthnumber0×crawlnumber0×crystal-densitynumberHow much of `color-ice` one crystal passes, as a power: higher is deeper (default 1.2).0×crystal-iornumberHow hard the crystals bend what is behind them; node renderer only, classic WebGL alpha-blends them (default 1.31).0×crystal-sizenumberRadius of the channel's crystals in mm; branches follow `branch-width` (default 1.3% of the span).0×everynumber0×fadenumberSeconds it takes to blow out (default 0.5).0×flickernumber0×flicker-speednumber0×floornumberThe y fallen crystals come to rest on; unset, they fall through.0×freezenumberSeconds the bolt hangs as ice: after the last stroke's `hold` a front runs back from the target and out along every branch, each segment freezing into a crystal with the light trapped inside, until it shatters from the target back to the origin (default 0, off; `true` is 2). It replaces `fade` and `residual`, keeps one fixed channel (`strands` and `channel=live` are ignored), and every stroke flashes the same forks.0×freeze-speednumberHow fast the whole lattice freezes, 1 / seconds from the target to the last tip (default 1.6).0×from"x y z"Where it leaves: `x y z` or a node's id.0×glownumber0×glow-falloffnumber0×glow-opacitynumber0×glow-widthnumber0×gravitynumbermm/s² on the thrown crystals (default 98% of the span).0×holdnumberSeconds it holds, guttering, after it lands (default 0.45).0×jitternumber0×jitter-falloffnumber0×kinksnumber0×leadernumberSeconds a dim leader creeps down in stepped jumps before the strike (default 0, off).0×leader-levelnumberHow bright the channel is until the strike lights it, 0..1 (default 0.22).0×leader-stepsnumberHow many jumps the leader makes (default 14).0×lighttrue / false`true` adds a point light riding the strike front; it is emissive only otherwise.0×light-decaynumber0×light-distancenumber0×light-intensitynumber0×looptrue / false`true` repeats the whole cast; `every` is its period in seconds.0×octavesnumber0×opacitynumber0×pathtextThe axis, `x y z; x y z; …` in mm (at least two points): leaves at the first, lands on the last.0×pinchnumber0×residualnumber0..1: over `fade` the cooling channel widens and breaks into beads (default 0, off).0×restrikenumber0×return-strokenumberSeconds the bright stroke climbs back up from the target (default 0, off); the way down is then dim.0×sagnumber0×seednumber0×shatternumber× how hard the crystals are thrown; 0 only drops them (default 1).0×shatter-spinnumberRadians a second it tumbles at (default 7).0×shatter-sweepnumberSeconds the break takes from the target to the origin (default 0.35).0×shatter-timenumberSeconds a thrown crystal lasts (default 1.4).0×spreadnumber0×spread-curvenumber0×spread-nearnumber0×spursnumber× how many rime spurs grow off the crystals (default 1).0×startnumberWhen the cast begins, seconds. A time, never a place.0×strand-flashnumber0×strandsnumber0×stroke-gapnumberSeconds the channel cools between strokes (default 0.16).0×strokesnumberFlashes down the same channel with new branches each time, sharing `hold` (default 1, at most 8). `restrike` is different: it re-rolls the shape many times a second.0×sub-branchesnumberForks leaving those forks (default 0, at most 32); alone it implies 6 branches.0×thicknessnumber0×tip-glownumber0×tip-lengthnumber0×to"x y z"textWhere it lands: `x y z`, or a node's id to land on that node's surface and size the cast to it; a keyed node is followed.0×travelnumberSeconds the strike front takes to cross the path (default 0.12).0×twistnumber0×twist-speednumber0×width-curvenumber0×width-tipnumber0×wire-aatrue / false`true`: a filament is never drawn thinner than about 1.5 px, and the width it lacks comes back as dimmer light, so a far bolt fades instead of breaking into dashes. Off by default.0×