chore(needle): version MenuScene src/generated and stop ignoring it

Track codegen output so clones build without a local Unity export step for
those files; remove src/generated/ from Needle app .gitignore.

Made-with: Cursor
This commit is contained in:
pelpanagiotis
2026-04-20 08:00:49 +03:00
parent 3499f8257a
commit 50be1cdf35
5 changed files with 58 additions and 2 deletions

View File

@@ -1,7 +1,6 @@
**/node_modules **/node_modules
# Only ignore exported Unity assets at project root, not dist/assets/ # Only ignore exported Unity assets at project root, not dist/assets/
/assets/ /assets/
src/generated/
include/draco/ include/draco/
include/ktx2/ include/ktx2/
include/three/ include/three/

View File

@@ -0,0 +1,27 @@
/*
* Developer Information:
* This file was generated using Unity 6000.4.3f1.
* Do not modify this file manually.
* Instead of using generated code you can also load the 3D scene like this: <needle-engine src="/assets/your_glTF_name.glb"></needle-engine>
* (When you're working with Unity the glTF file name will always match your scene or prefab's name)
*/
globalThis["needle:dependencies:ready"] = import("./register_types.ts")
/** @type {string[]} */
export const needle_exported_files = new Array();
globalThis["needle:codegen_files"] = needle_exported_files;
import "../../assets/MenuScene.glb?url";
needle_exported_files.push("./assets/MenuScene.glb");
document.addEventListener("DOMContentLoaded", () =>
{
const needleEngine = document.querySelector("needle-engine");
if(needleEngine && needleEngine.getAttribute("src") === null)
{
needleEngine.setAttribute("hash", "1776659726595");
needleEngine.setAttribute("src", JSON.stringify(needle_exported_files));
}
});
console.log("Made\ with\ ♥\ by\ 🌵\ Needle\ -\ https://needle\.tools\ —\ Version\ 5\.0\.3");

View File

@@ -0,0 +1,16 @@
{
"sceneName": "Menu Scene",
"meta": null,
"absolutePath": "https://localhost:3000",
"deployOnly": false,
"needleEditor": null,
"gzip": true,
"generator": "Unity 6000.4.3f1, Needle Engine Integration @5.0.3",
"license": {
"team": "org_vl8u9dsjhx6b"
},
"allowHotReload": true,
"developmentBuild": false,
"facebookInstantGames": null,
"useRapier": true
}

View File

@@ -0,0 +1,15 @@
/* eslint-disable */
import { TypeStore } from "@needle-tools/engine"
// Import types
import { ARObjectController } from "../scripts/ARObjectController.js";
import { MenuController } from "../scripts/MenuController.js";
import { PostProcessingVolumeController } from "../scripts/PostProcessingVolumeController.js";
// Register types
export function registerTypes() {
TypeStore.add("ARObjectController", ARObjectController);
TypeStore.add("MenuController", MenuController);
TypeStore.add("PostProcessingVolumeController", PostProcessingVolumeController);
}
registerTypes();

View File

@@ -1,6 +1,5 @@
**/node_modules **/node_modules
/assets/ /assets/
src/generated/
include/draco/ include/draco/
include/ktx2/ include/ktx2/
include/three/ include/three/