import { _decorator, Input, input, } from "cc";
import Scene from "db://assets/Module/Scene";


const { ccclass, property } = _decorator;


@ccclass("MainGame")
export class MainGame extends Scene {
    static bundle: string = "MainGame";
    static skin: string = "MainGame";

    onLoad() {

    }

    async start() {
        input.on(Input.EventType.TOUCH_START, this.onTouchStart, this);
        input.on(Input.EventType.TOUCH_END, this.onTouchEnd, this);
        input.on(Input.EventType.TOUCH_CANCEL, this.onTouchEnd, this);
    }

    onDestroy() {
        input.off(Input.EventType.TOUCH_START, this.onTouchStart, this);
        input.off(Input.EventType.TOUCH_END, this.onTouchEnd, this);
        input.off(Input.EventType.TOUCH_CANCEL, this.onTouchEnd, this);
    }


    onTouchStart(event: any) {

    }

    onTouchEnd(event: any) {

    }

    update(dt: number) {


    }

}
