HELLO THREADS

par davidnurdin · Démos et expériences
pas encore noté
▶ Jouer Sources Éditer GitHub
games/hello-threads / config / game.yaml · commit 8d554d3
# Hello Threads: the "hello world" of JumPHP\Async. A fractal computed by worker threads while the game# keeps running at full speed. Every key is optional (defaults: JumPHP\Kernel\GameConfig::DEFAULTS).game:  id: hello-threads  title: "HELLO THREADS"  version: 0.1.0  description: "A fractal computed by a pool of PHP threads (TrueAsync), while the main loop keeps drawing."  width: 320  height: 180  scale: 3  background: [10, 10, 24]  start_scene: App\Scene\TitleScene  lang: en  # PHP 8.6 ZTS + TrueAsync on the desktop (docker/desktop-async): real threads. The browser build runs the  # same code without threads (the work is spread over the frames).  runtime: async  controls: "Space: next spot. M: threads / main thread. Escape: pause."  touch: { a: Space, b: M, start: Escape }  smoke:    scene: App\Scene\FractalScene    params: { demo: true }