Video Game Design and Coding · PLECK lesson

PLECK lesson 87 · suggested week 18, day 2

Triage and repair the most important defect

Objective. Use severity and reproduction to prioritize work.

Godot Engine Standard desktop editor 4.7.2-stable, GDScript (Godot 4), Compatibility renderer. Headless Godot 4.7.2.stable.official.ed1daf0bf passed 106 assertions on the supplied scaffolds, including malformed JSON saves. Audio used the Dummy driver and a synthetic WAV, not a speaker. The visual editor, browser export, and signed-in submission were not tested. The desk still does not run a student's own upload.

About 55 minutes. The due date is chosen by a parent.

Consent-based playtesting, repairs, evidence and reflection

Suggested pace: Recall and predict 5 min; Read instruction and scaffold 12 min; Build or design the assigned artifact 25 min; Run acceptance tests 8 min; Explain and checkpoint 5 min.

Materials: Godot Standard 4.7.2 desktop editor (GDScript, Compatibility renderer), Local course folder and prior checkpoint, No paid assets or public account required.

Comes after VGC-L086.

Triage sorts defects by impact. A crash or impossible goal blocks the game; unreadable instructions may block some players; a slightly uneven decoration is lower priority. Choose the highest-impact reproducible issue and write steps, expected result, actual result and suspected cause. Make one focused repair in a new version, then repeat the exact reproduction and the full minimum checklist. If no real defect appears, inject a reversible fault in a duplicate and show the same process.

Worked example

A report states candidate version, setup, action, expected result and actual result. A repair is verified by replaying exactly those steps, then checking neighboring features. Scaffold C-TESTS — A tiny pure-function test harness Setup: Attach to Node TestLab. If using command line, create a separate SceneTree harness rather than running this Node script with --script. Run current TestLab scene in editor; assert reports a failed condition in Debugger. No external test framework or package is needed. ```gdscript extends Node func bounded_score(old_score: int, change: int) -> int: return clampi(old_score + change, 0, 999) func _ready() -> void: assert(bounded_score(10, 2) == 12) assert(bounded_score(0, -3) == 0) assert(bounded_score(998, 9) == 999) print("3 score checks passed") ```

A tiny pure-function test harness

GDScript (Godot 4, not Scratch, Python, JavaScript or C#). Scaffold C-TESTS. Copy starts from this text. The desk does not run it.

Scene and node setup

Attach to Node TestLab. If using command line, create a separate SceneTree harness rather than running this Node script with --script. Run current TestLab scene in editor; assert reports a failed condition in Debugger. No external test framework or package is needed.

extends Node
func bounded_score(old_score: int, change: int) -> int:
    return clampi(old_score + change, 0, 999)
func _ready() -> void:
    assert(bounded_score(10, 2) == 12)
    assert(bounded_score(0, -3) == 0)
    assert(bounded_score(998, 9) == 999)
    print("3 score checks passed")

Checks to run in the editor

Native Godot 4.7.2.stable.official.ed1daf0bf headless compile and representative node-tree/runtime tests passed; see native-qa-results.json. Visual UI, audible output, exports and website submission still need separate checks.

Triage and repair the most important defect — evidence task

  1. 1. Rank at least three issues by impact.
  2. 2. Repair one high-impact issue and document focused plus regression tests.

Deliverable. Triage table, repaired source and before/after report.

Acceptance checks

Understanding question. Does a dramatic-looking visual issue always outrank a silent state bug?

Include a downloadable project ZIP with project.godot, .tscn, .gd and original asset files when code changes. A private, teacher-accessible download link to that ZIP is equivalent. Screenshots or a playthrough do not replace editable source.

If this is still shaky. Prioritize crashes, blocked completion and misleading controls before cosmetic feedback. Retest the original reproduction after each fix. Start with the first assigned task and re-run its acceptance test before adding the remaining feature.

Optional extra. Explain one alternative implementation and why you chose the current one. Document one changed parameter, your prediction, and the observed effect; optional, not required for completion.

Name ____________________ Date ____________________