feat: Migrate to Vite build system, update dependencies, and refine graphics setup with debugging aids.
This commit is contained in:
12
.vscode/launch.json
vendored
Normal file
12
.vscode/launch.json
vendored
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"version": "0.2.0",
|
||||||
|
"configurations": [
|
||||||
|
{
|
||||||
|
"type": "chrome",
|
||||||
|
"request": "launch",
|
||||||
|
"name": "Launch Chrome against localhost",
|
||||||
|
"url": "http://localhost:5173",
|
||||||
|
"webRoot": "${workspaceFolder}"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -8,6 +8,7 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id="game-container"></div>
|
<div id="game-container"></div>
|
||||||
|
<div id="debug-log" style="position: absolute; top: 10px; left: 10px; z-index: 999; color: lime; font-family: monospace; pointer-events: none; background: rgba(0,0,0,0.5);"></div>
|
||||||
|
|
||||||
<div id="ui-layer">
|
<div id="ui-layer">
|
||||||
<div id="start-screen">
|
<div id="start-screen">
|
||||||
|
|||||||
49
node_modules/.package-lock.json
generated
vendored
49
node_modules/.package-lock.json
generated
vendored
@@ -4,43 +4,47 @@
|
|||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"node_modules/@esbuild/darwin-x64": {
|
"node_modules/@esbuild/linux-x64": {
|
||||||
"version": "0.27.2",
|
"version": "0.27.2",
|
||||||
"resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.27.2.tgz",
|
"resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.27.2.tgz",
|
||||||
"integrity": "sha512-ZxtijOmlQCBWGwbVmwOF/UCzuGIbUkqB1faQRf5akQmxRJ1ujusWsb3CVfk/9iZKr2L5SMU5wPBi1UWbvL+VQA==",
|
"integrity": "sha512-uwp2Tip5aPmH+NRUwTcfLb+W32WXjpFejTIOWZFw/v7/KnpCDKG66u4DLcurQpiYTiYwQ9B7KOeMJvLCu/OvbA==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"linux"
|
||||||
],
|
],
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@rollup/rollup-darwin-x64": {
|
"node_modules/@rollup/rollup-linux-x64-gnu": {
|
||||||
"version": "4.54.0",
|
"version": "4.54.0",
|
||||||
"resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.54.0.tgz",
|
"resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.54.0.tgz",
|
||||||
"integrity": "sha512-cOo7biqwkpawslEfox5Vs8/qj83M/aZCSSNIWpVzfU2CYHa2G3P1UN5WF01RdTHSgCkri7XOlTdtk17BezlV3A==",
|
"integrity": "sha512-WGt5J8Ij/rvyqpFexxk3ffKqqbLf9AqrTBbWDk7ApGUzaIs6V+s2s84kAxklFwmMF/vBNGrVdYgbblCOFFezMQ==",
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"linux"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"node_modules/@types/estree": {
|
"node_modules/@types/estree": {
|
||||||
"version": "1.0.8",
|
"version": "1.0.8",
|
||||||
"resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz",
|
"resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz",
|
||||||
"integrity": "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w=="
|
"integrity": "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==",
|
||||||
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/esbuild": {
|
"node_modules/esbuild": {
|
||||||
"version": "0.27.2",
|
"version": "0.27.2",
|
||||||
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.2.tgz",
|
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.2.tgz",
|
||||||
"integrity": "sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==",
|
"integrity": "sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==",
|
||||||
"hasInstallScript": true,
|
"hasInstallScript": true,
|
||||||
|
"license": "MIT",
|
||||||
"bin": {
|
"bin": {
|
||||||
"esbuild": "bin/esbuild"
|
"esbuild": "bin/esbuild"
|
||||||
},
|
},
|
||||||
@@ -80,6 +84,7 @@
|
|||||||
"version": "6.5.0",
|
"version": "6.5.0",
|
||||||
"resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz",
|
"resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz",
|
||||||
"integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==",
|
"integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==",
|
||||||
|
"license": "MIT",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=12.0.0"
|
"node": ">=12.0.0"
|
||||||
},
|
},
|
||||||
@@ -92,19 +97,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/fsevents": {
|
|
||||||
"version": "2.3.3",
|
|
||||||
"resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz",
|
|
||||||
"integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==",
|
|
||||||
"hasInstallScript": true,
|
|
||||||
"optional": true,
|
|
||||||
"os": [
|
|
||||||
"darwin"
|
|
||||||
],
|
|
||||||
"engines": {
|
|
||||||
"node": "^8.16.0 || ^10.6.0 || >=11.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/nanoid": {
|
"node_modules/nanoid": {
|
||||||
"version": "3.3.11",
|
"version": "3.3.11",
|
||||||
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz",
|
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz",
|
||||||
@@ -115,6 +107,7 @@
|
|||||||
"url": "https://github.com/sponsors/ai"
|
"url": "https://github.com/sponsors/ai"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"bin": {
|
"bin": {
|
||||||
"nanoid": "bin/nanoid.cjs"
|
"nanoid": "bin/nanoid.cjs"
|
||||||
},
|
},
|
||||||
@@ -125,12 +118,14 @@
|
|||||||
"node_modules/picocolors": {
|
"node_modules/picocolors": {
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",
|
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",
|
||||||
"integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA=="
|
"integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==",
|
||||||
|
"license": "ISC"
|
||||||
},
|
},
|
||||||
"node_modules/picomatch": {
|
"node_modules/picomatch": {
|
||||||
"version": "4.0.3",
|
"version": "4.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz",
|
"resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz",
|
||||||
"integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==",
|
"integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==",
|
||||||
|
"license": "MIT",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
},
|
},
|
||||||
@@ -156,6 +151,7 @@
|
|||||||
"url": "https://github.com/sponsors/ai"
|
"url": "https://github.com/sponsors/ai"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"nanoid": "^3.3.11",
|
"nanoid": "^3.3.11",
|
||||||
"picocolors": "^1.1.1",
|
"picocolors": "^1.1.1",
|
||||||
@@ -169,6 +165,7 @@
|
|||||||
"version": "4.54.0",
|
"version": "4.54.0",
|
||||||
"resolved": "https://registry.npmjs.org/rollup/-/rollup-4.54.0.tgz",
|
"resolved": "https://registry.npmjs.org/rollup/-/rollup-4.54.0.tgz",
|
||||||
"integrity": "sha512-3nk8Y3a9Ea8szgKhinMlGMhGMw89mqule3KWczxhIzqudyHdCIOHw8WJlj/r329fACjKLEh13ZSk7oE22kyeIw==",
|
"integrity": "sha512-3nk8Y3a9Ea8szgKhinMlGMhGMw89mqule3KWczxhIzqudyHdCIOHw8WJlj/r329fACjKLEh13ZSk7oE22kyeIw==",
|
||||||
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/estree": "1.0.8"
|
"@types/estree": "1.0.8"
|
||||||
},
|
},
|
||||||
@@ -209,6 +206,7 @@
|
|||||||
"version": "1.2.1",
|
"version": "1.2.1",
|
||||||
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz",
|
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz",
|
||||||
"integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",
|
"integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",
|
||||||
|
"license": "BSD-3-Clause",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=0.10.0"
|
"node": ">=0.10.0"
|
||||||
}
|
}
|
||||||
@@ -216,12 +214,14 @@
|
|||||||
"node_modules/three": {
|
"node_modules/three": {
|
||||||
"version": "0.182.0",
|
"version": "0.182.0",
|
||||||
"resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz",
|
"resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz",
|
||||||
"integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ=="
|
"integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ==",
|
||||||
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/tinyglobby": {
|
"node_modules/tinyglobby": {
|
||||||
"version": "0.2.15",
|
"version": "0.2.15",
|
||||||
"resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.15.tgz",
|
"resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.15.tgz",
|
||||||
"integrity": "sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==",
|
"integrity": "sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==",
|
||||||
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"fdir": "^6.5.0",
|
"fdir": "^6.5.0",
|
||||||
"picomatch": "^4.0.3"
|
"picomatch": "^4.0.3"
|
||||||
@@ -237,6 +237,7 @@
|
|||||||
"version": "7.3.0",
|
"version": "7.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/vite/-/vite-7.3.0.tgz",
|
"resolved": "https://registry.npmjs.org/vite/-/vite-7.3.0.tgz",
|
||||||
"integrity": "sha512-dZwN5L1VlUBewiP6H9s2+B3e3Jg96D0vzN+Ry73sOefebhYr9f94wwkMNN/9ouoU8pV1BqA1d1zGk8928cx0rg==",
|
"integrity": "sha512-dZwN5L1VlUBewiP6H9s2+B3e3Jg96D0vzN+Ry73sOefebhYr9f94wwkMNN/9ouoU8pV1BqA1d1zGk8928cx0rg==",
|
||||||
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"esbuild": "^0.27.0",
|
"esbuild": "^0.27.0",
|
||||||
"fdir": "^6.5.0",
|
"fdir": "^6.5.0",
|
||||||
|
|||||||
34
node_modules/.vite/deps/_metadata.json
generated
vendored
Normal file
34
node_modules/.vite/deps/_metadata.json
generated
vendored
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
{
|
||||||
|
"hash": "77190db0",
|
||||||
|
"configHash": "0fdb68c8",
|
||||||
|
"lockfileHash": "fe3966e1",
|
||||||
|
"browserHash": "bfeec663",
|
||||||
|
"optimized": {
|
||||||
|
"three": {
|
||||||
|
"src": "../../three/build/three.module.js",
|
||||||
|
"file": "three.js",
|
||||||
|
"fileHash": "3e7017a4",
|
||||||
|
"needsInterop": false
|
||||||
|
},
|
||||||
|
"three/addons/controls/PointerLockControls.js": {
|
||||||
|
"src": "../../three/examples/jsm/controls/PointerLockControls.js",
|
||||||
|
"file": "three_addons_controls_PointerLockControls__js.js",
|
||||||
|
"fileHash": "185d9100",
|
||||||
|
"needsInterop": false
|
||||||
|
},
|
||||||
|
"three/examples/jsm/controls/PointerLockControls.js": {
|
||||||
|
"src": "../../three/examples/jsm/controls/PointerLockControls.js",
|
||||||
|
"file": "three_examples_jsm_controls_PointerLockControls__js.js",
|
||||||
|
"fileHash": "98cdccce",
|
||||||
|
"needsInterop": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"chunks": {
|
||||||
|
"chunk-PIN6L3XG": {
|
||||||
|
"file": "chunk-PIN6L3XG.js"
|
||||||
|
},
|
||||||
|
"chunk-XSTVJSXX": {
|
||||||
|
"file": "chunk-XSTVJSXX.js"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
125
node_modules/.vite/deps/chunk-PIN6L3XG.js
generated
vendored
Normal file
125
node_modules/.vite/deps/chunk-PIN6L3XG.js
generated
vendored
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
import {
|
||||||
|
Controls,
|
||||||
|
Euler,
|
||||||
|
Vector3
|
||||||
|
} from "./chunk-XSTVJSXX.js";
|
||||||
|
|
||||||
|
// node_modules/three/examples/jsm/controls/PointerLockControls.js
|
||||||
|
var _euler = new Euler(0, 0, 0, "YXZ");
|
||||||
|
var _vector = new Vector3();
|
||||||
|
var _changeEvent = { type: "change" };
|
||||||
|
var _lockEvent = { type: "lock" };
|
||||||
|
var _unlockEvent = { type: "unlock" };
|
||||||
|
var _MOUSE_SENSITIVITY = 2e-3;
|
||||||
|
var _PI_2 = Math.PI / 2;
|
||||||
|
var PointerLockControls = class extends Controls {
|
||||||
|
/**
|
||||||
|
* Constructs a new controls instance.
|
||||||
|
*
|
||||||
|
* @param {Camera} camera - The camera that is managed by the controls.
|
||||||
|
* @param {?HTMLElement} domElement - The HTML element used for event listeners.
|
||||||
|
*/
|
||||||
|
constructor(camera, domElement = null) {
|
||||||
|
super(camera, domElement);
|
||||||
|
this.isLocked = false;
|
||||||
|
this.minPolarAngle = 0;
|
||||||
|
this.maxPolarAngle = Math.PI;
|
||||||
|
this.pointerSpeed = 1;
|
||||||
|
this._onMouseMove = onMouseMove.bind(this);
|
||||||
|
this._onPointerlockChange = onPointerlockChange.bind(this);
|
||||||
|
this._onPointerlockError = onPointerlockError.bind(this);
|
||||||
|
if (this.domElement !== null) {
|
||||||
|
this.connect(this.domElement);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
connect(element) {
|
||||||
|
super.connect(element);
|
||||||
|
this.domElement.ownerDocument.addEventListener("mousemove", this._onMouseMove);
|
||||||
|
this.domElement.ownerDocument.addEventListener("pointerlockchange", this._onPointerlockChange);
|
||||||
|
this.domElement.ownerDocument.addEventListener("pointerlockerror", this._onPointerlockError);
|
||||||
|
}
|
||||||
|
disconnect() {
|
||||||
|
this.domElement.ownerDocument.removeEventListener("mousemove", this._onMouseMove);
|
||||||
|
this.domElement.ownerDocument.removeEventListener("pointerlockchange", this._onPointerlockChange);
|
||||||
|
this.domElement.ownerDocument.removeEventListener("pointerlockerror", this._onPointerlockError);
|
||||||
|
}
|
||||||
|
dispose() {
|
||||||
|
this.disconnect();
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Returns the look direction of the camera.
|
||||||
|
*
|
||||||
|
* @param {Vector3} v - The target vector that is used to store the method's result.
|
||||||
|
* @return {Vector3} The normalized direction vector.
|
||||||
|
*/
|
||||||
|
getDirection(v) {
|
||||||
|
return v.set(0, 0, -1).applyQuaternion(this.object.quaternion);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Moves the camera forward parallel to the xz-plane. Assumes camera.up is y-up.
|
||||||
|
*
|
||||||
|
* @param {number} distance - The signed distance.
|
||||||
|
*/
|
||||||
|
moveForward(distance) {
|
||||||
|
if (this.enabled === false) return;
|
||||||
|
const camera = this.object;
|
||||||
|
_vector.setFromMatrixColumn(camera.matrix, 0);
|
||||||
|
_vector.crossVectors(camera.up, _vector);
|
||||||
|
camera.position.addScaledVector(_vector, distance);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Moves the camera sidewards parallel to the xz-plane.
|
||||||
|
*
|
||||||
|
* @param {number} distance - The signed distance.
|
||||||
|
*/
|
||||||
|
moveRight(distance) {
|
||||||
|
if (this.enabled === false) return;
|
||||||
|
const camera = this.object;
|
||||||
|
_vector.setFromMatrixColumn(camera.matrix, 0);
|
||||||
|
camera.position.addScaledVector(_vector, distance);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Activates the pointer lock.
|
||||||
|
*
|
||||||
|
* @param {boolean} [unadjustedMovement=false] - Disables OS-level adjustment for mouse acceleration, and accesses raw mouse input instead.
|
||||||
|
* Setting it to true will disable mouse acceleration.
|
||||||
|
*/
|
||||||
|
lock(unadjustedMovement = false) {
|
||||||
|
this.domElement.requestPointerLock({
|
||||||
|
unadjustedMovement
|
||||||
|
});
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Exits the pointer lock.
|
||||||
|
*/
|
||||||
|
unlock() {
|
||||||
|
this.domElement.ownerDocument.exitPointerLock();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
function onMouseMove(event) {
|
||||||
|
if (this.enabled === false || this.isLocked === false) return;
|
||||||
|
const camera = this.object;
|
||||||
|
_euler.setFromQuaternion(camera.quaternion);
|
||||||
|
_euler.y -= event.movementX * _MOUSE_SENSITIVITY * this.pointerSpeed;
|
||||||
|
_euler.x -= event.movementY * _MOUSE_SENSITIVITY * this.pointerSpeed;
|
||||||
|
_euler.x = Math.max(_PI_2 - this.maxPolarAngle, Math.min(_PI_2 - this.minPolarAngle, _euler.x));
|
||||||
|
camera.quaternion.setFromEuler(_euler);
|
||||||
|
this.dispatchEvent(_changeEvent);
|
||||||
|
}
|
||||||
|
function onPointerlockChange() {
|
||||||
|
if (this.domElement.ownerDocument.pointerLockElement === this.domElement) {
|
||||||
|
this.dispatchEvent(_lockEvent);
|
||||||
|
this.isLocked = true;
|
||||||
|
} else {
|
||||||
|
this.dispatchEvent(_unlockEvent);
|
||||||
|
this.isLocked = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function onPointerlockError() {
|
||||||
|
console.error("THREE.PointerLockControls: Unable to use Pointer Lock API");
|
||||||
|
}
|
||||||
|
|
||||||
|
export {
|
||||||
|
PointerLockControls
|
||||||
|
};
|
||||||
|
//# sourceMappingURL=chunk-PIN6L3XG.js.map
|
||||||
7
node_modules/.vite/deps/chunk-PIN6L3XG.js.map
generated
vendored
Normal file
7
node_modules/.vite/deps/chunk-PIN6L3XG.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
43003
node_modules/.vite/deps/chunk-XSTVJSXX.js
generated
vendored
Normal file
43003
node_modules/.vite/deps/chunk-XSTVJSXX.js
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
7
node_modules/.vite/deps/chunk-XSTVJSXX.js.map
generated
vendored
Normal file
7
node_modules/.vite/deps/chunk-XSTVJSXX.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
3
node_modules/.vite/deps/package.json
generated
vendored
Normal file
3
node_modules/.vite/deps/package.json
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"type": "module"
|
||||||
|
}
|
||||||
876
node_modules/.vite/deps/three.js
generated
vendored
Normal file
876
node_modules/.vite/deps/three.js
generated
vendored
Normal file
@@ -0,0 +1,876 @@
|
|||||||
|
import {
|
||||||
|
ACESFilmicToneMapping,
|
||||||
|
AddEquation,
|
||||||
|
AddOperation,
|
||||||
|
AdditiveAnimationBlendMode,
|
||||||
|
AdditiveBlending,
|
||||||
|
AgXToneMapping,
|
||||||
|
AlphaFormat,
|
||||||
|
AlwaysCompare,
|
||||||
|
AlwaysDepth,
|
||||||
|
AlwaysStencilFunc,
|
||||||
|
AmbientLight,
|
||||||
|
AnimationAction,
|
||||||
|
AnimationClip,
|
||||||
|
AnimationLoader,
|
||||||
|
AnimationMixer,
|
||||||
|
AnimationObjectGroup,
|
||||||
|
AnimationUtils,
|
||||||
|
ArcCurve,
|
||||||
|
ArrayCamera,
|
||||||
|
ArrowHelper,
|
||||||
|
AttachedBindMode,
|
||||||
|
Audio,
|
||||||
|
AudioAnalyser,
|
||||||
|
AudioContext,
|
||||||
|
AudioListener,
|
||||||
|
AudioLoader,
|
||||||
|
AxesHelper,
|
||||||
|
BackSide,
|
||||||
|
BasicDepthPacking,
|
||||||
|
BasicShadowMap,
|
||||||
|
BatchedMesh,
|
||||||
|
Bone,
|
||||||
|
BooleanKeyframeTrack,
|
||||||
|
Box2,
|
||||||
|
Box3,
|
||||||
|
Box3Helper,
|
||||||
|
BoxGeometry,
|
||||||
|
BoxHelper,
|
||||||
|
BufferAttribute,
|
||||||
|
BufferGeometry,
|
||||||
|
BufferGeometryLoader,
|
||||||
|
ByteType,
|
||||||
|
Cache,
|
||||||
|
Camera,
|
||||||
|
CameraHelper,
|
||||||
|
CanvasTexture,
|
||||||
|
CapsuleGeometry,
|
||||||
|
CatmullRomCurve3,
|
||||||
|
CineonToneMapping,
|
||||||
|
CircleGeometry,
|
||||||
|
ClampToEdgeWrapping,
|
||||||
|
Clock,
|
||||||
|
Color,
|
||||||
|
ColorKeyframeTrack,
|
||||||
|
ColorManagement,
|
||||||
|
CompressedArrayTexture,
|
||||||
|
CompressedCubeTexture,
|
||||||
|
CompressedTexture,
|
||||||
|
CompressedTextureLoader,
|
||||||
|
ConeGeometry,
|
||||||
|
ConstantAlphaFactor,
|
||||||
|
ConstantColorFactor,
|
||||||
|
Controls,
|
||||||
|
CubeCamera,
|
||||||
|
CubeDepthTexture,
|
||||||
|
CubeReflectionMapping,
|
||||||
|
CubeRefractionMapping,
|
||||||
|
CubeTexture,
|
||||||
|
CubeTextureLoader,
|
||||||
|
CubeUVReflectionMapping,
|
||||||
|
CubicBezierCurve,
|
||||||
|
CubicBezierCurve3,
|
||||||
|
CubicInterpolant,
|
||||||
|
CullFaceBack,
|
||||||
|
CullFaceFront,
|
||||||
|
CullFaceFrontBack,
|
||||||
|
CullFaceNone,
|
||||||
|
Curve,
|
||||||
|
CurvePath,
|
||||||
|
CustomBlending,
|
||||||
|
CustomToneMapping,
|
||||||
|
CylinderGeometry,
|
||||||
|
Cylindrical,
|
||||||
|
Data3DTexture,
|
||||||
|
DataArrayTexture,
|
||||||
|
DataTexture,
|
||||||
|
DataTextureLoader,
|
||||||
|
DataUtils,
|
||||||
|
DecrementStencilOp,
|
||||||
|
DecrementWrapStencilOp,
|
||||||
|
DefaultLoadingManager,
|
||||||
|
DepthFormat,
|
||||||
|
DepthStencilFormat,
|
||||||
|
DepthTexture,
|
||||||
|
DetachedBindMode,
|
||||||
|
DirectionalLight,
|
||||||
|
DirectionalLightHelper,
|
||||||
|
DiscreteInterpolant,
|
||||||
|
DodecahedronGeometry,
|
||||||
|
DoubleSide,
|
||||||
|
DstAlphaFactor,
|
||||||
|
DstColorFactor,
|
||||||
|
DynamicCopyUsage,
|
||||||
|
DynamicDrawUsage,
|
||||||
|
DynamicReadUsage,
|
||||||
|
EdgesGeometry,
|
||||||
|
EllipseCurve,
|
||||||
|
EqualCompare,
|
||||||
|
EqualDepth,
|
||||||
|
EqualStencilFunc,
|
||||||
|
EquirectangularReflectionMapping,
|
||||||
|
EquirectangularRefractionMapping,
|
||||||
|
Euler,
|
||||||
|
EventDispatcher,
|
||||||
|
ExternalTexture,
|
||||||
|
ExtrudeGeometry,
|
||||||
|
FileLoader,
|
||||||
|
Float16BufferAttribute,
|
||||||
|
Float32BufferAttribute,
|
||||||
|
FloatType,
|
||||||
|
Fog,
|
||||||
|
FogExp2,
|
||||||
|
FramebufferTexture,
|
||||||
|
FrontSide,
|
||||||
|
Frustum,
|
||||||
|
FrustumArray,
|
||||||
|
GLBufferAttribute,
|
||||||
|
GLSL1,
|
||||||
|
GLSL3,
|
||||||
|
GreaterCompare,
|
||||||
|
GreaterDepth,
|
||||||
|
GreaterEqualCompare,
|
||||||
|
GreaterEqualDepth,
|
||||||
|
GreaterEqualStencilFunc,
|
||||||
|
GreaterStencilFunc,
|
||||||
|
GridHelper,
|
||||||
|
Group,
|
||||||
|
HalfFloatType,
|
||||||
|
HemisphereLight,
|
||||||
|
HemisphereLightHelper,
|
||||||
|
IcosahedronGeometry,
|
||||||
|
ImageBitmapLoader,
|
||||||
|
ImageLoader,
|
||||||
|
ImageUtils,
|
||||||
|
IncrementStencilOp,
|
||||||
|
IncrementWrapStencilOp,
|
||||||
|
InstancedBufferAttribute,
|
||||||
|
InstancedBufferGeometry,
|
||||||
|
InstancedInterleavedBuffer,
|
||||||
|
InstancedMesh,
|
||||||
|
Int16BufferAttribute,
|
||||||
|
Int32BufferAttribute,
|
||||||
|
Int8BufferAttribute,
|
||||||
|
IntType,
|
||||||
|
InterleavedBuffer,
|
||||||
|
InterleavedBufferAttribute,
|
||||||
|
Interpolant,
|
||||||
|
InterpolateDiscrete,
|
||||||
|
InterpolateLinear,
|
||||||
|
InterpolateSmooth,
|
||||||
|
InterpolationSamplingMode,
|
||||||
|
InterpolationSamplingType,
|
||||||
|
InvertStencilOp,
|
||||||
|
KeepStencilOp,
|
||||||
|
KeyframeTrack,
|
||||||
|
LOD,
|
||||||
|
LatheGeometry,
|
||||||
|
Layers,
|
||||||
|
LessCompare,
|
||||||
|
LessDepth,
|
||||||
|
LessEqualCompare,
|
||||||
|
LessEqualDepth,
|
||||||
|
LessEqualStencilFunc,
|
||||||
|
LessStencilFunc,
|
||||||
|
Light,
|
||||||
|
LightProbe,
|
||||||
|
Line,
|
||||||
|
Line3,
|
||||||
|
LineBasicMaterial,
|
||||||
|
LineCurve,
|
||||||
|
LineCurve3,
|
||||||
|
LineDashedMaterial,
|
||||||
|
LineLoop,
|
||||||
|
LineSegments,
|
||||||
|
LinearFilter,
|
||||||
|
LinearInterpolant,
|
||||||
|
LinearMipMapLinearFilter,
|
||||||
|
LinearMipMapNearestFilter,
|
||||||
|
LinearMipmapLinearFilter,
|
||||||
|
LinearMipmapNearestFilter,
|
||||||
|
LinearSRGBColorSpace,
|
||||||
|
LinearToneMapping,
|
||||||
|
LinearTransfer,
|
||||||
|
Loader,
|
||||||
|
LoaderUtils,
|
||||||
|
LoadingManager,
|
||||||
|
LoopOnce,
|
||||||
|
LoopPingPong,
|
||||||
|
LoopRepeat,
|
||||||
|
MOUSE,
|
||||||
|
Material,
|
||||||
|
MaterialLoader,
|
||||||
|
MathUtils,
|
||||||
|
Matrix2,
|
||||||
|
Matrix3,
|
||||||
|
Matrix4,
|
||||||
|
MaxEquation,
|
||||||
|
Mesh,
|
||||||
|
MeshBasicMaterial,
|
||||||
|
MeshDepthMaterial,
|
||||||
|
MeshDistanceMaterial,
|
||||||
|
MeshLambertMaterial,
|
||||||
|
MeshMatcapMaterial,
|
||||||
|
MeshNormalMaterial,
|
||||||
|
MeshPhongMaterial,
|
||||||
|
MeshPhysicalMaterial,
|
||||||
|
MeshStandardMaterial,
|
||||||
|
MeshToonMaterial,
|
||||||
|
MinEquation,
|
||||||
|
MirroredRepeatWrapping,
|
||||||
|
MixOperation,
|
||||||
|
MultiplyBlending,
|
||||||
|
MultiplyOperation,
|
||||||
|
NearestFilter,
|
||||||
|
NearestMipMapLinearFilter,
|
||||||
|
NearestMipMapNearestFilter,
|
||||||
|
NearestMipmapLinearFilter,
|
||||||
|
NearestMipmapNearestFilter,
|
||||||
|
NeutralToneMapping,
|
||||||
|
NeverCompare,
|
||||||
|
NeverDepth,
|
||||||
|
NeverStencilFunc,
|
||||||
|
NoBlending,
|
||||||
|
NoColorSpace,
|
||||||
|
NoNormalPacking,
|
||||||
|
NoToneMapping,
|
||||||
|
NormalAnimationBlendMode,
|
||||||
|
NormalBlending,
|
||||||
|
NormalGAPacking,
|
||||||
|
NormalRGPacking,
|
||||||
|
NotEqualCompare,
|
||||||
|
NotEqualDepth,
|
||||||
|
NotEqualStencilFunc,
|
||||||
|
NumberKeyframeTrack,
|
||||||
|
Object3D,
|
||||||
|
ObjectLoader,
|
||||||
|
ObjectSpaceNormalMap,
|
||||||
|
OctahedronGeometry,
|
||||||
|
OneFactor,
|
||||||
|
OneMinusConstantAlphaFactor,
|
||||||
|
OneMinusConstantColorFactor,
|
||||||
|
OneMinusDstAlphaFactor,
|
||||||
|
OneMinusDstColorFactor,
|
||||||
|
OneMinusSrcAlphaFactor,
|
||||||
|
OneMinusSrcColorFactor,
|
||||||
|
OrthographicCamera,
|
||||||
|
PCFShadowMap,
|
||||||
|
PCFSoftShadowMap,
|
||||||
|
PMREMGenerator,
|
||||||
|
Path,
|
||||||
|
PerspectiveCamera,
|
||||||
|
Plane,
|
||||||
|
PlaneGeometry,
|
||||||
|
PlaneHelper,
|
||||||
|
PointLight,
|
||||||
|
PointLightHelper,
|
||||||
|
Points,
|
||||||
|
PointsMaterial,
|
||||||
|
PolarGridHelper,
|
||||||
|
PolyhedronGeometry,
|
||||||
|
PositionalAudio,
|
||||||
|
PropertyBinding,
|
||||||
|
PropertyMixer,
|
||||||
|
QuadraticBezierCurve,
|
||||||
|
QuadraticBezierCurve3,
|
||||||
|
Quaternion,
|
||||||
|
QuaternionKeyframeTrack,
|
||||||
|
QuaternionLinearInterpolant,
|
||||||
|
R11_EAC_Format,
|
||||||
|
RED_GREEN_RGTC2_Format,
|
||||||
|
RED_RGTC1_Format,
|
||||||
|
REVISION,
|
||||||
|
RG11_EAC_Format,
|
||||||
|
RGBADepthPacking,
|
||||||
|
RGBAFormat,
|
||||||
|
RGBAIntegerFormat,
|
||||||
|
RGBA_ASTC_10x10_Format,
|
||||||
|
RGBA_ASTC_10x5_Format,
|
||||||
|
RGBA_ASTC_10x6_Format,
|
||||||
|
RGBA_ASTC_10x8_Format,
|
||||||
|
RGBA_ASTC_12x10_Format,
|
||||||
|
RGBA_ASTC_12x12_Format,
|
||||||
|
RGBA_ASTC_4x4_Format,
|
||||||
|
RGBA_ASTC_5x4_Format,
|
||||||
|
RGBA_ASTC_5x5_Format,
|
||||||
|
RGBA_ASTC_6x5_Format,
|
||||||
|
RGBA_ASTC_6x6_Format,
|
||||||
|
RGBA_ASTC_8x5_Format,
|
||||||
|
RGBA_ASTC_8x6_Format,
|
||||||
|
RGBA_ASTC_8x8_Format,
|
||||||
|
RGBA_BPTC_Format,
|
||||||
|
RGBA_ETC2_EAC_Format,
|
||||||
|
RGBA_PVRTC_2BPPV1_Format,
|
||||||
|
RGBA_PVRTC_4BPPV1_Format,
|
||||||
|
RGBA_S3TC_DXT1_Format,
|
||||||
|
RGBA_S3TC_DXT3_Format,
|
||||||
|
RGBA_S3TC_DXT5_Format,
|
||||||
|
RGBDepthPacking,
|
||||||
|
RGBFormat,
|
||||||
|
RGBIntegerFormat,
|
||||||
|
RGB_BPTC_SIGNED_Format,
|
||||||
|
RGB_BPTC_UNSIGNED_Format,
|
||||||
|
RGB_ETC1_Format,
|
||||||
|
RGB_ETC2_Format,
|
||||||
|
RGB_PVRTC_2BPPV1_Format,
|
||||||
|
RGB_PVRTC_4BPPV1_Format,
|
||||||
|
RGB_S3TC_DXT1_Format,
|
||||||
|
RGDepthPacking,
|
||||||
|
RGFormat,
|
||||||
|
RGIntegerFormat,
|
||||||
|
RawShaderMaterial,
|
||||||
|
Ray,
|
||||||
|
Raycaster,
|
||||||
|
RectAreaLight,
|
||||||
|
RedFormat,
|
||||||
|
RedIntegerFormat,
|
||||||
|
ReinhardToneMapping,
|
||||||
|
RenderTarget,
|
||||||
|
RenderTarget3D,
|
||||||
|
RepeatWrapping,
|
||||||
|
ReplaceStencilOp,
|
||||||
|
ReverseSubtractEquation,
|
||||||
|
RingGeometry,
|
||||||
|
SIGNED_R11_EAC_Format,
|
||||||
|
SIGNED_RED_GREEN_RGTC2_Format,
|
||||||
|
SIGNED_RED_RGTC1_Format,
|
||||||
|
SIGNED_RG11_EAC_Format,
|
||||||
|
SRGBColorSpace,
|
||||||
|
SRGBTransfer,
|
||||||
|
Scene,
|
||||||
|
ShaderChunk,
|
||||||
|
ShaderLib,
|
||||||
|
ShaderMaterial,
|
||||||
|
ShadowMaterial,
|
||||||
|
Shape,
|
||||||
|
ShapeGeometry,
|
||||||
|
ShapePath,
|
||||||
|
ShapeUtils,
|
||||||
|
ShortType,
|
||||||
|
Skeleton,
|
||||||
|
SkeletonHelper,
|
||||||
|
SkinnedMesh,
|
||||||
|
Source,
|
||||||
|
Sphere,
|
||||||
|
SphereGeometry,
|
||||||
|
Spherical,
|
||||||
|
SphericalHarmonics3,
|
||||||
|
SplineCurve,
|
||||||
|
SpotLight,
|
||||||
|
SpotLightHelper,
|
||||||
|
Sprite,
|
||||||
|
SpriteMaterial,
|
||||||
|
SrcAlphaFactor,
|
||||||
|
SrcAlphaSaturateFactor,
|
||||||
|
SrcColorFactor,
|
||||||
|
StaticCopyUsage,
|
||||||
|
StaticDrawUsage,
|
||||||
|
StaticReadUsage,
|
||||||
|
StereoCamera,
|
||||||
|
StreamCopyUsage,
|
||||||
|
StreamDrawUsage,
|
||||||
|
StreamReadUsage,
|
||||||
|
StringKeyframeTrack,
|
||||||
|
SubtractEquation,
|
||||||
|
SubtractiveBlending,
|
||||||
|
TOUCH,
|
||||||
|
TangentSpaceNormalMap,
|
||||||
|
TetrahedronGeometry,
|
||||||
|
Texture,
|
||||||
|
TextureLoader,
|
||||||
|
TextureUtils,
|
||||||
|
Timer,
|
||||||
|
TimestampQuery,
|
||||||
|
TorusGeometry,
|
||||||
|
TorusKnotGeometry,
|
||||||
|
Triangle,
|
||||||
|
TriangleFanDrawMode,
|
||||||
|
TriangleStripDrawMode,
|
||||||
|
TrianglesDrawMode,
|
||||||
|
TubeGeometry,
|
||||||
|
UVMapping,
|
||||||
|
Uint16BufferAttribute,
|
||||||
|
Uint32BufferAttribute,
|
||||||
|
Uint8BufferAttribute,
|
||||||
|
Uint8ClampedBufferAttribute,
|
||||||
|
Uniform,
|
||||||
|
UniformsGroup,
|
||||||
|
UniformsLib,
|
||||||
|
UniformsUtils,
|
||||||
|
UnsignedByteType,
|
||||||
|
UnsignedInt101111Type,
|
||||||
|
UnsignedInt248Type,
|
||||||
|
UnsignedInt5999Type,
|
||||||
|
UnsignedIntType,
|
||||||
|
UnsignedShort4444Type,
|
||||||
|
UnsignedShort5551Type,
|
||||||
|
UnsignedShortType,
|
||||||
|
VSMShadowMap,
|
||||||
|
Vector2,
|
||||||
|
Vector3,
|
||||||
|
Vector4,
|
||||||
|
VectorKeyframeTrack,
|
||||||
|
VideoFrameTexture,
|
||||||
|
VideoTexture,
|
||||||
|
WebGL3DRenderTarget,
|
||||||
|
WebGLArrayRenderTarget,
|
||||||
|
WebGLCoordinateSystem,
|
||||||
|
WebGLCubeRenderTarget,
|
||||||
|
WebGLRenderTarget,
|
||||||
|
WebGLRenderer,
|
||||||
|
WebGLUtils,
|
||||||
|
WebGPUCoordinateSystem,
|
||||||
|
WebXRController,
|
||||||
|
WireframeGeometry,
|
||||||
|
WrapAroundEnding,
|
||||||
|
ZeroCurvatureEnding,
|
||||||
|
ZeroFactor,
|
||||||
|
ZeroSlopeEnding,
|
||||||
|
ZeroStencilOp,
|
||||||
|
createCanvasElement,
|
||||||
|
error,
|
||||||
|
getConsoleFunction,
|
||||||
|
log,
|
||||||
|
setConsoleFunction,
|
||||||
|
warn,
|
||||||
|
warnOnce
|
||||||
|
} from "./chunk-XSTVJSXX.js";
|
||||||
|
export {
|
||||||
|
ACESFilmicToneMapping,
|
||||||
|
AddEquation,
|
||||||
|
AddOperation,
|
||||||
|
AdditiveAnimationBlendMode,
|
||||||
|
AdditiveBlending,
|
||||||
|
AgXToneMapping,
|
||||||
|
AlphaFormat,
|
||||||
|
AlwaysCompare,
|
||||||
|
AlwaysDepth,
|
||||||
|
AlwaysStencilFunc,
|
||||||
|
AmbientLight,
|
||||||
|
AnimationAction,
|
||||||
|
AnimationClip,
|
||||||
|
AnimationLoader,
|
||||||
|
AnimationMixer,
|
||||||
|
AnimationObjectGroup,
|
||||||
|
AnimationUtils,
|
||||||
|
ArcCurve,
|
||||||
|
ArrayCamera,
|
||||||
|
ArrowHelper,
|
||||||
|
AttachedBindMode,
|
||||||
|
Audio,
|
||||||
|
AudioAnalyser,
|
||||||
|
AudioContext,
|
||||||
|
AudioListener,
|
||||||
|
AudioLoader,
|
||||||
|
AxesHelper,
|
||||||
|
BackSide,
|
||||||
|
BasicDepthPacking,
|
||||||
|
BasicShadowMap,
|
||||||
|
BatchedMesh,
|
||||||
|
Bone,
|
||||||
|
BooleanKeyframeTrack,
|
||||||
|
Box2,
|
||||||
|
Box3,
|
||||||
|
Box3Helper,
|
||||||
|
BoxGeometry,
|
||||||
|
BoxHelper,
|
||||||
|
BufferAttribute,
|
||||||
|
BufferGeometry,
|
||||||
|
BufferGeometryLoader,
|
||||||
|
ByteType,
|
||||||
|
Cache,
|
||||||
|
Camera,
|
||||||
|
CameraHelper,
|
||||||
|
CanvasTexture,
|
||||||
|
CapsuleGeometry,
|
||||||
|
CatmullRomCurve3,
|
||||||
|
CineonToneMapping,
|
||||||
|
CircleGeometry,
|
||||||
|
ClampToEdgeWrapping,
|
||||||
|
Clock,
|
||||||
|
Color,
|
||||||
|
ColorKeyframeTrack,
|
||||||
|
ColorManagement,
|
||||||
|
CompressedArrayTexture,
|
||||||
|
CompressedCubeTexture,
|
||||||
|
CompressedTexture,
|
||||||
|
CompressedTextureLoader,
|
||||||
|
ConeGeometry,
|
||||||
|
ConstantAlphaFactor,
|
||||||
|
ConstantColorFactor,
|
||||||
|
Controls,
|
||||||
|
CubeCamera,
|
||||||
|
CubeDepthTexture,
|
||||||
|
CubeReflectionMapping,
|
||||||
|
CubeRefractionMapping,
|
||||||
|
CubeTexture,
|
||||||
|
CubeTextureLoader,
|
||||||
|
CubeUVReflectionMapping,
|
||||||
|
CubicBezierCurve,
|
||||||
|
CubicBezierCurve3,
|
||||||
|
CubicInterpolant,
|
||||||
|
CullFaceBack,
|
||||||
|
CullFaceFront,
|
||||||
|
CullFaceFrontBack,
|
||||||
|
CullFaceNone,
|
||||||
|
Curve,
|
||||||
|
CurvePath,
|
||||||
|
CustomBlending,
|
||||||
|
CustomToneMapping,
|
||||||
|
CylinderGeometry,
|
||||||
|
Cylindrical,
|
||||||
|
Data3DTexture,
|
||||||
|
DataArrayTexture,
|
||||||
|
DataTexture,
|
||||||
|
DataTextureLoader,
|
||||||
|
DataUtils,
|
||||||
|
DecrementStencilOp,
|
||||||
|
DecrementWrapStencilOp,
|
||||||
|
DefaultLoadingManager,
|
||||||
|
DepthFormat,
|
||||||
|
DepthStencilFormat,
|
||||||
|
DepthTexture,
|
||||||
|
DetachedBindMode,
|
||||||
|
DirectionalLight,
|
||||||
|
DirectionalLightHelper,
|
||||||
|
DiscreteInterpolant,
|
||||||
|
DodecahedronGeometry,
|
||||||
|
DoubleSide,
|
||||||
|
DstAlphaFactor,
|
||||||
|
DstColorFactor,
|
||||||
|
DynamicCopyUsage,
|
||||||
|
DynamicDrawUsage,
|
||||||
|
DynamicReadUsage,
|
||||||
|
EdgesGeometry,
|
||||||
|
EllipseCurve,
|
||||||
|
EqualCompare,
|
||||||
|
EqualDepth,
|
||||||
|
EqualStencilFunc,
|
||||||
|
EquirectangularReflectionMapping,
|
||||||
|
EquirectangularRefractionMapping,
|
||||||
|
Euler,
|
||||||
|
EventDispatcher,
|
||||||
|
ExternalTexture,
|
||||||
|
ExtrudeGeometry,
|
||||||
|
FileLoader,
|
||||||
|
Float16BufferAttribute,
|
||||||
|
Float32BufferAttribute,
|
||||||
|
FloatType,
|
||||||
|
Fog,
|
||||||
|
FogExp2,
|
||||||
|
FramebufferTexture,
|
||||||
|
FrontSide,
|
||||||
|
Frustum,
|
||||||
|
FrustumArray,
|
||||||
|
GLBufferAttribute,
|
||||||
|
GLSL1,
|
||||||
|
GLSL3,
|
||||||
|
GreaterCompare,
|
||||||
|
GreaterDepth,
|
||||||
|
GreaterEqualCompare,
|
||||||
|
GreaterEqualDepth,
|
||||||
|
GreaterEqualStencilFunc,
|
||||||
|
GreaterStencilFunc,
|
||||||
|
GridHelper,
|
||||||
|
Group,
|
||||||
|
HalfFloatType,
|
||||||
|
HemisphereLight,
|
||||||
|
HemisphereLightHelper,
|
||||||
|
IcosahedronGeometry,
|
||||||
|
ImageBitmapLoader,
|
||||||
|
ImageLoader,
|
||||||
|
ImageUtils,
|
||||||
|
IncrementStencilOp,
|
||||||
|
IncrementWrapStencilOp,
|
||||||
|
InstancedBufferAttribute,
|
||||||
|
InstancedBufferGeometry,
|
||||||
|
InstancedInterleavedBuffer,
|
||||||
|
InstancedMesh,
|
||||||
|
Int16BufferAttribute,
|
||||||
|
Int32BufferAttribute,
|
||||||
|
Int8BufferAttribute,
|
||||||
|
IntType,
|
||||||
|
InterleavedBuffer,
|
||||||
|
InterleavedBufferAttribute,
|
||||||
|
Interpolant,
|
||||||
|
InterpolateDiscrete,
|
||||||
|
InterpolateLinear,
|
||||||
|
InterpolateSmooth,
|
||||||
|
InterpolationSamplingMode,
|
||||||
|
InterpolationSamplingType,
|
||||||
|
InvertStencilOp,
|
||||||
|
KeepStencilOp,
|
||||||
|
KeyframeTrack,
|
||||||
|
LOD,
|
||||||
|
LatheGeometry,
|
||||||
|
Layers,
|
||||||
|
LessCompare,
|
||||||
|
LessDepth,
|
||||||
|
LessEqualCompare,
|
||||||
|
LessEqualDepth,
|
||||||
|
LessEqualStencilFunc,
|
||||||
|
LessStencilFunc,
|
||||||
|
Light,
|
||||||
|
LightProbe,
|
||||||
|
Line,
|
||||||
|
Line3,
|
||||||
|
LineBasicMaterial,
|
||||||
|
LineCurve,
|
||||||
|
LineCurve3,
|
||||||
|
LineDashedMaterial,
|
||||||
|
LineLoop,
|
||||||
|
LineSegments,
|
||||||
|
LinearFilter,
|
||||||
|
LinearInterpolant,
|
||||||
|
LinearMipMapLinearFilter,
|
||||||
|
LinearMipMapNearestFilter,
|
||||||
|
LinearMipmapLinearFilter,
|
||||||
|
LinearMipmapNearestFilter,
|
||||||
|
LinearSRGBColorSpace,
|
||||||
|
LinearToneMapping,
|
||||||
|
LinearTransfer,
|
||||||
|
Loader,
|
||||||
|
LoaderUtils,
|
||||||
|
LoadingManager,
|
||||||
|
LoopOnce,
|
||||||
|
LoopPingPong,
|
||||||
|
LoopRepeat,
|
||||||
|
MOUSE,
|
||||||
|
Material,
|
||||||
|
MaterialLoader,
|
||||||
|
MathUtils,
|
||||||
|
Matrix2,
|
||||||
|
Matrix3,
|
||||||
|
Matrix4,
|
||||||
|
MaxEquation,
|
||||||
|
Mesh,
|
||||||
|
MeshBasicMaterial,
|
||||||
|
MeshDepthMaterial,
|
||||||
|
MeshDistanceMaterial,
|
||||||
|
MeshLambertMaterial,
|
||||||
|
MeshMatcapMaterial,
|
||||||
|
MeshNormalMaterial,
|
||||||
|
MeshPhongMaterial,
|
||||||
|
MeshPhysicalMaterial,
|
||||||
|
MeshStandardMaterial,
|
||||||
|
MeshToonMaterial,
|
||||||
|
MinEquation,
|
||||||
|
MirroredRepeatWrapping,
|
||||||
|
MixOperation,
|
||||||
|
MultiplyBlending,
|
||||||
|
MultiplyOperation,
|
||||||
|
NearestFilter,
|
||||||
|
NearestMipMapLinearFilter,
|
||||||
|
NearestMipMapNearestFilter,
|
||||||
|
NearestMipmapLinearFilter,
|
||||||
|
NearestMipmapNearestFilter,
|
||||||
|
NeutralToneMapping,
|
||||||
|
NeverCompare,
|
||||||
|
NeverDepth,
|
||||||
|
NeverStencilFunc,
|
||||||
|
NoBlending,
|
||||||
|
NoColorSpace,
|
||||||
|
NoNormalPacking,
|
||||||
|
NoToneMapping,
|
||||||
|
NormalAnimationBlendMode,
|
||||||
|
NormalBlending,
|
||||||
|
NormalGAPacking,
|
||||||
|
NormalRGPacking,
|
||||||
|
NotEqualCompare,
|
||||||
|
NotEqualDepth,
|
||||||
|
NotEqualStencilFunc,
|
||||||
|
NumberKeyframeTrack,
|
||||||
|
Object3D,
|
||||||
|
ObjectLoader,
|
||||||
|
ObjectSpaceNormalMap,
|
||||||
|
OctahedronGeometry,
|
||||||
|
OneFactor,
|
||||||
|
OneMinusConstantAlphaFactor,
|
||||||
|
OneMinusConstantColorFactor,
|
||||||
|
OneMinusDstAlphaFactor,
|
||||||
|
OneMinusDstColorFactor,
|
||||||
|
OneMinusSrcAlphaFactor,
|
||||||
|
OneMinusSrcColorFactor,
|
||||||
|
OrthographicCamera,
|
||||||
|
PCFShadowMap,
|
||||||
|
PCFSoftShadowMap,
|
||||||
|
PMREMGenerator,
|
||||||
|
Path,
|
||||||
|
PerspectiveCamera,
|
||||||
|
Plane,
|
||||||
|
PlaneGeometry,
|
||||||
|
PlaneHelper,
|
||||||
|
PointLight,
|
||||||
|
PointLightHelper,
|
||||||
|
Points,
|
||||||
|
PointsMaterial,
|
||||||
|
PolarGridHelper,
|
||||||
|
PolyhedronGeometry,
|
||||||
|
PositionalAudio,
|
||||||
|
PropertyBinding,
|
||||||
|
PropertyMixer,
|
||||||
|
QuadraticBezierCurve,
|
||||||
|
QuadraticBezierCurve3,
|
||||||
|
Quaternion,
|
||||||
|
QuaternionKeyframeTrack,
|
||||||
|
QuaternionLinearInterpolant,
|
||||||
|
R11_EAC_Format,
|
||||||
|
RED_GREEN_RGTC2_Format,
|
||||||
|
RED_RGTC1_Format,
|
||||||
|
REVISION,
|
||||||
|
RG11_EAC_Format,
|
||||||
|
RGBADepthPacking,
|
||||||
|
RGBAFormat,
|
||||||
|
RGBAIntegerFormat,
|
||||||
|
RGBA_ASTC_10x10_Format,
|
||||||
|
RGBA_ASTC_10x5_Format,
|
||||||
|
RGBA_ASTC_10x6_Format,
|
||||||
|
RGBA_ASTC_10x8_Format,
|
||||||
|
RGBA_ASTC_12x10_Format,
|
||||||
|
RGBA_ASTC_12x12_Format,
|
||||||
|
RGBA_ASTC_4x4_Format,
|
||||||
|
RGBA_ASTC_5x4_Format,
|
||||||
|
RGBA_ASTC_5x5_Format,
|
||||||
|
RGBA_ASTC_6x5_Format,
|
||||||
|
RGBA_ASTC_6x6_Format,
|
||||||
|
RGBA_ASTC_8x5_Format,
|
||||||
|
RGBA_ASTC_8x6_Format,
|
||||||
|
RGBA_ASTC_8x8_Format,
|
||||||
|
RGBA_BPTC_Format,
|
||||||
|
RGBA_ETC2_EAC_Format,
|
||||||
|
RGBA_PVRTC_2BPPV1_Format,
|
||||||
|
RGBA_PVRTC_4BPPV1_Format,
|
||||||
|
RGBA_S3TC_DXT1_Format,
|
||||||
|
RGBA_S3TC_DXT3_Format,
|
||||||
|
RGBA_S3TC_DXT5_Format,
|
||||||
|
RGBDepthPacking,
|
||||||
|
RGBFormat,
|
||||||
|
RGBIntegerFormat,
|
||||||
|
RGB_BPTC_SIGNED_Format,
|
||||||
|
RGB_BPTC_UNSIGNED_Format,
|
||||||
|
RGB_ETC1_Format,
|
||||||
|
RGB_ETC2_Format,
|
||||||
|
RGB_PVRTC_2BPPV1_Format,
|
||||||
|
RGB_PVRTC_4BPPV1_Format,
|
||||||
|
RGB_S3TC_DXT1_Format,
|
||||||
|
RGDepthPacking,
|
||||||
|
RGFormat,
|
||||||
|
RGIntegerFormat,
|
||||||
|
RawShaderMaterial,
|
||||||
|
Ray,
|
||||||
|
Raycaster,
|
||||||
|
RectAreaLight,
|
||||||
|
RedFormat,
|
||||||
|
RedIntegerFormat,
|
||||||
|
ReinhardToneMapping,
|
||||||
|
RenderTarget,
|
||||||
|
RenderTarget3D,
|
||||||
|
RepeatWrapping,
|
||||||
|
ReplaceStencilOp,
|
||||||
|
ReverseSubtractEquation,
|
||||||
|
RingGeometry,
|
||||||
|
SIGNED_R11_EAC_Format,
|
||||||
|
SIGNED_RED_GREEN_RGTC2_Format,
|
||||||
|
SIGNED_RED_RGTC1_Format,
|
||||||
|
SIGNED_RG11_EAC_Format,
|
||||||
|
SRGBColorSpace,
|
||||||
|
SRGBTransfer,
|
||||||
|
Scene,
|
||||||
|
ShaderChunk,
|
||||||
|
ShaderLib,
|
||||||
|
ShaderMaterial,
|
||||||
|
ShadowMaterial,
|
||||||
|
Shape,
|
||||||
|
ShapeGeometry,
|
||||||
|
ShapePath,
|
||||||
|
ShapeUtils,
|
||||||
|
ShortType,
|
||||||
|
Skeleton,
|
||||||
|
SkeletonHelper,
|
||||||
|
SkinnedMesh,
|
||||||
|
Source,
|
||||||
|
Sphere,
|
||||||
|
SphereGeometry,
|
||||||
|
Spherical,
|
||||||
|
SphericalHarmonics3,
|
||||||
|
SplineCurve,
|
||||||
|
SpotLight,
|
||||||
|
SpotLightHelper,
|
||||||
|
Sprite,
|
||||||
|
SpriteMaterial,
|
||||||
|
SrcAlphaFactor,
|
||||||
|
SrcAlphaSaturateFactor,
|
||||||
|
SrcColorFactor,
|
||||||
|
StaticCopyUsage,
|
||||||
|
StaticDrawUsage,
|
||||||
|
StaticReadUsage,
|
||||||
|
StereoCamera,
|
||||||
|
StreamCopyUsage,
|
||||||
|
StreamDrawUsage,
|
||||||
|
StreamReadUsage,
|
||||||
|
StringKeyframeTrack,
|
||||||
|
SubtractEquation,
|
||||||
|
SubtractiveBlending,
|
||||||
|
TOUCH,
|
||||||
|
TangentSpaceNormalMap,
|
||||||
|
TetrahedronGeometry,
|
||||||
|
Texture,
|
||||||
|
TextureLoader,
|
||||||
|
TextureUtils,
|
||||||
|
Timer,
|
||||||
|
TimestampQuery,
|
||||||
|
TorusGeometry,
|
||||||
|
TorusKnotGeometry,
|
||||||
|
Triangle,
|
||||||
|
TriangleFanDrawMode,
|
||||||
|
TriangleStripDrawMode,
|
||||||
|
TrianglesDrawMode,
|
||||||
|
TubeGeometry,
|
||||||
|
UVMapping,
|
||||||
|
Uint16BufferAttribute,
|
||||||
|
Uint32BufferAttribute,
|
||||||
|
Uint8BufferAttribute,
|
||||||
|
Uint8ClampedBufferAttribute,
|
||||||
|
Uniform,
|
||||||
|
UniformsGroup,
|
||||||
|
UniformsLib,
|
||||||
|
UniformsUtils,
|
||||||
|
UnsignedByteType,
|
||||||
|
UnsignedInt101111Type,
|
||||||
|
UnsignedInt248Type,
|
||||||
|
UnsignedInt5999Type,
|
||||||
|
UnsignedIntType,
|
||||||
|
UnsignedShort4444Type,
|
||||||
|
UnsignedShort5551Type,
|
||||||
|
UnsignedShortType,
|
||||||
|
VSMShadowMap,
|
||||||
|
Vector2,
|
||||||
|
Vector3,
|
||||||
|
Vector4,
|
||||||
|
VectorKeyframeTrack,
|
||||||
|
VideoFrameTexture,
|
||||||
|
VideoTexture,
|
||||||
|
WebGL3DRenderTarget,
|
||||||
|
WebGLArrayRenderTarget,
|
||||||
|
WebGLCoordinateSystem,
|
||||||
|
WebGLCubeRenderTarget,
|
||||||
|
WebGLRenderTarget,
|
||||||
|
WebGLRenderer,
|
||||||
|
WebGLUtils,
|
||||||
|
WebGPUCoordinateSystem,
|
||||||
|
WebXRController,
|
||||||
|
WireframeGeometry,
|
||||||
|
WrapAroundEnding,
|
||||||
|
ZeroCurvatureEnding,
|
||||||
|
ZeroFactor,
|
||||||
|
ZeroSlopeEnding,
|
||||||
|
ZeroStencilOp,
|
||||||
|
createCanvasElement,
|
||||||
|
error,
|
||||||
|
getConsoleFunction,
|
||||||
|
log,
|
||||||
|
setConsoleFunction,
|
||||||
|
warn,
|
||||||
|
warnOnce
|
||||||
|
};
|
||||||
7
node_modules/.vite/deps/three.js.map
generated
vendored
Normal file
7
node_modules/.vite/deps/three.js.map
generated
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"version": 3,
|
||||||
|
"sources": [],
|
||||||
|
"sourcesContent": [],
|
||||||
|
"mappings": "",
|
||||||
|
"names": []
|
||||||
|
}
|
||||||
7
node_modules/.vite/deps/three_addons_controls_PointerLockControls__js.js
generated
vendored
Normal file
7
node_modules/.vite/deps/three_addons_controls_PointerLockControls__js.js
generated
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
import {
|
||||||
|
PointerLockControls
|
||||||
|
} from "./chunk-PIN6L3XG.js";
|
||||||
|
import "./chunk-XSTVJSXX.js";
|
||||||
|
export {
|
||||||
|
PointerLockControls
|
||||||
|
};
|
||||||
7
node_modules/.vite/deps/three_addons_controls_PointerLockControls__js.js.map
generated
vendored
Normal file
7
node_modules/.vite/deps/three_addons_controls_PointerLockControls__js.js.map
generated
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"version": 3,
|
||||||
|
"sources": [],
|
||||||
|
"sourcesContent": [],
|
||||||
|
"mappings": "",
|
||||||
|
"names": []
|
||||||
|
}
|
||||||
7
node_modules/.vite/deps/three_examples_jsm_controls_PointerLockControls__js.js
generated
vendored
Normal file
7
node_modules/.vite/deps/three_examples_jsm_controls_PointerLockControls__js.js
generated
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
import {
|
||||||
|
PointerLockControls
|
||||||
|
} from "./chunk-PIN6L3XG.js";
|
||||||
|
import "./chunk-XSTVJSXX.js";
|
||||||
|
export {
|
||||||
|
PointerLockControls
|
||||||
|
};
|
||||||
7
node_modules/.vite/deps/three_examples_jsm_controls_PointerLockControls__js.js.map
generated
vendored
Normal file
7
node_modules/.vite/deps/three_examples_jsm_controls_PointerLockControls__js.js.map
generated
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"version": 3,
|
||||||
|
"sources": [],
|
||||||
|
"sourcesContent": [],
|
||||||
|
"mappings": "",
|
||||||
|
"names": []
|
||||||
|
}
|
||||||
@@ -1,3 +1,3 @@
|
|||||||
# esbuild
|
# esbuild
|
||||||
|
|
||||||
This is the macOS 64-bit binary for esbuild, a JavaScript bundler and minifier. See https://github.com/evanw/esbuild for details.
|
This is the Linux 64-bit binary for esbuild, a JavaScript bundler and minifier. See https://github.com/evanw/esbuild for details.
|
||||||
BIN
node_modules/@esbuild/darwin-x64/bin/esbuild → node_modules/@esbuild/linux-x64/bin/esbuild
generated
vendored
BIN
node_modules/@esbuild/darwin-x64/bin/esbuild → node_modules/@esbuild/linux-x64/bin/esbuild
generated
vendored
Binary file not shown.
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@esbuild/darwin-x64",
|
"name": "@esbuild/linux-x64",
|
||||||
"version": "0.27.2",
|
"version": "0.27.2",
|
||||||
"description": "The macOS 64-bit binary for esbuild, a JavaScript bundler.",
|
"description": "The Linux 64-bit binary for esbuild, a JavaScript bundler.",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git+https://github.com/evanw/esbuild.git"
|
"url": "git+https://github.com/evanw/esbuild.git"
|
||||||
@@ -12,7 +12,7 @@
|
|||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"linux"
|
||||||
],
|
],
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
3
node_modules/@rollup/rollup-darwin-x64/README.md
generated
vendored
3
node_modules/@rollup/rollup-darwin-x64/README.md
generated
vendored
@@ -1,3 +0,0 @@
|
|||||||
# `@rollup/rollup-darwin-x64`
|
|
||||||
|
|
||||||
This is the **x86_64-apple-darwin** binary for `rollup`
|
|
||||||
BIN
node_modules/@rollup/rollup-darwin-x64/rollup.darwin-x64.node
generated
vendored
BIN
node_modules/@rollup/rollup-darwin-x64/rollup.darwin-x64.node
generated
vendored
Binary file not shown.
3
node_modules/@rollup/rollup-linux-x64-gnu/README.md
generated
vendored
Normal file
3
node_modules/@rollup/rollup-linux-x64-gnu/README.md
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
# `@rollup/rollup-linux-x64-gnu`
|
||||||
|
|
||||||
|
This is the **x86_64-unknown-linux-gnu** binary for `rollup`
|
||||||
@@ -1,14 +1,14 @@
|
|||||||
{
|
{
|
||||||
"name": "@rollup/rollup-darwin-x64",
|
"name": "@rollup/rollup-linux-x64-gnu",
|
||||||
"version": "4.54.0",
|
"version": "4.54.0",
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"linux"
|
||||||
],
|
],
|
||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
"files": [
|
"files": [
|
||||||
"rollup.darwin-x64.node"
|
"rollup.linux-x64-gnu.node"
|
||||||
],
|
],
|
||||||
"description": "Native bindings for Rollup",
|
"description": "Native bindings for Rollup",
|
||||||
"author": "Lukas Taegert-Atkinson",
|
"author": "Lukas Taegert-Atkinson",
|
||||||
@@ -18,5 +18,8 @@
|
|||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git+https://github.com/rollup/rollup.git"
|
"url": "git+https://github.com/rollup/rollup.git"
|
||||||
},
|
},
|
||||||
"main": "./rollup.darwin-x64.node"
|
"libc": [
|
||||||
|
"glibc"
|
||||||
|
],
|
||||||
|
"main": "./rollup.linux-x64-gnu.node"
|
||||||
}
|
}
|
||||||
BIN
node_modules/@rollup/rollup-linux-x64-gnu/rollup.linux-x64-gnu.node
generated
vendored
Normal file
BIN
node_modules/@rollup/rollup-linux-x64-gnu/rollup.linux-x64-gnu.node
generated
vendored
Normal file
Binary file not shown.
BIN
node_modules/esbuild/bin/esbuild
generated
vendored
BIN
node_modules/esbuild/bin/esbuild
generated
vendored
Binary file not shown.
22
node_modules/fsevents/LICENSE
generated
vendored
22
node_modules/fsevents/LICENSE
generated
vendored
@@ -1,22 +0,0 @@
|
|||||||
MIT License
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Copyright (C) 2010-2020 by Philipp Dunkel, Ben Noordhuis, Elan Shankar, Paul Miller
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
|
||||||
in the Software without restriction, including without limitation the rights
|
|
||||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
||||||
copies of the Software, and to permit persons to whom the Software is
|
|
||||||
furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in
|
|
||||||
all copies or substantial portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
||||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
||||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
||||||
THE SOFTWARE.
|
|
||||||
89
node_modules/fsevents/README.md
generated
vendored
89
node_modules/fsevents/README.md
generated
vendored
@@ -1,89 +0,0 @@
|
|||||||
# fsevents
|
|
||||||
|
|
||||||
Native access to MacOS FSEvents in [Node.js](https://nodejs.org/)
|
|
||||||
|
|
||||||
The FSEvents API in MacOS allows applications to register for notifications of
|
|
||||||
changes to a given directory tree. It is a very fast and lightweight alternative
|
|
||||||
to kqueue.
|
|
||||||
|
|
||||||
This is a low-level library. For a cross-platform file watching module that
|
|
||||||
uses fsevents, check out [Chokidar](https://github.com/paulmillr/chokidar).
|
|
||||||
|
|
||||||
## Usage
|
|
||||||
|
|
||||||
```sh
|
|
||||||
npm install fsevents
|
|
||||||
```
|
|
||||||
|
|
||||||
Supports only **Node.js v8.16 and higher**.
|
|
||||||
|
|
||||||
```js
|
|
||||||
const fsevents = require('fsevents');
|
|
||||||
|
|
||||||
// To start observation
|
|
||||||
const stop = fsevents.watch(__dirname, (path, flags, id) => {
|
|
||||||
const info = fsevents.getInfo(path, flags);
|
|
||||||
});
|
|
||||||
|
|
||||||
// To end observation
|
|
||||||
stop();
|
|
||||||
```
|
|
||||||
|
|
||||||
> **Important note:** The API behaviour is slightly different from typical JS APIs. The `stop` function **must** be
|
|
||||||
> retrieved and stored somewhere, even if you don't plan to stop the watcher. If you forget it, the garbage collector
|
|
||||||
> will eventually kick in, the watcher will be unregistered, and your callbacks won't be called anymore.
|
|
||||||
|
|
||||||
The callback passed as the second parameter to `.watch` get's called whenever the operating system detects a
|
|
||||||
a change in the file system. It takes three arguments:
|
|
||||||
|
|
||||||
###### `fsevents.watch(dirname: string, (path: string, flags: number, id: string) => void): () => Promise<undefined>`
|
|
||||||
|
|
||||||
* `path: string` - the item in the filesystem that have been changed
|
|
||||||
* `flags: number` - a numeric value describing what the change was
|
|
||||||
* `id: string` - an unique-id identifying this specific event
|
|
||||||
|
|
||||||
Returns closer callback which when called returns a Promise resolving when the watcher process has been shut down.
|
|
||||||
|
|
||||||
###### `fsevents.getInfo(path: string, flags: number, id: string): FsEventInfo`
|
|
||||||
|
|
||||||
The `getInfo` function takes the `path`, `flags` and `id` arguments and converts those parameters into a structure
|
|
||||||
that is easier to digest to determine what the change was.
|
|
||||||
|
|
||||||
The `FsEventsInfo` has the following shape:
|
|
||||||
|
|
||||||
```js
|
|
||||||
/**
|
|
||||||
* @typedef {'created'|'modified'|'deleted'|'moved'|'root-changed'|'cloned'|'unknown'} FsEventsEvent
|
|
||||||
* @typedef {'file'|'directory'|'symlink'} FsEventsType
|
|
||||||
*/
|
|
||||||
{
|
|
||||||
"event": "created", // {FsEventsEvent}
|
|
||||||
"path": "file.txt",
|
|
||||||
"type": "file", // {FsEventsType}
|
|
||||||
"changes": {
|
|
||||||
"inode": true, // Had iNode Meta-Information changed
|
|
||||||
"finder": false, // Had Finder Meta-Data changed
|
|
||||||
"access": false, // Had access permissions changed
|
|
||||||
"xattrs": false // Had xAttributes changed
|
|
||||||
},
|
|
||||||
"flags": 0x100000000
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
## Changelog
|
|
||||||
|
|
||||||
- v2.3 supports Apple Silicon ARM CPUs
|
|
||||||
- v2 supports node 8.16+ and reduces package size massively
|
|
||||||
- v1.2.8 supports node 6+
|
|
||||||
- v1.2.7 supports node 4+
|
|
||||||
|
|
||||||
## Troubleshooting
|
|
||||||
|
|
||||||
- I'm getting `EBADPLATFORM` `Unsupported platform for fsevents` error.
|
|
||||||
- It's fine, nothing is broken. fsevents is macos-only. Other platforms are skipped. If you want to hide this warning, report a bug to NPM bugtracker asking them to hide ebadplatform warnings by default.
|
|
||||||
|
|
||||||
## License
|
|
||||||
|
|
||||||
The MIT License Copyright (C) 2010-2020 by Philipp Dunkel, Ben Noordhuis, Elan Shankar, Paul Miller — see LICENSE file.
|
|
||||||
|
|
||||||
Visit our [GitHub page](https://github.com/fsevents/fsevents) and [NPM Page](https://npmjs.org/package/fsevents)
|
|
||||||
46
node_modules/fsevents/fsevents.d.ts
generated
vendored
46
node_modules/fsevents/fsevents.d.ts
generated
vendored
@@ -1,46 +0,0 @@
|
|||||||
declare type Event = "created" | "cloned" | "modified" | "deleted" | "moved" | "root-changed" | "unknown";
|
|
||||||
declare type Type = "file" | "directory" | "symlink";
|
|
||||||
declare type FileChanges = {
|
|
||||||
inode: boolean;
|
|
||||||
finder: boolean;
|
|
||||||
access: boolean;
|
|
||||||
xattrs: boolean;
|
|
||||||
};
|
|
||||||
declare type Info = {
|
|
||||||
event: Event;
|
|
||||||
path: string;
|
|
||||||
type: Type;
|
|
||||||
changes: FileChanges;
|
|
||||||
flags: number;
|
|
||||||
};
|
|
||||||
declare type WatchHandler = (path: string, flags: number, id: string) => void;
|
|
||||||
export declare function watch(path: string, handler: WatchHandler): () => Promise<void>;
|
|
||||||
export declare function watch(path: string, since: number, handler: WatchHandler): () => Promise<void>;
|
|
||||||
export declare function getInfo(path: string, flags: number): Info;
|
|
||||||
export declare const constants: {
|
|
||||||
None: 0x00000000;
|
|
||||||
MustScanSubDirs: 0x00000001;
|
|
||||||
UserDropped: 0x00000002;
|
|
||||||
KernelDropped: 0x00000004;
|
|
||||||
EventIdsWrapped: 0x00000008;
|
|
||||||
HistoryDone: 0x00000010;
|
|
||||||
RootChanged: 0x00000020;
|
|
||||||
Mount: 0x00000040;
|
|
||||||
Unmount: 0x00000080;
|
|
||||||
ItemCreated: 0x00000100;
|
|
||||||
ItemRemoved: 0x00000200;
|
|
||||||
ItemInodeMetaMod: 0x00000400;
|
|
||||||
ItemRenamed: 0x00000800;
|
|
||||||
ItemModified: 0x00001000;
|
|
||||||
ItemFinderInfoMod: 0x00002000;
|
|
||||||
ItemChangeOwner: 0x00004000;
|
|
||||||
ItemXattrMod: 0x00008000;
|
|
||||||
ItemIsFile: 0x00010000;
|
|
||||||
ItemIsDir: 0x00020000;
|
|
||||||
ItemIsSymlink: 0x00040000;
|
|
||||||
ItemIsHardlink: 0x00100000;
|
|
||||||
ItemIsLastHardlink: 0x00200000;
|
|
||||||
OwnEvent: 0x00080000;
|
|
||||||
ItemCloned: 0x00400000;
|
|
||||||
};
|
|
||||||
export {};
|
|
||||||
83
node_modules/fsevents/fsevents.js
generated
vendored
83
node_modules/fsevents/fsevents.js
generated
vendored
@@ -1,83 +0,0 @@
|
|||||||
/*
|
|
||||||
** © 2020 by Philipp Dunkel, Ben Noordhuis, Elan Shankar, Paul Miller
|
|
||||||
** Licensed under MIT License.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* jshint node:true */
|
|
||||||
"use strict";
|
|
||||||
|
|
||||||
if (process.platform !== "darwin") {
|
|
||||||
throw new Error(`Module 'fsevents' is not compatible with platform '${process.platform}'`);
|
|
||||||
}
|
|
||||||
|
|
||||||
const Native = require("./fsevents.node");
|
|
||||||
const events = Native.constants;
|
|
||||||
|
|
||||||
function watch(path, since, handler) {
|
|
||||||
if (typeof path !== "string") {
|
|
||||||
throw new TypeError(`fsevents argument 1 must be a string and not a ${typeof path}`);
|
|
||||||
}
|
|
||||||
if ("function" === typeof since && "undefined" === typeof handler) {
|
|
||||||
handler = since;
|
|
||||||
since = Native.flags.SinceNow;
|
|
||||||
}
|
|
||||||
if (typeof since !== "number") {
|
|
||||||
throw new TypeError(`fsevents argument 2 must be a number and not a ${typeof since}`);
|
|
||||||
}
|
|
||||||
if (typeof handler !== "function") {
|
|
||||||
throw new TypeError(`fsevents argument 3 must be a function and not a ${typeof handler}`);
|
|
||||||
}
|
|
||||||
|
|
||||||
let instance = Native.start(Native.global, path, since, handler);
|
|
||||||
if (!instance) throw new Error(`could not watch: ${path}`);
|
|
||||||
return () => {
|
|
||||||
const result = instance ? Promise.resolve(instance).then(Native.stop) : Promise.resolve(undefined);
|
|
||||||
instance = undefined;
|
|
||||||
return result;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
function getInfo(path, flags) {
|
|
||||||
return {
|
|
||||||
path,
|
|
||||||
flags,
|
|
||||||
event: getEventType(flags),
|
|
||||||
type: getFileType(flags),
|
|
||||||
changes: getFileChanges(flags),
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
function getFileType(flags) {
|
|
||||||
if (events.ItemIsFile & flags) return "file";
|
|
||||||
if (events.ItemIsDir & flags) return "directory";
|
|
||||||
if (events.MustScanSubDirs & flags) return "directory";
|
|
||||||
if (events.ItemIsSymlink & flags) return "symlink";
|
|
||||||
}
|
|
||||||
function anyIsTrue(obj) {
|
|
||||||
for (let key in obj) {
|
|
||||||
if (obj[key]) return true;
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
function getEventType(flags) {
|
|
||||||
if (events.ItemRemoved & flags) return "deleted";
|
|
||||||
if (events.ItemRenamed & flags) return "moved";
|
|
||||||
if (events.ItemCreated & flags) return "created";
|
|
||||||
if (events.ItemModified & flags) return "modified";
|
|
||||||
if (events.RootChanged & flags) return "root-changed";
|
|
||||||
if (events.ItemCloned & flags) return "cloned";
|
|
||||||
if (anyIsTrue(flags)) return "modified";
|
|
||||||
return "unknown";
|
|
||||||
}
|
|
||||||
function getFileChanges(flags) {
|
|
||||||
return {
|
|
||||||
inode: !!(events.ItemInodeMetaMod & flags),
|
|
||||||
finder: !!(events.ItemFinderInfoMod & flags),
|
|
||||||
access: !!(events.ItemChangeOwner & flags),
|
|
||||||
xattrs: !!(events.ItemXattrMod & flags),
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
exports.watch = watch;
|
|
||||||
exports.getInfo = getInfo;
|
|
||||||
exports.constants = events;
|
|
||||||
BIN
node_modules/fsevents/fsevents.node
generated
vendored
BIN
node_modules/fsevents/fsevents.node
generated
vendored
Binary file not shown.
62
node_modules/fsevents/package.json
generated
vendored
62
node_modules/fsevents/package.json
generated
vendored
@@ -1,62 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "fsevents",
|
|
||||||
"version": "2.3.3",
|
|
||||||
"description": "Native Access to MacOS FSEvents",
|
|
||||||
"main": "fsevents.js",
|
|
||||||
"types": "fsevents.d.ts",
|
|
||||||
"os": [
|
|
||||||
"darwin"
|
|
||||||
],
|
|
||||||
"files": [
|
|
||||||
"fsevents.d.ts",
|
|
||||||
"fsevents.js",
|
|
||||||
"fsevents.node"
|
|
||||||
],
|
|
||||||
"engines": {
|
|
||||||
"node": "^8.16.0 || ^10.6.0 || >=11.0.0"
|
|
||||||
},
|
|
||||||
"scripts": {
|
|
||||||
"clean": "node-gyp clean && rm -f fsevents.node",
|
|
||||||
"build": "node-gyp clean && rm -f fsevents.node && node-gyp rebuild && node-gyp clean",
|
|
||||||
"test": "/bin/bash ./test.sh 2>/dev/null",
|
|
||||||
"prepublishOnly": "npm run build"
|
|
||||||
},
|
|
||||||
"repository": {
|
|
||||||
"type": "git",
|
|
||||||
"url": "https://github.com/fsevents/fsevents.git"
|
|
||||||
},
|
|
||||||
"keywords": [
|
|
||||||
"fsevents",
|
|
||||||
"mac"
|
|
||||||
],
|
|
||||||
"contributors": [
|
|
||||||
{
|
|
||||||
"name": "Philipp Dunkel",
|
|
||||||
"email": "pip@pipobscure.com"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "Ben Noordhuis",
|
|
||||||
"email": "info@bnoordhuis.nl"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "Elan Shankar",
|
|
||||||
"email": "elan.shanker@gmail.com"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "Miroslav Bajtoš",
|
|
||||||
"email": "mbajtoss@gmail.com"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "Paul Miller",
|
|
||||||
"url": "https://paulmillr.com"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"license": "MIT",
|
|
||||||
"bugs": {
|
|
||||||
"url": "https://github.com/fsevents/fsevents/issues"
|
|
||||||
},
|
|
||||||
"homepage": "https://github.com/fsevents/fsevents",
|
|
||||||
"devDependencies": {
|
|
||||||
"node-gyp": "^9.4.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
67
package-lock.json
generated
67
package-lock.json
generated
@@ -20,6 +20,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"ppc64"
|
"ppc64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"aix"
|
"aix"
|
||||||
@@ -35,6 +36,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm"
|
"arm"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"android"
|
"android"
|
||||||
@@ -50,6 +52,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"android"
|
"android"
|
||||||
@@ -65,6 +68,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"android"
|
"android"
|
||||||
@@ -80,6 +84,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"darwin"
|
||||||
@@ -95,6 +100,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"darwin"
|
||||||
@@ -110,6 +116,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"freebsd"
|
"freebsd"
|
||||||
@@ -125,6 +132,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"freebsd"
|
"freebsd"
|
||||||
@@ -140,6 +148,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm"
|
"arm"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -155,6 +164,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -170,6 +180,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"ia32"
|
"ia32"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -185,6 +196,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"loong64"
|
"loong64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -200,6 +212,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"mips64el"
|
"mips64el"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -215,6 +228,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"ppc64"
|
"ppc64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -230,6 +244,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"riscv64"
|
"riscv64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -245,6 +260,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"s390x"
|
"s390x"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -260,6 +276,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -275,6 +292,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"netbsd"
|
"netbsd"
|
||||||
@@ -290,6 +308,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"netbsd"
|
"netbsd"
|
||||||
@@ -305,6 +324,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"openbsd"
|
"openbsd"
|
||||||
@@ -320,6 +340,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"openbsd"
|
"openbsd"
|
||||||
@@ -335,6 +356,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"openharmony"
|
"openharmony"
|
||||||
@@ -350,6 +372,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"sunos"
|
"sunos"
|
||||||
@@ -365,6 +388,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"win32"
|
"win32"
|
||||||
@@ -380,6 +404,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"ia32"
|
"ia32"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"win32"
|
"win32"
|
||||||
@@ -395,6 +420,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"win32"
|
"win32"
|
||||||
@@ -410,6 +436,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm"
|
"arm"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"android"
|
"android"
|
||||||
@@ -422,6 +449,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"android"
|
"android"
|
||||||
@@ -434,6 +462,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"darwin"
|
||||||
@@ -446,6 +475,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"darwin"
|
||||||
@@ -458,6 +488,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"freebsd"
|
"freebsd"
|
||||||
@@ -470,6 +501,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"freebsd"
|
"freebsd"
|
||||||
@@ -482,6 +514,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm"
|
"arm"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -494,6 +527,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm"
|
"arm"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -506,6 +540,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -518,6 +553,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -530,6 +566,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"loong64"
|
"loong64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -542,6 +579,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"ppc64"
|
"ppc64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -554,6 +592,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"riscv64"
|
"riscv64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -566,6 +605,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"riscv64"
|
"riscv64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -578,6 +618,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"s390x"
|
"s390x"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -590,6 +631,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -602,6 +644,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"linux"
|
"linux"
|
||||||
@@ -614,6 +657,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"openharmony"
|
"openharmony"
|
||||||
@@ -626,6 +670,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"arm64"
|
"arm64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"win32"
|
"win32"
|
||||||
@@ -638,6 +683,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"ia32"
|
"ia32"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"win32"
|
"win32"
|
||||||
@@ -650,6 +696,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"win32"
|
"win32"
|
||||||
@@ -662,6 +709,7 @@
|
|||||||
"cpu": [
|
"cpu": [
|
||||||
"x64"
|
"x64"
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"win32"
|
"win32"
|
||||||
@@ -670,13 +718,15 @@
|
|||||||
"node_modules/@types/estree": {
|
"node_modules/@types/estree": {
|
||||||
"version": "1.0.8",
|
"version": "1.0.8",
|
||||||
"resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz",
|
"resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz",
|
||||||
"integrity": "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w=="
|
"integrity": "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==",
|
||||||
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/esbuild": {
|
"node_modules/esbuild": {
|
||||||
"version": "0.27.2",
|
"version": "0.27.2",
|
||||||
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.2.tgz",
|
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.2.tgz",
|
||||||
"integrity": "sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==",
|
"integrity": "sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==",
|
||||||
"hasInstallScript": true,
|
"hasInstallScript": true,
|
||||||
|
"license": "MIT",
|
||||||
"bin": {
|
"bin": {
|
||||||
"esbuild": "bin/esbuild"
|
"esbuild": "bin/esbuild"
|
||||||
},
|
},
|
||||||
@@ -716,6 +766,7 @@
|
|||||||
"version": "6.5.0",
|
"version": "6.5.0",
|
||||||
"resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz",
|
"resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz",
|
||||||
"integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==",
|
"integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==",
|
||||||
|
"license": "MIT",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=12.0.0"
|
"node": ">=12.0.0"
|
||||||
},
|
},
|
||||||
@@ -733,6 +784,7 @@
|
|||||||
"resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz",
|
"resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz",
|
||||||
"integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==",
|
"integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==",
|
||||||
"hasInstallScript": true,
|
"hasInstallScript": true,
|
||||||
|
"license": "MIT",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"os": [
|
"os": [
|
||||||
"darwin"
|
"darwin"
|
||||||
@@ -751,6 +803,7 @@
|
|||||||
"url": "https://github.com/sponsors/ai"
|
"url": "https://github.com/sponsors/ai"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"bin": {
|
"bin": {
|
||||||
"nanoid": "bin/nanoid.cjs"
|
"nanoid": "bin/nanoid.cjs"
|
||||||
},
|
},
|
||||||
@@ -761,12 +814,14 @@
|
|||||||
"node_modules/picocolors": {
|
"node_modules/picocolors": {
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",
|
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",
|
||||||
"integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA=="
|
"integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==",
|
||||||
|
"license": "ISC"
|
||||||
},
|
},
|
||||||
"node_modules/picomatch": {
|
"node_modules/picomatch": {
|
||||||
"version": "4.0.3",
|
"version": "4.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz",
|
"resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz",
|
||||||
"integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==",
|
"integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==",
|
||||||
|
"license": "MIT",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
},
|
},
|
||||||
@@ -792,6 +847,7 @@
|
|||||||
"url": "https://github.com/sponsors/ai"
|
"url": "https://github.com/sponsors/ai"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"nanoid": "^3.3.11",
|
"nanoid": "^3.3.11",
|
||||||
"picocolors": "^1.1.1",
|
"picocolors": "^1.1.1",
|
||||||
@@ -805,6 +861,7 @@
|
|||||||
"version": "4.54.0",
|
"version": "4.54.0",
|
||||||
"resolved": "https://registry.npmjs.org/rollup/-/rollup-4.54.0.tgz",
|
"resolved": "https://registry.npmjs.org/rollup/-/rollup-4.54.0.tgz",
|
||||||
"integrity": "sha512-3nk8Y3a9Ea8szgKhinMlGMhGMw89mqule3KWczxhIzqudyHdCIOHw8WJlj/r329fACjKLEh13ZSk7oE22kyeIw==",
|
"integrity": "sha512-3nk8Y3a9Ea8szgKhinMlGMhGMw89mqule3KWczxhIzqudyHdCIOHw8WJlj/r329fACjKLEh13ZSk7oE22kyeIw==",
|
||||||
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/estree": "1.0.8"
|
"@types/estree": "1.0.8"
|
||||||
},
|
},
|
||||||
@@ -845,6 +902,7 @@
|
|||||||
"version": "1.2.1",
|
"version": "1.2.1",
|
||||||
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz",
|
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz",
|
||||||
"integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",
|
"integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",
|
||||||
|
"license": "BSD-3-Clause",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=0.10.0"
|
"node": ">=0.10.0"
|
||||||
}
|
}
|
||||||
@@ -852,12 +910,14 @@
|
|||||||
"node_modules/three": {
|
"node_modules/three": {
|
||||||
"version": "0.182.0",
|
"version": "0.182.0",
|
||||||
"resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz",
|
"resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz",
|
||||||
"integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ=="
|
"integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ==",
|
||||||
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/tinyglobby": {
|
"node_modules/tinyglobby": {
|
||||||
"version": "0.2.15",
|
"version": "0.2.15",
|
||||||
"resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.15.tgz",
|
"resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.15.tgz",
|
||||||
"integrity": "sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==",
|
"integrity": "sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==",
|
||||||
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"fdir": "^6.5.0",
|
"fdir": "^6.5.0",
|
||||||
"picomatch": "^4.0.3"
|
"picomatch": "^4.0.3"
|
||||||
@@ -873,6 +933,7 @@
|
|||||||
"version": "7.3.0",
|
"version": "7.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/vite/-/vite-7.3.0.tgz",
|
"resolved": "https://registry.npmjs.org/vite/-/vite-7.3.0.tgz",
|
||||||
"integrity": "sha512-dZwN5L1VlUBewiP6H9s2+B3e3Jg96D0vzN+Ry73sOefebhYr9f94wwkMNN/9ouoU8pV1BqA1d1zGk8928cx0rg==",
|
"integrity": "sha512-dZwN5L1VlUBewiP6H9s2+B3e3Jg96D0vzN+Ry73sOefebhYr9f94wwkMNN/9ouoU8pV1BqA1d1zGk8928cx0rg==",
|
||||||
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"esbuild": "^0.27.0",
|
"esbuild": "^0.27.0",
|
||||||
"fdir": "^6.5.0",
|
"fdir": "^6.5.0",
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ export class Game {
|
|||||||
loop(time) {
|
loop(time) {
|
||||||
requestAnimationFrame(this.loop.bind(this));
|
requestAnimationFrame(this.loop.bind(this));
|
||||||
|
|
||||||
const dt = Math.min((time - this.lastTime) / 1000, 0.1); // Cap dt
|
const dt = this.lastTime === 0 ? 0 : Math.min((time - this.lastTime) / 1000, 0.1); // Cap dt
|
||||||
this.lastTime = time;
|
this.lastTime = time;
|
||||||
|
|
||||||
if (this.isRunning) {
|
if (this.isRunning) {
|
||||||
|
|||||||
@@ -4,23 +4,38 @@ export class Graphics {
|
|||||||
constructor() {
|
constructor() {
|
||||||
// Main scene rendering
|
// Main scene rendering
|
||||||
this.scene = new THREE.Scene();
|
this.scene = new THREE.Scene();
|
||||||
this.scene.fog = new THREE.Fog(0x000000, 2, 15);
|
this.scene.fog = new THREE.Fog(0x111122, 2, 15);
|
||||||
this.scene.background = new THREE.Color(0x000000);
|
this.scene.background = new THREE.Color(0x111122); // Dark blue background instead of black
|
||||||
|
|
||||||
this.camera = new THREE.PerspectiveCamera(70, window.innerWidth / window.innerHeight, 0.1, 100);
|
this.camera = new THREE.PerspectiveCamera(70, window.innerWidth / window.innerHeight, 0.1, 100);
|
||||||
|
|
||||||
// Real Screen Renderer
|
// Real Screen Renderer
|
||||||
this.renderer = new THREE.WebGLRenderer({ antialias: false });
|
this.renderer = new THREE.WebGLRenderer({ antialias: false });
|
||||||
this.renderer.setSize(window.innerWidth, window.innerHeight);
|
this.renderer.setSize(window.innerWidth, window.innerHeight);
|
||||||
document.getElementById('game-container').appendChild(this.renderer.domElement);
|
this.renderer.setClearColor(0xff00ff); // STRIKING MAGENTA for diagnostic
|
||||||
|
this.renderer.domElement.style.border = '5px solid yellow'; // VISIBLE BORDER
|
||||||
|
this.renderer.domElement.style.zIndex = '100'; // FORCE TO FRONT
|
||||||
|
this.renderer.domElement.id = 'three-canvas';
|
||||||
|
|
||||||
|
const container = document.getElementById('game-container');
|
||||||
|
if (container) {
|
||||||
|
container.appendChild(this.renderer.domElement);
|
||||||
|
window.log('Renderer attached to DOM');
|
||||||
|
} else {
|
||||||
|
window.log('ERROR: game-container not found');
|
||||||
|
}
|
||||||
|
|
||||||
|
this.scene.add(new THREE.AxesHelper(10)); // Add axis lines (Red, Green, Blue)
|
||||||
|
this.camera.position.set(5, 5, 5); // Move camera out of the floor
|
||||||
|
this.camera.lookAt(0, 0, 0);
|
||||||
|
|
||||||
// --- Retro Pipeline Setup ---
|
// --- Retro Pipeline Setup ---
|
||||||
|
|
||||||
// 1. Off-screen Render Target (Small Resolution)
|
// 1. Off-screen Render Target (Small Resolution)
|
||||||
// We render the 3D scene here first.
|
// We render the 3D scene here first.
|
||||||
this.targetWidth = 320;
|
this.targetWidth = 320;
|
||||||
this.targetHeight = 240;
|
this.targetHeight = 240;
|
||||||
|
|
||||||
this.renderTarget = new THREE.WebGLRenderTarget(this.targetWidth, this.targetHeight, {
|
this.renderTarget = new THREE.WebGLRenderTarget(this.targetWidth, this.targetHeight, {
|
||||||
minFilter: THREE.NearestFilter,
|
minFilter: THREE.NearestFilter,
|
||||||
magFilter: THREE.NearestFilter,
|
magFilter: THREE.NearestFilter,
|
||||||
@@ -38,7 +53,7 @@ export class Graphics {
|
|||||||
const postMaterial = new THREE.ShaderMaterial({
|
const postMaterial = new THREE.ShaderMaterial({
|
||||||
uniforms: {
|
uniforms: {
|
||||||
tDiffuse: { value: this.renderTarget.texture },
|
tDiffuse: { value: this.renderTarget.texture },
|
||||||
colorDepth: { value: 32.0 } // 32 levels per channel (5-bit)
|
colorDepth: { value: 16.0 } // 16 levels per channel (4-bit per channel - 4096 colors)
|
||||||
},
|
},
|
||||||
vertexShader: `
|
vertexShader: `
|
||||||
varying vec2 vUv;
|
varying vec2 vUv;
|
||||||
@@ -53,8 +68,8 @@ export class Graphics {
|
|||||||
varying vec2 vUv;
|
varying vec2 vUv;
|
||||||
void main() {
|
void main() {
|
||||||
vec4 tex = texture2D(tDiffuse, vUv);
|
vec4 tex = texture2D(tDiffuse, vUv);
|
||||||
// Quantize color
|
// Quantize color and ensure it's not absolutely zeroed if there's light
|
||||||
vec3 color = floor(tex.rgb * colorDepth) / colorDepth;
|
vec3 color = floor(tex.rgb * colorDepth + 0.5) / colorDepth;
|
||||||
gl_FragColor = vec4(color, tex.a);
|
gl_FragColor = vec4(color, tex.a);
|
||||||
}
|
}
|
||||||
`
|
`
|
||||||
@@ -74,7 +89,7 @@ export class Graphics {
|
|||||||
|
|
||||||
handleResize() {
|
handleResize() {
|
||||||
const aspect = window.innerWidth / window.innerHeight;
|
const aspect = window.innerWidth / window.innerHeight;
|
||||||
|
|
||||||
// Update 3D Camera
|
// Update 3D Camera
|
||||||
this.camera.aspect = aspect;
|
this.camera.aspect = aspect;
|
||||||
this.camera.updateProjectionMatrix();
|
this.camera.updateProjectionMatrix();
|
||||||
@@ -89,6 +104,17 @@ export class Graphics {
|
|||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
|
if (!this.renderCount) this.renderCount = 0;
|
||||||
|
this.renderCount++;
|
||||||
|
if (this.renderCount % 100 === 0) window.log(`Rendering frame ${this.renderCount}`);
|
||||||
|
|
||||||
|
// --- Diagnostic: Render directly to screen ---
|
||||||
|
// 1. Render 3D Scene to Screen
|
||||||
|
this.renderer.setRenderTarget(null);
|
||||||
|
this.renderer.render(this.scene, this.camera);
|
||||||
|
|
||||||
|
/*
|
||||||
|
// Original Post-Processing Pipeline
|
||||||
// 1. Render 3D Scene to RenderTarget
|
// 1. Render 3D Scene to RenderTarget
|
||||||
this.renderer.setRenderTarget(this.renderTarget);
|
this.renderer.setRenderTarget(this.renderTarget);
|
||||||
this.renderer.render(this.scene, this.camera);
|
this.renderer.render(this.scene, this.camera);
|
||||||
@@ -96,5 +122,6 @@ export class Graphics {
|
|||||||
// 2. Render Post-Processing Quad to Screen
|
// 2. Render Post-Processing Quad to Screen
|
||||||
this.renderer.setRenderTarget(null);
|
this.renderer.setRenderTarget(null);
|
||||||
this.renderer.render(this.postScene, this.postCamera);
|
this.renderer.render(this.postScene, this.postCamera);
|
||||||
|
*/
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import * as THREE from 'three';
|
import * as THREE from 'three';
|
||||||
import { PointerLockControls } from 'three/addons/controls/PointerLockControls.js';
|
import { PointerLockControls } from 'three/examples/jsm/controls/PointerLockControls.js';
|
||||||
|
|
||||||
export class Player {
|
export class Player {
|
||||||
constructor(camera, colliders) {
|
constructor(camera, colliders) {
|
||||||
@@ -20,8 +20,23 @@ export class Player {
|
|||||||
this.moveRight = false;
|
this.moveRight = false;
|
||||||
this.velocity = new THREE.Vector3();
|
this.velocity = new THREE.Vector3();
|
||||||
this.direction = new THREE.Vector3();
|
this.direction = new THREE.Vector3();
|
||||||
|
this.flashlightOn = true; // Started as ON
|
||||||
|
|
||||||
this.setupInput();
|
this.setupInput();
|
||||||
|
this.setupFlashlight();
|
||||||
|
}
|
||||||
|
|
||||||
|
setupFlashlight() {
|
||||||
|
this.flashlight = new THREE.SpotLight(0xffffff, 10);
|
||||||
|
this.flashlight.angle = Math.PI / 6;
|
||||||
|
this.flashlight.penumbra = 0.3;
|
||||||
|
this.flashlight.decay = 2;
|
||||||
|
this.flashlight.distance = 15;
|
||||||
|
|
||||||
|
this.camera.add(this.flashlight);
|
||||||
|
this.flashlight.position.set(0, 0, 0);
|
||||||
|
this.flashlight.target.position.set(0, 0, -1);
|
||||||
|
this.camera.add(this.flashlight.target);
|
||||||
}
|
}
|
||||||
|
|
||||||
setupInput() {
|
setupInput() {
|
||||||
@@ -31,6 +46,7 @@ export class Player {
|
|||||||
case 'KeyA': this.moveLeft = true; break;
|
case 'KeyA': this.moveLeft = true; break;
|
||||||
case 'KeyS': this.moveBackward = true; break;
|
case 'KeyS': this.moveBackward = true; break;
|
||||||
case 'KeyD': this.moveRight = true; break;
|
case 'KeyD': this.moveRight = true; break;
|
||||||
|
case 'KeyF': this.toggleFlashlight(); break;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -47,6 +63,14 @@ export class Player {
|
|||||||
document.addEventListener('keyup', onKeyUp);
|
document.addEventListener('keyup', onKeyUp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
toggleFlashlight() {
|
||||||
|
if (!this.controls.isLocked) return; // Only toggle when game is active
|
||||||
|
this.flashlightOn = !this.flashlightOn;
|
||||||
|
if (this.flashlight) {
|
||||||
|
this.flashlight.visible = this.flashlightOn;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
lockControls() {
|
lockControls() {
|
||||||
this.controls.lock();
|
this.controls.lock();
|
||||||
}
|
}
|
||||||
@@ -105,5 +129,10 @@ export class Player {
|
|||||||
|
|
||||||
// Keep player on ground
|
// Keep player on ground
|
||||||
playerPos.y = this.height;
|
playerPos.y = this.height;
|
||||||
|
|
||||||
|
// Flashlight flicker effect (subtle)
|
||||||
|
if (this.flashlight && this.flashlightOn) {
|
||||||
|
this.flashlight.intensity = 10 + Math.random() * 0.5;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
17
src/World.js
17
src/World.js
@@ -7,15 +7,14 @@ export class World {
|
|||||||
}
|
}
|
||||||
|
|
||||||
load() {
|
load() {
|
||||||
// Basic lighting
|
// Grid helper for depth
|
||||||
const ambientLight = new THREE.AmbientLight(0x404040, 0.5); // Dim ambient
|
this.scene.add(new THREE.GridHelper(20, 20));
|
||||||
this.scene.add(ambientLight);
|
|
||||||
|
|
||||||
// Floor
|
// Floor (Basic Material - no light needed)
|
||||||
const floorGeo = new THREE.PlaneGeometry(20, 20);
|
const floorGeo = new THREE.PlaneGeometry(20, 20);
|
||||||
const floorMat = new THREE.MeshStandardMaterial({
|
const floorMat = new THREE.MeshBasicMaterial({
|
||||||
color: 0x333333,
|
color: 0x333333,
|
||||||
roughness: 0.8
|
side: THREE.DoubleSide
|
||||||
});
|
});
|
||||||
const floor = new THREE.Mesh(floorGeo, floorMat);
|
const floor = new THREE.Mesh(floorGeo, floorMat);
|
||||||
floor.rotation.x = -Math.PI / 2;
|
floor.rotation.x = -Math.PI / 2;
|
||||||
@@ -27,10 +26,10 @@ export class World {
|
|||||||
this.createWall(-10, 2.5, 0, 20, 5, true); // Left
|
this.createWall(-10, 2.5, 0, 20, 5, true); // Left
|
||||||
this.createWall(10, 2.5, 0, 20, 5, true); // Right
|
this.createWall(10, 2.5, 0, 20, 5, true); // Right
|
||||||
|
|
||||||
// Add a reference cube to see depth
|
// Add a reference cube (Bright Yellow Basic Material)
|
||||||
const cube = new THREE.Mesh(
|
const cube = new THREE.Mesh(
|
||||||
new THREE.BoxGeometry(1, 1, 1),
|
new THREE.BoxGeometry(1, 1, 1),
|
||||||
new THREE.MeshStandardMaterial({ color: 0xff0000 })
|
new THREE.MeshBasicMaterial({ color: 0xffff00 })
|
||||||
);
|
);
|
||||||
cube.position.set(0, 0.5, -5);
|
cube.position.set(0, 0.5, -5);
|
||||||
this.scene.add(cube);
|
this.scene.add(cube);
|
||||||
@@ -39,7 +38,7 @@ export class World {
|
|||||||
|
|
||||||
createWall(x, y, z, width, height, rotate = false) {
|
createWall(x, y, z, width, height, rotate = false) {
|
||||||
const geo = new THREE.BoxGeometry(width, height, 0.5);
|
const geo = new THREE.BoxGeometry(width, height, 0.5);
|
||||||
const mat = new THREE.MeshStandardMaterial({ color: 0x555555 });
|
const mat = new THREE.MeshBasicMaterial({ color: 0x555555 });
|
||||||
const wall = new THREE.Mesh(geo, mat);
|
const wall = new THREE.Mesh(geo, mat);
|
||||||
wall.position.set(x, y, z);
|
wall.position.set(x, y, z);
|
||||||
if (rotate) wall.rotation.y = Math.PI / 2;
|
if (rotate) wall.rotation.y = Math.PI / 2;
|
||||||
|
|||||||
@@ -1,6 +1,14 @@
|
|||||||
|
window.log = (msg) => {
|
||||||
|
const logDiv = document.getElementById('debug-log');
|
||||||
|
if (logDiv) logDiv.innerHTML += `> ${msg}<br>`;
|
||||||
|
console.log(msg);
|
||||||
|
};
|
||||||
|
|
||||||
import { Game } from './Game.js';
|
import { Game } from './Game.js';
|
||||||
|
|
||||||
window.addEventListener('DOMContentLoaded', () => {
|
window.addEventListener('DOMContentLoaded', () => {
|
||||||
|
window.log('DOM Content Loaded');
|
||||||
const game = new Game();
|
const game = new Game();
|
||||||
game.start();
|
game.start();
|
||||||
|
window.log('Game Started');
|
||||||
});
|
});
|
||||||
|
|||||||
8
vite.config.js
Normal file
8
vite.config.js
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
import { defineConfig } from 'vite';
|
||||||
|
|
||||||
|
export default defineConfig({
|
||||||
|
server: {
|
||||||
|
host: '0.0.0.0',
|
||||||
|
port: 5173,
|
||||||
|
},
|
||||||
|
});
|
||||||
Reference in New Issue
Block a user