Module 5 · In Studio · challenge 2 of 2 in this lesson

reachable walks up, down, left and right links from the start, ignores links to missing buttons, and returns the names sorted

A test in Studio grades it and prints a pass code.

Open

Level 3, Professional

Challenge

Write the four rules in challenges/work/console_nav.luau. The test draws Beacon Yard's real shop and settings panels as gamepad links, plus a pause menu with a dead end and a link to a missing button. The written solution is challenges/solutions/console-vr.md. In Play, run game.ServerScriptService.RunGameTests:Invoke("console-vr", "console-vr-nav") and paste the pass code here.

Start from
The game at milestone m14 (download)
Grade it
In Studio, press Play, then run game.ServerScriptService.RunGameTests:Invoke("console-vr", "console-vr-nav") in the server command bar. Copy the pass code from Output.

Done means

  • reachable walks up, down, left and right links from the start, ignores links to missing buttons, and returns the names sorted
  • deadEnds lists every reachable button that cannot reach a closer, and nothing when B closes the menu
  • The real m14-ship settings panel reports both toggles as dead ends, and the shop reports none
  • sameLookPx and inSafeArea match the lesson's laptop, TV and 5 percent rules
  • challenges/console-vr.luau prints TEST PASS for every check

The Course Runner prints this code when the test passes.