diff --git a/js/intro-scene.js b/js/intro-scene.js index 5e5a1d2..df5c0d2 100644 --- a/js/intro-scene.js +++ b/js/intro-scene.js @@ -136,12 +136,16 @@ function tick() { planeHolder.position.set(px, py + bob, 0); - /* Banking — léger roulis + nez relevé (cabré réaliste) */ - const targetRoll = 0.18 + (p - 0.5) * 0.25; // .z = roulis - const targetPitch = -0.18 - p * 0.04; // .x = nez en l'air ~10° - const targetYaw = -(p - 0.5) * 0.10; // .y = soupçon de yaw - planeHolder.rotation.z += (targetRoll - planeHolder.rotation.z) * 0.08; - planeHolder.rotation.x += (targetPitch - planeHolder.rotation.x) * 0.08; + /* Pour un avion volant -X (nose à gauche), avec up = +Y : + - rotation.z (axe latéral du monde) = PITCH. Négatif → nez en l'air. + - rotation.x (axe longitudinal du monde) = ROLL. + - rotation.y (axe vertical du monde) = YAW. + */ + const targetPitch = -0.30 - p * 0.05; // ~17°-20° nez en l'air (montée) + const targetRoll = 0.12 + (p - 0.5) * 0.10; // léger roulis + const targetYaw = 0; + planeHolder.rotation.z += (targetPitch - planeHolder.rotation.z) * 0.08; + planeHolder.rotation.x += (targetRoll - planeHolder.rotation.x) * 0.08; planeHolder.rotation.y += (targetYaw - planeHolder.rotation.y) * 0.08; renderer.render(scene, camera);