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.
 
 
 

20 lines
584 B

/**
* Implentation of the mars.
* Texture from https://www.solarsystemscope.com/textures/1
*/
import * as THREE from '/website/node_modules/three/build/three.module.js';
const marsTexture = new THREE.TextureLoader().load('/website/mars/mars.jpg');
const marsSphere = new THREE.SphereGeometry(10, 32, 16);
const material = new THREE.MeshStandardMaterial({ map: marsTexture });
export const mars = new THREE.Mesh( marsSphere, material );
mars.position.x = 130;
export function rotation(){
mars.rotation.x -= 0.01;
mars.rotation.y -= 0.01;
mars.rotation.z -= 0.01;
}