22 lines
No EOL
2.1 KiB
HTML
22 lines
No EOL
2.1 KiB
HTML
<!doctype html>
|
||
<html lang="en">
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||
<title>Fx — Ludic</title>
|
||
<meta name="description" content="Engine-owned transient effects.">
|
||
<link rel="stylesheet" href="base.css">
|
||
<link rel="stylesheet" href="docs.css">
|
||
</head>
|
||
<body>
|
||
<header class="nav"><div class="wrap nav-in"><a class="brand" href="index.html"><span class="logo">L</span> Ludic</a><button class="nav-toggle" aria-label="Toggle menu" aria-expanded="false">☰</button><nav class="nav-links"><a href="index.html">Home</a><a href="api.html">API Reference</a><a class="nav-cta" href="https://git.workshopsoft.io/workshopsoft/ludic">Source ↗</a></nav></div></header>
|
||
<main class="wrap item">
|
||
<div class="crumbs"><a href="api.html">API Reference</a> <span>›</span> <span class="here">Fx</span></div>
|
||
<div class="item-head"><span class="kind-badge kind-namespace">namespace</span><h1 id="top">Fx</h1></div>
|
||
<p class="ns-blurb">Engine-owned transient effects. A game asks for a burst of sparks or a floating number and the engine owns the rest: it moves and ages them every Update, draws them every Render after the sprites (through the camera, shake and clip), and drops them when they expire. Nothing is an entity, so a hit effect needs no component, model, handler or draw call. Velocities and lifetimes come from the seeded RNG, so a replay produces the same sparks.</p>
|
||
<div class="ns-methods"><a class="ns-method" href="fx-sparks.html"><code class="nm-sig">Fx.sparks(x: px, y: px, color: c, count: n)</code><span class="nm-tip">A burst of sparks flying out of a point.</span></a><a class="ns-method" href="fx-number.html"><code class="nm-sig">Fx.number(x: px, y: px, value: n, color: c)</code><span class="nm-tip">A number that floats up from a point and fades.</span></a><a class="ns-method" href="fx-clear.html"><code class="nm-sig">Fx.clear()</code><span class="nm-tip">Drop every spark and number at once.</span></a></div>
|
||
<a class="back" href="api.html">← All symbols</a>
|
||
</main>
|
||
<script src="ludic-highlight.js"></script>
|
||
<script>Ludic.installCards(); Ludic.flashTarget();</script>
|
||
</body></html> |