← CiudadObjeto 3Dfogon/cine
Cine
Arrastrá para girarlo// «Cine» · gpt-6-sol (medium)
// An old movie theater: a two-story facade with a big lit marquee sign sticking out over the entrance with rows of small yellow bulbs and the word CINE, framed movie posters on both sides of glass doors facing -y, a ticket booth in the middle, and art deco stripes on the upper facade in red and gold.
const brick = "#bc6654";
const brickLight = "#cd7964";
const brickDark = "#a85147";
const cream = "#f4dfb7";
const creamShade = "#dbc49d";
const gold = "#e7b653";
const goldDark = "#aa7135";
const red = "#a93842";
const redLight = "#d45151";
const glass = "#75b9bb";
const glassLight = "#ace0d1";
const glassDark = "#346b75";
const iron = "#264c48";
// Compact hollow building, with a solid floor and roof.
box(6, 14, 1, 41, 36, 2, "#807b72");
box(6, 14, 3, 7, 36, 37, brickDark);
box(40, 14, 3, 41, 36, 37, brickDark);
box(8, 35, 3, 39, 36, 37, brick);
box(8, 13, 3, 39, 14, 37, brick);
box(6, 14, 37, 41, 36, 39, creamShade);
box(7, 15, 39, 40, 35, 39, cream);
// Brick variation and chunky courses on the visible facade.
for (let z = 3; z <= 36; z++) {
for (let x = 8; x <= 39; x++) {
if (rand() < 0.075) set(x, 12, z, rand() < 0.5 ? brickLight : brickDark);
}
}
for (let z = 5; z <= 16; z += 4) {
for (let x = 8 + (z % 8 ? 2 : 0); x < 40; x += 6) {
box(x, 12, z, x + 2, 12, z, brickDark);
}
}
// Pale stone base, corner piers, and the upper story's red painted facade.
box(5, 13, 1, 42, 36, 2, creamShade);
box(5, 12, 3, 7, 15, 36, cream);
box(40, 12, 3, 42, 15, 36, cream);
box(6, 12, 26, 41, 13, 36, red);
box(8, 11, 27, 39, 11, 28, redLight);
box(8, 11, 35, 39, 11, 36, brickDark);
box(5, 11, 26, 42, 15, 27, cream);
box(5, 12, 37, 42, 16, 38, cream);
box(7, 12, 39, 40, 16, 39, goldDark);
box(17, 13, 40, 30, 17, 41, cream);
box(20, 13, 42, 27, 17, 42, gold);
// Art deco fluting and stepped gold rays.
for (const x of [8, 9, 17, 18, 29, 30, 38, 39]) {
box(x, 10, 29, x, 10, 35, gold);
}
for (let i = 0; i < 5; i++) {
box(19 + i, 10, 34 + i, 19 + i, 10, 35 + i, gold);
box(28 - i, 10, 34 + i, 28 - i, 10, 35 + i, gold);
}
box(21, 10, 29, 26, 10, 33, cream);
box(22, 9, 30, 25, 9, 32, gold);
box(23, 8, 31, 24, 8, 31, red);
// Upper windows, set deep in the painted facade.
function upperWindow(x0, x1) {
box(x0 - 1, 10, 28, x1 + 1, 10, 35, cream);
box(x0, 9, 29, x1, 9, 34, iron);
box(x0 + 1, 8, 30, x1 - 1, 8, 33, glassDark);
box(x0 + 1, 7, 32, x1 - 1, 7, 33, glass);
box(x0 + 2, 7, 33, x0 + 2, 7, 33, glassLight);
box(x0 - 1, 8, 28, x1 + 1, 10, 28, goldDark);
box(x0 - 1, 8, 35, x1 + 1, 10, 35, gold);
}
upperWindow(11, 15);
upperWindow(32, 36);
// Entrance recesses and double glass doors.
for (const [a, b] of [[14, 20], [28, 34]]) {
box(a, 12, 2, b, 14, 14, null);
box(a, 15, 2, b, 15, 14, "#344448");
box(a, 12, 2, b, 12, 13, iron);
box(a + 1, 11, 3, b - 1, 11, 12, glassDark);
box(a + 1, 10, 8, b - 1, 10, 11, glass);
box(a + 1, 10, 4, b - 1, 10, 6, glass);
const mid = Math.floor((a + b) / 2);
box(mid, 9, 3, mid, 9, 12, iron);
box(mid - 1, 8, 6, mid - 1, 8, 8, gold);
box(mid + 1, 8, 6, mid + 1, 8, 8, gold);
box(a - 1, 10, 2, a - 1, 12, 15, cream);
box(b + 1, 10, 2, b + 1, 12, 15, cream);
box(a, 10, 14, b, 12, 15, creamShade);
}
// Bright framed movie posters on either side.
function poster(x, background, accent) {
box(x - 1, 9, 4, x + 4, 12, 14, goldDark);
box(x, 8, 5, x + 3, 8, 13, cream);
box(x, 7, 6, x + 3, 7, 12, background);
box(x + 1, 6, 8, x + 2, 6, 11, accent);
box(x + 1, 6, 6, x + 2, 6, 6, "#fff1bc");
box(x, 8, 4, x + 3, 9, 4, iron);
}
poster(8, "#31788a", "#f3b971");
poster(36, "#d56269", "#f7db8c");
// Little projecting ticket booth, centered between the doors.
box(21, 8, 2, 27, 14, 4, red);
box(21, 8, 5, 27, 13, 12, creamShade);
box(22, 7, 6, 26, 7, 11, iron);
box(23, 6, 7, 25, 6, 10, glass);
box(24, 5, 8, 24, 5, 9, glassLight);
box(21, 6, 5, 27, 9, 6, goldDark);
box(22, 5, 6, 26, 6, 6, cream);
box(20, 7, 12, 28, 14, 14, red);
box(21, 6, 13, 27, 7, 13, gold);
box(22, 5, 14, 26, 6, 14, cream);
box(23, 5, 12, 25, 5, 12, "#fff1bc");
set(24, 4, 11, gold);
// Raised sidewalk and a dark green entrance mat.
box(7, 7, 0, 40, 16, 0, "#a8a49a");
box(12, 7, 0, 35, 12, 0, "#cbc4b4");
box(14, 10, 1, 34, 13, 1, creamShade);
box(18, 9, 1, 30, 10, 1, iron);
// Deep, projecting marquee with a broad red sign face.
box(8, 6, 18, 39, 16, 25, red);
box(9, 5, 19, 38, 5, 24, redLight);
box(8, 6, 17, 39, 16, 18, goldDark);
box(8, 6, 25, 39, 16, 26, gold);
box(9, 5, 18, 38, 5, 18, cream);
box(9, 5, 25, 38, 5, 25, cream);
box(8, 5, 19, 8, 5, 24, cream);
box(39, 5, 19, 39, 5, 24, cream);
for (const x of [11, 36]) {
box(x, 4, 20, x, 4, 23, gold);
set(x + (x < 24 ? 1 : -1), 4, 21, cream);
set(x + (x < 24 ? 1 : -1), 4, 22, cream);
}
// Large block lettering on the front: CINE.
const letters = {
C: ["0111", "1000", "1000", "1000", "0111"],
I: ["1110", "0100", "0100", "0100", "1110"],
N: ["1001", "1101", "1011", "1001", "1001"],
E: ["1111", "1000", "1110", "1000", "1111"]
};
let letterX = 14;
for (const ch of "CINE") {
const pixels = letters[ch];
for (let row = 0; row < 5; row++) {
for (let col = 0; col < 4; col++) {
if (pixels[row][col] === "1") {
set(letterX + col, 4, 23 - row, "#fff0bd");
set(letterX + col, 5, 23 - row, goldDark);
}
}
}
letterX += 5;
}
// Only the incandescent bulbs belong to the animated part.
part("marquee_bulbs", [24, 10, 22]);
for (let x = 9; x <= 39; x += 2) {
set(x, 4, 17, "#ffe066");
set(x, 4, 26, "#fff6cc");
set(x, 8, 27, "#ffe066");
set(x, 13, 27, "#ff9933");
}
for (let z = 19; z <= 25; z += 2) {
set(8, 4, z, "#ffe066");
set(39, 4, z, "#fff6cc");
}
animate("marquee_bulbs", {
type: "colors",
palette: ["#ffe066", "#ff9933", "#fff6cc"],
pattern: "wave",
glow: 0.9
});import { draw } from "./assets/voxel";
import { cine } from "./assets/cine";
// En cada cuadro: parado sobre (x, y), el centro de su base.
draw(ctx, cine, 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 cine
# Con las herramientas de Fogón (conector)
add_assets({ slug: "<tu-juego>", ids: ["cine"] })
# Queda en client/assets/cine.ts
# https://fogon.page/object/cine