Compare commits

...
Author SHA1 Message Date
Ratdoku Builder e0fd33c25e fix(profile): restore original Crumb portrait in game
The new Krea2 Crumb render is used only for the app icon. Guests keep true headshot avatars.
2026-12-04 05:56:18 -06:00
Ratdoku Builder f2a92e6be2 fix(profile): verify and correct headshots, picker and icon
Verification pass: generated true face close-ups for all avatars, gave the wallpaper picker a real height so previews show, corrected Crumb's headshot, and removed the generic paw from the icon.
2026-12-04 05:48:42 -06:00
Ratdoku Builder a54279ffd1 fix(profile): polish touch scroll, avatars and wallpaper picker
Local-only v0.8.1 build. Achievement rows pass touch drags, avatars use head crops and hide locked identities, difficulty cycles Zen/Easy/Normal, wallpaper setting opens a preview picker, Brie uses the approved render with a text-free sheet, and the app icon is regenerated in gouache style.
2026-12-04 05:37:34 -06:00
38 changed files with 227 additions and 31 deletions

No files matched your search

+14
View File
@@ -2,6 +2,20 @@
All notable alpha milestones for Ratdoku. All notable alpha milestones for Ratdoku.
## v0.8.1-alpha — UI Polish (local build)
- Fixed touch scrolling on dynamically rebuilt achievement rows.
- Avatar previews now use circular head crops instead of full-body thumbnails.
- Locked guest avatars now show `???` and room number instead of revealing name and portrait.
- Difficulty cycle is now Zen → Easy → Normal.
- Wallpaper setting opens a themed picker with real image previews and Confirm/Cancel.
- Regenerated Brie with the approved cheese-and-notebook render and a text-free character sheet.
- Added a new Krea2-generated app icon in the project's gouache style.
- Verification pass replaced the circular full-body guest crops with true face close-ups; Crumb keeps the original in-game portrait.
- Verification pass fixed the wallpaper picker panel height so all five previews are visible and scrollable.
- Verification pass removed the generic animal paw from the icon; rat-track motifs stay on the wallpapers only.
- Not yet published to Gitea.
## v0.8.0-alpha — Meowdoku Lessons (local build) ## v0.8.0-alpha — Meowdoku Lessons (local build)
- Added editable player name and generated player ID in Profile. - Added editable player name and generated player ID in Profile.
+10 -7
View File
@@ -150,12 +150,12 @@ build/Ratdoku.apk
It is a **debug-signed, arm64-v8a** APK: It is a **debug-signed, arm64-v8a** APK:
- Package: `com.ratdoku.game` - Package: `com.ratdoku.game`
- Version: `0.8.0` (version code 18) - Version: `0.8.1` (version code 19)
- Min SDK: 24 (Android 7.0) - Min SDK: 24 (Android 7.0)
- Target SDK: 36 - Target SDK: 36
- Size: about 41 MB - Size: about 41 MB
- Portrait orientation - Portrait orientation
- Build label: `v0.8.0-alpha · build 2026-12-04` - Build label: `v0.8.1-alpha · build 2026-12-04`
To install, copy the APK to the phone, open it, and allow “Install unknown apps” for the file manager/browser. Or with a USB-connected phone and USB debugging: To install, copy the APK to the phone, open it, and allow “Install unknown apps” for the file manager/browser. Or with a USB-connected phone and USB debugging:
@@ -204,7 +204,7 @@ Run the whole QA suite (class scan, every test script, log-error scan, optional
## Versioning and releases ## Versioning and releases
The current development build is **v0.8.0-alpha** (“Meowdoku Lessons”) with the build label on Home and in Settings. The current development build is **v0.8.1-alpha** (“UI Polish”) with the build label on Home and in Settings.
Gitea repository: Gitea repository:
@@ -228,14 +228,17 @@ Alpha releases (all marked prerelease, each with a debug APK and source archive)
- **v0.6.2-alpha** — transparent cutout portraits, alternate variants, and full character sheets - **v0.6.2-alpha** — transparent cutout portraits, alternate variants, and full character sheets
- **v0.6.3-alpha** — full 30-room daily rotation, visible profile actions, and reset-safe avatar/frame selection - **v0.6.3-alpha** — full 30-room daily rotation, visible profile actions, and reset-safe avatar/frame selection
- **v0.6.4-alpha** — streak reward milestones and cleaned Krea2 workflow prompts - **v0.6.4-alpha** — streak reward milestones and cleaned Krea2 workflow prompts
- **v0.7.0-alpha** — instrumental hotel-lounge music, Music toggle, and Brie refresh
- **v0.8.0-alpha** — player ID, achievements, claimable gift, daily share/stats, board resume, wallpapers
- **v0.8.1-alpha** — touch-scroll fix, headshot avatars, locked-guest privacy, wallpaper picker, difficulty order, new icon
https://gitea.nyxara.cc/Ahri-the-Vastaya/Ratdoku/releases/tag/v0.6.4-alpha https://gitea.nyxara.cc/Ahri-the-Vastaya/Ratdoku/releases/tag/v0.8.1-alpha
The v0.6.4-alpha APK is also at: The v0.8.1-alpha APK is also at:
`https://gitea.nyxara.cc/Ahri-the-Vastaya/Ratdoku/releases/download/v0.6.4-alpha/Ratdoku-v0.6.4-alpha.apk` `https://gitea.nyxara.cc/Ahri-the-Vastaya/Ratdoku/releases/download/v0.8.1-alpha/Ratdoku-v0.8.1-alpha.apk`
`redesign-360` is the branch with the current 360dp work; it is tagged `v0.6.4-alpha`. `redesign-360` is the branch with the current 360dp work; it is tagged `v0.8.1-alpha`.
The version is set in three places: `project.godot` (`config/version`), `scripts/Version.gd` (display label), and `export_presets.cfg` (`version/name`, `version/code`). The version is set in three places: `project.godot` (`config/version`), `scripts/Version.gd` (display label), and `export_presets.cfg` (`version/name`, `version/code`).
Binary file not shown.

Before

Width:  |  Height:  |  Size: 254 KiB

After

Width:  |  Height:  |  Size: 233 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 58 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 57 KiB

After

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 76 KiB

After

Width:  |  Height:  |  Size: 110 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 73 KiB

After

Width:  |  Height:  |  Size: 114 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 66 KiB

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 60 KiB

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 73 KiB

After

Width:  |  Height:  |  Size: 115 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 55 KiB

After

Width:  |  Height:  |  Size: 105 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 112 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 112 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 67 KiB

After

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 68 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 63 KiB

After

Width:  |  Height:  |  Size: 108 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 68 KiB

After

Width:  |  Height:  |  Size: 112 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 47 KiB

After

Width:  |  Height:  |  Size: 101 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 67 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 58 KiB

After

Width:  |  Height:  |  Size: 103 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 106 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 61 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 103 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 55 KiB

After

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 57 KiB

After

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 62 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 71 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 76 KiB

After

Width:  |  Height:  |  Size: 70 KiB

+2 -2
View File
@@ -32,8 +32,8 @@ architectures/armeabi-v7a=false
architectures/arm64-v8a=true architectures/arm64-v8a=true
architectures/x86=false architectures/x86=false
architectures/x86_64=false architectures/x86_64=false
version/code=18 version/code=19
version/name="0.8.0" version/name="0.8.1"
package/unique_name="com.ratdoku.game" package/unique_name="com.ratdoku.game"
package/name="Ratdoku" package/name="Ratdoku"
package/signed=true package/signed=true
BIN
View File
Binary file not shown.

Before

Width:  |  Height:  |  Size: 387 KiB

After

Width:  |  Height:  |  Size: 454 KiB

+1 -1
View File
@@ -12,7 +12,7 @@ config_version=5
config/name="Ratdoku" config/name="Ratdoku"
run/main_scene="res://scenes/Main.tscn" run/main_scene="res://scenes/Main.tscn"
config/version="0.8.0-alpha" config/version="0.8.1-alpha"
config/features=PackedStringArray("4.7", "GL Compatibility") config/features=PackedStringArray("4.7", "GL Compatibility")
config/icon="res://icon.png" config/icon="res://icon.png"
boot_splash/show_image=false boot_splash/show_image=false
+6
View File
@@ -38,6 +38,12 @@ static func portrait_path(id: String) -> String:
return str(avatar.get("path", "res://art/crumb_head.png")) return str(avatar.get("path", "res://art/crumb_head.png"))
static func head_path(id: String) -> String:
if id == "crumb":
return "res://art/crumb_head.png"
return "res://art/guests/heads/%s.png" % id
static func is_unlocked(id: String) -> bool: static func is_unlocked(id: String) -> bool:
if id == "crumb": if id == "crumb":
return true return true
+1 -1
View File
@@ -173,7 +173,7 @@ func _build_avatar() -> void:
var avatar := Button.new() var avatar := Button.new()
avatar.custom_minimum_size = Vector2(44, 44) avatar.custom_minimum_size = Vector2(44, 44)
avatar.flat = true avatar.flat = true
avatar.icon = load(Avatars.portrait_path(SaveGame.selected_avatar())) avatar.icon = load(Avatars.head_path(SaveGame.selected_avatar()))
avatar.expand_icon = true avatar.expand_icon = true
avatar.icon_alignment = HORIZONTAL_ALIGNMENT_CENTER avatar.icon_alignment = HORIZONTAL_ALIGNMENT_CENTER
avatar.alignment = HORIZONTAL_ALIGNMENT_CENTER avatar.alignment = HORIZONTAL_ALIGNMENT_CENTER
+21 -4
View File
@@ -192,7 +192,7 @@ func _build_portrait() -> void:
child.queue_free() child.queue_free()
var frame := Frames.frame_panel(pending_frame, 118) var frame := Frames.frame_panel(pending_frame, 118)
var head := TextureRect.new() var head := TextureRect.new()
head.texture = load(Avatars.portrait_path(pending_avatar)) head.texture = load(Avatars.head_path(pending_avatar))
head.custom_minimum_size = Vector2(96, 96) head.custom_minimum_size = Vector2(96, 96)
head.expand_mode = TextureRect.EXPAND_IGNORE_SIZE head.expand_mode = TextureRect.EXPAND_IGNORE_SIZE
head.stretch_mode = TextureRect.STRETCH_KEEP_ASPECT_CENTERED head.stretch_mode = TextureRect.STRETCH_KEEP_ASPECT_CENTERED
@@ -228,12 +228,24 @@ func _build_grid() -> void:
var badge := Frames.frame_panel(pending_frame if current_tab == "avatar" else id, 46) var badge := Frames.frame_panel(pending_frame if current_tab == "avatar" else id, 46)
badge.mouse_filter = Control.MOUSE_FILTER_IGNORE badge.mouse_filter = Control.MOUSE_FILTER_IGNORE
var head := TextureRect.new() var head := TextureRect.new()
head.texture = load(Avatars.portrait_path(id) if current_tab == "avatar" else "res://art/crumb_head.png") head.texture = load(Avatars.head_path(id) if current_tab == "avatar" else "res://art/crumb_head.png")
head.custom_minimum_size = Vector2(30, 30) head.custom_minimum_size = Vector2(30, 30)
head.expand_mode = TextureRect.EXPAND_IGNORE_SIZE head.expand_mode = TextureRect.EXPAND_IGNORE_SIZE
head.stretch_mode = TextureRect.STRETCH_KEEP_ASPECT_CENTERED head.stretch_mode = TextureRect.STRETCH_KEEP_ASPECT_CENTERED
head.mouse_filter = Control.MOUSE_FILTER_IGNORE head.mouse_filter = Control.MOUSE_FILTER_IGNORE
badge.add_child(head) badge.add_child(head)
var hidden := current_tab == "avatar" and not unlocked
if hidden:
var veil := ColorRect.new()
veil.color = Color(0.98, 0.93, 0.84, 0.82)
veil.set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)
veil.mouse_filter = Control.MOUSE_FILTER_IGNORE
badge.add_child(veil)
var question := UI.label("???", 12, Palette.INK)
question.set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)
question.vertical_alignment = VERTICAL_ALIGNMENT_CENTER
question.mouse_filter = Control.MOUSE_FILTER_IGNORE
badge.add_child(question)
row.add_child(badge) row.add_child(badge)
var text := VBoxContainer.new() var text := VBoxContainer.new()
@@ -242,7 +254,8 @@ func _build_grid() -> void:
text.mouse_filter = Control.MOUSE_FILTER_IGNORE text.mouse_filter = Control.MOUSE_FILTER_IGNORE
row.add_child(text) row.add_child(text)
var name := UI.label(str(entry.get("name", "")), 12) var display_name := "???" if (current_tab == "avatar" and not unlocked) else str(entry.get("name", ""))
var name := UI.label(display_name, 12)
name.horizontal_alignment = HORIZONTAL_ALIGNMENT_LEFT name.horizontal_alignment = HORIZONTAL_ALIGNMENT_LEFT
text.add_child(name) text.add_child(name)
@@ -251,8 +264,10 @@ func _build_grid() -> void:
detail = "Selected" detail = "Selected"
elif unlocked: elif unlocked:
detail = "Unlocked" detail = "Unlocked"
elif current_tab == "avatar":
detail = "Room %d" % int(entry.get("room", 0))
else: else:
detail = Avatars.requirement_text(id) if current_tab == "avatar" else Frames.requirement_text(id) detail = Frames.requirement_text(id)
var sub := UI.label(detail, 9, Palette.GOLD if id == selected else (Palette.MUTED if unlocked else Palette.RED)) var sub := UI.label(detail, 9, Palette.GOLD if id == selected else (Palette.MUTED if unlocked else Palette.RED))
sub.horizontal_alignment = HORIZONTAL_ALIGNMENT_LEFT sub.horizontal_alignment = HORIZONTAL_ALIGNMENT_LEFT
text.add_child(sub) text.add_child(sub)
@@ -321,6 +336,8 @@ func _build_achievements() -> void:
row.add_child(label) row.add_child(label)
achievements_box.add_child(row) achievements_box.add_child(row)
UI.pass_scroll_input(achievements_box)
func _build_rename_dialog() -> void: func _build_rename_dialog() -> void:
rename_layer = ColorRect.new() rename_layer = ColorRect.new()
+150 -12
View File
@@ -13,6 +13,9 @@ var hold_panel: PanelContainer
var music_volume_slider: HSlider var music_volume_slider: HSlider
var difficulty_button: Button var difficulty_button: Button
var theme_button: Button var theme_button: Button
var wallpaper_layer: ColorRect
var wallpaper_grid: GridContainer
var pending_theme := "cream"
var game_actions: HBoxContainer var game_actions: HBoxContainer
var reset_row: Control var reset_row: Control
var resume_button: Button var resume_button: Button
@@ -100,7 +103,7 @@ func _ready() -> void:
difficulty_button.pressed.connect(_cycle_difficulty) difficulty_button.pressed.connect(_cycle_difficulty)
list.add_child(difficulty_button) list.add_child(difficulty_button)
theme_button = UI.button("Wallpaper: Cream", false, 40) theme_button = UI.button("Wallpaper: Cream", false, 40)
theme_button.pressed.connect(_cycle_theme) theme_button.pressed.connect(_open_wallpaper_picker)
list.add_child(theme_button) list.add_child(theme_button)
_add_hold_row(list) _add_hold_row(list)
@@ -120,6 +123,8 @@ func _ready() -> void:
# label, toggle, or button. # label, toggle, or button.
UI.pass_scroll_input(list) UI.pass_scroll_input(list)
_build_wallpaper_picker()
game_actions = HBoxContainer.new() game_actions = HBoxContainer.new()
game_actions.add_theme_constant_override("separation", 6) game_actions.add_theme_constant_override("separation", 6)
column.add_child(game_actions) column.add_child(game_actions)
@@ -320,23 +325,156 @@ func _add_slider_row(parent: VBoxContainer, title: String, detail: String, key:
func _cycle_difficulty() -> void: func _cycle_difficulty() -> void:
var order := ["normal", "easy", "zen"] var order := ["zen", "easy", "normal"]
var current := str(SaveGame.get_setting("difficulty")) var current := str(SaveGame.get_setting("difficulty"))
var next_index := (order.find(current) + 1) % order.size() var next_index := (order.find(current) + 1) % order.size()
SaveGame.set_setting("difficulty", order[next_index]) SaveGame.set_setting("difficulty", order[next_index])
refresh() refresh()
func _cycle_theme() -> void: func _open_wallpaper_picker() -> void:
var order := ["cream", "sage", "rose", "dusk", "gold"] pending_theme = SaveGame.theme_id()
var current := SaveGame.theme_id() _build_wallpaper_grid()
var start := order.find(current) wallpaper_layer.visible = true
for offset in range(1, order.size() + 1): wallpaper_layer.move_to_front()
var candidate: String = order[(start + offset) % order.size()]
if SaveGame.is_theme_unlocked(candidate):
SaveGame.select_theme(candidate) func _build_wallpaper_picker() -> void:
refresh() wallpaper_layer = ColorRect.new()
return wallpaper_layer.color = Color(0.18, 0.12, 0.08, 0.62)
wallpaper_layer.set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)
wallpaper_layer.mouse_filter = Control.MOUSE_FILTER_STOP
wallpaper_layer.gui_input.connect(func(event: InputEvent) -> void:
if event is InputEventMouseButton and event.pressed and event.button_index == MOUSE_BUTTON_LEFT:
wallpaper_layer.visible = false
)
wallpaper_layer.visible = false
add_child(wallpaper_layer)
var center := CenterContainer.new()
center.set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)
center.mouse_filter = Control.MOUSE_FILTER_IGNORE
wallpaper_layer.add_child(center)
var panel := UI.panel(Palette.CREAM, 24, 16)
var view_size := get_viewport_rect().size
var max_width: int = max(280, int(view_size.x) - 32)
var panel_height: int = max(320, min(470, int(view_size.y) - 96))
panel.custom_minimum_size = Vector2(min(360, max_width), panel_height)
center.add_child(panel)
var box := VBoxContainer.new()
box.add_theme_constant_override("separation", 8)
panel.add_child(box)
box.add_child(UI.heading("Wallpapers", 20))
var scroll := ScrollContainer.new()
scroll.custom_minimum_size = Vector2(0, max(180, panel_height - 170))
scroll.size_flags_vertical = Control.SIZE_EXPAND_FILL
scroll.horizontal_scroll_mode = ScrollContainer.SCROLL_MODE_DISABLED
box.add_child(scroll)
wallpaper_grid = GridContainer.new()
wallpaper_grid.columns = 2
wallpaper_grid.size_flags_horizontal = Control.SIZE_EXPAND_FILL
wallpaper_grid.add_theme_constant_override("h_separation", 6)
wallpaper_grid.add_theme_constant_override("v_separation", 6)
scroll.add_child(wallpaper_grid)
var actions := HBoxContainer.new()
actions.add_theme_constant_override("separation", 8)
box.add_child(actions)
var cancel := UI.button("Cancel", false, 46)
cancel.size_flags_horizontal = Control.SIZE_EXPAND_FILL
cancel.pressed.connect(func() -> void: wallpaper_layer.visible = false)
actions.add_child(cancel)
var confirm := UI.button("Apply", true, 46)
confirm.size_flags_horizontal = Control.SIZE_EXPAND_FILL
confirm.pressed.connect(_apply_wallpaper)
actions.add_child(confirm)
func _theme_requirement(def: Dictionary) -> String:
if str(def.get("name", "")) == "Gold":
return "Open the 7-day gift"
var rooms := int(def.get("rooms", 0))
var streak := int(def.get("streak", 0))
if rooms > 0 and streak > 0:
return "%d rooms · %d-day streak" % [rooms, streak]
if rooms > 0:
return "Complete %d rooms" % rooms
if streak > 0:
return "%d-day best streak" % streak
return "Always available"
func _build_wallpaper_grid() -> void:
for child in wallpaper_grid.get_children():
child.queue_free()
for id in SaveGame.THEMES.keys():
var def: Dictionary = SaveGame.THEMES[id]
var unlocked := SaveGame.is_theme_unlocked(id)
var card := Button.new()
card.custom_minimum_size = Vector2(150, 118)
card.flat = true
card.add_theme_stylebox_override("normal", _card_style(Palette.GOLD if id == pending_theme else Palette.PAPER))
card.add_theme_stylebox_override("hover", _card_style(Palette.PAPER_DARK))
card.pressed.connect(_select_pending_theme.bind(str(id), unlocked))
var column := VBoxContainer.new()
column.set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT)
column.add_theme_constant_override("separation", 2)
column.mouse_filter = Control.MOUSE_FILTER_IGNORE
card.add_child(column)
var preview := TextureRect.new()
preview.custom_minimum_size = Vector2(0, 68)
preview.size_flags_vertical = Control.SIZE_EXPAND_FILL
preview.expand_mode = TextureRect.EXPAND_IGNORE_SIZE
preview.stretch_mode = TextureRect.STRETCH_SCALE
preview.mouse_filter = Control.MOUSE_FILTER_IGNORE
var path := "res://assets/backgrounds/%s.png" % str(id)
if ResourceLoader.exists(path):
preview.texture = load(path)
column.add_child(preview)
var title := UI.label(str(def.get("name", id)), 11, Palette.INK)
title.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER
column.add_child(title)
var state := "Selected" if id == pending_theme else ("Unlocked" if unlocked else _theme_requirement(def))
var sub := UI.label(state, 9, Palette.GOLD if id == pending_theme else (Palette.MUTED if unlocked else Palette.RED))
sub.horizontal_alignment = HORIZONTAL_ALIGNMENT_CENTER
column.add_child(sub)
if not unlocked:
card.modulate = Color(1, 1, 1, 0.72)
wallpaper_grid.add_child(card)
UI.pass_scroll_input(wallpaper_grid)
func _select_pending_theme(id: String, unlocked: bool) -> void:
if not unlocked:
return
call_deferred("_set_pending_theme", id)
func _set_pending_theme(id: String) -> void:
pending_theme = id
_build_wallpaper_grid()
func _apply_wallpaper() -> void:
SaveGame.select_theme(pending_theme)
wallpaper_layer.visible = false
refresh()
func _card_style(color: Color) -> StyleBoxFlat:
var style := StyleBoxFlat.new()
style.bg_color = color
style.corner_radius_top_left = 12
style.corner_radius_top_right = 12
style.corner_radius_bottom_left = 12
style.corner_radius_bottom_right = 12
style.content_margin_left = 6
style.content_margin_right = 6
style.content_margin_top = 6
style.content_margin_bottom = 6
return style
func _add_hold_row(parent: VBoxContainer) -> void: func _add_hold_row(parent: VBoxContainer) -> void:
+3 -3
View File
@@ -1,7 +1,7 @@
class_name Version class_name Version
extends RefCounted extends RefCounted
const NUMBER := "0.8.0-alpha" const NUMBER := "0.8.1-alpha"
const CODENAME := "Meowdoku Lessons" const CODENAME := "UI Polish"
const BUILD_DATE := "2026-12-04" const BUILD_DATE := "2026-12-04"
const BUILD_LABEL := "v0.8.0-alpha · build 2026-12-04" const BUILD_LABEL := "v0.8.1-alpha · build 2026-12-04"
+19 -1
View File
@@ -6,6 +6,7 @@ extends SceneTree
var failures := 0 var failures := 0
var frames var frames
var avatars
func _init() -> void: func _init() -> void:
@@ -39,6 +40,8 @@ func _run() -> void:
# autoloads are registered when this script is launched with --script. # autoloads are registered when this script is launched with --script.
frames = load("res://scripts/Frames.gd") frames = load("res://scripts/Frames.gd")
_check(frames != null, "Frames script missing") _check(frames != null, "Frames script missing")
avatars = load("res://scripts/Avatars.gd")
_check(avatars != null, "Avatars script missing")
_test_screen_cycle(main) _test_screen_cycle(main)
await _test_settings(main, save) await _test_settings(main, save)
@@ -114,9 +117,16 @@ func _test_settings(main, save) -> void:
_check(main.settings_sheet.music_volume_slider != null, "music volume slider missing") _check(main.settings_sheet.music_volume_slider != null, "music volume slider missing")
_check(main.settings_sheet.difficulty_button.text.find("Difficulty") >= 0, "difficulty control missing") _check(main.settings_sheet.difficulty_button.text.find("Difficulty") >= 0, "difficulty control missing")
main.settings_sheet._cycle_difficulty() main.settings_sheet._cycle_difficulty()
_check(str(save.get_setting("difficulty")) == "easy", "difficulty should cycle") _check(str(save.get_setting("difficulty")) == "zen", "difficulty should cycle to zen first")
save.set_setting("difficulty", "normal") save.set_setting("difficulty", "normal")
_check(main.background_rect.texture != null, "wallpaper texture should load") _check(main.background_rect.texture != null, "wallpaper texture should load")
main.settings_sheet._open_wallpaper_picker()
_check(main.settings_sheet.wallpaper_layer.visible, "wallpaper picker should open")
_check(main.settings_sheet.wallpaper_grid.get_child_count() == 5, "wallpaper picker should show all themes")
_check(main.settings_sheet.wallpaper_grid.get_child(0).mouse_filter == Control.MOUSE_FILTER_PASS, "wallpaper cards should pass swipes")
main.settings_sheet._set_pending_theme("cream")
main.settings_sheet._apply_wallpaper()
_check(not main.settings_sheet.wallpaper_layer.visible, "wallpaper picker should close after apply")
# Changes made through SaveGame must be reflected after an explicit refresh. # Changes made through SaveGame must be reflected after an explicit refresh.
save.set_setting("patterns", false) save.set_setting("patterns", false)
@@ -254,6 +264,7 @@ func _test_profile(main, save) -> void:
_check(profile.player_id_label.text.begins_with("RAT-"), "profile should show player ID") _check(profile.player_id_label.text.begins_with("RAT-"), "profile should show player ID")
_check(profile.achievements_box.get_child_count() == 8, "profile should list achievements") _check(profile.achievements_box.get_child_count() == 8, "profile should list achievements")
_check(profile.achievements_box.get_child(0).mouse_filter == Control.MOUSE_FILTER_PASS, "achievement rows should pass swipes")
profile._show_rename() profile._show_rename()
profile.name_input.text = "Ahri" profile.name_input.text = "Ahri"
profile._save_name() profile._save_name()
@@ -330,6 +341,13 @@ func _test_profile(main, save) -> void:
profile._set_tab("avatar") profile._set_tab("avatar")
await process_frame await process_frame
_check(profile.frame_grid.get_child_count() > 10, "avatar tab should list portraits") _check(profile.frame_grid.get_child_count() > 10, "avatar tab should list portraits")
var locked_index := -1
for i in avatars.all().size():
if str(avatars.all()[i].get("id", "")) == "pepper":
locked_index = i
if locked_index >= 0 and locked_index < profile.frame_grid.get_child_count():
var labels = profile.frame_grid.get_child(locked_index).find_children("*", "Label", true, false)
_check(labels.size() > 0 and str(labels[0].text) == "???", "locked avatar should hide its name")
for i in range(profile.frame_grid.get_child_count()): for i in range(profile.frame_grid.get_child_count()):
_check( _check(
profile.frame_grid.get_child(i).mouse_filter == Control.MOUSE_FILTER_PASS, profile.frame_grid.get_child(i).mouse_filter == Control.MOUSE_FILTER_PASS,