2.2K tris9.66 × 6.98 × 9.66 m
Use it in code
Remix in the editorlunar-lander.js · 572 lines
Self-contained ES module — only depends on three. Call the factory and add the group to your scene.
/**
* Lunar Lander — Codels 3D model library
* License: CC0-1.0 · Units: meters · Y-up · Front: +Z · Origin: center of the base (y = 0)
* Triangles: 2,234 · Size (W × H × D): 9.66 × 6.98 × 9.66 m
*
* Usage:
* import { createLunarLander } from './lunar-lander.js';
*
* const model = createLunarLander();
* model.position.set(0, 0, 0);
* scene.add(model);
*/
import * as THREE from 'three';
const deg = THREE.MathUtils.degToRad;
// Extrude a 2D outline along Z (centered). bevel = [thickness, size, segments].
function extrude(outline, depth, holes = [], bevel = null) {
const shape = new THREE.Shape(outline.map(([x, y]) => new THREE.Vector2(x, y)));
for (const hole of holes) shape.holes.push(new THREE.Path(hole.map(([x, y]) => new THREE.Vector2(x, y))));
const options = bevel
? { depth, bevelEnabled: true, bevelThickness: bevel[0], bevelSize: bevel[1], bevelSegments: bevel[2] }
: { depth, bevelEnabled: false };
return new THREE.ExtrudeGeometry(shape, options).translate(0, 0, -depth / 2);
}
export function createLunarLander() {
const root = new THREE.Group();
root.name = 'LunarLander';
// Materials
const foilMat = new THREE.MeshStandardMaterial({ name: 'foil', color: 0xd9a33b, roughness: 0.3, metalness: 0.65, flatShading: true });
const foilDarkMat = new THREE.MeshStandardMaterial({ name: 'foilDark', color: 0x987229, roughness: 0.35, metalness: 0.6, flatShading: true });
const cabinMat = new THREE.MeshStandardMaterial({ name: 'cabin', color: 0xc4c7cd, roughness: 0.5, metalness: 0.35, flatShading: true });
const blackMat = new THREE.MeshStandardMaterial({ name: 'black', color: 0x26272b, roughness: 0.7, metalness: 0.2, flatShading: true });
const metalMat = new THREE.MeshStandardMaterial({ name: 'metal', color: 0xa3a8b0, roughness: 0.35, metalness: 0.75, flatShading: true, side: THREE.DoubleSide });
const glassMat = new THREE.MeshStandardMaterial({ name: 'glass', color: 0x25313e, roughness: 0.2, metalness: 0.35 });
// Shared geometries
const boxGeo = new THREE.BoxGeometry(1.62, 1.419, 0.06);
const boxGeo2 = new THREE.BoxGeometry(0.06, 0.8, 1);
const boxGeo3 = new THREE.BoxGeometry(0.04, 0.5, 0.04);
const cylinderGeo = new THREE.CylinderGeometry(0.09, 0.11, 3.6412, 8);
const cylinderGeo2 = new THREE.CylinderGeometry(0.075, 0.075, 1.1399, 6);
const cylinderGeo3 = new THREE.CylinderGeometry(0.05, 0.05, 1.735, 6);
const cylinderGeo4 = new THREE.CylinderGeometry(0.48, 0.34, 0.16, 12);
const cylinderGeo5 = new THREE.CylinderGeometry(0.12, 0.14, 0.18, 6);
const cylinderGeo6 = new THREE.CylinderGeometry(0.025, 0.025, 2.7037, 4);
const boxGeo4 = new THREE.BoxGeometry(0.6, 0.035, 0.05);
const cylinderGeo7 = new THREE.CylinderGeometry(0.95, 0.95, 0.3, 10);
const boxGeo5 = new THREE.BoxGeometry(0.06, 0.7, 0.9);
const cylinderGeo8 = new THREE.CylinderGeometry(0.015, 0.015, 1.3, 4);
const boxGeo6 = new THREE.BoxGeometry(0.9, 0.08, 0.08);
const boxGeo7 = new THREE.BoxGeometry(0.26, 0.26, 0.26);
const coneGeo = new THREE.ConeGeometry(0.07, 0.16, 6, 1, true);
const cylinderGeo9 = new THREE.CylinderGeometry(0.06, 0.06, 0.01, 6);
// Parts
const descentStage = new THREE.Group();
descentStage.name = 'descentStage';
root.add(descentStage);
const descentBody = new THREE.Mesh(new THREE.CylinderGeometry(2.25, 2.25, 1.65, 8, 1, false, 0.3927), foilMat);
descentBody.name = 'descentBody';
descentBody.position.set(0, 2.375, 0);
descentStage.add(descentBody);
const cornerBay = new THREE.Mesh(boxGeo, foilDarkMat);
cornerBay.name = 'cornerBay';
cornerBay.position.set(1.484, 2.375, 1.484);
cornerBay.rotation.set(0, deg(45), 0);
descentStage.add(cornerBay);
const cornerBay2 = new THREE.Mesh(boxGeo, foilDarkMat);
cornerBay2.name = 'cornerBay';
cornerBay2.position.set(1.484, 2.375, -1.484);
cornerBay2.rotation.set(0, deg(135), 0);
descentStage.add(cornerBay2);
const cornerBay3 = new THREE.Mesh(boxGeo, foilDarkMat);
cornerBay3.name = 'cornerBay';
cornerBay3.position.set(-1.484, 2.375, -1.484);
cornerBay3.rotation.set(0, deg(225), 0);
descentStage.add(cornerBay3);
const cornerBay4 = new THREE.Mesh(boxGeo, foilDarkMat);
cornerBay4.name = 'cornerBay';
cornerBay4.position.set(-1.484, 2.375, 1.484);
cornerBay4.rotation.set(0, deg(315), 0);
descentStage.add(cornerBay4);
const sidePanel = new THREE.Mesh(boxGeo2, blackMat);
sidePanel.name = 'sidePanel';
sidePanel.position.set(2.0987, 2.4, 0);
descentStage.add(sidePanel);
const sidePanel2 = new THREE.Mesh(boxGeo2, blackMat);
sidePanel2.name = 'sidePanel';
sidePanel2.position.set(-2.0987, 2.4, 0);
descentStage.add(sidePanel2);
const sidePanel3 = new THREE.Mesh(new THREE.BoxGeometry(1, 0.8, 0.06), blackMat);
sidePanel3.name = 'sidePanel';
sidePanel3.position.set(0, 2.4, -2.0987);
descentStage.add(sidePanel3);
const deckPlate = new THREE.Mesh(new THREE.CylinderGeometry(2.1825, 2.1825, 0.08, 8, 1, false, 0.3927), blackMat);
deckPlate.name = 'deckPlate';
deckPlate.position.set(0, 3.24, 0);
descentStage.add(deckPlate);
const heatShield = new THREE.Mesh(new THREE.CylinderGeometry(2.025, 2.025, 0.06, 8, 1, false, 0.3927), foilDarkMat);
heatShield.name = 'heatShield';
heatShield.position.set(0, 1.52, 0);
descentStage.add(heatShield);
const descentEngine = new THREE.Mesh(new THREE.CylinderGeometry(0.42, 0.8, 1.05, 12), metalMat);
descentEngine.name = 'descentEngine';
descentEngine.position.set(0, 0.995, 0);
descentStage.add(descentEngine);
const descentNozzleExit = new THREE.Mesh(new THREE.CylinderGeometry(0.76, 0.76, 0.03, 12), blackMat);
descentNozzleExit.name = 'descentNozzleExit';
descentNozzleExit.position.set(0, 0.465, 0);
descentStage.add(descentNozzleExit);
const porch = new THREE.Mesh(new THREE.BoxGeometry(1.1, 0.06, 0.7), metalMat);
porch.name = 'porch';
porch.position.set(0, 3.15, 2.3987);
descentStage.add(porch);
const porchRail = new THREE.Mesh(boxGeo3, metalMat);
porchRail.name = 'porchRail';
porchRail.position.set(0.53, 3.4, 2.7187);
descentStage.add(porchRail);
const porchRail2 = new THREE.Mesh(boxGeo3, metalMat);
porchRail2.name = 'porchRail';
porchRail2.position.set(-0.53, 3.4, 2.7187);
descentStage.add(porchRail2);
const box17 = new THREE.Mesh(new THREE.BoxGeometry(1.1, 0.04, 0.04), metalMat);
box17.position.set(0, 3.65, 2.7187);
descentStage.add(box17);
const legF = new THREE.Group();
legF.name = 'legF';
legF.position.set(0, 2.95, 1.9787);
root.add(legF);
const primaryStrut = new THREE.Mesh(cylinderGeo, foilMat);
primaryStrut.name = 'primaryStrut';
primaryStrut.position.set(0, -1.315, 1.1856);
primaryStrut.rotation.set(deg(137.9614), 0, 0);
legF.add(primaryStrut);
const shockStrut = new THREE.Mesh(cylinderGeo2, metalMat);
shockStrut.name = 'shockStrut';
shockStrut.position.set(0, -2.315, 1.8963);
shockStrut.rotation.set(deg(123.5507), 0, 0);
legF.add(shockStrut);
const secondaryStrut = new THREE.Mesh(cylinderGeo3, metalMat);
secondaryStrut.name = 'secondaryStrut';
secondaryStrut.position.set(-0.4, -1.65, 0.7356);
secondaryStrut.rotation.set(deg(93.4084), deg(-37.6518), deg(-35.6173));
legF.add(secondaryStrut);
const secondaryStrut2 = new THREE.Mesh(cylinderGeo3, metalMat);
secondaryStrut2.name = 'secondaryStrut';
secondaryStrut2.position.set(0.4, -1.65, 0.7356);
secondaryStrut2.rotation.set(deg(93.4084), deg(37.6518), deg(35.6173));
legF.add(secondaryStrut2);
const footPad = new THREE.Mesh(cylinderGeo4, foilMat);
footPad.name = 'footPad';
footPad.position.set(0, -2.87, 2.3713);
legF.add(footPad);
const padSocket = new THREE.Mesh(cylinderGeo5, metalMat);
padSocket.name = 'padSocket';
padSocket.position.set(0, -2.72, 2.3713);
legF.add(padSocket);
const ladderRail = new THREE.Mesh(cylinderGeo6, metalMat);
ladderRail.name = 'ladderRail';
ladderRail.position.set(0.3, -1.25, 1.2606);
ladderRail.rotation.set(deg(148.2863), 0, 0);
legF.add(ladderRail);
const ladderRail2 = new THREE.Mesh(cylinderGeo6, metalMat);
ladderRail2.name = 'ladderRail';
ladderRail2.position.set(-0.3, -1.25, 1.2606);
ladderRail2.rotation.set(deg(148.2863), 0, 0);
legF.add(ladderRail2);
const rung = new THREE.Mesh(boxGeo4, metalMat);
rung.name = 'rung';
rung.position.set(0, -0.3875, 0.7277);
legF.add(rung);
const rung2 = new THREE.Mesh(boxGeo4, metalMat);
rung2.name = 'rung';
rung2.position.set(0, -0.675, 0.9053);
legF.add(rung2);
const rung3 = new THREE.Mesh(boxGeo4, metalMat);
rung3.name = 'rung';
rung3.position.set(0, -0.9625, 1.083);
legF.add(rung3);
const rung4 = new THREE.Mesh(boxGeo4, metalMat);
rung4.name = 'rung';
rung4.position.set(0, -1.25, 1.2606);
legF.add(rung4);
const rung5 = new THREE.Mesh(boxGeo4, metalMat);
rung5.name = 'rung';
rung5.position.set(0, -1.5375, 1.4383);
legF.add(rung5);
const rung6 = new THREE.Mesh(boxGeo4, metalMat);
rung6.name = 'rung';
rung6.position.set(0, -1.825, 1.616);
legF.add(rung6);
const rung7 = new THREE.Mesh(boxGeo4, metalMat);
rung7.name = 'rung';
rung7.position.set(0, -2.1125, 1.7936);
legF.add(rung7);
const legL = new THREE.Group();
legL.name = 'legL';
legL.position.set(1.9787, 2.95, 0);
root.add(legL);
const primaryStrut2 = new THREE.Mesh(cylinderGeo, foilMat);
primaryStrut2.name = 'primaryStrut';
primaryStrut2.position.set(1.1856, -1.315, 0);
primaryStrut2.rotation.set(0, 0, deg(-137.9614));
legL.add(primaryStrut2);
const shockStrut2 = new THREE.Mesh(cylinderGeo2, metalMat);
shockStrut2.name = 'shockStrut';
shockStrut2.position.set(1.8963, -2.315, 0);
shockStrut2.rotation.set(0, 0, deg(-123.5507));
legL.add(shockStrut2);
const secondaryStrut3 = new THREE.Mesh(cylinderGeo3, metalMat);
secondaryStrut3.name = 'secondaryStrut';
secondaryStrut3.position.set(0.7356, -1.65, 0.4);
secondaryStrut3.rotation.set(deg(-35.6173), deg(37.6518), deg(-93.4084));
legL.add(secondaryStrut3);
const secondaryStrut4 = new THREE.Mesh(cylinderGeo3, metalMat);
secondaryStrut4.name = 'secondaryStrut';
secondaryStrut4.position.set(0.7356, -1.65, -0.4);
secondaryStrut4.rotation.set(deg(35.6173), deg(-37.6518), deg(-93.4084));
legL.add(secondaryStrut4);
const footPad2 = new THREE.Mesh(cylinderGeo4, foilMat);
footPad2.name = 'footPad';
footPad2.position.set(2.3713, -2.87, 0);
legL.add(footPad2);
const padSocket2 = new THREE.Mesh(cylinderGeo5, metalMat);
padSocket2.name = 'padSocket';
padSocket2.position.set(2.3713, -2.72, 0);
legL.add(padSocket2);
const legB = new THREE.Group();
legB.name = 'legB';
legB.position.set(0, 2.95, -1.9787);
root.add(legB);
const primaryStrut3 = new THREE.Mesh(cylinderGeo, foilMat);
primaryStrut3.name = 'primaryStrut';
primaryStrut3.position.set(0, -1.315, -1.1856);
primaryStrut3.rotation.set(deg(-137.9614), 0, 0);
legB.add(primaryStrut3);
const shockStrut3 = new THREE.Mesh(cylinderGeo2, metalMat);
shockStrut3.name = 'shockStrut';
shockStrut3.position.set(0, -2.315, -1.8963);
shockStrut3.rotation.set(deg(-123.5507), 0, 0);
legB.add(shockStrut3);
const secondaryStrut5 = new THREE.Mesh(cylinderGeo3, metalMat);
secondaryStrut5.name = 'secondaryStrut';
secondaryStrut5.position.set(0.4, -1.65, -0.7356);
secondaryStrut5.rotation.set(deg(-93.4084), deg(-37.6518), deg(35.6173));
legB.add(secondaryStrut5);
const secondaryStrut6 = new THREE.Mesh(cylinderGeo3, metalMat);
secondaryStrut6.name = 'secondaryStrut';
secondaryStrut6.position.set(-0.4, -1.65, -0.7356);
secondaryStrut6.rotation.set(deg(-93.4084), deg(37.6518), deg(-35.6173));
legB.add(secondaryStrut6);
const footPad3 = new THREE.Mesh(cylinderGeo4, foilMat);
footPad3.name = 'footPad';
footPad3.position.set(0, -2.87, -2.3713);
legB.add(footPad3);
const padSocket3 = new THREE.Mesh(cylinderGeo5, metalMat);
padSocket3.name = 'padSocket';
padSocket3.position.set(0, -2.72, -2.3713);
legB.add(padSocket3);
const legR = new THREE.Group();
legR.name = 'legR';
legR.position.set(-1.9787, 2.95, 0);
root.add(legR);
const primaryStrut4 = new THREE.Mesh(cylinderGeo, foilMat);
primaryStrut4.name = 'primaryStrut';
primaryStrut4.position.set(-1.1856, -1.315, 0);
primaryStrut4.rotation.set(0, 0, deg(137.9614));
legR.add(primaryStrut4);
const shockStrut4 = new THREE.Mesh(cylinderGeo2, metalMat);
shockStrut4.name = 'shockStrut';
shockStrut4.position.set(-1.8963, -2.315, 0);
shockStrut4.rotation.set(0, 0, deg(123.5507));
legR.add(shockStrut4);
const secondaryStrut7 = new THREE.Mesh(cylinderGeo3, metalMat);
secondaryStrut7.name = 'secondaryStrut';
secondaryStrut7.position.set(-0.7356, -1.65, -0.4);
secondaryStrut7.rotation.set(deg(35.6173), deg(37.6518), deg(93.4084));
legR.add(secondaryStrut7);
const secondaryStrut8 = new THREE.Mesh(cylinderGeo3, metalMat);
secondaryStrut8.name = 'secondaryStrut';
secondaryStrut8.position.set(-0.7356, -1.65, 0.4);
secondaryStrut8.rotation.set(deg(-35.6173), deg(-37.6518), deg(93.4084));
legR.add(secondaryStrut8);
const footPad4 = new THREE.Mesh(cylinderGeo4, foilMat);
footPad4.name = 'footPad';
footPad4.position.set(-2.3713, -2.87, 0);
legR.add(footPad4);
const padSocket4 = new THREE.Mesh(cylinderGeo5, metalMat);
padSocket4.name = 'padSocket';
padSocket4.position.set(-2.3713, -2.72, 0);
legR.add(padSocket4);
const ascentStage = new THREE.Group();
ascentStage.name = 'ascentStage';
ascentStage.position.set(0, 3.28, 0.15);
root.add(ascentStage);
const crewCabin = new THREE.Mesh(extrude([[1.25, 0], [1.55, 0.75], [1.4, 1.65], [0.75, 2.35], [-0.6, 2.35], [-1.15, 1.7], [-1.15, 0]], 2.8, [], [0.05, 0.05, 1]), cabinMat);
crewCabin.name = 'crewCabin';
crewCabin.position.set(0, 0.1, 0);
crewCabin.rotation.set(0, deg(-90), 0);
ascentStage.add(crewCabin);
const aftBay = new THREE.Mesh(new THREE.BoxGeometry(2.2, 1.5, 1.2), foilDarkMat);
aftBay.name = 'aftBay';
aftBay.position.set(0, 1.05, -1.7);
ascentStage.add(aftBay);
const aftBayLid = new THREE.Mesh(new THREE.BoxGeometry(2, 0.08, 1), blackMat);
aftBayLid.name = 'aftBayLid';
aftBayLid.position.set(0, 1.84, -1.7);
ascentStage.add(aftBayLid);
const cabinCheek = new THREE.Mesh(cylinderGeo7, cabinMat);
cabinCheek.name = 'cabinCheek';
cabinCheek.position.set(1.5, 1.2, 0.1);
cabinCheek.rotation.set(0, 0, deg(90));
ascentStage.add(cabinCheek);
const cheekPanel = new THREE.Mesh(boxGeo5, blackMat);
cheekPanel.name = 'cheekPanel';
cheekPanel.position.set(1.67, 1.2, 0.1);
ascentStage.add(cheekPanel);
const cabinCheek2 = new THREE.Mesh(cylinderGeo7, cabinMat);
cabinCheek2.name = 'cabinCheek';
cabinCheek2.position.set(-1.5, 1.2, 0.1);
cabinCheek2.rotation.set(0, 0, deg(90));
ascentStage.add(cabinCheek2);
const cheekPanel2 = new THREE.Mesh(boxGeo5, blackMat);
cheekPanel2.name = 'cheekPanel';
cheekPanel2.position.set(-1.67, 1.2, 0.1);
ascentStage.add(cheekPanel2);
const windowL = new THREE.Mesh(extrude([[0, 0], [0.62, 0], [0.1, 0.55]], 0.06), glassMat);
windowL.name = 'windowL';
windowL.position.set(0.12, 1.85, 1.39);
windowL.rotation.set(deg(-43), 0, 0);
ascentStage.add(windowL);
const windowR = new THREE.Mesh(extrude([[0, 0], [-0.62, 0], [-0.1, 0.55]], 0.06), glassMat);
windowR.name = 'windowR';
windowR.position.set(-0.12, 1.85, 1.39);
windowR.rotation.set(deg(-43), 0, 0);
ascentStage.add(windowR);
const hatch = new THREE.Mesh(new THREE.BoxGeometry(0.85, 0.85, 0.06), blackMat);
hatch.name = 'hatch';
hatch.position.set(0, 0.55, 1.47);
hatch.rotation.set(deg(21.8), 0, 0);
ascentStage.add(hatch);
const hatchHandle = new THREE.Mesh(new THREE.BoxGeometry(0.14, 0.14, 0.06), metalMat);
hatchHandle.name = 'hatchHandle';
hatchHandle.position.set(0.28, 0.53, 1.52);
hatchHandle.rotation.set(deg(21.8), 0, 0);
ascentStage.add(hatchHandle);
const dockingTunnel = new THREE.Mesh(new THREE.CylinderGeometry(0.55, 0.6, 0.45, 12), cabinMat);
dockingTunnel.name = 'dockingTunnel';
dockingTunnel.position.set(0, 2.625, 0.05);
ascentStage.add(dockingTunnel);
const dockingHatch = new THREE.Mesh(new THREE.CylinderGeometry(0.42, 0.42, 0.04, 12), blackMat);
dockingHatch.name = 'dockingHatch';
dockingHatch.position.set(0, 2.87, 0.05);
ascentStage.add(dockingHatch);
const radarMast = new THREE.Mesh(new THREE.CylinderGeometry(0.04, 0.04, 0.4, 5), metalMat);
radarMast.name = 'radarMast';
radarMast.position.set(0.85, 2.58, 0.9);
ascentStage.add(radarMast);
const rendezvousRadar = new THREE.Mesh(new THREE.SphereGeometry(0.32, 10, 3, 0, Math.PI * 2, 1.9478, 1.1938), metalMat);
rendezvousRadar.name = 'rendezvousRadar';
rendezvousRadar.position.set(0.85, 3, 0.75);
rendezvousRadar.rotation.set(deg(63.4349), 0, 0);
ascentStage.add(rendezvousRadar);
const dishMast = new THREE.Mesh(new THREE.CylinderGeometry(0.04, 0.04, 0.9, 5), metalMat);
dishMast.name = 'dishMast';
dishMast.position.set(-0.95, 2.83, -0.55);
ascentStage.add(dishMast);
const dish = new THREE.Group();
dish.name = 'dish';
dish.position.set(-0.95, 3.6, -0.55);
dish.rotation.set(deg(-35), 0, 0);
ascentStage.add(dish);
const dishBowl = new THREE.Mesh(new THREE.SphereGeometry(0.45, 12, 3, 0, Math.PI * 2, 1.9478, 1.1938), metalMat);
dishBowl.name = 'dishBowl';
dish.add(dishBowl);
const dishFeed = new THREE.Mesh(new THREE.CylinderGeometry(0.02, 0.02, 0.38, 4), metalMat);
dishFeed.name = 'dishFeed';
dishFeed.position.set(0, -0.26, 0);
dish.add(dishFeed);
const vhfAntenna = new THREE.Mesh(cylinderGeo8, metalMat);
vhfAntenna.name = 'vhfAntenna';
vhfAntenna.position.set(1.1, 2.7, -1.3);
vhfAntenna.rotation.set(0, 0, deg(-30));
ascentStage.add(vhfAntenna);
const vhfAntenna2 = new THREE.Mesh(cylinderGeo8, metalMat);
vhfAntenna2.name = 'vhfAntenna2';
vhfAntenna2.position.set(-1.1, 2.7, -1.3);
vhfAntenna2.rotation.set(0, 0, deg(30));
ascentStage.add(vhfAntenna2);
const rcsBoom = new THREE.Mesh(boxGeo6, metalMat);
rcsBoom.name = 'rcsBoom';
rcsBoom.position.set(1.35, 1.75, 0.95);
ascentStage.add(rcsBoom);
const rcsQuad = new THREE.Mesh(boxGeo7, cabinMat);
rcsQuad.name = 'rcsQuad';
rcsQuad.position.set(1.75, 1.75, 0.95);
ascentStage.add(rcsQuad);
const rcsNozzle = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle.name = 'rcsNozzle';
rcsNozzle.position.set(1.75, 1.95, 0.95);
rcsNozzle.rotation.set(0, 0, deg(180));
ascentStage.add(rcsNozzle);
const cylinder80 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder80.position.set(1.75, 2.03, 0.95);
ascentStage.add(cylinder80);
const rcsNozzle2 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle2.name = 'rcsNozzle';
rcsNozzle2.position.set(1.75, 1.55, 0.95);
ascentStage.add(rcsNozzle2);
const cylinder82 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder82.position.set(1.75, 1.47, 0.95);
cylinder82.rotation.set(0, 0, deg(180));
ascentStage.add(cylinder82);
const rcsNozzle3 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle3.name = 'rcsNozzle';
rcsNozzle3.position.set(1.95, 1.75, 0.95);
rcsNozzle3.rotation.set(0, 0, deg(90));
ascentStage.add(rcsNozzle3);
const cylinder84 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder84.position.set(2.03, 1.75, 0.95);
cylinder84.rotation.set(0, 0, deg(-90));
ascentStage.add(cylinder84);
const rcsNozzle4 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle4.name = 'rcsNozzle';
rcsNozzle4.position.set(1.75, 1.75, 1.15);
rcsNozzle4.rotation.set(deg(-90), 0, 0);
ascentStage.add(rcsNozzle4);
const cylinder86 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder86.position.set(1.75, 1.75, 1.23);
cylinder86.rotation.set(deg(90), 0, 0);
ascentStage.add(cylinder86);
const rcsBoom2 = new THREE.Mesh(boxGeo6, metalMat);
rcsBoom2.name = 'rcsBoom';
rcsBoom2.position.set(-1.35, 1.75, 0.95);
ascentStage.add(rcsBoom2);
const rcsQuad2 = new THREE.Mesh(boxGeo7, cabinMat);
rcsQuad2.name = 'rcsQuad';
rcsQuad2.position.set(-1.75, 1.75, 0.95);
ascentStage.add(rcsQuad2);
const rcsNozzle5 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle5.name = 'rcsNozzle';
rcsNozzle5.position.set(-1.75, 1.95, 0.95);
rcsNozzle5.rotation.set(0, 0, deg(180));
ascentStage.add(rcsNozzle5);
const cylinder90 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder90.position.set(-1.75, 2.03, 0.95);
ascentStage.add(cylinder90);
const rcsNozzle6 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle6.name = 'rcsNozzle';
rcsNozzle6.position.set(-1.75, 1.55, 0.95);
ascentStage.add(rcsNozzle6);
const cylinder92 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder92.position.set(-1.75, 1.47, 0.95);
cylinder92.rotation.set(0, 0, deg(180));
ascentStage.add(cylinder92);
const rcsNozzle7 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle7.name = 'rcsNozzle';
rcsNozzle7.position.set(-1.95, 1.75, 0.95);
rcsNozzle7.rotation.set(0, 0, deg(-90));
ascentStage.add(rcsNozzle7);
const cylinder94 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder94.position.set(-2.03, 1.75, 0.95);
cylinder94.rotation.set(0, 0, deg(90));
ascentStage.add(cylinder94);
const rcsNozzle8 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle8.name = 'rcsNozzle';
rcsNozzle8.position.set(-1.75, 1.75, 1.15);
rcsNozzle8.rotation.set(deg(-90), 0, 0);
ascentStage.add(rcsNozzle8);
const cylinder96 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder96.position.set(-1.75, 1.75, 1.23);
cylinder96.rotation.set(deg(90), 0, 0);
ascentStage.add(cylinder96);
const rcsBoom3 = new THREE.Mesh(boxGeo6, metalMat);
rcsBoom3.name = 'rcsBoom';
rcsBoom3.position.set(1.35, 1.75, -1.55);
ascentStage.add(rcsBoom3);
const rcsQuad3 = new THREE.Mesh(boxGeo7, cabinMat);
rcsQuad3.name = 'rcsQuad';
rcsQuad3.position.set(1.75, 1.75, -1.55);
ascentStage.add(rcsQuad3);
const rcsNozzle9 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle9.name = 'rcsNozzle';
rcsNozzle9.position.set(1.75, 1.95, -1.55);
rcsNozzle9.rotation.set(0, 0, deg(180));
ascentStage.add(rcsNozzle9);
const cylinder100 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder100.position.set(1.75, 2.03, -1.55);
ascentStage.add(cylinder100);
const rcsNozzle10 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle10.name = 'rcsNozzle';
rcsNozzle10.position.set(1.75, 1.55, -1.55);
ascentStage.add(rcsNozzle10);
const cylinder102 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder102.position.set(1.75, 1.47, -1.55);
cylinder102.rotation.set(0, 0, deg(180));
ascentStage.add(cylinder102);
const rcsNozzle11 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle11.name = 'rcsNozzle';
rcsNozzle11.position.set(1.95, 1.75, -1.55);
rcsNozzle11.rotation.set(0, 0, deg(90));
ascentStage.add(rcsNozzle11);
const cylinder104 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder104.position.set(2.03, 1.75, -1.55);
cylinder104.rotation.set(0, 0, deg(-90));
ascentStage.add(cylinder104);
const rcsNozzle12 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle12.name = 'rcsNozzle';
rcsNozzle12.position.set(1.75, 1.75, -1.75);
rcsNozzle12.rotation.set(deg(90), 0, 0);
ascentStage.add(rcsNozzle12);
const cylinder106 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder106.position.set(1.75, 1.75, -1.83);
cylinder106.rotation.set(deg(-90), 0, 0);
ascentStage.add(cylinder106);
const rcsBoom4 = new THREE.Mesh(boxGeo6, metalMat);
rcsBoom4.name = 'rcsBoom';
rcsBoom4.position.set(-1.35, 1.75, -1.55);
ascentStage.add(rcsBoom4);
const rcsQuad4 = new THREE.Mesh(boxGeo7, cabinMat);
rcsQuad4.name = 'rcsQuad';
rcsQuad4.position.set(-1.75, 1.75, -1.55);
ascentStage.add(rcsQuad4);
const rcsNozzle13 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle13.name = 'rcsNozzle';
rcsNozzle13.position.set(-1.75, 1.95, -1.55);
rcsNozzle13.rotation.set(0, 0, deg(180));
ascentStage.add(rcsNozzle13);
const cylinder110 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder110.position.set(-1.75, 2.03, -1.55);
ascentStage.add(cylinder110);
const rcsNozzle14 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle14.name = 'rcsNozzle';
rcsNozzle14.position.set(-1.75, 1.55, -1.55);
ascentStage.add(rcsNozzle14);
const cylinder112 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder112.position.set(-1.75, 1.47, -1.55);
cylinder112.rotation.set(0, 0, deg(180));
ascentStage.add(cylinder112);
const rcsNozzle15 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle15.name = 'rcsNozzle';
rcsNozzle15.position.set(-1.95, 1.75, -1.55);
rcsNozzle15.rotation.set(0, 0, deg(-90));
ascentStage.add(rcsNozzle15);
const cylinder114 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder114.position.set(-2.03, 1.75, -1.55);
cylinder114.rotation.set(0, 0, deg(90));
ascentStage.add(cylinder114);
const rcsNozzle16 = new THREE.Mesh(coneGeo, blackMat);
rcsNozzle16.name = 'rcsNozzle';
rcsNozzle16.position.set(-1.75, 1.75, -1.75);
rcsNozzle16.rotation.set(deg(90), 0, 0);
ascentStage.add(rcsNozzle16);
const cylinder116 = new THREE.Mesh(cylinderGeo9, blackMat);
cylinder116.position.set(-1.75, 1.75, -1.83);
cylinder116.rotation.set(deg(-90), 0, 0);
ascentStage.add(cylinder116);
root.traverse((o) => {
if (o.isMesh) {
o.castShadow = true;
o.receiveShadow = true;
}
});
return root;
}
export default createLunarLander;
Ratings & comments
0 comments
No comments yet. Share how you used this model or what could be better.
Related models
Same category or similar tags









