fogón

← Asian3D assetfogon/portal-de-templo

Portal de templo

by fogonCC09778 blocks
Portal de temploDrag to turn it
// «Portal de templo» · gpt-6-sol (medium)
// A Chinese paifang memorial gate: three openings between four red pillars on stone bases, a horizontal gold-and-blue painted beam with a central plaque, and three small tiled roofs on top, the middle one higher.

// Chinese paifang memorial gate — front faces -y.
const red = "#a72929", redLight = "#c64232", redDark = "#751d24";
const gold = "#e9b94f", paleGold = "#ffe08a", darkGold = "#a97930";
const blue = "#214b76", deepBlue = "#193651", jade = "#65a888";

function edgedBox(x0, y0, z0, x1, y1, z1, main, edge) {
  box(x0, y0, z0, x1, y1, z1, main);
  box(x0, y0, z0, x1, y0, z1, edge);
  box(x0, y0, z1, x1, y1, z1, edge);
}

// Four stone footings and lacquered pillars.
for (const x of [5, 16, 29, 40]) {
  box(x-2, 18, 0, x+5, 29, 1, "#aab2aa");
  box(x-1, 19, 2, x+4, 28, 3, "#d5d8ca");
  box(x, 20, 4, x+3, 27, 5, "#f0ead7");
  box(x, 21, 6, x+3, 26, 22, red);
  box(x, 21, 6, x, 21, 22, redLight);
  box(x+3, 21, 6, x+3, 21, 22, redDark);
  for (const z of [6, 8, 20, 22]) {
    box(x, 20, z, x+3, 27, z, z === 6 ? darkGold : gold);
  }
  box(x, 19, 18, x+3, 20, 21, redDark);
  box(x+1, 18, 19, x+2, 18, 20, paleGold);
  box(x-1, 20, 22, x+4, 27, 23, darkGold);
}

// Main horizontal beam: red structure, blue painted fascia, gilded edges.
box(4, 20, 23, 44, 27, 26, redDark);
box(3, 19, 25, 45, 28, 28, blue);
box(3, 18, 25, 45, 18, 25, darkGold);
box(3, 18, 28, 45, 28, 28, gold);
box(4, 18, 26, 44, 18, 27, "#295d82");
for (let x = 5; x <= 43; x += 4) {
  box(x, 17, 26, x, 17, 27, gold);
  set(x+1, 17, 27, jade);
  set(x+2, 17, 26, paleGold);
}
for (const x of [4, 15, 28, 40, 44]) {
  box(x, 17, 24, x, 18, 29, gold);
  box(x, 16, 26, x, 16, 27, paleGold);
}

// Brackets and short decorated walls beneath each roof.
for (const [a, b] of [[4, 19], [14, 34], [29, 44]]) {
  box(a, 20, 29, b, 27, 30, red);
  box(a, 19, 29, b, 19, 29, darkGold);
  for (let x = a+2; x < b; x += 4) {
    box(x, 18, 29, x+1, 18, 30, blue);
    set(x, 17, 30, paleGold);
  }
}
box(15, 21, 31, 33, 26, 34, redDark);
box(16, 19, 32, 32, 20, 33, redLight);
for (const x of [15, 19, 24, 29, 33]) {
  box(x, 18, 32, x, 18, 34, gold);
}

// Central hanging inscription plaque.
edgedBox(19, 16, 26, 29, 18, 33, deepBlue, darkGold);
for (let x = 19; x <= 29; x++) {
  set(x, 15, 26, gold);
  set(x, 15, 33, paleGold);
}
for (let z = 26; z <= 33; z++) {
  set(19, 15, z, gold);
  set(29, 15, z, gold);
}
box(20, 15, 27, 28, 15, 32, blue);
// Two compact, calligraphic gold characters.
for (const x of [21, 25]) {
  box(x, 14, 31, x+2, 14, 31, paleGold);
  box(x, 14, 29, x+2, 14, 29, gold);
  box(x+1, 14, 28, x+1, 14, 32, paleGold);
  set(x, 14, 27, gold);
  set(x+2, 14, 27, gold);
}

// A pitched glazed-tile roof. Its ends curl upward at the corners.
function roof(left, right, eave) {
  for (let x = left; x <= right; x++) {
    const end = Math.min(x-left, right-x);
    for (let y = 15; y <= 32; y++) {
      const distance = Math.abs(y-23.5);
      const curl = end < 2 && distance > 6 ? 2 : end < 4 && distance > 6 ? 1 : 0;
      const z = eave + 5 - Math.floor(distance * 0.61) + curl;
      const tile = (x % 3 === 0) ? "#79a398"
        : (x % 3 === 1) ? "#326d66" : "#245451";
      set(x, y, z-1, "#244c48");
      set(x, y, z, tile);
      if (y === 15 || y === 32) {
        set(x, y, z-1, gold);
        if (x % 3 === 0) set(x, y, z, "#a9c3aa");
      }
    }
  }
  // Raised ridge and gilded end ornaments.
  box(left+2, 23, eave+6, right-2, 24, eave+6, "#193f3d");
  for (let x = left+3; x <= right-3; x += 3)
    box(x, 23, eave+7, x, 24, eave+7, gold);
  for (const x of [left, right]) {
    box(x, 15, eave+2, x, 16, eave+4, darkGold);
    set(x, 15, eave+5, paleGold);
    set(x, 32, eave+4, gold);
  }
}

// Side roofs sit lower; the central roof crowns the gate.
roof(2, 19, 29);
roof(29, 46, 29);
roof(13, 35, 35);

// Warm stone grain and tiny jade accents on the visible bases.
for (const x of [5, 16, 29, 40]) {
  for (let i = 0; i < 14; i++) {
    const px = x - 1 + Math.floor(rand()*6);
    const pz = Math.floor(rand()*4);
    set(px, 18 + (pz > 1 ? 1 : 0), pz,
        rand() < 0.5 ? "#e9e6d7" : "#bec4b8");
  }
  set(x+1, 19, 3, jade);
  set(x+2, 19, 3, jade);
}