Add input handling

This commit is contained in:
schmelczerandras 2020-07-18 22:02:09 +02:00
parent 29c6b14440
commit d5be727040
36 changed files with 417 additions and 113 deletions

View file

@ -0,0 +1,7 @@
import { Typed } from '../transport/serializable';
import { Vec2 } from '../math/vec2';
export class GameObject extends Typed {
public position = new Vec2();
public boundingBoxSize = new Vec2();
}

View file

@ -0,0 +1,8 @@
import { GameObject } from './game-object';
import { Camera } from './types/camera';
export class ObjectContainer {
private objects: Array<GameObject> = [];
constructor(public camera: Camera) {}
}

View file

@ -0,0 +1,3 @@
import { GameObject } from '../game-object';
export class Camera extends GameObject {}