rimworld-blax-slaves/Source/Art/README.md

2.8 KiB

Preview art

preview.html renders About/Preview.png (1280x720) and icon.html renders About/ModIcon.png (256x256), in the Blax CI from https://www.blax.at/ui-ci: Blax black #050805, Blax green #19C63C, logo gray #CDCDCD, Geist for headings, Inter for body, Rajdhani only for the "Blax Gaming" wordmark. Fonts are the woff2 files blax.at self-hosts (all SIL Open Font License); icons are lucide.

Render with Edge headless from this folder. The separate profile folder keeps the headless run away from an open Edge window, and | Out-Null waits for each screenshot.

$edge = 'C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe'
$here = (Get-Location).Path -replace '\\','/'
$edgeData = "$env:TEMP\blax-art-edge"
& $edge --headless=new --disable-gpu --hide-scrollbars --user-data-dir="$edgeData" --virtual-time-budget=3000 --window-size=1280,720 --screenshot="$PWD\..\..\About\Preview.png" "file:///$here/preview.html" | Out-Null
& $edge --headless=new --disable-gpu --hide-scrollbars --user-data-dir="$edgeData" --virtual-time-budget=2000 --window-size=256,256 --default-background-color=00000000 --screenshot="$PWD\..\..\About\ModIcon.png" "file:///$here/icon.html" | Out-Null

Workshop page art

The Steam description (docs/workshop-description.txt) shows section headers from docs/art/steam/ and Blax Software's Open Source Initiative banner at the end. Steam shows no SVG, so the banner (docs/art/blax-oss-banner.svg, the same file as in blax-software/laravel-workkit art/oss-initiative-banner.svg) is also rendered as a PNG. header.html takes the title, subtitle and lucide icon name as query parameters.

& $edge --headless=new --disable-gpu --hide-scrollbars --user-data-dir="$edgeData" --virtual-time-budget=3000 --window-size=1600,254 --screenshot="$PWD\..\..\docs\art\blax-oss-banner.png" "file:///$here/oss-banner.html" | Out-Null
& $edge --headless=new --disable-gpu --hide-scrollbars --user-data-dir="$edgeData" --virtual-time-budget=3000 --window-size=1270,150 --screenshot="$PWD\..\..\docs\art\steam\trade.png" "file:///$here/header.html?t=Trade&s=Buy%2C%20sell%20and%20call%20in%20slavers&i=coins" | Out-Null

The other headers: slaves (Slaves, "Brands, runaways and calm colonists", flame), replaces (Replaces, "Mods you can unsubscribe", replace), compatibility (Compatibility, "Plays well with these", puzzle).

The Steam page loads these images from the Blax CDN (https://cdn.blax.at/blax-gaming/), not from Forgejo: Steam requests description images cross-origin, and only the CDN answers with Access-Control-Allow-Origin. After re-rendering, copy the PNGs to the same paths on the CDN (blax-gaming/blax-oss-banner.png, blax-gaming/slaves/<name>.png); the upload steps are in Blax's internal infrastructure docs.