Triforce v0.8.0

Evil HD (SMAA Ultra, 16x filtering, full textures, ambient occlusion with bounce light, sunlight shafts, foliage drawn 4x as far, the remastered texture pack's loader and the launcher's download of it), FSR 3.1 frame generation for every GPU, Intel XeSS, FSR 4 model choice, ReShade presets, Auto (this PC), HUD placement, the options menu in 13 languages, a second input for every control, hold to toggle, DualSense speaker and haptics, NFC from the player's own dumps, the above-60 fps game fixes, the Debug tab's flight and Inventory fixes, the launcher's full settings, and over 250 fixes.
This commit is contained in:
ruckus7382sfgsgdf
2026-11-25 10:21:32 -06:00
parent 861702476a
commit 4fa4f9188b
881 changed files with 179428 additions and 15581 deletions

View File

@@ -58,7 +58,44 @@ def main():
costs = dict(l.split() for l in Path(d, chunks.COSTS).read_text().splitlines())
check("every chunk and part has a cost", set(costs) == {os.path.basename(p) for p in [files[0]] + parts})
check("a part's cost is its estimate", all(int(costs[os.path.basename(p)]) == chunks.text_cost(t) for p, t in zip(parts, texts)))
print("ok: %d parts, the functions as they were" % len(parts))
stopped_part_way(budget)
print("ok: %d parts, the functions as they were, and again after a split stopped part way" % len(parts))
def stopped_part_way(budget):
"""A split that stops after its first file (its process ended) leaves the chunk whole: the next split cuts it again"""
with tempfile.TemporaryDirectory(prefix="hookshot-chunk-stop-") as d:
big = [function(0x81000000 + 16 * i, 2000) for i in range(40)] + [function(0x81100000, 300000)] + [
function(0x81200000 + 16 * i, 2000) for i in range(200)]
path = os.path.join(d, "code_001.c")
Path(path).write_text(PREAMBLE + "".join(big), newline=chr(10))
class Stopped(Exception):
pass
real = chunks.whole_write.write_whole
writes = []
def stop_after_one(out, text, *a, **k):
if writes:
raise Stopped()
writes.append(out)
return real(out, text, *a, **k)
chunks.whole_write.write_whole = stop_after_one
try:
chunks.split_one(d, path, budget)
check("the chunk is cut into parts, so a split can stop between two of them", False)
except Stopped:
pass
finally:
chunks.whole_write.write_whole = real
made = chunks.split_big(d, [path], budget=budget)
parts = [path] + sorted(made, key=lambda p: int(re.search(r"_(\d+)\.c$", p).group(1)))
texts = []
for p in parts:
with open(p, newline="") as f:
texts.append(f.read())
check("after a stopped split the chunk is cut again", len(parts) >= 2)
check("after a stopped split every function is still there", "".join(t[len(PREAMBLE):] for t in texts) == "".join(big))
if __name__ == "__main__":