import { _decorator, Component, Node, Prefab, instantiate } from 'cc';
const { ccclass, property } = _decorator;

@ccclass('NewComponent')
export class NewComponent extends Component {
    @property(Prefab) mapPrefab: Prefab = null;
    start() {
        this.node.addChild(instantiate(this.mapPrefab));
    }

    update(deltaTime: number) {

    }
}

