Changing things
Adding a look
Section titled “Adding a look”Add an entry to THEMES in main.rs and change the array’s size. A look is a set of colours plus an arrangement (Three, Split or Stack), a tab style and a corner radius. The settings.txt value is the index into this array.
Adding a Study chapter
Section titled “Adding a Study chapter”Each chapter is a text file in the course folder, listed in order in FILES at the top of src/course.rs (the file explains the format: a header with title, blurb, Discord slang and level, then ## headings, paragraphs, - lists, | tables, fenced code, > tips, @link lines, ???/!!! exercises and an @quiz section). Add the file to FILES where it belongs. Quizzes and slang live inside each chapter, so reordering chapters never mismatches them. cargo test reads every chapter and checks every quiz.
Adding a practice file
Section titled “Adding a practice file”- Write a program in
practice\src\bin\, following the existing ones. - Build it and copy the exe to
src\practice\. - Add a
ChallengetoCHALLENGESinpractice.rs, with hints, a solution and acheckfunction that mirrors the program’s rule. - Open the built exe in the app and make sure the hints describe what is really there.
Solved state is stored as one bit per challenge, by position.
Adding an ability to the Overview
Section titled “Adding an ability to the Overview”Add a row to RULES in triage.rs: a title, a one-line note, and the function names.
Adding an instruction explanation
Section titled “Adding an instruction explanation”Add a line to meaning in explain.rs. The key is the instruction name in lower case.
Teaching the C view a new instruction
Section titled “Teaching the C view a new instruction”Add a case to Lifter::step in decomp.rs. Read the operands with read, build a formula, and store it with write. Return false for anything you cannot handle, and it will fall back to __asm.