← Antiguo y prehistoriaObjeto 3Dfogon/velociraptor
Velociraptor
Arrastrá para girarlo// «Velociraptor» · gpt-6-sol (medium)
// A small agile cartoon velociraptor running on two long hind legs, body horizontal along y: a narrow head with a long snout and little teeth at the front (-y), short clawed arms, a long stiff tail behind (+y). Sandy brown with darker brown stripes on the back, a few colorful blue-and-red feathers on the head and arms, a big curved claw on each foot.
const sand = "#b9884f";
const light = "#d4a667";
const shadow = "#8c6039";
const dark = "#68452e";
const belly = "#e1bf85";
const blue = "#207f9b";
const lapis = "#285c91";
const red = "#b8493d";
const ivory = "#f5e8c9";
// Horizontal body and pale underside.
ellipsoid(24, 25, 21, 8, 10, 6, sand);
ellipsoid(24, 23, 18, 6, 8, 3, belly);
ellipsoid(24, 17, 25, 5, 6, 5, sand);
ellipsoid(24, 12, 30, 6, 6, 5, light);
// Long, narrow muzzle and lower jaw.
ellipsoid(24, 7, 28, 4, 7, 3, light);
box(21, 3, 25, 27, 11, 26, shadow);
box(21, 3, 26, 27, 10, 26, dark);
box(22, 3, 24, 26, 10, 25, belly);
for (const y of [4, 7, 10]) {
set(20, y, 25, ivory);
set(28, y, 25, ivory);
set(21, y, 24, ivory);
set(27, y, 24, ivory);
}
set(22, 3, 29, dark);
set(26, 3, 29, dark);
// Warm, irregular dorsal markings.
for (const y of [19, 23, 27, 30]) {
for (let x = 18; x <= 30; x++) {
const z = Math.round(21 + 6 * Math.sqrt(Math.max(0, 1 - ((x - 24) / 8) ** 2
- ((y - 25) / 11) ** 2)));
if (get(x, y, z)) set(x, y, z, (x + y) % 4 === 0 ? dark : shadow);
}
}
forEach((x, y, z, color) => {
if (color === sand && rand() < 0.065)
set(x, y, z, rand() < 0.5 ? light : shadow);
});
// Big friendly eyes, visible from the front and sides.
for (const x of [19, 29]) {
ellipsoid(x, 9, 32, 2, 2, 2, shadow);
sphere(x, 8, 32, 1, "#241f1c");
set(x, 7, 33, "#ffffff");
}
// Small swept-back crest feathers.
for (const [x, y, z, color] of [
[22, 13, 34, blue], [24, 14, 35, red], [26, 15, 34, lapis]
]) {
line(x, y, z, x, y + 3, z + 5, 1, color);
set(x, y + 3, z + 5, color);
}
// Short arms, three little claws, and bright elbow feathers.
for (const side of [-1, 1]) {
const sx = 24 + side * 7;
line(sx, 18, 23, sx + side * 2, 15, 20, 2, sand);
sphere(sx + side * 2, 15, 20, 2, light);
line(sx + side * 2, 15, 20, sx + side * 2, 12, 18, 1, sand);
for (let i = -1; i <= 1; i++) {
line(sx + side * 2 + i, 12, 18, sx + side * 2 + i, 10, 17, 0, ivory);
}
line(sx + side * 2, 16, 21, sx + side * 4, 18, 24, 1, blue);
line(sx + side * 2, 15, 20, sx + side * 4, 17, 22, 1, red);
}
// Stiff tapered tail, with a gentle side-to-side running swing.
part("tail", [24, 32, 22]);
for (let y = 31; y <= 45; y++) {
const t = (y - 31) / 14;
const radius = Math.max(1, Math.round(4 - 3 * t));
const z = Math.round(22 - 3 * t);
sphere(24, y, z, radius, t > 0.72 ? shadow : sand);
if (y % 4 === 1 && y < 43)
line(24 - radius, y, z + 1, 24 + radius, y + 1, z + 1, 0, dark);
}
animate("tail", { type: "swing", axis: "z", speed: 3, amplitude: 0.2 });
part("body");
// Alternating, long running legs. The forward leg and rear leg
// have different poses so the silhouette reads even when still.
for (const side of [-1, 1]) {
const x = 24 + side * 6;
const forward = side === -1;
const kneeY = forward ? 20 : 29;
const ankleY = forward ? 23 : 29;
const toeY = forward ? 15 : 22;
const name = side === -1 ? "leftLeg" : "rightLeg";
part(name, [x, 26, 19]);
sphere(x, 26, 19, 3, shadow);
line(x, 26, 18, x + side, kneeY, 11, 3, sand);
ellipsoid(x + side, kneeY, 11, 3, 3, 3, light);
line(x + side, kneeY, 10, x + side, ankleY, 3, 2, shadow);
sphere(x + side, ankleY, 3, 2, sand);
// Broad, three-toed foot planted close to the ground.
box(x + side - 2, toeY + 2, 0, x + side + 2, ankleY + 1, 2, sand);
for (const dx of [-2, 0, 2]) {
line(x + side + dx, toeY + 3, 1, x + side + dx, toeY, 1, 1, light);
set(x + side + dx, toeY - 1, 0, ivory);
}
// Oversized hooked sickle claw, raised above the other toes.
const clawX = x + side * 2;
line(clawX, toeY + 2, 2, clawX, toeY, 6, 1, ivory);
line(clawX, toeY, 6, clawX, toeY - 3, 7, 1, ivory);
line(clawX, toeY - 3, 7, clawX, toeY - 4, 4, 0, dark);
animate(name, {
type: "swing", axis: "x",
speed: forward ? 7 : -7, amplitude: 0.4
});
}
part("body");import { draw } from "./assets/voxel";
import { velociraptor } from "./assets/velociraptor";
// En cada cuadro: parado sobre (x, y), el centro de su base.
draw(ctx, velociraptor, x, y, { size: 64, angle: 0, t: performance.now() / 1000 });
// size: lo que mide en px su lado más largo
// angle: giro sobre el piso, en radianes
// t: segundos; si se mueve, se anima solo con eso# En una terminal, en la carpeta del juego
fogon assets add velociraptor
# Con las herramientas de Fogón (conector)
add_assets({ slug: "<tu-juego>", ids: ["velociraptor"] })
# Queda en client/assets/velociraptor.ts
# https://fogon.page/object/velociraptor