mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-06-06 08:44:06 +02:00
wip
This commit is contained in:
Binary file not shown.
Binary file not shown.
BIN
packages/frontend/assets/room/rooms/museum/floor.jpg
Normal file
BIN
packages/frontend/assets/room/rooms/museum/floor.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 626 KiB |
BIN
packages/frontend/assets/room/rooms/museum/museum.blend
Normal file
BIN
packages/frontend/assets/room/rooms/museum/museum.blend
Normal file
Binary file not shown.
@@ -279,13 +279,6 @@ export class RoomEngine extends EventEmitter {
|
|||||||
this.envMapOutdoor = BABYLON.CubeTexture.CreateFromPrefilteredData(this.time === 2 ? '/client-assets/room/outdoor-night.env' : '/client-assets/room/outdoor-day.env', this.scene);
|
this.envMapOutdoor = BABYLON.CubeTexture.CreateFromPrefilteredData(this.time === 2 ? '/client-assets/room/outdoor-night.env' : '/client-assets/room/outdoor-day.env', this.scene);
|
||||||
this.envMapOutdoor.level = this.time === 0 ? 0.5 : this.time === 1 ? 0.3 : 0.1;
|
this.envMapOutdoor.level = this.time === 0 ? 0.5 : this.time === 1 ? 0.3 : 0.1;
|
||||||
|
|
||||||
const roomCollisionCube = BABYLON.MeshBuilder.CreateBox('roomCollisionCube', { size: cm(300) }, this.scene);
|
|
||||||
roomCollisionCube.position.y = cm(150);
|
|
||||||
roomCollisionCube.scaling.x = -1; // flip normals
|
|
||||||
roomCollisionCube.isVisible = false;
|
|
||||||
roomCollisionCube.isPickable = false;
|
|
||||||
roomCollisionCube.checkCollisions = true;
|
|
||||||
|
|
||||||
this.scene.collisionsEnabled = true;
|
this.scene.collisionsEnabled = true;
|
||||||
|
|
||||||
this.camera = new BABYLON.FreeCamera('camera', new BABYLON.Vector3(0, cm(130), cm(0)), this.scene);
|
this.camera = new BABYLON.FreeCamera('camera', new BABYLON.Vector3(0, cm(130), cm(0)), this.scene);
|
||||||
@@ -871,6 +864,9 @@ export class RoomEngine extends EventEmitter {
|
|||||||
m.receiveShadows = false;
|
m.receiveShadows = false;
|
||||||
m.isVisible = false;
|
m.isVisible = false;
|
||||||
m.checkCollisions = false;
|
m.checkCollisions = false;
|
||||||
|
if (m.name.includes('__COLLISION__')) {
|
||||||
|
m.checkCollisions = true;
|
||||||
|
}
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
import * as BABYLON from '@babylonjs/core';
|
import * as BABYLON from '@babylonjs/core';
|
||||||
import { WORLD_SCALE } from '../utility.js';
|
import { cm, WORLD_SCALE } from '../utility.js';
|
||||||
import { findMaterial } from './utility.js';
|
import { findMaterial } from './utility.js';
|
||||||
|
|
||||||
//export interface HeyaManager<T = any> {
|
//export interface HeyaManager<T = any> {
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import * as BABYLON from '@babylonjs/core';
|
|||||||
import { applyMorphTargetsToMesh, cm, getPlaneUvIndexes, Timer } from '../utility.js';
|
import { applyMorphTargetsToMesh, cm, getPlaneUvIndexes, Timer } from '../utility.js';
|
||||||
|
|
||||||
export const SYSTEM_MESH_NAMES = ['__TOP__', '__SIDE__', '__PICK__', '__COLLISION__'];
|
export const SYSTEM_MESH_NAMES = ['__TOP__', '__SIDE__', '__PICK__', '__COLLISION__'];
|
||||||
export const SYSTEM_HEYA_MESH_NAMES = ['__ROOM_WALL__', '__ROOM_SIDE__', '__ROOM_FLOOR__', '__ROOM_CEILING__', '__ROOM_TOP__', '__ROOM_BOTTOM__'];
|
export const SYSTEM_HEYA_MESH_NAMES = ['__ROOM_WALL__', '__ROOM_SIDE__', '__ROOM_FLOOR__', '__ROOM_CEILING__', '__ROOM_TOP__', '__ROOM_BOTTOM__', '__COLLISION__'];
|
||||||
|
|
||||||
export function yuge(scene: BABYLON.Scene, mesh: BABYLON.Mesh, offset: BABYLON.Vector3) {
|
export function yuge(scene: BABYLON.Scene, mesh: BABYLON.Mesh, offset: BABYLON.Vector3) {
|
||||||
const emitter = new BABYLON.TransformNode('emitter', scene);
|
const emitter = new BABYLON.TransformNode('emitter', scene);
|
||||||
|
|||||||
Reference in New Issue
Block a user