<template>
	<PolygonjsScene
		:loadFunction="loadFunction"
		:sceneName="'scene_01'"
		@sceneready="onSceneReady"
		:baseUrl="BASE_URL"
	/>
</template>

<script lang="ts">
import { defineComponent, computed } from "vue";
import { PolygonjsScene } from "@polygonjs/vue3";
import { loadScene_scene_01 } from "./scene_01/autogenerated/loadScene";
import type { PolySceneWithNodeMap_scene_01 } from "./scene_01/autogenerated/PolySceneWithNodeMap";

const BASE_URL = import.meta.env.BASE_URL;

export default defineComponent({
	name: "scene-01",
	components: {
		PolygonjsScene,
	},
	setup() {
		let scene: PolySceneWithNodeMap_scene_01 | undefined;

		function onSceneReady(loadedScene: PolySceneWithNodeMap_scene_01) {
			scene = loadedScene;
		}
		const loadFunction = computed(() => loadScene_scene_01);

		return {
			loadFunction,
			onSceneReady,
			BASE_URL,
		};
	},
});
</script>

<style></style>
