1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-06-06 18:04:12 +02:00
This commit is contained in:
syuilo
2026-02-09 20:35:22 +09:00
parent 8619367ac0
commit 09993a8ac8
2 changed files with 38 additions and 23 deletions

View File

@@ -86,6 +86,11 @@ onMounted(() => {
type: 'steel-rack',
position: [130, 0, 115],
rotation: [0, 0, 0],
}, {
id: 'k',
type: 'cup-noodle',
position: [-100, 70, 40],
rotation: [0, -2, 0],
}],
});

View File

@@ -23,16 +23,10 @@ type ObjectDef = {
onInit?: (room: RoomEngine, obj: BABYLON.ISceneLoaderAsyncResult) => void;
};
const OBJECTS = {
plant: {
placement: 'top',
},
mug: {
placement: 'top',
onInit: (room, obj) => {
function yuge(room: RoomEngine, obj: BABYLON.ISceneLoaderAsyncResult, offset: BABYLON.Vector3) {
const emitter = new BABYLON.TransformNode('emitter', room.scene);
emitter.parent = obj.meshes[0];
emitter.position = new BABYLON.Vector3(0, 5/*cm*/, 0);
emitter.position = offset;
const ps = new BABYLON.ParticleSystem('steamParticleSystem', 8, room.scene);
ps.particleTexture = new BABYLON.Texture('/client-assets/room/steam.png');
ps.emitter = emitter;
@@ -53,6 +47,22 @@ const OBJECTS = {
ps.colorDead = new BABYLON.Color4(1, 1, 1, 0);
ps.preWarmCycles = 350;
ps.start();
}
const OBJECTS = {
plant: {
placement: 'top',
},
mug: {
placement: 'top',
onInit: (room, obj) => {
yuge(room, obj, new BABYLON.Vector3(0, 5/*cm*/, 0));
},
},
'cup-noodle': {
placement: 'top',
onInit: (room, obj) => {
yuge(room, obj, new BABYLON.Vector3(0, 10/*cm*/, 0));
},
},
stickyNote: {