Dies ist das Repository meines kleinen Portfolios. Im Hintergrund läuft eine Planetensimulation, geschrieben in JavaScript und Three.js. Die zu sehenden Texturen stammen von: https://www.solarsystemscope.com/textures/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
658 B

/**
* 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.y += 0.01;
moon.rotation.z += 0.01;
}
function forward(){
}