Interactive button library for pixi.js
pixijs-basic-button depend on pixi.js
npm install pixi.js --save-dev
and
npm install @masatomakino/pixijs-basic-button.git --save-dev
pixijs-basic-button is composed of ES6 modules and TypeScript d.ts files.
At first, import classes.
import { BasicClickButton } from "@masatomakino/pixijs-basic-button";
import { Assets, Sprite } form "pixi.js"
await Assets.load(bitmapURL);
const button = new BasicClickButton({
normal: Sprite.form(bitmapURL),
});
stage.addChild(button);