← Asian3D assetfogon/gato-de-la-suerte
Gato de la suerte
Drag to turn it// «Gato de la suerte» · gpt-6-sol (medium)
// A Japanese lucky cat (maneki-neko) figurine sitting: white body, red collar with a golden bell, holding a golden coin, pink inside the ears, closed happy eyes. Its raised left paw is the moving part, waving.
// Lacquered display plinth
box(7, 9, 0, 41, 39, 1, "#7e211c");
box(8, 10, 2, 40, 38, 2, "#d3a044");
box(10, 12, 3, 38, 36, 3, "#9f3025");
box(9, 10, 0, 39, 10, 0, "#e1ae4e");
box(9, 38, 0, 39, 38, 0, "#b47b36");
// Seated body and haunches
ellipsoid(24, 26, 17, 12, 10, 14, "#e8e6de");
ellipsoid(24, 25, 19, 10, 9, 10, "#f8f6ee");
ellipsoid(16, 26, 11, 7, 8, 8, "#e9e8e2");
ellipsoid(32, 26, 11, 7, 8, 8, "#e9e8e2");
ellipsoid(16, 17, 7, 5, 5, 4, "#faf8f0");
ellipsoid(32, 17, 7, 5, 5, 4, "#faf8f0");
// Curled tail, visible at the right
line(34, 31, 7, 39, 32, 9, 3, "#deded8");
line(39, 32, 9, 39, 30, 15, 2.5, "#f6f4ed");
sphere(38, 30, 15, 2.5, "#ffffff");
// Head and upright, pointed ears
ellipsoid(24, 22, 32, 10, 9, 9, "#f9f8f2");
for (let side of [-1, 1]) {
const c = 24 + side * 8;
for (let z = 37; z <= 45; z++) {
const half = Math.max(0, Math.floor((45 - z) * 0.43));
box(c - half, 18, z, c + half, 23, z, z < 41 ? "#f7f6ef" : "#fffdf5");
if (z >= 39 && z <= 43) {
const inner = Math.max(0, half - 1);
box(c - inner, 17, z, c + inner, 18, z, "#e99ba4");
}
}
}
// Soft variation on the large porcelain surfaces
forEach((x, y, z, color) => {
if (color === "#e8e6de" || color === "#e9e8e2" ||
color === "#f8f6ee" || color === "#f9f8f2") {
if (rand() < 0.075) set(x, y, z, "#fffdf6");
else if (rand() < 0.045 && z < 19) set(x, y, z, "#dcdcd6");
}
});
// Red collar and its gold edging
for (let x = 17; x <= 31; x++) {
const y = 14 + Math.round(Math.abs(x - 24) * 0.22);
box(x, y, 23, x, y, 25, "#bd302b");
set(x, y - 1, 23, "#e3aa48");
}
box(21, 13, 25, 27, 13, 25, "#e64b3c");
sphere(24, 12, 22, 3, "#e9ae39");
sphere(23, 10, 23, 1, "#ffe18a");
line(22, 9, 21, 26, 9, 21, 0, "#936224");
set(24, 9, 20, "#664621");
// Closed, smiling eyes: sweeping dark curves
for (const c of [19, 29]) {
line(c - 3, 12, 32, c - 1, 11, 30, 0, "#574741");
line(c - 1, 11, 30, c + 1, 11, 30, 0, "#574741");
line(c + 1, 11, 30, c + 3, 12, 32, 0, "#574741");
}
ellipsoid(16, 12, 27, 2, 1, 1, "#efb9b5");
ellipsoid(32, 12, 27, 2, 1, 1, "#efb9b5");
ellipsoid(24, 11, 28, 1.5, 1, 1, "#db8693");
line(24, 10, 27, 24, 10, 25, 0, "#75534c");
line(24, 10, 25, 22, 10, 24, 0, "#75534c");
line(24, 10, 25, 26, 10, 24, 0, "#75534c");
for (const z of [26, 28]) {
line(12, 12, z + 1, 19, 11, z, 0, "#a3988a");
line(29, 11, z, 36, 12, z + 1, 0, "#a3988a");
}
// One stationary paw supports the coin
line(17, 19, 20, 13, 15, 16, 3, "#eeeae3");
sphere(13, 14, 16, 3, "#fffdf5");
// Large gold koban, presented toward the viewer
cylinder(15, 10, 16, 7, 4, "#a66a25", "y");
cylinder(15, 8, 16, 7, 2, "#f4bd4c", "y");
cylinder(15, 7, 16, 6, 2, "#ffd86a", "y");
cylinder(15, 6, 16, 5, 2, "#e9a93c", "y");
for (let x = 9; x <= 21; x++) {
for (let z = 10; z <= 22; z++) {
const d = Math.hypot(x - 15, z - 16);
if (d >= 5.5 && d <= 6.8) set(x, 6, z, "#ffe391");
}
}
// Bold embossed lucky inscription
line(15, 5, 12, 15, 5, 20, 0, "#9b6229");
line(12, 5, 18, 18, 5, 18, 0, "#9b6229");
line(13, 5, 15, 17, 5, 15, 0, "#9b6229");
set(14, 5, 21, "#fff0ac");
// Raised left paw is separate so it can wave from its shoulder.
part("waving_paw", [32, 19, 25]);
sphere(33, 19, 25, 3, "#e5e3dc");
line(34, 18, 27, 37, 17, 36, 3, "#f4f2eb");
sphere(37, 17, 37, 4, "#fffdf5");
ellipsoid(37, 13, 37, 2, 1, 2, "#e7a6a6");
for (const x of [34, 37, 40]) {
sphere(x, 13, 40, 1, "#e7a6a6");
}
animate("waving_paw", {
type: "swing",
axis: "y",
speed: 4,
amplitude: 0.5
});
part("body");import { draw } from "./assets/voxel";
import { gatoDeLaSuerte } from "./assets/gato-de-la-suerte";
// Every frame: standing on (x, y), the centre of its base.
draw(ctx, gatoDeLaSuerte, 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 gato-de-la-suerte
# With Fogón's tools (connector)
add_assets({ slug: "<your-game>", ids: ["gato-de-la-suerte"] })
# It lands in client/assets/gato-de-la-suerte.ts
# https://fogon.page/object/gato-de-la-suerte