Tiny Shelf 50 · Update the game and keep the scrapbook

Tiny Shelf Studio · Lesson 50 of 50 · Publishing · About 45 min

An update adds a reduced-motion option. A player who completed Counter Window should keep their stamp even if the game's layout or the order of its briefs changes.

Tiny fictional paper cartons, jars and tins displayed on a handmade wooden shelf.
What you’ll make Safely preserve completed brief IDs when an example save format gains a new preference.

Download the projects from the course page. In Godot’s Project Manager, choose Import, select project.godot, and use Run Project (F5). Start from checkpoints/49 when the lesson builds on prior work, or copy the checkpoints/50 folder to try this lesson on its own. Read the file names in the steps before editing.

Read. Load the temporary sample. → Guard. Check types and version. → Preserve. Keep completed IDs. → Test. Verify a genuine upgrade.
Read → Guard → Preserve → Test
Godot checkpoint window for Update the game and keep the scrapbook
From the running Godot checkpoint.

Build it step by step

Language and tools in this lesson JSON.parse_string(), Variant, is, typed Array, stable ID, save migration.

  1. Compare formats

    Import checkpoint 50 and press F5. Try the old, current and incompatible records. Schema 1 stores a completed list. Schema 2 renames that list and adds a Boolean reduced-motion preference.

    Why it works A schema tells the game the shape of the save and how to read it.

  2. Guard the parser

    Find migrate() and read the first if after parsing. An array is valid JSON, but this save requires a dictionary. Try the incompatible case before reading any fields.

    if not (document is Dictionary):

    Why it works A type test prevents a different-shaped file from being treated as a real scrapbook.

  3. Use stable IDs

    Follow the selected key into clean. It only accepts strings and adds each ID once. Change the old sample to include a duplicate counter_window and run the migration.

    if brief_id not in clean:

    Why it works IDs survive changes to display names and position. A duplicate should never earn a second stamp.

  4. Preserve the old file

    The practice lab reads strings in memory. In the reference game, inspect scripts/progress.gd and its ConfigFile save in user://. Back up real test data and validate a migrated record before replacing a writable file. Keep unrecognised originals for recovery.

    Why it works A learner can try bad data in this lab without risking saved progress from the game.

  5. Test an actual upgrade

    With the adult publisher, run an older authorised build on a supported device and earn a stamp. Upgrade to your later signed test build using the same app identity. Look for the original stamp, then try the new setting. Repeat with a fresh install.

    Why it works The genuine test includes app identity and device storage as well as the code.

  6. Assemble your original studio project

    Save your edited game and invented mini art. Include your first-brief route, newest build number, tested device results, asset register, store worksheet and one idea for a later update.

    Why it works These pieces let another person play, inspect and continue the version you made.

Watch the values change

  1. Load an older example It contains counter_window with no reduced-motion field.
    What you see. Schema 2 keeps the ID and defaults to regular motion.
  2. Load a newer example It has two saved IDs and reduced motion on.
    What you see. The migration keeps both stamps and the preference.
  3. Load an array It has no dictionary fields for version or stamps.
    What you see. The lab tells you to keep the source and recover.

Predict before you run What keeps the same brief marked as complete after its name changes?

Reveal the answer

Its underlying ID. The new display name can change while the saved ID still points to the same brief.

Complete checkpoint

Schema 2 keeps one older stamp with regular motion or two current stamps with reduced motion. The incompatible sample leaves a recovery message.

main.gd

extends Control

const Lab = preload("res://release_lab.gd")
const PackArt = preload("res://pack_preview.gd")
const TITLE := "Update the game and keep the scrapbook"
const NUMBER := 50
var ui: VBoxContainer

func _ready() -> void:
	var preview := Control.new()
	preview.set_script(PackArt)
	preview.mouse_filter = Control.MOUSE_FILTER_IGNORE
	add_child(preview)
	preview.set_anchors_and_offsets_preset(Control.PRESET_RIGHT_WIDE)
	preview.offset_left = -258.0
	preview.offset_right = -28.0
	preview.offset_top = 32.0
	preview.offset_bottom = -32.0
	ui = VBoxContainer.new()
	ui.set_script(Lab)
	add_child(ui)
	ui.start(TITLE, NUMBER)
	build()

const OLD_SAVE := '{"schema":1,"completed":["counter_window"]}'
const CURRENT_SAVE := '{"schema":2,"stamps":["counter_window","new_display"],"reduced_motion":true}'
const UNKNOWN_SAVE := '["counter_window","unknown"]'

func build() -> void:
	ui.say("Read sample scrapbook records. No real files are changed.")
	ui.option("Read the older save", show_record.bind(OLD_SAVE))
	ui.option("Read the current save", show_record.bind(CURRENT_SAVE))
	ui.option("Read an incompatible record", show_record.bind(UNKNOWN_SAVE))

func show_record(raw: String) -> void:
	var result := migrate(raw)
	if result.is_empty():
		ui.say("Unsupported record. Keep the source and offer recovery.")
	else:
		ui.say("Schema %d. Saved stamps: %d. Reduced motion: %s.\n%s" % [
			result.schema, result.stamps.size(), "on" if result.reduced_motion else "off",
			", ".join(result.stamps)
		])

func migrate(raw: String) -> Dictionary:
	var document: Variant = JSON.parse_string(raw)
	if not (document is Dictionary):
		return {}
	var schema: Variant = document.get("schema")
	if schema != 1 and schema != 2:
		return {}
	var saved_key := "completed" if schema == 1 else "stamps"
	var saved_ids: Variant = document.get(saved_key)
	if not (saved_ids is Array):
		return {}
	var clean: Array[String] = []
	for brief_id in saved_ids:
		if not (brief_id is String) or brief_id.is_empty():
			return {}
		if brief_id not in clean:
			clean.append(brief_id)
	var reduced: Variant = false if schema == 1 else document.get("reduced_motion")
	if not (reduced is bool):
		return {}
	return {"schema": 2, "stamps": clean, "reduced_motion": reduced}

release_lab.gd

extends VBoxContainer

var output: Label

func start(title_text: String, lesson_number: int) -> void:
	set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)
	offset_left = 35.0
	offset_top = 29.0
	offset_right = -315.0
	offset_bottom = -24.0
	add_theme_constant_override("separation", 12)

	var paper := ColorRect.new()
	paper.color = Color("#142536")
	paper.mouse_filter = Control.MOUSE_FILTER_IGNORE
	get_parent().add_child(paper)
	paper.set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)
	get_parent().move_child(paper, 0)

	var eyebrow := Label.new()
	eyebrow.text = "TINY SHELF STUDIO   /   LESSON %d" % lesson_number
	eyebrow.add_theme_font_size_override("font_size", 14)
	eyebrow.add_theme_color_override("font_color", Color("#9ce3cf"))
	add_child(eyebrow)

	var title := Label.new()
	title.text = title_text
	title.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART
	title.add_theme_font_size_override("font_size", 29)
	title.add_theme_color_override("font_color", Color("#ffe3ae"))
	add_child(title)

	output = Label.new()
	output.custom_minimum_size.y = 132.0
	output.autowrap_mode = TextServer.AUTOWRAP_WORD_SMART
	output.vertical_alignment = VERTICAL_ALIGNMENT_CENTER
	output.add_theme_font_size_override("font_size", 20)
	output.add_theme_color_override("font_color", Color("#ecf3f7"))
	add_child(output)

func say(message: String) -> void:
	output.text = message

func option(label: String, command: Callable) -> void:
	var button := Button.new()
	button.text = label
	button.focus_mode = Control.FOCUS_ALL
	button.custom_minimum_size.y = 48.0
	button.add_theme_font_size_override("font_size", 18)
	button.pressed.connect(command)
	add_child(button)

pack_preview.gd

extends Control

func _draw() -> void:
	var cream := Color("#fff1d7")
	var turquoise := Color("#65c9b6")
	var font := ThemeDB.fallback_font
	draw_rect(Rect2(Vector2.ZERO, size), Color("#203951"))
	draw_string(font, Vector2(20, 40), "THE PROTOTYPE SHELF", HORIZONTAL_ALIGNMENT_LEFT, -1, 15, cream)
	draw_rect(Rect2(20, 60, 190, 3), turquoise)
	front(Rect2(42, 124, 111, 143), Vector2(18, -12), Color("#ec9e69"), "LEMON", "FIZZ")
	front(Rect2(100, 288, 86, 101), Vector2(15, -11), Color("#93afd9"), "MOON", "MILK")
	draw_rect(Rect2(18, 396, 194, 7), Color("#5a7b8b"))
	draw_string(font, Vector2(20, 437), "Invented packs · original art", HORIZONTAL_ALIGNMENT_LEFT, -1, 14, cream)

func front(rect: Rect2, depth: Vector2, ink: Color, name_top: String, name_bottom: String) -> void:
	var top_left := rect.position
	var top_right := Vector2(rect.end.x, rect.position.y)
	var side_bottom := rect.end + depth
	draw_colored_polygon(PackedVector2Array([top_left, top_left + depth, top_right + depth, top_right]), ink.lightened(0.28))
	draw_colored_polygon(PackedVector2Array([top_right, top_right + depth, side_bottom, rect.end]), ink.darkened(0.28))
	draw_rect(rect, ink)
	draw_circle(rect.position + rect.size * Vector2(0.72, 0.27), 10, Color("#fff1d7"))
	var font := ThemeDB.fallback_font
	var label_color := Color("#162b3e")
	draw_string(font, rect.position + Vector2(10, 57), name_top, HORIZONTAL_ALIGNMENT_LEFT, -1, 16, label_color)
	draw_string(font, rect.position + Vector2(10, 76), name_bottom, HORIZONTAL_ALIGNMENT_LEFT, -1, 16, label_color)

GDScript line by line

Follow the line numbers, including the indent at the start of each line. Find the code the game will run first, then look for the function that reacts when you tap or change something.

Read main.gd line by line
  1. extends ControlStarts with Godot's Control type. This script gets the abilities of that type and adds the game's own rules.
  2. const Lab = preload("res://release_lab.gd")Load the practice panel's script before the game runs so the scene can give a VBoxContainer those useful methods.
  3. const PackArt = preload("res://pack_preview.gd")Load the drawing script for the original product forms. It has no effect on the checklist logic.
  4. const TITLE := "Update the game and keep the scrapbook"Creates a constant named TITLE. The expression uses the text inside the quotes. Godot infers the type from the first value.
  5. const NUMBER := 50Creates a constant named NUMBER. The expression uses the whole number 50. Godot infers the type from the first value.
  6. var ui: VBoxContainerDeclares ui for later use. A colon followed by a type says which kind of value belongs here.
  7. func _ready() -> void:Godot calls this once after the scene and its children are ready. Use it to set up the room and connect controls.
  8. var preview := Control.new()Creates a variable named preview. The expression creates a new Control object. Godot infers the type from the first value.
  9. preview.set_script(PackArt)Attach the illustration behaviour to the new Control. The package drawing now belongs to this node.
  10. preview.mouse_filter = Control.MOUSE_FILTER_IGNOREThe illustration is decorative, so mouse input passes by it instead of stopping there.
  11. add_child(preview)Adds the new node to the scene tree so that Godot can run and draw it.
  12. preview.set_anchors_and_offsets_preset(Control.PRESET_RIGHT_WIDE)Anchor the illustration on the right and stretch its region vertically.
  13. preview.offset_left = -258.0Give the right-side artwork a left edge 258 pixels from its anchored edge.
  14. preview.offset_right = -28.0Give the right edge a 28-pixel margin.
  15. preview.offset_top = 32.0Stores the new value in preview.offset_top. The expression reads 32.0.
  16. preview.offset_bottom = -32.0Stores the new value in preview.offset_bottom. The expression reads -32.0.
  17. ui = VBoxContainer.new()Create a visual container that arranges its children in a column.
  18. ui.set_script(Lab)Calls ui.set_script with the values in its parentheses.
  19. add_child(ui)Adds the new node to the scene tree so that Godot can run and draw it.
  20. ui.start(TITLE, NUMBER)Set up the labelled teaching panel. The next instruction adds this lesson's buttons.
  21. build()The scene is in place. Now add this lesson's practice actions and initial prompt.
  22. const OLD_SAVE := '{"schema":1,"completed":["counter_window"]}'A schema-one sample stores direct completed brief IDs.
  23. const CURRENT_SAVE := '{"schema":2,"stamps":["counter_window","new_display"],"reduced_motion":true}'A schema-two sample stores stamps and a genuine Boolean preference.
  24. const UNKNOWN_SAVE := '["counter_window","unknown"]'This valid JSON array has the wrong shape for a scrapbook.
  25. func build() -> void:Defines build, a reusable set of instructions. Parameters between the parentheses receive inputs. A return type after the arrow tells you which kind of result to expect.
  26. ui.say("Read sample scrapbook records. No real files are changed.")Calls ui.say with the values in its parentheses.
  27. ui.option("Read the older save", show_record.bind(OLD_SAVE))Calls ui.option with the values in its parentheses.
  28. ui.option("Read the current save", show_record.bind(CURRENT_SAVE))Calls ui.option with the values in its parentheses.
  29. ui.option("Read an incompatible record", show_record.bind(UNKNOWN_SAVE))Calls ui.option with the values in its parentheses.
  30. func show_record(raw: String) -> void:Defines show record, a reusable set of instructions. Parameters between the parentheses receive inputs. A return type after the arrow tells you which kind of result to expect.
  31. var result := migrate(raw)Convert the sample into the current shape first, then display a useful result.
  32. if result.is_empty():Checks result.is_empty(). The indented instructions below run only if this test passes.
  33. ui.say("Unsupported record. Keep the source and offer recovery.")Calls ui.say with the values in its parentheses.
  34. else:Runs the indented fallback instructions if none of the earlier tests passed.
  35. ui.say("Schema %d. Saved stamps: %d. Reduced motion: %s.\n%s" % [Calls ui.say with the values in its parentheses.
  36. result.schema, result.stamps.size(), "on" if result.reduced_motion else "off",Continues the same instruction on a new line. This is one of the arguments, data entries or expressions started above.
  37. ", ".join(result.stamps)Continues the same instruction on a new line. This is one of the arguments, data entries or expressions started above.
  38. ])Continues the same instruction on a new line. This is one of the arguments, data entries or expressions started above.
  39. func migrate(raw: String) -> Dictionary:Defines migrate, a reusable set of instructions. Parameters between the parentheses receive inputs. A return type after the arrow tells you which kind of result to expect.
  40. var document: Variant = JSON.parse_string(raw)Godot's parser can return different data types. Keep that flexible type until the guard checks it.
  41. if not (document is Dictionary):Only a dictionary can use named fields the way this scrapbook expects.
  42. return {}Finishes the function and hands its result back to the caller. The expression makes a dictionary that looks up values by key.
  43. var schema: Variant = document.get("schema")Creates a variable named schema. The expression looks up a named or indexed value, using a fallback when the call gives one. The type after the colon says what kind of value it can hold.
  44. if schema != 1 and schema != 2:Accept the two versions this migration can recognise. Reject any future version without overwriting it.
  45. return {}Finishes the function and hands its result back to the caller. The expression makes a dictionary that looks up values by key.
  46. var saved_key := "completed" if schema == 1 else "stamps"Look for the old key only in the old format and for stamps in the current format.
  47. var saved_ids: Variant = document.get(saved_key)Creates a variable named saved_ids. The expression looks up a named or indexed value, using a fallback when the call gives one. The type after the colon says what kind of value it can hold.
  48. if not (saved_ids is Array):The stamp list must be an array before the loop reads its items.
  49. return {}Finishes the function and hands its result back to the caller. The expression makes a dictionary that looks up values by key.
  50. var clean: Array[String] = []Build a fresh typed list to preserve valid IDs and filter duplicate entries.
  51. for brief_id in saved_ids:Repeats the indented instructions for each value in saved_ids.
  52. if not (brief_id is String) or brief_id.is_empty():A stamp requires a non-empty string. Reject a damaged entry before producing a migrated record.
  53. return {}Finishes the function and hands its result back to the caller. The expression makes a dictionary that looks up values by key.
  54. if brief_id not in clean:A repeated ID should preserve its stamp once.
  55. clean.append(brief_id)Adds an item to the end of a list.
  56. var reduced: Variant = false if schema == 1 else document.get("reduced_motion")Supply regular motion for an older record or read the stated preference in a newer one.
  57. if not (reduced is bool):Checks not (reduced is bool). The indented instructions below run only if this test passes.
  58. return {}Finishes the function and hands its result back to the caller. The expression makes a dictionary that looks up values by key.
  59. return {"schema": 2, "stamps": clean, "reduced_motion": reduced}Return new data without mutating the older record. Use the current format's key names.
Read release_lab.gd line by line
  1. extends VBoxContainerStarts with Godot's VBoxContainer type. This script gets the abilities of that type and adds the game's own rules.
  2. var output: LabelDeclares output for later use. A colon followed by a type says which kind of value belongs here.
  3. func start(title_text: String, lesson_number: int) -> void:Defines start, a reusable set of instructions. Parameters between the parentheses receive inputs. A return type after the arrow tells you which kind of result to expect.
  4. set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)Start with a panel attached to all four edges of its parent.
  5. offset_left = 35.0Stores the new value in offset_left. The expression reads 35.0.
  6. offset_top = 29.0Stores the new value in offset_top. The expression reads 29.0.
  7. offset_right = -315.0Leave 315 pixels of space for artwork beside the exercises.
  8. offset_bottom = -24.0Stores the new value in offset_bottom. The expression reads -24.0.
  9. add_theme_constant_override("separation", 12)Calls add_theme_constant_override with the values in its parentheses.
  10. var paper := ColorRect.new()Creates a variable named paper. The expression creates a new ColorRect object. Godot infers the type from the first value.
  11. paper.color = Color("#142536")Stores the new value in paper.color. The expression builds a colour from these values.
  12. paper.mouse_filter = Control.MOUSE_FILTER_IGNORELet clicks pass through the background so it cannot interrupt a button.
  13. get_parent().add_child(paper)Calls get_parent with the values in its parentheses.
  14. paper.set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)Stretch the paper colour to the full scene edge.
  15. get_parent().move_child(paper, 0)Place the paper first in drawing order, behind the artwork and teaching panel.
  16. var eyebrow := Label.new()Creates a variable named eyebrow. The expression creates a new Label object. Godot infers the type from the first value.
  17. eyebrow.text = "TINY SHELF STUDIO / LESSON %d" % lesson_numberThe integer in lesson_number replaces %d in the heading string.
  18. eyebrow.add_theme_font_size_override("font_size", 14)Calls eyebrow.add_theme_font_size_override with the values in its parentheses.
  19. eyebrow.add_theme_color_override("font_color", Color("#9ce3cf"))Calls eyebrow.add_theme_color_override with the values in its parentheses.
  20. add_child(eyebrow)Adds the new node to the scene tree so that Godot can run and draw it.
  21. var title := Label.new()Creates a variable named title. The expression creates a new Label object. Godot infers the type from the first value.
  22. title.text = title_textUpdates title.text, which controls the words a player sees. The expression reads title_text.
  23. title.autowrap_mode = TextServer.AUTOWRAP_WORD_SMARTAllow a long heading to wrap on word boundaries.
  24. title.add_theme_font_size_override("font_size", 29)Calls title.add_theme_font_size_override with the values in its parentheses.
  25. title.add_theme_color_override("font_color", Color("#ffe3ae"))Calls title.add_theme_color_override with the values in its parentheses.
  26. add_child(title)Adds the new node to the scene tree so that Godot can run and draw it.
  27. output = Label.new()Stores the new value in output. The expression creates a new Label object.
  28. output.custom_minimum_size.y = 132.0Keep a stable 132-pixel space for the result, so the buttons stay in place when the text changes.
  29. output.autowrap_mode = TextServer.AUTOWRAP_WORD_SMARTFit multi-line results to the current width without requiring horizontal scrolling.
  30. output.vertical_alignment = VERTICAL_ALIGNMENT_CENTERStores the new value in output.vertical_alignment. The expression reads VERTICAL_ALIGNMENT_CENTER.
  31. output.add_theme_font_size_override("font_size", 20)Calls output.add_theme_font_size_override with the values in its parentheses.
  32. output.add_theme_color_override("font_color", Color("#ecf3f7"))Calls output.add_theme_color_override with the values in its parentheses.
  33. add_child(output)Adds the new node to the scene tree so that Godot can run and draw it.
  34. func say(message: String) -> void:Defines say, a reusable set of instructions. Parameters between the parentheses receive inputs. A return type after the arrow tells you which kind of result to expect.
  35. output.text = messageReplace the practice status with a result the player can read.
  36. func option(label: String, command: Callable) -> void:Defines option, a reusable set of instructions. Parameters between the parentheses receive inputs. A return type after the arrow tells you which kind of result to expect.
  37. var button := Button.new()Creates a variable named button. The expression creates a new Button object. Godot infers the type from the first value.
  38. button.text = labelUpdates button.text, which controls the words a player sees. The expression reads label.
  39. button.focus_mode = Control.FOCUS_ALLKeep the button reachable by keyboard as well as a pointer or touch.
  40. button.custom_minimum_size.y = 48.0Give the control a taller hit area.
  41. button.add_theme_font_size_override("font_size", 18)Calls button.add_theme_font_size_override with the values in its parentheses.
  42. button.pressed.connect(command)Connect the press signal to the supplied action. That action runs when a learner chooses the button.
  43. add_child(button)Adds the new node to the scene tree so that Godot can run and draw it.
Read pack_preview.gd line by line
  1. extends ControlStarts with Godot's Control type. This script gets the abilities of that type and adds the game's own rules.
  2. func _draw() -> void:Godot calls this when the node needs drawing. The instructions inside paint the current state.
  3. var cream := Color("#fff1d7")Creates a variable named cream. The expression builds a colour from these values. Godot infers the type from the first value.
  4. var turquoise := Color("#65c9b6")Creates a variable named turquoise. The expression builds a colour from these values. Godot infers the type from the first value.
  5. var font := ThemeDB.fallback_fontUse an engine-supplied font so the drawings and text need no extra download.
  6. draw_rect(Rect2(Vector2.ZERO, size), Color("#203951"))Fill the local area from the upper left to the current width and height.
  7. draw_string(font, Vector2(20, 40), "THE PROTOTYPE SHELF", HORIZONTAL_ALIGNMENT_LEFT, -1, 15, cream)Paints a piece of text with a font at a position measured from the node's origin.
  8. draw_rect(Rect2(20, 60, 190, 3), turquoise)Paints a rectangle at the given position and size.
  9. front(Rect2(42, 124, 111, 143), Vector2(18, -12), Color("#ec9e69"), "LEMON", "FIZZ")Draw the Lemon Fizz face with its width, height, invented name, ink and depth.
  10. front(Rect2(100, 288, 86, 101), Vector2(15, -11), Color("#93afd9"), "MOON", "MILK")Draw a smaller, bluer Moon Milk pack. The depth vector gives it a separate top and side.
  11. draw_rect(Rect2(18, 396, 194, 7), Color("#5a7b8b"))Paints a rectangle at the given position and size.
  12. draw_string(font, Vector2(20, 437), "Invented packs · original art", HORIZONTAL_ALIGNMENT_LEFT, -1, 14, cream)Paints a piece of text with a font at a position measured from the node's origin.
  13. func front(rect: Rect2, depth: Vector2, ink: Color, name_top: String, name_bottom: String) -> void:Defines front, a reusable set of instructions. Parameters between the parentheses receive inputs. A return type after the arrow tells you which kind of result to expect.
  14. var top_left := rect.positionCreates a variable named top_left. The expression reads rect.position. Godot infers the type from the first value.
  15. var top_right := Vector2(rect.end.x, rect.position.y)Use the right end and the upper y coordinate to find the top-right corner.
  16. var side_bottom := rect.end + depthOffset the bottom-right corner by the depth vector to finish the angled side.
  17. draw_colored_polygon(PackedVector2Array([top_left, top_left + depth, top_right + depth, top_right]), ink.lightened(0.28))Connect the four corners of the top, and lighten its colour as if light fell on it.
  18. draw_colored_polygon(PackedVector2Array([top_right, top_right + depth, side_bottom, rect.end]), ink.darkened(0.28))Connect the four corners of the right side. Darkening the ink makes the three-dimensional edge clearer.
  19. draw_rect(rect, ink)Paints a rectangle at the given position and size.
  20. draw_circle(rect.position + rect.size * Vector2(0.72, 0.27), 10, Color("#fff1d7"))Use a relative point inside the rectangle so the round badge is placed consistently on both packs.
  21. var font := ThemeDB.fallback_fontUse an engine-supplied font so the drawings and text need no extra download.
  22. var label_color := Color("#162b3e")Creates a variable named label_color. The expression builds a colour from these values. Godot infers the type from the first value.
  23. draw_string(font, rect.position + Vector2(10, 57), name_top, HORIZONTAL_ALIGNMENT_LEFT, -1, 16, label_color)Write the product name on its face, with its own inset inside the shape.
  24. draw_string(font, rect.position + Vector2(10, 76), name_bottom, HORIZONTAL_ALIGNMENT_LEFT, -1, 16, label_color)Write the product name on its face, with its own inset inside the shape.

Find and fix a bug

If the lab rejects the new preference because it is a string, check that true in JSON has no quotation marks.

Try a change

Ages 10–12. Predict old, current and invalid results. Ages 13–16. Add a duplicate old ID and an unsupported future version, then verify both outcomes.

Official instructions