Repository navigation
Pixel Engine 0.47.0
Pixel Engine 0.47.0 as the engine kit: pixel-engine.zip below holds the engine as one ES module, its guides, a starter game and check.mjs. Unzip it, then read README.md and GUIDE.md.
The newest release is always https://github.com/michaelcrosato/riftlight/releases/latest/download/pixel-engine.zip; this one stays at https://github.com/michaelcrosato/riftlight/releases/download/engine-v0.47.0/pixel-engine.zip.
What changed in 0.47.0
- AI Hub sessions (docs/engine/hub.md):
HubSession.join({ mode, seats })takes part in a round of
the AI Hub (AI Hub Session Protocol v1) inparallel,ghostorshared-worldmode, and is null
outside one. The hub's events (start, other copies'messages,leave,time-up,end) arrive as
input commands (hubEvents(ctx.input.commands)), so a session records and replays.progress,
resultandfinish(once, and only an outcome the hub can take),send(bundled per destination
under the hub's rate and size limits; what the rate holds back waits), and atendthe engine
stands still (speed 0) and goes quiet.RemoteTrackdraws another copy's state smoothly;LocalHub
is the hub in memory for tests, held to the real client's limits.HUB_COLORS,HUB_LIMITS,
headMeta,validResult,validFinish. - Languages (docs/engine/lang.md, AI Hub Languages v1):
LangandlangFor(lines)give lines in
the player's language witht(id, values): blanks, plural forms, control tags, numbers formatted for
the language, right-to-left isolates, and the original line whenever a translation is missing or
broken.pickLanguage,languageName,chooseLanguage, the test languagesen-XA,zh-XC,
ar-XB(fakeLine),pieces,lineWidth,blockJson,pageBlock,HUB_LANGUAGES. - Text in every writing system: the pixel font composes accented capitals (
glyphFor: É, Ñ, Ç, Ş,
İ, Ẹ́, plus ¿ ¡ « » „ – — … € Æ Œ Ø Ɓ Ɗ Ƙ) and upper-cases in the drawing language
(setTextLocale). A line in a language it can't draw (Cyrillic, Chinese, Arabic, Hindi,
Vietnamese...) is drawn byctx.hudin the device's own font at the screen's resolution, in the same
box (pixelCovers,drawDeviceText,surfaceScale).hud.measureandtextWidthPxmeasure the
font that draws;wrapTextwraps by measured width atIntl.Segmenterword breaks.textWidthcounts
letters with their marks, not UTF-16 units. - Gamepad: View + Menu held together (buttons 8 and 9,
HOST_CHORD) press neither until both are
let go: the AI Hub opens its bar on them.