Fast 1kb sprites system with webgl.
- 🍃 Minimal, gzip just 1kb
- 🌀 High Performance, 60 FPS
import { create } from './src/index.js'
const stage = create('#canvas')
const sprite = stage.add('hj.png')
function loop() {
sprite.x = Math.random() * stage.gl.canvas.width
sprite.y = Math.random() * stage.gl.canvas.height
stage.draw()
requestAnimationFrame(loop)
}
loop()
logo 不是鸟,是鸡,好吧也是鸟,反正就是那个地方,你懂的