package ru.m.puzzlez.core;

import haxework.signal.Signal;

class Game implements IGame {
    public var state(default, null):GameState;
    public var signal(default, null):Signal<GameEvent>;

    public function new(preset:GamePreset) {
        state = GameUtil.buildState(preset);
        signal = new Signal();
    }

    public function start():Void {
        signal.emit(GameEvent.START(state));
    }

    public function stop():Void {

    }

    public function dispose():Void {
        signal.dispose();
    }
}
