fogón

← Farm3D assetfogon/bebedero

Bebedero

by fogonCC08994 blocks
BebederoDrag to turn it
// «Bebedero» · gpt-6-sol (medium)
// A round galvanized metal water trough for animals: a wide low light grey metal tub with rolled rim and ring seams, filled almost to the top with blue water with lighter ripple highlights, sitting on the grass, with a small hand water pump with a curved handle on one side.

// Sunny grass beneath the trough
for (let x = 2; x <= 46; x++) {
  for (let y = 3; y <= 45; y++) {
    const d = ((x - 24) / 22) ** 2 + ((y - 24) / 21) ** 2;
    if (d < 1 + (rand() - 0.5) * 0.09) {
      const shades = ["#62bb43", "#6bc54a", "#75cb4f", "#56ae3d"];
      set(x, y, 0, shades[Math.floor(rand() * shades.length)]);
      if (d > 0.72 && rand() < 0.13)
        set(x, y, 1, rand() < 0.5 ? "#83d256" : "#449e36");
    }
  }
}

const cx = 24, cy = 24;
function oval(x, y, rx, ry) {
  return ((x - cx) / rx) ** 2 + ((y - cy) / ry) ** 2;
}

// Tapered, solid-bottom galvanized tub
for (let z = 1; z <= 12; z++) {
  const t = (z - 1) / 11;
  const rx = 15.7 + 2.1 * t;
  const ry = 11.8 + 2.2 * t;
  for (let x = 5; x <= 43; x++) {
    for (let y = 8; y <= 40; y++) {
      const d = oval(x, y, rx, ry);
      if (d > 1) continue;

      if (z <= 3 || d > oval(x, y, rx - 1.7, ry - 1.7) / d) {
        let color;
        if (z === 5 || z === 9) color = "#a7b6ba"; // raised ring seams
        else if (z === 4 || z === 8) color = "#738a92";
        else if (z >= 11) color = "#ccd8d9";
        else color = y < 23 ? "#bbcacc" : "#a8b9bd";
        if (rand() < 0.09) color = "#d1dcda";
        if (rand() < 0.045) color = "#849ba1";
        set(x, y, z, color);
      }
    }
  }
}

// Water sits just below the rolled lip
for (let x = 7; x <= 41; x++) {
  for (let y = 10; y <= 38; y++) {
    if (oval(x, y, 15.8, 11.9) < 1) {
      for (let z = 4; z <= 10; z++) set(x, y, z, "#368fc3");
      set(x, y, 11, rand() < 0.13 ? "#60bae0" : "#399fd0");
    }
  }
}

// Broad rolled rim: dark inner edge, bright sunlit top
for (let x = 5; x <= 43; x++) {
  for (let y = 8; y <= 40; y++) {
    const outer = oval(x, y, 18.5, 14.7);
    if (outer <= 1 && oval(x, y, 15.8, 12) >= 1) {
      set(x, y, 12, "#8fa5aa");
      set(x, y, 13, y < 24 ? "#e2e9e5" : "#c5d2d3");
      if (outer > 0.94) set(x, y, 12, "#758c94");
      if (rand() < 0.06) set(x, y, 13, "#f2f3e9");
    }
  }
}

// Gentle broken ripple rings, kept inside the water
for (const [rx, ry, ox, oy] of [
  [5.5, 3.1, 22, 23],
  [10.5, 6.8, 23, 24],
  [4.1, 2.3, 31, 29]
]) {
  for (let a = 0; a < Math.PI * 2; a += 0.055) {
    if (Math.sin(a * 7 + ox) < -0.23) continue;
    const x = Math.round(ox + rx * Math.cos(a));
    const y = Math.round(oy + ry * Math.sin(a));
    if (oval(x, y, 15.2, 11.3) < 1 && get(x, y, 11))
      set(x, y, 11, Math.sin(a * 4) > 0 ? "#a2e6ee" : "#78d2e9");
  }
}

// Small stamped rivets on the visible front wall
for (const x of [12, 18, 24, 30, 36]) {
  const y = Math.round(24 - 13.5 * Math.sqrt(1 - ((x - 24) / 18) ** 2));
  for (const z of [6, 10]) {
    set(x, y - 1, z, "#718990");
    set(x, y - 1, z + 1, "#e0e8e4");
  }
}

// Side-mounted hand pump: base, upright barrel, and spout
box(38, 32, 1, 42, 36, 3, "#859da1");
box(39, 33, 3, 41, 35, 20, "#aabdc0");
box(39, 33, 4, 39, 35, 19, "#d5e0dd");
box(38, 32, 7, 42, 36, 8, "#7c969c");
box(38, 32, 18, 42, 36, 19, "#829da2");
box(38, 32, 20, 42, 36, 22, "#c6d4d4");
box(39, 33, 23, 41, 35, 23, "#edf0e7");

line(39, 34, 18, 34, 34, 18, 1, "#b9cbcc");
line(34, 34, 18, 33, 33, 16, 1, "#a4b9bc");
set(33, 33, 15, "#738f98");
set(33, 33, 14, "#6bc8e7");

// Curved operating handle and warm wooden handgrip
line(40, 34, 23, 42, 34, 25, 1, "#718b91");
line(42, 34, 25, 42, 34, 27, 1, "#829ba0");
line(42, 34, 27, 40, 34, 29, 1, "#91a9ab");
line(40, 34, 29, 37, 34, 29, 1, "#829ba0");
line(37, 34, 29, 35, 34, 27, 1, "#829ba0");
box(33, 33, 26, 36, 35, 27, "#a96a38");
box(33, 33, 27, 36, 33, 27, "#cf9250");

// A few bright grass tufts around the tub
for (const [x, y] of [[8, 7], [15, 6], [39, 8], [44, 25], [43, 40], [27, 43], [9, 39]]) {
  set(x, y, 1, "#389b38");
  set(x - 1, y, 1, "#74cb4b");
  set(x, y, 2, "#65bd41");
}