/** * Implentation of the earth. * Texture from https://upload.wikimedia.org/wikipedia/commons/d/d6/Nasa_land_ocean_ice_8192.jpg */ import * as THREE from '/website/node_modules/three/build/three.module.js'; const pi = 3; const moonTexture = new THREE.TextureLoader().load('/website/moon/moon.jpg'); const moonSphere = new THREE.SphereGeometry(3, 32, 16); const material = new THREE.MeshStandardMaterial({ map: moonTexture }); export const moon = new THREE.Mesh( moonSphere, material ); moon.position.x = -15; moon.position.z = 10; export function rotation(){ moon.rotation.x -= 0.01; moon.rotation.y -= 0.01; moon.rotation.z -= 0.01; } function forward(){ }