From f895293217dc085f52f7edd4465bc9ee65ab14f6 Mon Sep 17 00:00:00 2001 From: bryanthaboi Date: Sun, 23 Aug 2026 12:21:50 -0400 Subject: [PATCH] Teach custom carts about Crystal Both features landed independently and each was green on its own, so the gap only appears in the combination. - tools/cartkit.py BASES did not list crystal, so cartkit rejected a Crystal cart as an unknown base game. The Lua validator never had this problem: it asks GameVersion.VERSIONS, so it accepted Crystal the moment the row existed. - Two self-tests used the literal "crystal" as their never-a-game sentinel and invert now that Crystal is real: tests/engine/cart_manifest.lua and cartkit's own t_identity. Both re-pointed at "nonesuch", the token the rest of the suite already uses for this. --- tests/engine/cart_manifest.lua | 2 +- tools/cartkit.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/engine/cart_manifest.lua b/tests/engine/cart_manifest.lua index 37a4a197..493fdc9a 100644 --- a/tests/engine/cart_manifest.lua +++ b/tests/engine/cart_manifest.lua @@ -139,7 +139,7 @@ rejects(function(c) c.label = "../../etc/passwd" end, "cart label", "a climbing rejects(function(c) c.label = "/etc/passwd" end, "cart label", "an absolute label path") rejects(function(c) c.label = ("a"):rep(129) end, "cart label", "a 129 character label path") rejects(function(c) c.base = nil end, "cart base", "a missing base game") -rejects(function(c) c.base = "crystal" end, "cart base", "an unknown base game") +rejects(function(c) c.base = "nonesuch" end, "cart base", "an unknown base game") rejects(function(c) c.engine = "" end, "cart engine", "an empty engine range") rejects(function(c) c.engine = 3 end, "cart engine", "a numeric engine range") rejects(function(c) c.seal = "welded" end, "cart seal", "an unknown seal") diff --git a/tools/cartkit.py b/tools/cartkit.py index 4852eba9..b1febf74 100644 --- a/tools/cartkit.py +++ b/tools/cartkit.py @@ -57,7 +57,7 @@ BUNDLE_FORMAT = "g1rcart" BUNDLE_VERSION = 1 CART_SCHEMA = 1 -BASES = ("red", "blue", "yellow", "gold", "silver") +BASES = ("red", "blue", "yellow", "gold", "silver", "crystal") SEALS = ("sealed", "open") SOURCES = ("github", "gamebanana") MAX_MODS = 64 @@ -1380,7 +1380,7 @@ def t_identity(): ("title", ""), ("title", "t" * 49), ("version", "1.0"), ("version", "v1.0.0"), ("author", ""), ("shell", "8b1a1a"), - ("shell", "#8b1a1"), ("base", "crystal"), + ("shell", "#8b1a1"), ("base", "nonesuch"), ("seal", "welded"), ("schema", 2), ("summary", "s" * 121), ("repo", "someone"), ("engine", ">=1.0.0 <<2.0.0")):