1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-20 21:05:28 +02:00
This commit is contained in:
syuilo
2026-04-15 08:51:47 +09:00
parent cf9349f29c
commit 3db0b8a1fd
16 changed files with 126 additions and 116 deletions

View File

@@ -5,7 +5,7 @@
import * as BABYLON from '@babylonjs/core';
import { defineObject } from '../engine.js';
import { createPlaneUvMapper } from '../utility.js';
import { cm, createPlaneUvMapper } from '../utility.js';
export const allInOnePc = defineObject({
id: 'allInOnePc',
@@ -51,10 +51,10 @@ export const allInOnePc = defineObject({
const scale = new BABYLON.Vector3();
matrix.decompose(scale);
const light = new BABYLON.SpotLight('', new BABYLON.Vector3(0/*cm*/, 30/*cm*/ / Math.abs(scale.y), 0), new BABYLON.Vector3(0, 0, 1), Math.PI / 1, 2, scene, room?.lightContainer != null);
const light = new BABYLON.SpotLight('', new BABYLON.Vector3(cm(0), cm(30) / Math.abs(scale.y), 0), new BABYLON.Vector3(0, 0, 1), Math.PI / 1, 2, scene, room?.lightContainer != null);
light.parent = model.root;
light.diffuse = new BABYLON.Color3(1.0, 1.0, 1.0);
light.range = 100/*cm*/;
light.range = cm(100);
if (room?.lightContainer != null) room.lightContainer.addLight(light);
const screenMesh = model.findMesh('__X_SCREEN__');