← Gear3D assetfogon/escudo-redondo
Escudo redondo de madera
Drag to turn it// «Escudo redondo de madera» · gpt-6-sol (medium)
// A round wooden shield standing upright facing -y: a thick disc of vertical wooden planks in two warm browns, a riveted iron rim around the edge and a big round iron boss in the center, with a faded red painted stripe across it. A wooden stand-free base: the bottom edge simply rests on the floor. It stands upright on the floor (z=0), facing front (-y), centered, chunky and readable.
const cx = 24, cz = 19.5;
const radius = 20;
const plankColors = ["#a86c37", "#b77b42", "#98602f", "#c08749", "#a66a35"];
const grainColors = ["#8f572d", "#d09352", "#ad6e38"];
// Solid, upright wooden disc. Its rounded bottom rests directly on z=0.
for (let x = 4; x <= 44; x++) {
for (let z = 0; z <= 39; z++) {
const d = Math.hypot(x - cx, z - cz);
if (d > radius) continue;
const plank = Math.floor((x - 4) / 5);
const seam = (x - 4) % 5 === 4;
let wood = plankColors[plank % plankColors.length];
if (rand() < 0.075) wood = grainColors[Math.floor(rand() * grainColors.length)];
for (let y = 20; y <= 27; y++) {
set(x, y, z, y === 27 ? "#80502e" : wood);
}
// Raised front face and dark gaps between the vertical planks.
set(x, 19, z, seam ? "#684027" : wood);
if (!seam && rand() < 0.10) {
set(x, 19, z, grainColors[Math.floor(rand() * grainColors.length)]);
}
}
}
// Worn red paint crosses the planks diagonally, beneath the metal boss.
for (let x = 5; x <= 43; x++) {
for (let z = 0; z <= 39; z++) {
const d = Math.hypot(x - cx, z - cz);
const stripeCenter = 21 - 0.27 * (x - cx);
const distance = Math.abs(z - stripeCenter);
if (d > 17.2 || distance > 3.5) continue;
const seam = (x - 4) % 5 === 4;
const worn = rand();
if (worn < 0.075 || (distance > 2.7 && worn < 0.35)) continue;
let paint = worn < 0.24 ? "#a3493b" :
worn < 0.48 ? "#b85443" : "#994034";
if (seam) paint = "#77382f";
set(x, 18, z, paint);
}
}
// Thick iron binding: dark outside edge, brighter front and upper highlights.
for (let x = 4; x <= 44; x++) {
for (let z = 0; z <= 39; z++) {
const d = Math.hypot(x - cx, z - cz);
if (d < 17.15 || d > radius) continue;
for (let y = 18; y <= 28; y++) {
let iron = "#50565a";
if (y >= 25) iron = "#41464a";
if (y <= 20) iron = "#737b7e";
if (d > 19.1 && y >= 21) iron = "#62696c";
set(x, y, z, iron);
}
set(x, 17, z,
d < 17.8 ? "#42494d" :
z > cz + 5 || x < cx - 6 ? "#aeb5b4" : "#848d8f");
if (d > 19.15 && (z > cz || x < cx)) {
set(x, 18, z, "#c0c5bf");
}
}
}
// Large hammered iron boss, built as a stepped round dome.
for (let x = 16; x <= 32; x++) {
for (let z = 12; z <= 28; z++) {
const d = Math.hypot(x - cx, z - 20);
if (d > 8.1) continue;
const frontY = d < 2.6 ? 12 :
d < 4.2 ? 13 :
d < 5.3 ? 14 :
d < 6.2 ? 15 :
d < 7.1 ? 16 : 17;
for (let y = frontY; y <= 19; y++) {
let iron = "#686f72";
if (d > 7.1) iron = "#41484d";
else if (d > 6.1) iron = "#9da5a6";
else if (z > 21 || x < 22) iron = "#929c9e";
if (y === frontY && d < 5.4 && z >= 21 && x <= 25) iron = "#b5bdba";
if (y === frontY && d < 5.4 && z < 18 && x > 25) iron = "#555d63";
set(x, y, z, iron);
}
}
}
// Bright rivets around the rim, and smaller fasteners on the boss flange.
for (let i = 0; i < 16; i++) {
const a = i * Math.PI * 2 / 16;
const x = Math.round(cx + Math.cos(a) * 18.5);
const z = Math.round(cz + Math.sin(a) * 18.5);
box(x - 1, 15, z - 1, x + 1, 16, z + 1, "#596064");
set(x, 14, z, "#d0d1c8");
set(x - 1, 15, z, "#aeb5b3");
set(x, 15, z + 1, "#aeb5b3");
}
for (let i = 0; i < 8; i++) {
const a = (i + 0.5) * Math.PI * 2 / 8;
const x = Math.round(cx + Math.cos(a) * 7.3);
const z = Math.round(20 + Math.sin(a) * 7.3);
set(x, 16, z, "#c1c5bd");
set(x, 17, z, "#858d8c");
}import { draw } from "./assets/voxel";
import { escudoRedondo } from "./assets/escudo-redondo";
// Every frame: standing on (x, y), the centre of its base.
draw(ctx, escudoRedondo, x, y, { size: 64, angle: 0, t: performance.now() / 1000 });
// size: its longest side, in px
// angle: turn on the floor, in radians
// t: seconds; if it moves, that animates it# In a terminal, in the game's folder
fogon assets add escudo-redondo
# With Fogón's tools (connector)
add_assets({ slug: "<your-game>", ids: ["escudo-redondo"] })
# It lands in client/assets/escudo-redondo.ts
# https://fogon.page/object/escudo-redondo