[READ-ONLY] Mirror of https://github.com/flo-bit/pixi-scaffold. basic pixi.js scaffold for quick testing/demoing flo-bit.github.io/pixi-scaffold/
javascript pixijs scaffold
0

Configure Feed

Select the types of activity you want to include in your feed.

JavaScript 94.8%
HTML 5.2%
Other 0.1%
26 1 0

Clone this repository

https://tangled.org/flo-bit.dev/pixi-scaffold https://tangled.org/did:plc:abxg6e45wsahjwtoiowkh4gh
git@tangled.org:flo-bit.dev/pixi-scaffold git@tangled.org:did:plc:abxg6e45wsahjwtoiowkh4gh

For self-hosted knots, clone URLs may differ based on your setup.



Readme.md

PIXI scaffold#

This is a scaffold for PIXI.js projects.

includes:

  • automatic resizing of root container (fixed size) and canvas to window size
  • keydown and keyup events
  • setup and update functions

see flo-bit.github.io/pixi-scaffold/ for a simple example.

Usage#

  • import the pixi-scaffold module
import PixiScaffold from "https://flo-bit.github.io/pixi-scaffold/pixi-scaffold.js";
  • make a game class with a setup and update function
class Game {
  setup(app) {
    // setup your game here
  }
  update(delta, total, app) {
    // update your game here
  }
}
  • call PixiScaffold.run and pass an instance of your game class
PixiScaffold.run(new Game());