TutorialsBinary Search

Appendix F — Glossary

One word for each idea, used the same way everywhere in the game and in this book.

Back, Clear
Back removes the last digit of the entry; Clear empties it.
Budget
The most scans one trial allows (7; the Safe Settings cell scanBudget).
Button Clicks
The Logic on Safe Rules that does what each clicked button asks; each button sends it a Custom Event ending in Clicked (scanClicked).
Card Face
The Data Structure every piece of a Scan Card carries: scan (its number), guess and clue (in words).
Card Guess, Card Clue
The two texts on a Scan Card: the guess, and the clue in words (HIGHER, LOWER, UNLOCKED).
clickEvent
The Custom Event a button sends when clicked (a Per Instance Variable of the button).
Clue
What a scan tells: Higher, Lower, or Unlocked.
Clue Word
The Function that turns a clue (1, -1, 0) into the words a Scan Card shows.
Code
The secret whole number, 1 to 100, that opens the safe.
Code Mark
One of the marks on screen, one per possible code (100 for 1 to 100).
Computer
The binary search that cracks a code the human locks in.
computerTurn
The named Recurring Timer of Run: first turn after runDelay, then one turn every runInterval (Safe Settings).
Digit Key
One of the ten keypad buttons 0 to 9 (one Object, ten placements).
Entry
The number on the keypad display, waiting to be scanned or locked.
Game Controls
The Input Context that holds every game Command; it is off while the Myth Lesson is open, and the game’s buttons ask it too.
Goal line
The line under the title that says the goal of the role (Human Goal, Computer Goal).
Guess
A number tried against the code.
Human
The person playing.
Human Result
The line “YOU: SCAN(S) / UNLOCKED” or “/ OUT OF SCANS” shown beside the computer’s search after Watch computer; also the text Object that shows it.
Human Role, Computer Role
The two Logic Components on Safe Rules, one turned on at a time, that say what the controls do in each role.
humanScans, humanUnlocked
The Safe State fields that keep the human’s result while the computer takes its turn.
Keypad
The ten Digit Keys, Back, Clear and the entry display beside them; also the part of the game and its group.
Lay Out Scan Record
The Logic on Safe Rules that makes the Code Marks and the Scan Cards when the Safe Room begins.
Lesson Line
One line of the Myth Lesson’s words (one Object, placed eleven times).
Lock Code
Locking the entry as the secret code during Setup (the LOCK CODE button or Enter).
Locked, Unlocked, Exhausted
The trial’s phases: scanning; the code was found; the budget was spent without finding it (Game States).
Low, High
The two ends of the range.
Lowest Code Label, Highest Code Label
The texts under the two ends of the strip, the lowest code (“1”) and the highest (“100”), read from Safe Settings; the original’s Range Minimum and Range Maximum.
Mark Face
The Data Structure a Code Mark carries: code, the code it marks.
Message
The line under the safe that says what the last action did (the Global message, words from Safe Copy).
Midpoint
floor((low + high) / 2), the computer’s next guess.
Mode
The editor’s word for what an Event runs; every Event of this game has one Mode, named for what it does (“Press”, “Scan”). Formerly Mode.
Myth Lesson
The optional panel that explains the game’s Functions.
Myth Lesson (Input Context)
The Input Context that is on exactly while the lesson is open; it holds F and Escape.
Myth Lesson Button, Close Lesson Button
The “Myth lesson” button (opens or closes the lesson) and the lesson’s “Close” button.
Pause
Turning Run off with the RUN / PAUSE control (the PAUSE button or A while running); the range, scans and Scan Log stay.
Player
The person at the keyboard, in either role. (In the Human role the player cracks the safe; in the Computer role the player chooses the code.)
Range
The codes still possible, from low to high, both included.
Range Line, Possibilities
The texts “POSSIBLE CODE: - ” and “ possibilities remain”.
Readout
The computer’s lines beside the entry: BINARY SEARCH, NEXT GUESS (or SOLVED IN) and the midpoint formula.
Readout Line
The Data Structure the readout line carries for its words and number.
Reset Trial
The Function that makes a fresh trial on the same safe; Start New Safe and Start Code Setup begin with it.
Result Line
The Data Structure the Human Result text carries: scansUsed, scanWord, outcome.
Role
Who is cracking the safe: Human or Computer.
Role Tab
One of the two tabs under the title, “I crack it” and “Computer cracks it” (one Object, two placements).
Run
Repeat Step on a timer until the trial ends or is paused.
Run Search
The Logic Component on Safe Rules that is turned on exactly while Run is on; it owns the computerTurn timer.
Safe
The locked box the player tries to open; the whole game is about it.
Safe Button
The one Logic Component that every button except the Digit Keys carries; each placement picks the Function its press calls.
Safe Copy
The table of the words the player reads, one row per message.
Safe Room
The game’s one Scene: the room with the title, the Safe and Safe Rules; also the first part of the game and its group.
Safe Rules
The one Object that holds the game’s rules and its Safe State.
Safe Settings
The table of tuning numbers, one row “Standard Safe”.
Safe State
The Data Structure Safe Rules carries: code and startsNewEntry.
Scan
One accepted guess. A guess that is out of range or already ruled out is not a scan and costs nothing.
Scan Card
One of the cards on screen, one per scan of the budget, that shows a Scan Log row; made of the card, its Card Guess and its Card Clue.
Scan Count
The counter “ / ”.
Scan Log
The table that records each scan of the current trial, one row “Scan N” per scan: guess, clue, low and high.
scanBudget
The Safe Settings column that holds the Budget (7).
Screen Layout
The table of which piece shows in which situation: a row per piece, a Yes/No column per situation.
Setup
The Computer role’s first phase, while the player types and locks a code (the Game State Setup; Configure in the original).
Shared Variable, Per Instance Variable
A value a Logic Component needs from the Object holding it: one for the Object (@self.safeRules), or one for each placement (self.digit).
Situation
Where the game is for the screen: human, humanDone, codeSetup, searching, running, solved or outOfScans (the role, the phase and Run); Current Situation names it.
Slot (markSlot, cardSlot)
An equal share of the strip’s or the row’s width: one per code for the Code Marks, one per scan of the budget for the Scan Cards; each piece sits in the middle of its slot. cardScale is how large a card is drawn when its slot is narrower than cardRoom.
Step
One computer turn: choose the midpoint, scan it.
Step Once
What STEP and Space do: turn Run off, then take one Step.
The parts of the game
The groups, the same in every section and in build order: Safe Room, Keypad (Chapter 1); Scan Guess (Chapter 2); Scan Record (Chapter 3: the Scan Log, Scan Cards and Code Marks); Choose Role, Computer Search (Chapter 4: the roles; Lock Code, Step and the Readout); Compare Same Safe (Chapter 5: Watch Computer and the Human Result), Myth Lesson (Chapter 5).
Trial
One attempt on one code, from a new safe until Unlocked or Exhausted.
Watch Computer
After a human trial ends, the computer searches the same code.
Watch Computer Button
The Watch computer button, shown in the Human role once the trial has ended.