From 424e60111b1676b6f0bb61bc4eaf03358055df0e Mon Sep 17 00:00:00 2001 From: Bachir Soussi Chiadmi Date: Mon, 12 Oct 2020 14:51:57 +0200 Subject: [PATCH] solwed down building entering --- src/App.vue | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/App.vue b/src/App.vue index 14bc63a..9b4d5ea 100644 --- a/src/App.vue +++ b/src/App.vue @@ -336,9 +336,10 @@ export default { this.opened_vnode = vnode // get new camera target pos - let toPos + let toPos, tweenTime if (object.name === 'Content') { toPos = { ...object.position } + tweenTime = 3000 this.controls.lat = 0 switch (vnode.face) { case 'left': @@ -367,12 +368,13 @@ export default { } else if (object.name === 'Project') { toPos = { ...object.userData.position } toPos.y = 2 + tweenTime = 7000 } // toPos.y = 5 let camPos = { ...this.camera.position } new TWEEN.Tween(camPos) .easing(TWEEN.Easing.Quadratic.InOut) - .to(toPos, 3000) + .to(toPos, tweenTime) .onUpdate(function () { // console.log('tween update', this._object) cam.position.set(this._object.x, this._object.y, this._object.z)