Codels
3,2 B üçgen8,35 × 17,4 × 11,9 m
Bağımsız bir ES modülü — yalnızca three paketine bağımlıdır. Fabrika fonksiyonunu çağırıp dönen grubu sahnene ekle.
/**
 * Stone Chapel — Codels 3D model library
 * License: CC0-1.0 · Units: meters · Y-up · Front: +Z · Origin: center of the base (y = 0)
 * Triangles: 3,220 · Size (W × H × D): 8.35 × 17.40 × 11.88 m
 *
 * Usage:
 *   import { createChapel } from './chapel.js';
 *   
 *   const model = createChapel();
 *   model.position.set(0, 0, 0);
 *   scene.add(model);
 */
import * as THREE from 'three';

const deg = THREE.MathUtils.degToRad;

// Deterministic vertex displacement (organic low-poly look).
function jitter(geometry, amount, seed) {
  const pos = geometry.attributes.position;
  const h = (a, b, c, s) => {
    let x = Math.imul(a, 73856093) ^ Math.imul(b, 19349663) ^ Math.imul(c, 83492791) ^ Math.imul(s, 2654435761);
    x = Math.imul(x ^ (x >>> 16), 2246822507);
    x = Math.imul(x ^ (x >>> 13), 3266489909);
    return ((x ^ (x >>> 16)) >>> 0) / 4294967295 - 0.5;
  };
  for (let i = 0; i < pos.count; i++) {
    const x = pos.getX(i), y = pos.getY(i), z = pos.getZ(i);
    const qx = Math.round(x * 1000), qy = Math.round(y * 1000), qz = Math.round(z * 1000);
    pos.setXYZ(i, x + h(qx, qy, qz, seed) * 2 * amount, y + h(qx, qy, qz, seed + 1) * 2 * amount, z + h(qx, qy, qz, seed + 2) * 2 * amount);
  }
  pos.needsUpdate = true;
  geometry.computeVertexNormals();
  return geometry;
}

// Revolve a 2D profile [[radius, y], ...] around the Y axis.
function lathe(points, segments, phiStart = 0, phiLength = Math.PI * 2) {
  return new THREE.LatheGeometry(points.map(([x, y]) => new THREE.Vector2(x, y)), segments, phiStart, phiLength);
}

// 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 createChapel() {
  const root = new THREE.Group();
  root.name = 'Chapel';

  // Materials
  const stoneMat = new THREE.MeshStandardMaterial({ name: 'stone', color: 0xb1a894, roughness: 0.95, flatShading: true });
  const stone2Mat = new THREE.MeshStandardMaterial({ name: 'stone2', color: 0x938b7b, roughness: 0.95, flatShading: true });
  const roofMat = new THREE.MeshStandardMaterial({ name: 'roof', color: 0x4b5160, roughness: 0.8, flatShading: true });
  const woodMat = new THREE.MeshStandardMaterial({ name: 'wood', color: 0x6f4627, roughness: 0.9, flatShading: true });
  const ironMat = new THREE.MeshStandardMaterial({ name: 'iron', color: 0x2d2f33, roughness: 0.5, metalness: 0.65, flatShading: true });
  const glassMat = new THREE.MeshStandardMaterial({ name: 'glass', color: 0x7fa6e0, roughness: 0.25, emissive: 0x3459a8, emissiveIntensity: 0.7, flatShading: true });
  const glass2Mat = new THREE.MeshStandardMaterial({ name: 'glass2', color: 0xe0b25a, roughness: 0.25, emissive: 0xa8611c, emissiveIntensity: 0.7, flatShading: true });
  const bronzeMat = new THREE.MeshStandardMaterial({ name: 'bronze', color: 0xb8893a, roughness: 0.35, metalness: 0.75, flatShading: true });
  const whiteMat = new THREE.MeshStandardMaterial({ name: 'white', color: 0xf2eee4, roughness: 0.6, flatShading: true });

  // Shared geometries
  const boxGeo = new THREE.BoxGeometry(4.4802, 0.18, 0.34);
  const boxGeo2 = new THREE.BoxGeometry(8.8, 0.1, 4.7102);
  const boxGeo3 = new THREE.BoxGeometry(8.82, 0.07, 0.8478);
  const cylinderGeo = new THREE.CylinderGeometry(0.01, 0.33, 0.35, 4, 1, false, Math.PI / 4);
  const extrudeGeo = extrude([[-0.475, -0.1], [0.475, -0.1], [0.475, 1.5773], [0.4177, 1.9022], [0.2527, 2.1879], [0, 2.4], [-0.2527, 2.1879], [-0.4177, 1.9022], [-0.475, 1.5773]], 0.1);
  const extrudeGeo2 = extrude([[-0.35, 0], [0.35, 0], [0.35, 1.6938], [0.3078, 1.9332], [0.1862, 2.1438], [0, 2.3], [-0.1862, 2.1438], [-0.3078, 1.9332], [-0.35, 1.6938]], 0.06);
  const boxGeo4 = new THREE.BoxGeometry(0.04, 1.9, 0.03);
  const boxGeo5 = new THREE.BoxGeometry(1.05, 0.1, 0.24);
  const boxGeo6 = new THREE.BoxGeometry(1.46, 0.08, 0.025);
  const torusGeo = new THREE.TorusGeometry(0.07, 0.014, 3, 6);
  const boxGeo7 = new THREE.BoxGeometry(1.3, 0.05, 0.03);
  const extrudeGeo3 = extrude([[-0.3, -0.08], [0.3, -0.08], [0.3, 1.0504], [0.2638, 1.2556], [0.1596, 1.4361], [0, 1.57], [-0.1596, 1.4361], [-0.2638, 1.2556], [-0.3, 1.0504]], 0.08);
  const extrudeGeo4 = extrude([[-0.21, 0], [0.21, 0], [0.21, 1.1363], [0.1847, 1.2799], [0.1117, 1.4063], [0, 1.5], [-0.1117, 1.4063], [-0.1847, 1.2799], [-0.21, 1.1363]], 0.06);
  const boxGeo8 = new THREE.BoxGeometry(2.76, 0.2, 2.76);
  const boxGeo9 = new THREE.BoxGeometry(0.42, 1, 0.06);
  const boxGeo10 = new THREE.BoxGeometry(0.16, 0.8, 0.06);
  const boxGeo11 = new THREE.BoxGeometry(0.48, 2.1, 0.48);
  const extrudeGeo5 = extrude([[-0.84, 0.93], [-0.82, 0.93], [-0.7576, 1.2438], [-0.5798, 1.5098], [-0.3138, 1.6876], [0, 1.75], [0.3138, 1.6876], [0.5798, 1.5098], [0.7576, 1.2438], [0.82, 0.93], [0.84, 0.93], [0.84, 2.1], [-0.84, 2.1]], 0.3);
  const boxGeo12 = new THREE.BoxGeometry(1.74, 0.12, 0.36);

  // Parts
  const chapel = new THREE.Group();
  chapel.name = 'chapel';
  chapel.position.set(1.05, 0, 0.35);
  root.add(chapel);
  const plinth = new THREE.Mesh(jitter(new THREE.BoxGeometry(5.44, 0.45, 8.74), 0.01, 1), stone2Mat);
  plinth.name = 'plinth';
  plinth.position.set(0, 0.225, 0);
  chapel.add(plinth);
  const naveWalls = new THREE.Mesh(new THREE.BoxGeometry(5.2, 4, 8.5), stoneMat);
  naveWalls.name = 'naveWalls';
  naveWalls.position.set(0, 2.45, 0);
  chapel.add(naveWalls);
  const gables = new THREE.Mesh(extrude([[-2.6, 0], [2.6, 0], [0, 3.37]], 8.5), stoneMat);
  gables.name = 'gables';
  gables.position.set(0, 4.45, 0);
  chapel.add(gables);
  const coping = new THREE.Mesh(boxGeo, stone2Mat);
  coping.name = 'coping';
  coping.position.set(-1.3, 6.27, -4.31);
  coping.rotation.set(0, 0, deg(52.5946));
  chapel.add(coping);
  const coping2 = new THREE.Mesh(boxGeo, stone2Mat);
  coping2.name = 'coping';
  coping2.position.set(1.3, 6.27, -4.31);
  coping2.rotation.set(0, 0, deg(-52.5946));
  chapel.add(coping2);
  const coping3 = new THREE.Mesh(boxGeo, stone2Mat);
  coping3.name = 'coping';
  coping3.position.set(-1.3, 6.27, 4.31);
  coping3.rotation.set(0, 0, deg(52.5946));
  chapel.add(coping3);
  const coping4 = new THREE.Mesh(boxGeo, stone2Mat);
  coping4.name = 'coping';
  coping4.position.set(1.3, 6.27, 4.31);
  coping4.rotation.set(0, 0, deg(-52.5946));
  chapel.add(coping4);
  const gableCross = new THREE.Mesh(new THREE.BoxGeometry(0.12, 0.7, 0.1), stone2Mat);
  gableCross.name = 'gableCross';
  gableCross.position.set(0, 8.3, 4.31);
  chapel.add(gableCross);
  const gableCross2 = new THREE.Mesh(new THREE.BoxGeometry(0.45, 0.12, 0.1), stone2Mat);
  gableCross2.name = 'gableCross';
  gableCross2.position.set(0, 8.4, 4.31);
  chapel.add(gableCross2);
  const roof = new THREE.Group();
  roof.name = 'roof';
  roof.rotation.set(0, deg(90), 0);
  chapel.add(roof);
  const roofSlab = new THREE.Mesh(boxGeo2, roofMat);
  roofSlab.name = 'roofSlab';
  roofSlab.position.set(0, 6.0334, -1.4521);
  roofSlab.rotation.set(deg(-52.5946), 0, 0);
  roof.add(roofSlab);
  const shingles = new THREE.Mesh(boxGeo3, roofMat);
  shingles.name = 'shingles';
  shingles.position.set(0, 7.644, -0.3274);
  shingles.rotation.set(deg(-58.5946), 0, 0);
  roof.add(shingles);
  const shingles2 = new THREE.Mesh(boxGeo3, roofMat);
  shingles2.name = 'shingles';
  shingles2.position.set(0, 7.0204, -0.8043);
  shingles2.rotation.set(deg(-58.5946), 0, 0);
  roof.add(shingles2);
  const shingles3 = new THREE.Mesh(boxGeo3, roofMat);
  shingles3.name = 'shingles';
  shingles3.position.set(0, 6.3968, -1.2812);
  shingles3.rotation.set(deg(-58.5946), 0, 0);
  roof.add(shingles3);
  const shingles4 = new THREE.Mesh(boxGeo3, roofMat);
  shingles4.name = 'shingles';
  shingles4.position.set(0, 5.7733, -1.7581);
  shingles4.rotation.set(deg(-58.5946), 0, 0);
  roof.add(shingles4);
  const shingles5 = new THREE.Mesh(boxGeo3, roofMat);
  shingles5.name = 'shingles';
  shingles5.position.set(0, 5.1497, -2.2349);
  shingles5.rotation.set(deg(-58.5946), 0, 0);
  roof.add(shingles5);
  const shingles6 = new THREE.Mesh(boxGeo3, roofMat);
  shingles6.name = 'shingles';
  shingles6.position.set(0, 4.5261, -2.7118);
  shingles6.rotation.set(deg(-58.5946), 0, 0);
  roof.add(shingles6);
  const roofSlab2 = new THREE.Mesh(boxGeo2, roofMat);
  roofSlab2.name = 'roofSlab';
  roofSlab2.position.set(0, 6.0334, 1.4521);
  roofSlab2.rotation.set(deg(52.5946), 0, 0);
  roof.add(roofSlab2);
  const shingles7 = new THREE.Mesh(boxGeo3, roofMat);
  shingles7.name = 'shingles';
  shingles7.position.set(0, 7.644, 0.3274);
  shingles7.rotation.set(deg(58.5946), 0, 0);
  roof.add(shingles7);
  const shingles8 = new THREE.Mesh(boxGeo3, roofMat);
  shingles8.name = 'shingles';
  shingles8.position.set(0, 7.0204, 0.8043);
  shingles8.rotation.set(deg(58.5946), 0, 0);
  roof.add(shingles8);
  const shingles9 = new THREE.Mesh(boxGeo3, roofMat);
  shingles9.name = 'shingles';
  shingles9.position.set(0, 6.3968, 1.2812);
  shingles9.rotation.set(deg(58.5946), 0, 0);
  roof.add(shingles9);
  const shingles10 = new THREE.Mesh(boxGeo3, roofMat);
  shingles10.name = 'shingles';
  shingles10.position.set(0, 5.7733, 1.7581);
  shingles10.rotation.set(deg(58.5946), 0, 0);
  roof.add(shingles10);
  const shingles11 = new THREE.Mesh(boxGeo3, roofMat);
  shingles11.name = 'shingles';
  shingles11.position.set(0, 5.1497, 2.2349);
  shingles11.rotation.set(deg(58.5946), 0, 0);
  roof.add(shingles11);
  const shingles12 = new THREE.Mesh(boxGeo3, roofMat);
  shingles12.name = 'shingles';
  shingles12.position.set(0, 4.5261, 2.7118);
  shingles12.rotation.set(deg(58.5946), 0, 0);
  roof.add(shingles12);
  const ridge = new THREE.Mesh(new THREE.BoxGeometry(8.88, 0.2, 0.2), stone2Mat);
  ridge.name = 'ridge';
  ridge.position.set(0, 8.1299, 0);
  ridge.rotation.set(deg(45), 0, 0);
  roof.add(ridge);
  const buttress = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.55, 2.6, 0.5), 0.01, 2), stone2Mat);
  buttress.name = 'buttress';
  buttress.position.set(-2.86, 1.65, -3.95);
  chapel.add(buttress);
  const buttress2 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.32, 0.9, 0.42), 0.01, 3), stone2Mat);
  buttress2.name = 'buttress';
  buttress2.position.set(-2.75, 3.4, -3.95);
  chapel.add(buttress2);
  const buttressCap = new THREE.Mesh(cylinderGeo, stone2Mat);
  buttressCap.name = 'buttressCap';
  buttressCap.position.set(-2.75, 4.025, -3.95);
  buttressCap.scale.set(0.78, 1, 1);
  chapel.add(buttressCap);
  const lancet = new THREE.Group();
  lancet.name = 'lancet';
  lancet.position.set(-2.6, 1.65, -2.8333);
  lancet.rotation.set(0, deg(-90), 0);
  chapel.add(lancet);
  const lancetFrame = new THREE.Mesh(extrudeGeo, stone2Mat);
  lancetFrame.name = 'lancetFrame';
  lancetFrame.position.set(0, 0, 0.02);
  lancet.add(lancetFrame);
  const stainedGlass = new THREE.Mesh(extrudeGeo2, glassMat);
  stainedGlass.name = 'stainedGlass';
  stainedGlass.position.set(0, 0, 0.05);
  lancet.add(stainedGlass);
  const tracery = new THREE.Mesh(boxGeo4, ironMat);
  tracery.name = 'tracery';
  tracery.position.set(0, 1, 0.085);
  lancet.add(tracery);
  const lancetSill = new THREE.Mesh(boxGeo5, stone2Mat);
  lancetSill.name = 'lancetSill';
  lancetSill.position.set(0, -0.15, 0.1);
  lancet.add(lancetSill);
  const buttress3 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.55, 2.6, 0.5), 0.01, 4), stone2Mat);
  buttress3.name = 'buttress';
  buttress3.position.set(-2.86, 1.65, -1.4167);
  chapel.add(buttress3);
  const buttress4 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.32, 0.9, 0.42), 0.01, 5), stone2Mat);
  buttress4.name = 'buttress';
  buttress4.position.set(-2.75, 3.4, -1.4167);
  chapel.add(buttress4);
  const buttressCap2 = new THREE.Mesh(cylinderGeo, stone2Mat);
  buttressCap2.name = 'buttressCap';
  buttressCap2.position.set(-2.75, 4.025, -1.4167);
  buttressCap2.scale.set(0.78, 1, 1);
  chapel.add(buttressCap2);
  const lancet2 = new THREE.Group();
  lancet2.name = 'lancet';
  lancet2.position.set(-2.6, 1.65, 0);
  lancet2.rotation.set(0, deg(-90), 0);
  chapel.add(lancet2);
  const lancetFrame2 = new THREE.Mesh(extrudeGeo, stone2Mat);
  lancetFrame2.name = 'lancetFrame';
  lancetFrame2.position.set(0, 0, 0.02);
  lancet2.add(lancetFrame2);
  const stainedGlass2 = new THREE.Mesh(extrudeGeo2, glass2Mat);
  stainedGlass2.name = 'stainedGlass';
  stainedGlass2.position.set(0, 0, 0.05);
  lancet2.add(stainedGlass2);
  const tracery2 = new THREE.Mesh(boxGeo4, ironMat);
  tracery2.name = 'tracery';
  tracery2.position.set(0, 1, 0.085);
  lancet2.add(tracery2);
  const lancetSill2 = new THREE.Mesh(boxGeo5, stone2Mat);
  lancetSill2.name = 'lancetSill';
  lancetSill2.position.set(0, -0.15, 0.1);
  lancet2.add(lancetSill2);
  const buttress5 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.55, 2.6, 0.5), 0.01, 6), stone2Mat);
  buttress5.name = 'buttress';
  buttress5.position.set(-2.86, 1.65, 1.4167);
  chapel.add(buttress5);
  const buttress6 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.32, 0.9, 0.42), 0.01, 7), stone2Mat);
  buttress6.name = 'buttress';
  buttress6.position.set(-2.75, 3.4, 1.4167);
  chapel.add(buttress6);
  const buttressCap3 = new THREE.Mesh(cylinderGeo, stone2Mat);
  buttressCap3.name = 'buttressCap';
  buttressCap3.position.set(-2.75, 4.025, 1.4167);
  buttressCap3.scale.set(0.78, 1, 1);
  chapel.add(buttressCap3);
  const lancet3 = new THREE.Group();
  lancet3.name = 'lancet';
  lancet3.position.set(-2.6, 1.65, 2.8333);
  lancet3.rotation.set(0, deg(-90), 0);
  chapel.add(lancet3);
  const lancetFrame3 = new THREE.Mesh(extrudeGeo, stone2Mat);
  lancetFrame3.name = 'lancetFrame';
  lancetFrame3.position.set(0, 0, 0.02);
  lancet3.add(lancetFrame3);
  const stainedGlass3 = new THREE.Mesh(extrudeGeo2, glassMat);
  stainedGlass3.name = 'stainedGlass';
  stainedGlass3.position.set(0, 0, 0.05);
  lancet3.add(stainedGlass3);
  const tracery3 = new THREE.Mesh(boxGeo4, ironMat);
  tracery3.name = 'tracery';
  tracery3.position.set(0, 1, 0.085);
  lancet3.add(tracery3);
  const lancetSill3 = new THREE.Mesh(boxGeo5, stone2Mat);
  lancetSill3.name = 'lancetSill';
  lancetSill3.position.set(0, -0.15, 0.1);
  lancet3.add(lancetSill3);
  const buttress7 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.55, 2.6, 0.5), 0.01, 8), stone2Mat);
  buttress7.name = 'buttress';
  buttress7.position.set(-2.86, 1.65, 3.95);
  chapel.add(buttress7);
  const buttress8 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.32, 0.9, 0.42), 0.01, 9), stone2Mat);
  buttress8.name = 'buttress';
  buttress8.position.set(-2.75, 3.4, 3.95);
  chapel.add(buttress8);
  const buttressCap4 = new THREE.Mesh(cylinderGeo, stone2Mat);
  buttressCap4.name = 'buttressCap';
  buttressCap4.position.set(-2.75, 4.025, 3.95);
  buttressCap4.scale.set(0.78, 1, 1);
  chapel.add(buttressCap4);
  const buttress9 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.55, 2.6, 0.5), 0.01, 10), stone2Mat);
  buttress9.name = 'buttress';
  buttress9.position.set(2.86, 1.65, -3.95);
  chapel.add(buttress9);
  const buttress10 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.32, 0.9, 0.42), 0.01, 11), stone2Mat);
  buttress10.name = 'buttress';
  buttress10.position.set(2.75, 3.4, -3.95);
  chapel.add(buttress10);
  const buttressCap5 = new THREE.Mesh(cylinderGeo, stone2Mat);
  buttressCap5.name = 'buttressCap';
  buttressCap5.position.set(2.75, 4.025, -3.95);
  buttressCap5.scale.set(0.78, 1, 1);
  chapel.add(buttressCap5);
  const lancet4 = new THREE.Group();
  lancet4.name = 'lancet';
  lancet4.position.set(2.6, 1.65, -2.8333);
  lancet4.rotation.set(0, deg(90), 0);
  chapel.add(lancet4);
  const lancetFrame4 = new THREE.Mesh(extrudeGeo, stone2Mat);
  lancetFrame4.name = 'lancetFrame';
  lancetFrame4.position.set(0, 0, 0.02);
  lancet4.add(lancetFrame4);
  const stainedGlass4 = new THREE.Mesh(extrudeGeo2, glassMat);
  stainedGlass4.name = 'stainedGlass';
  stainedGlass4.position.set(0, 0, 0.05);
  lancet4.add(stainedGlass4);
  const tracery4 = new THREE.Mesh(boxGeo4, ironMat);
  tracery4.name = 'tracery';
  tracery4.position.set(0, 1, 0.085);
  lancet4.add(tracery4);
  const lancetSill4 = new THREE.Mesh(boxGeo5, stone2Mat);
  lancetSill4.name = 'lancetSill';
  lancetSill4.position.set(0, -0.15, 0.1);
  lancet4.add(lancetSill4);
  const buttress11 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.55, 2.6, 0.5), 0.01, 12), stone2Mat);
  buttress11.name = 'buttress';
  buttress11.position.set(2.86, 1.65, -1.4167);
  chapel.add(buttress11);
  const buttress12 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.32, 0.9, 0.42), 0.01, 13), stone2Mat);
  buttress12.name = 'buttress';
  buttress12.position.set(2.75, 3.4, -1.4167);
  chapel.add(buttress12);
  const buttressCap6 = new THREE.Mesh(cylinderGeo, stone2Mat);
  buttressCap6.name = 'buttressCap';
  buttressCap6.position.set(2.75, 4.025, -1.4167);
  buttressCap6.scale.set(0.78, 1, 1);
  chapel.add(buttressCap6);
  const lancet5 = new THREE.Group();
  lancet5.name = 'lancet';
  lancet5.position.set(2.6, 1.65, 0);
  lancet5.rotation.set(0, deg(90), 0);
  chapel.add(lancet5);
  const lancetFrame5 = new THREE.Mesh(extrudeGeo, stone2Mat);
  lancetFrame5.name = 'lancetFrame';
  lancetFrame5.position.set(0, 0, 0.02);
  lancet5.add(lancetFrame5);
  const stainedGlass5 = new THREE.Mesh(extrudeGeo2, glass2Mat);
  stainedGlass5.name = 'stainedGlass';
  stainedGlass5.position.set(0, 0, 0.05);
  lancet5.add(stainedGlass5);
  const tracery5 = new THREE.Mesh(boxGeo4, ironMat);
  tracery5.name = 'tracery';
  tracery5.position.set(0, 1, 0.085);
  lancet5.add(tracery5);
  const lancetSill5 = new THREE.Mesh(boxGeo5, stone2Mat);
  lancetSill5.name = 'lancetSill';
  lancetSill5.position.set(0, -0.15, 0.1);
  lancet5.add(lancetSill5);
  const buttress13 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.55, 2.6, 0.5), 0.01, 14), stone2Mat);
  buttress13.name = 'buttress';
  buttress13.position.set(2.86, 1.65, 1.4167);
  chapel.add(buttress13);
  const buttress14 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.32, 0.9, 0.42), 0.01, 15), stone2Mat);
  buttress14.name = 'buttress';
  buttress14.position.set(2.75, 3.4, 1.4167);
  chapel.add(buttress14);
  const buttressCap7 = new THREE.Mesh(cylinderGeo, stone2Mat);
  buttressCap7.name = 'buttressCap';
  buttressCap7.position.set(2.75, 4.025, 1.4167);
  buttressCap7.scale.set(0.78, 1, 1);
  chapel.add(buttressCap7);
  const lancet6 = new THREE.Group();
  lancet6.name = 'lancet';
  lancet6.position.set(2.6, 1.65, 2.8333);
  lancet6.rotation.set(0, deg(90), 0);
  chapel.add(lancet6);
  const lancetFrame6 = new THREE.Mesh(extrudeGeo, stone2Mat);
  lancetFrame6.name = 'lancetFrame';
  lancetFrame6.position.set(0, 0, 0.02);
  lancet6.add(lancetFrame6);
  const stainedGlass6 = new THREE.Mesh(extrudeGeo2, glassMat);
  stainedGlass6.name = 'stainedGlass';
  stainedGlass6.position.set(0, 0, 0.05);
  lancet6.add(stainedGlass6);
  const tracery6 = new THREE.Mesh(boxGeo4, ironMat);
  tracery6.name = 'tracery';
  tracery6.position.set(0, 1, 0.085);
  lancet6.add(tracery6);
  const lancetSill6 = new THREE.Mesh(boxGeo5, stone2Mat);
  lancetSill6.name = 'lancetSill';
  lancetSill6.position.set(0, -0.15, 0.1);
  lancet6.add(lancetSill6);
  const buttress15 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.55, 2.6, 0.5), 0.01, 16), stone2Mat);
  buttress15.name = 'buttress';
  buttress15.position.set(2.86, 1.65, 3.95);
  chapel.add(buttress15);
  const buttress16 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.32, 0.9, 0.42), 0.01, 17), stone2Mat);
  buttress16.name = 'buttress';
  buttress16.position.set(2.75, 3.4, 3.95);
  chapel.add(buttress16);
  const buttressCap8 = new THREE.Mesh(cylinderGeo, stone2Mat);
  buttressCap8.name = 'buttressCap';
  buttressCap8.position.set(2.75, 4.025, 3.95);
  buttressCap8.scale.set(0.78, 1, 1);
  chapel.add(buttressCap8);
  const portal = new THREE.Group();
  portal.name = 'portal';
  portal.position.set(0, 0.45, 4.25);
  chapel.add(portal);
  const archivolt = new THREE.Mesh(extrude([[-1.25, 0], [-1.04, 0], [-1.04, 1.85], [-0.9891, 2.1714], [-0.8414, 2.4613], [-0.6113, 2.6914], [-0.3214, 2.8391], [0, 2.89], [0.3214, 2.8391], [0.6113, 2.6914], [0.8414, 2.4613], [0.9891, 2.1714], [1.04, 1.85], [1.04, 0], [1.25, 0], [1.25, 1.85], [1.1888, 2.2363], [1.0113, 2.5847], [0.7347, 2.8613], [0.3863, 3.0388], [0, 3.1], [-0.3863, 3.0388], [-0.7347, 2.8613], [-1.0113, 2.5847], [-1.1888, 2.2363], [-1.25, 1.85]], 0.2), stone2Mat);
  archivolt.name = 'archivolt';
  archivolt.position.set(0, 0, 0.18);
  portal.add(archivolt);
  const archivolt2 = new THREE.Mesh(extrude([[-1.025, 0], [-0.815, 0], [-0.815, 1.825], [-0.7751, 2.0768], [-0.6593, 2.304], [-0.479, 2.4843], [-0.2518, 2.6001], [0, 2.64], [0.2518, 2.6001], [0.479, 2.4843], [0.6593, 2.304], [0.7751, 2.0768], [0.815, 1.825], [0.815, 0], [1.025, 0], [1.025, 1.825], [0.9748, 2.1417], [0.8292, 2.4275], [0.6025, 2.6542], [0.3167, 2.7998], [0, 2.85], [-0.3167, 2.7998], [-0.6025, 2.6542], [-0.8292, 2.4275], [-0.9748, 2.1417], [-1.025, 1.825]], 0.2), stoneMat);
  archivolt2.name = 'archivolt';
  archivolt2.position.set(0, 0, 0.1);
  portal.add(archivolt2);
  const doorLeaves = new THREE.Mesh(extrude([[-0.75, 0], [0.75, 0], [0.75, 1.85], [0.7133, 2.0818], [0.6068, 2.2908], [0.4408, 2.4568], [0.2318, 2.5633], [0, 2.6], [-0.2318, 2.5633], [-0.4408, 2.4568], [-0.6068, 2.2908], [-0.7133, 2.0818], [-0.75, 1.85]], 0.08), woodMat);
  doorLeaves.name = 'doorLeaves';
  doorLeaves.position.set(0, 0, 0.02);
  portal.add(doorLeaves);
  const doorSplit = new THREE.Mesh(new THREE.BoxGeometry(0.04, 2.5, 0.03), ironMat);
  doorSplit.name = 'doorSplit';
  doorSplit.position.set(0, 1.27, 0.07);
  portal.add(doorSplit);
  const doorBand = new THREE.Mesh(boxGeo6, ironMat);
  doorBand.name = 'doorBand';
  doorBand.position.set(0, 0.5, 0.07);
  portal.add(doorBand);
  const doorBand2 = new THREE.Mesh(boxGeo6, ironMat);
  doorBand2.name = 'doorBand';
  doorBand2.position.set(0, 1.4, 0.07);
  portal.add(doorBand2);
  const doorRing = new THREE.Mesh(torusGeo, ironMat);
  doorRing.name = 'doorRing';
  doorRing.position.set(-0.18, 1.05, 0.09);
  portal.add(doorRing);
  const doorRing2 = new THREE.Mesh(torusGeo, ironMat);
  doorRing2.name = 'doorRing';
  doorRing2.position.set(0.18, 1.05, 0.09);
  portal.add(doorRing2);
  const step = new THREE.Mesh(jitter(new THREE.BoxGeometry(2.9, 0.16, 0.4), 0.008, 18), stone2Mat);
  step.name = 'step';
  step.position.set(0, 0.08, 5);
  chapel.add(step);
  const step2 = new THREE.Mesh(jitter(new THREE.BoxGeometry(2.6, 0.16, 0.4), 0.008, 19), stone2Mat);
  step2.name = 'step';
  step2.position.set(0, 0.23, 4.68);
  chapel.add(step2);
  const step3 = new THREE.Mesh(jitter(new THREE.BoxGeometry(2.3, 0.16, 0.4), 0.008, 20), stone2Mat);
  step3.name = 'step';
  step3.position.set(0, 0.38, 4.36);
  chapel.add(step3);
  const roseWindow = new THREE.Group();
  roseWindow.name = 'roseWindow';
  roseWindow.position.set(0, 5.2, 4.25);
  chapel.add(roseWindow);
  const roseFrame = new THREE.Mesh(new THREE.CylinderGeometry(0.85, 0.85, 0.14, 16), stone2Mat);
  roseFrame.name = 'roseFrame';
  roseFrame.position.set(0, 0, 0.02);
  roseFrame.rotation.set(deg(90), 0, 0);
  roseWindow.add(roseFrame);
  const roseGlass = new THREE.Mesh(new THREE.CylinderGeometry(0.65, 0.65, 0.1, 16), glassMat);
  roseGlass.name = 'roseGlass';
  roseGlass.position.set(0, 0, 0.06);
  roseGlass.rotation.set(deg(90), 0, 0);
  roseWindow.add(roseGlass);
  const roseCenter = new THREE.Mesh(new THREE.CylinderGeometry(0.16, 0.16, 0.06, 8), glass2Mat);
  roseCenter.name = 'roseCenter';
  roseCenter.position.set(0, 0, 0.12);
  roseCenter.rotation.set(deg(90), 0, 0);
  roseWindow.add(roseCenter);
  const roseSpoke = new THREE.Mesh(boxGeo7, stone2Mat);
  roseSpoke.name = 'roseSpoke';
  roseSpoke.position.set(0, 0, 0.115);
  roseWindow.add(roseSpoke);
  const roseSpoke2 = new THREE.Mesh(boxGeo7, stone2Mat);
  roseSpoke2.name = 'roseSpoke';
  roseSpoke2.position.set(0, 0, 0.115);
  roseSpoke2.rotation.set(0, 0, deg(45));
  roseWindow.add(roseSpoke2);
  const roseSpoke3 = new THREE.Mesh(boxGeo7, stone2Mat);
  roseSpoke3.name = 'roseSpoke';
  roseSpoke3.position.set(0, 0, 0.115);
  roseSpoke3.rotation.set(0, 0, deg(90));
  roseWindow.add(roseSpoke3);
  const roseSpoke4 = new THREE.Mesh(boxGeo7, stone2Mat);
  roseSpoke4.name = 'roseSpoke';
  roseSpoke4.position.set(0, 0, 0.115);
  roseSpoke4.rotation.set(0, 0, deg(135));
  roseWindow.add(roseSpoke4);
  const roseRing = new THREE.Mesh(new THREE.TorusGeometry(0.42, 0.03, 3, 12), stone2Mat);
  roseRing.name = 'roseRing';
  roseRing.position.set(0, 0, 0.115);
  roseWindow.add(roseRing);
  const apsePlinth = new THREE.Mesh(new THREE.CylinderGeometry(2.25, 2.25, 0.45, 12, 1, false, Math.PI / 2, Math.PI), stone2Mat);
  apsePlinth.name = 'apsePlinth';
  apsePlinth.position.set(0, 0.225, -4.23);
  chapel.add(apsePlinth);
  const apse = new THREE.Mesh(new THREE.CylinderGeometry(2.15, 2.15, 3.6, 12, 1, false, Math.PI / 2, Math.PI), stoneMat);
  apse.name = 'apse';
  apse.position.set(0, 2.25, -4.23);
  chapel.add(apse);
  const apseRoof = new THREE.Mesh(new THREE.ConeGeometry(2.45, 2, 12, 1, false, Math.PI / 2, Math.PI), roofMat);
  apseRoof.name = 'apseRoof';
  apseRoof.position.set(0, 5.05, -4.23);
  chapel.add(apseRoof);
  const apseWindow = new THREE.Group();
  apseWindow.name = 'apseWindow';
  apseWindow.position.set(-1.6223, 1.75, -5.5913);
  apseWindow.rotation.set(0, deg(-130), 0);
  chapel.add(apseWindow);
  const lancetFrame7 = new THREE.Mesh(extrudeGeo3, stone2Mat);
  lancetFrame7.name = 'lancetFrame';
  lancetFrame7.position.set(0, 0, 0.02);
  apseWindow.add(lancetFrame7);
  const stainedGlass7 = new THREE.Mesh(extrudeGeo4, glass2Mat);
  stainedGlass7.name = 'stainedGlass';
  stainedGlass7.position.set(0, 0, 0.045);
  apseWindow.add(stainedGlass7);
  const apseWindow2 = new THREE.Group();
  apseWindow2.name = 'apseWindow';
  apseWindow2.position.set(0, 1.75, -6.3478);
  apseWindow2.rotation.set(0, deg(180), 0);
  chapel.add(apseWindow2);
  const lancetFrame8 = new THREE.Mesh(extrudeGeo3, stone2Mat);
  lancetFrame8.name = 'lancetFrame';
  lancetFrame8.position.set(0, 0, 0.02);
  apseWindow2.add(lancetFrame8);
  const stainedGlass8 = new THREE.Mesh(extrudeGeo4, glass2Mat);
  stainedGlass8.name = 'stainedGlass';
  stainedGlass8.position.set(0, 0, 0.045);
  apseWindow2.add(stainedGlass8);
  const apseWindow3 = new THREE.Group();
  apseWindow3.name = 'apseWindow';
  apseWindow3.position.set(1.6223, 1.75, -5.5913);
  apseWindow3.rotation.set(0, deg(130), 0);
  chapel.add(apseWindow3);
  const lancetFrame9 = new THREE.Mesh(extrudeGeo3, stone2Mat);
  lancetFrame9.name = 'lancetFrame';
  lancetFrame9.position.set(0, 0, 0.02);
  apseWindow3.add(lancetFrame9);
  const stainedGlass9 = new THREE.Mesh(extrudeGeo4, glass2Mat);
  stainedGlass9.name = 'stainedGlass';
  stainedGlass9.position.set(0, 0, 0.045);
  apseWindow3.add(stainedGlass9);
  const towerPlinth = new THREE.Mesh(jitter(new THREE.BoxGeometry(2.9, 0.65, 2.9), 0.01, 21), stone2Mat);
  towerPlinth.name = 'towerPlinth';
  towerPlinth.position.set(-3.75, 0.325, 2.75);
  chapel.add(towerPlinth);
  const towerShaft = new THREE.Mesh(new THREE.BoxGeometry(2.6, 9.9, 2.6), stoneMat);
  towerShaft.name = 'towerShaft';
  towerShaft.position.set(-3.75, 4.95, 2.75);
  chapel.add(towerShaft);
  const stringCourse = new THREE.Mesh(boxGeo8, stone2Mat);
  stringCourse.name = 'stringCourse';
  stringCourse.position.set(-3.75, 4.45, 2.75);
  chapel.add(stringCourse);
  const stringCourse2 = new THREE.Mesh(boxGeo8, stone2Mat);
  stringCourse2.name = 'stringCourse';
  stringCourse2.position.set(-3.75, 9.8, 2.75);
  chapel.add(stringCourse2);
  const quoin = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 22), stone2Mat);
  quoin.name = 'quoin';
  quoin.position.set(-4.83, 0.81, 1.57);
  chapel.add(quoin);
  const quoin2 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 23), stone2Mat);
  quoin2.name = 'quoin';
  quoin2.position.set(-4.93, 1.76, 1.67);
  chapel.add(quoin2);
  const quoin3 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 24), stone2Mat);
  quoin3.name = 'quoin';
  quoin3.position.set(-4.83, 2.71, 1.57);
  chapel.add(quoin3);
  const quoin4 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 25), stone2Mat);
  quoin4.name = 'quoin';
  quoin4.position.set(-4.93, 3.66, 1.67);
  chapel.add(quoin4);
  const quoin5 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 26), stone2Mat);
  quoin5.name = 'quoin';
  quoin5.position.set(-4.83, 4.61, 1.57);
  chapel.add(quoin5);
  const quoin6 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 27), stone2Mat);
  quoin6.name = 'quoin';
  quoin6.position.set(-4.93, 5.56, 1.67);
  chapel.add(quoin6);
  const quoin7 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 28), stone2Mat);
  quoin7.name = 'quoin';
  quoin7.position.set(-4.83, 6.51, 1.57);
  chapel.add(quoin7);
  const quoin8 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 29), stone2Mat);
  quoin8.name = 'quoin';
  quoin8.position.set(-4.93, 7.46, 1.67);
  chapel.add(quoin8);
  const quoin9 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 30), stone2Mat);
  quoin9.name = 'quoin';
  quoin9.position.set(-4.83, 8.41, 1.57);
  chapel.add(quoin9);
  const quoin10 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 31), stone2Mat);
  quoin10.name = 'quoin';
  quoin10.position.set(-4.83, 0.81, 3.93);
  chapel.add(quoin10);
  const quoin11 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 32), stone2Mat);
  quoin11.name = 'quoin';
  quoin11.position.set(-4.93, 1.76, 3.83);
  chapel.add(quoin11);
  const quoin12 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 33), stone2Mat);
  quoin12.name = 'quoin';
  quoin12.position.set(-4.83, 2.71, 3.93);
  chapel.add(quoin12);
  const quoin13 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 34), stone2Mat);
  quoin13.name = 'quoin';
  quoin13.position.set(-4.93, 3.66, 3.83);
  chapel.add(quoin13);
  const quoin14 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 35), stone2Mat);
  quoin14.name = 'quoin';
  quoin14.position.set(-4.83, 4.61, 3.93);
  chapel.add(quoin14);
  const quoin15 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 36), stone2Mat);
  quoin15.name = 'quoin';
  quoin15.position.set(-4.93, 5.56, 3.83);
  chapel.add(quoin15);
  const quoin16 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 37), stone2Mat);
  quoin16.name = 'quoin';
  quoin16.position.set(-4.83, 6.51, 3.93);
  chapel.add(quoin16);
  const quoin17 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 38), stone2Mat);
  quoin17.name = 'quoin';
  quoin17.position.set(-4.93, 7.46, 3.83);
  chapel.add(quoin17);
  const quoin18 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 39), stone2Mat);
  quoin18.name = 'quoin';
  quoin18.position.set(-4.83, 8.41, 3.93);
  chapel.add(quoin18);
  const quoin19 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 40), stone2Mat);
  quoin19.name = 'quoin';
  quoin19.position.set(-2.67, 0.81, 3.93);
  chapel.add(quoin19);
  const quoin20 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 41), stone2Mat);
  quoin20.name = 'quoin';
  quoin20.position.set(-2.57, 1.76, 3.83);
  chapel.add(quoin20);
  const quoin21 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 42), stone2Mat);
  quoin21.name = 'quoin';
  quoin21.position.set(-2.67, 2.71, 3.93);
  chapel.add(quoin21);
  const quoin22 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 43), stone2Mat);
  quoin22.name = 'quoin';
  quoin22.position.set(-2.57, 3.66, 3.83);
  chapel.add(quoin22);
  const quoin23 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 44), stone2Mat);
  quoin23.name = 'quoin';
  quoin23.position.set(-2.67, 4.61, 3.93);
  chapel.add(quoin23);
  const quoin24 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 45), stone2Mat);
  quoin24.name = 'quoin';
  quoin24.position.set(-2.57, 5.56, 3.83);
  chapel.add(quoin24);
  const quoin25 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 46), stone2Mat);
  quoin25.name = 'quoin';
  quoin25.position.set(-2.67, 6.51, 3.93);
  chapel.add(quoin25);
  const quoin26 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.3, 0.42, 0.5), 0.008, 47), stone2Mat);
  quoin26.name = 'quoin';
  quoin26.position.set(-2.57, 7.46, 3.83);
  chapel.add(quoin26);
  const quoin27 = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.5, 0.42, 0.3), 0.008, 48), stone2Mat);
  quoin27.name = 'quoin';
  quoin27.position.set(-2.67, 8.41, 3.93);
  chapel.add(quoin27);
  const towerSlit = new THREE.Group();
  towerSlit.name = 'towerSlit';
  towerSlit.position.set(-5.05, 3.2, 2.75);
  towerSlit.rotation.set(0, deg(-90), 0);
  chapel.add(towerSlit);
  const box146 = new THREE.Mesh(boxGeo9, stone2Mat);
  box146.position.set(0, 0, 0.01);
  towerSlit.add(box146);
  const box147 = new THREE.Mesh(boxGeo10, ironMat);
  box147.position.set(0, 0, 0.03);
  towerSlit.add(box147);
  const towerSlit2 = new THREE.Group();
  towerSlit2.name = 'towerSlit';
  towerSlit2.position.set(-5.05, 5.6, 2.75);
  towerSlit2.rotation.set(0, deg(-90), 0);
  chapel.add(towerSlit2);
  const box149 = new THREE.Mesh(boxGeo9, stone2Mat);
  box149.position.set(0, 0, 0.01);
  towerSlit2.add(box149);
  const box150 = new THREE.Mesh(boxGeo10, ironMat);
  box150.position.set(0, 0, 0.03);
  towerSlit2.add(box150);
  const clock = new THREE.Group();
  clock.name = 'clock';
  clock.position.set(-3.75, 8.95, 4.05);
  chapel.add(clock);
  const clockRim = new THREE.Mesh(new THREE.CylinderGeometry(0.55, 0.55, 0.08, 14), stone2Mat);
  clockRim.name = 'clockRim';
  clockRim.position.set(0, 0, 0.02);
  clockRim.rotation.set(deg(90), 0, 0);
  clock.add(clockRim);
  const clockFace = new THREE.Mesh(new THREE.CylinderGeometry(0.46, 0.46, 0.06, 14), whiteMat);
  clockFace.name = 'clockFace';
  clockFace.position.set(0, 0, 0.05);
  clockFace.rotation.set(deg(90), 0, 0);
  clock.add(clockFace);
  const clockHand = new THREE.Mesh(new THREE.BoxGeometry(0.05, 0.36, 0.02), ironMat);
  clockHand.name = 'clockHand';
  clockHand.position.set(0, 0.15, 0.09);
  clock.add(clockHand);
  const clockHand2 = new THREE.Mesh(new THREE.BoxGeometry(0.26, 0.05, 0.02), ironMat);
  clockHand2.name = 'clockHand';
  clockHand2.position.set(0.1, 0, 0.09);
  clock.add(clockHand2);
  const belfryPier = new THREE.Mesh(boxGeo11, stoneMat);
  belfryPier.name = 'belfryPier';
  belfryPier.position.set(-4.81, 10.95, 1.69);
  chapel.add(belfryPier);
  const belfryPier2 = new THREE.Mesh(boxGeo11, stoneMat);
  belfryPier2.name = 'belfryPier';
  belfryPier2.position.set(-4.81, 10.95, 3.81);
  chapel.add(belfryPier2);
  const belfryPier3 = new THREE.Mesh(boxGeo11, stoneMat);
  belfryPier3.name = 'belfryPier';
  belfryPier3.position.set(-2.69, 10.95, 1.69);
  chapel.add(belfryPier3);
  const belfryPier4 = new THREE.Mesh(boxGeo11, stoneMat);
  belfryPier4.name = 'belfryPier';
  belfryPier4.position.set(-2.69, 10.95, 3.81);
  chapel.add(belfryPier4);
  const belfryArch = new THREE.Mesh(extrudeGeo5, stoneMat);
  belfryArch.name = 'belfryArch';
  belfryArch.position.set(-3.75, 9.9, 3.9);
  chapel.add(belfryArch);
  const belfrySill = new THREE.Mesh(boxGeo12, stone2Mat);
  belfrySill.name = 'belfrySill';
  belfrySill.position.set(-3.75, 9.96, 3.9);
  chapel.add(belfrySill);
  const belfryArch2 = new THREE.Mesh(extrudeGeo5, stoneMat);
  belfryArch2.name = 'belfryArch';
  belfryArch2.position.set(-2.6, 9.9, 2.75);
  belfryArch2.rotation.set(0, deg(90), 0);
  chapel.add(belfryArch2);
  const belfrySill2 = new THREE.Mesh(boxGeo12, stone2Mat);
  belfrySill2.name = 'belfrySill';
  belfrySill2.position.set(-2.6, 9.96, 2.75);
  belfrySill2.rotation.set(0, deg(90), 0);
  chapel.add(belfrySill2);
  const belfryArch3 = new THREE.Mesh(extrudeGeo5, stoneMat);
  belfryArch3.name = 'belfryArch';
  belfryArch3.position.set(-3.75, 9.9, 1.6);
  belfryArch3.rotation.set(0, deg(180), 0);
  chapel.add(belfryArch3);
  const belfrySill3 = new THREE.Mesh(boxGeo12, stone2Mat);
  belfrySill3.name = 'belfrySill';
  belfrySill3.position.set(-3.75, 9.96, 1.6);
  belfrySill3.rotation.set(0, deg(180), 0);
  chapel.add(belfrySill3);
  const belfryArch4 = new THREE.Mesh(extrudeGeo5, stoneMat);
  belfryArch4.name = 'belfryArch';
  belfryArch4.position.set(-4.9, 9.9, 2.75);
  belfryArch4.rotation.set(0, deg(270), 0);
  chapel.add(belfryArch4);
  const belfrySill4 = new THREE.Mesh(boxGeo12, stone2Mat);
  belfrySill4.name = 'belfrySill';
  belfrySill4.position.set(-4.9, 9.96, 2.75);
  belfrySill4.rotation.set(0, deg(270), 0);
  chapel.add(belfrySill4);
  const belfryFloor = new THREE.Mesh(new THREE.BoxGeometry(2.5, 0.08, 2.5), stone2Mat);
  belfryFloor.name = 'belfryFloor';
  belfryFloor.position.set(-3.75, 9.94, 2.75);
  chapel.add(belfryFloor);
  const bellBeam = new THREE.Mesh(new THREE.BoxGeometry(2.2, 0.14, 0.14), woodMat);
  bellBeam.name = 'bellBeam';
  bellBeam.position.set(-3.75, 11.5, 2.75);
  chapel.add(bellBeam);
  const bell = new THREE.Mesh(lathe([[0.55, 0], [0.5, 0.08], [0.38, 0.3], [0.33, 0.62], [0.2, 0.74], [0.02, 0.78]], 10), bronzeMat);
  bell.name = 'bell';
  bell.position.set(-3.75, 10.58, 2.75);
  chapel.add(bell);
  const clapper = new THREE.Mesh(new THREE.SphereGeometry(0.08, 6, 4), ironMat);
  clapper.name = 'clapper';
  clapper.position.set(-3.75, 10.55, 2.75);
  chapel.add(clapper);
  const cornice = new THREE.Mesh(jitter(new THREE.BoxGeometry(2.9, 0.25, 2.9), 0.01, 49), stone2Mat);
  cornice.name = 'cornice';
  cornice.position.set(-3.75, 12.125, 2.75);
  chapel.add(cornice);
  const spire = new THREE.Mesh(new THREE.CylinderGeometry(0.02, 1.9092, 4.2, 4, 1, false, Math.PI / 4), roofMat);
  spire.name = 'spire';
  spire.position.set(-3.75, 14.35, 2.75);
  chapel.add(spire);
  const spireBall = new THREE.Mesh(new THREE.SphereGeometry(0.12, 6, 4), bronzeMat);
  spireBall.name = 'spireBall';
  spireBall.position.set(-3.75, 16.45, 2.75);
  chapel.add(spireBall);
  const cross = new THREE.Mesh(new THREE.BoxGeometry(0.08, 0.9, 0.08), bronzeMat);
  cross.name = 'cross';
  cross.position.set(-3.75, 16.95, 2.75);
  chapel.add(cross);
  const cross2 = new THREE.Mesh(new THREE.BoxGeometry(0.5, 0.08, 0.08), bronzeMat);
  cross2.name = 'cross';
  cross2.position.set(-3.75, 17.1, 2.75);
  chapel.add(cross2);
  const wallStone = new THREE.Mesh(jitter(new THREE.BoxGeometry(0.05, 0.22, 0.5102), 0.008, 50), stoneMat);
  wallStone.name = 'wallStone';
  wallStone.position.set(2.612, 1.0325, 2.4873);
  chapel.add(wallStone);

  root.traverse((o) => {
    if (o.isMesh) {
      o.castShadow = true;
      o.receiveShadow = true;
    }
  });
  return root;
}

export default createChapel;

Puanlar ve yorumlar

—
Henüz puan yok — ilk puanı sen ver.
5
0
4
0
3
0
2
0
1
0

Puan vermek ve yorum yapmak için giriş yap.

0 yorum

Henüz yorum yok. Bu modeli nasıl kullandığını ya da neyin daha iyi olabileceğini paylaş.

Benzer modeller

Aynı kategori ya da benzer etiketler