This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| extends Node | |
| enum TERRAIN_SHAPE { NONE, FLAT, PEAK, DROP, SLANT } | |
| const QUAD_UVS: = PoolVector2Array([Vector2(0, 0), Vector2(1, 0), Vector2(1, 1), Vector2(0, 1)]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { readdir, readFile, writeFile } from 'node:fs/promises'; | |
| import { join } from 'node:path'; | |
| async function walk(dir: string) { | |
| for (const e of await readdir(dir, { withFileTypes: true })) { | |
| const p = join(dir, e.name); | |
| if (e.isDirectory()) { | |
| await walk(p); | |
| } else if (e.isFile() && p.endsWith('.d.ts')) { | |
| const src = await readFile(p, 'utf8'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| import os, io, json, random, datetime, subprocess, ssl, urllib.request | |
| from PIL import Image, ImageDraw, ImageFont | |
| # ---------------- CONFIG ---------------- | |
| DPI = 300 | |
| PAPER = os.getenv("PAPER", "A4").upper() # 'A4' or 'LETTER' | |
| def mm_px(mm): return round(mm / 25.4 * DPI) |
OlderNewer