Files
BT411/scratchpad/night6/file_79close.py
T

33 lines
1.6 KiB
Python

"""#79 particles.png recovered -- comment + close."""
import base64
import json
import subprocess
import urllib.request
REPO = r"C:\git\bt411"
BASE = "https://gitea.mysticmachines.com/api/v1/repos/VWE/BT411"
out = subprocess.run(["git", "credential", "fill"],
input="protocol=https\nhost=gitea.mysticmachines.com\n\n",
capture_output=True, text=True, cwd=REPO)
cred = dict(l.split("=", 1) for l in out.stdout.strip().splitlines() if "=" in l)
AUTH = "Basic " + base64.b64encode(
(cred["username"] + ":" + cred["password"]).encode()).decode()
def call(method, path, payload=None):
data = json.dumps(payload).encode() if payload is not None else None
r = urllib.request.Request(BASE + path, data=data, method=method)
r.add_header("Authorization", AUTH)
r.add_header("Content-Type", "application/json")
return json.load(urllib.request.urlopen(r))
BODY = """**Recovered by cyd** and landed in `1ac4258`: `content/VIDEO/particles.png` (128x128 RGBA) -- the texture `L4PARTICLES` has tried to load since the engine was written. Boot-verified: `[particles] device objects created (max=8192, texture=loaded)`. Every particle effect now draws textured.
Historical note for the record: the file never shipped to the arcades, so the 1995 pods displayed untextured quads -- the textured look is the AUTHORED intent, first time on screen. If the old-timers prefer the field look we can gate it, but intended-by-default seems right. Closing."""
call("POST", "/issues/79/comments", {"body": BODY})
call("PATCH", "/issues/79", {"state": "closed"})
print("#79 commented + closed")