Skip to content

Free games for graphing calculators: NumWorks, TI-Nspire CX, Casio fx-CG50 and soon TI-84 Plus CE. Balatro, Celeste, Hollow Knight, Minecraft and more.

NumBlocks in the play guide; the uninstall test checks prefix records

Mason Chenc3e890a25df0
diff --git a/docs/play.md b/docs/play.md
index 4eeb600a..03760a0d 100644
--- a/docs/play.md
+++ b/docs/play.md
@@ -98,6 +98,28 @@ Shooting yourself with a blank keeps your turn.
<br clear="right">
+## NumBlocks
+
+<img src="media/numblocks.gif" width="320" align="right" alt="NumBlocks: walking through a forest, mining and building">
+
+| Key | What it does |
+| --- | --- |
+| **Arrows** | Look around |
+| **ln**, **cos**, **sin**, **tan** | Walk forward, back, left, right |
+| **π** | Jump (twice in Creative: fly) |
+| **√** / **x²** | Sneak / sprint |
+| **Back** | Mine and attack (hold it to mine) |
+| **OK** or **EXE** | Place a block, use, eat |
+| **var** | Inventory (in Creative: every block and item) |
+| **1** to **9** | Pick a hotbar slot |
+| **x,n,t** | Drop the item |
+| **Toolbox** | Pause |
+| **Home** | Save and quit |
+
+In NumBlocks, Back mines, so **Toolbox** pauses. In the inventory, the arrows move between slots, **OK** picks up or puts down a stack, **EXE** one item, and **shift** with **OK** sends a stack to the other side. Your world saves as you play and when you quit.
+
+<br clear="right">
+
## Champion Island
<img src="media/championisland.gif" width="320" align="right" alt="Champion Island: Lucky crossing the island, then the island map">
diff --git a/tests/test_uninstall.py b/tests/test_uninstall.py
index 8e732914..a2db0a05 100644
--- a/tests/test_uninstall.py
+++ b/tests/test_uninstall.py
@@ -51,11 +51,15 @@ def main():
# the game's own files go with it; a script and another game's save stay
own = next(g["records"] for g in manifest if g["id"] == target)
+ # a name ending with '*' stands for every file starting so (NumBlocks' world)
+ prefixes = [n[:-1] for n in own if n.endswith("*")]
+ own = [n for n in own if not n.endswith("*")]
save = own[0] if own else None
other = ("crossyroad.sav", bytes(range(24))) if target == "tetris" else ("tetris.set", struct.pack("<3I", 1, 1, 1234))
records = [("pi.py", b"\x01print(3.14)\n"), (save or "none.sav", bytes(range(40))),
("script.py", b"\x01import math\nprint(math.e)\n"), other]
records[3:3] = [(n, bytes(range(12))) for n in own[1:2]]
+ records[3:3] = [(p + s, bytes(range(16))) for p in prefixes for s in ("0_0.nbe", "-1_2.nbe")]
c.set_records(records, cached="script.py")
# Home: the settings card is last. Settings: the games are listed in order,
@@ -168,9 +172,12 @@ def main():
for name in own:
if name in names:
fail(f"{name} is still there")
+ for p in prefixes:
+ if any(n.startswith(p) for n in names):
+ fail(f"a file starting with {p} is still there")
buf = c.storage_bytes()
for name, content in records:
- if name in own:
+ if name in own or any(name.startswith(p) for p in prefixes):
continue
if name not in names:
fail(f"{name} disappeared")