Update to use new sdf-2d API
This commit is contained in:
parent
41ea5d7db9
commit
f0a9c1df68
13 changed files with 38 additions and 41 deletions
|
|
@ -1,9 +1,10 @@
|
|||
import { vec2 } from 'gl-matrix';
|
||||
import { Droplet } from 'sdf-2d';
|
||||
import { DropletFactory } from 'sdf-2d';
|
||||
import { Random } from '../../helper/random';
|
||||
|
||||
export const Droplet = DropletFactory(1);
|
||||
export class DropletWrapper {
|
||||
public readonly drawable: Droplet;
|
||||
public readonly drawable: InstanceType<typeof Droplet>;
|
||||
|
||||
private speed = Random.getRandom() * 0.2 + 0.2;
|
||||
private position = vec2.fromValues(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue