/** * Implentation of the saturn. * Texture from https://www.solarsystemscope.com/textures/1 */ import * as THREE from '/website/node_modules/three/build/three.module.js'; const saturnRingTexture = new THREE.TextureLoader().load('/website/saturn/saturnring.jpg'); const saturnRing = new THREE.TorusGeometry(12, 1, 16, 60); const materialRing = new THREE.MeshStandardMaterial({ map: saturnRingTexture }); export const saturn = new THREE.Mesh( saturnRing, materialRing ); // Den Saturnplaneten hinzufuegen const saturnTexture = new THREE.TextureLoader().load('/website/saturn/saturn.jpg'); const saturnPlanet = new THREE.SphereGeometry( 10, 32, 16 ); const materialSaturn = new THREE.MeshStandardMaterial( { map: saturnTexture } ); const saturnSphere = new THREE.Mesh( saturnPlanet, materialSaturn ); saturn.add(saturnSphere) saturn.position.x = 210; export function rotation(){ saturn.rotation.x -= 0.01; saturn.rotation.y -= 0.01; saturn.rotation.z -= 0.01; }