mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-05-13 14:05:35 +02:00
Update books.ts
This commit is contained in:
@@ -25,6 +25,7 @@ export const books = defineObject({
|
||||
placement: 'top',
|
||||
hasCollisions: false,
|
||||
hasTexture: true,
|
||||
canPreMeshesMerging: false,
|
||||
createInstance: ({ scene, options, model }) => {
|
||||
const coverMaterial = model.findMaterial('__X_COVER__');
|
||||
|
||||
@@ -54,14 +55,16 @@ export const books = defineObject({
|
||||
];
|
||||
|
||||
for (const meshes of bookMeshes) {
|
||||
const z = Math.random() * cm(0.005);
|
||||
const y = Math.random() * cm(0.0025);
|
||||
const z = Math.random() * 0.005;
|
||||
const y = Math.random() * 0.0025;
|
||||
for (const mesh of meshes) {
|
||||
mesh.position.z -= z;
|
||||
mesh.position.y += y;
|
||||
}
|
||||
}
|
||||
|
||||
model.updated();
|
||||
|
||||
return {
|
||||
onOptionsUpdated: ([k, v]) => {
|
||||
applyVariation();
|
||||
|
||||
Reference in New Issue
Block a user