farming-simulator/scenes/components/dialog_ui.tscn
Dmitrii Bykov d1b3afd006
Some checks failed
Godot CI / Import + smoke test (push) Failing after 19s
act1: FPV-комната с подарком, запиской и флешкой
3D-сцена 4×4м: стены/пол/потолок, окно (свечение), дверь, стол с пека,
кровать с одеялом, подарок-коробка на полу, отец-NPC в дверях.

Архитектура:
- FPVController (CharacterBody3D + Camera3D + RayCast3D) — mouse look,
  WASD, raycast-pickup, lock_input для катсцен.
- Interactable (StaticBody3D base) — toggle через collision_layer.
- DialogManager (autoload CanvasLayer) — субтитры snake-case, fullscreen
  записка, HUD-подсказки, prompt над крестом, await через signal.
- act1.gd — state machine: INTRO → EXPLORE_GIFT → INSIDE_GIFT →
  NOTE_READ → FATHER_FAREWELL (tween x-2.5) → SEEK_DRIVE → ENDING.

Канон-реплики из Пролог_Первый_день.md без правок:
- Отец intro + про флешку с Шиндой
- Записка «Не сожги. Пароль от Wi-Fi на холодильнике. — Бать»
- Мысли героя: «новый пека?», «бать ну ты красавчик», «Андрюхино так Андрюхино»

GL Compatibility renderer, unshaded материалы плоскими цветами под
pixel-art 640×360. Тестировано на RTX 5070 — стартует без ошибок.

main.tscn placeholder удалён, main_scene = act1_room.tscn.

Не покрыто в MVP (TBD):
- Опц. выход на кухню → холодильник → Wi-Fi пароль
- Mastermind hack-mini-game для подбора Wi-Fi
- Sfxr звуки (открытие коробки, шаги)
- Переход в Акт 2 (пока quit на финале)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-24 17:12:04 +03:00

94 lines
2.3 KiB
Text

[gd_scene load_steps=2 format=3]
[ext_resource type="Script" path="res://scripts/ui/dialog_manager.gd" id="1_dlg"]
[node name="DialogManager" type="CanvasLayer"]
layer = 10
script = ExtResource("1_dlg")
[node name="HudLabel" type="Label" parent="."]
offset_left = 8.0
offset_top = 4.0
offset_right = 632.0
offset_bottom = 22.0
text = ""
modulate = Color(0.85, 0.85, 0.85, 1)
[node name="PromptLabel" type="Label" parent="."]
offset_left = 0.0
offset_top = 200.0
offset_right = 640.0
offset_bottom = 220.0
text = ""
horizontal_alignment = 1
modulate = Color(1, 0.95, 0.6, 1)
[node name="SubtitlePanel" type="PanelContainer" parent="."]
offset_left = 20.0
offset_top = 260.0
offset_right = 620.0
offset_bottom = 350.0
[node name="V" type="VBoxContainer" parent="SubtitlePanel"]
layout_mode = 2
[node name="Who" type="Label" parent="SubtitlePanel/V"]
layout_mode = 2
text = "[Я]"
modulate = Color(0.9, 0.8, 0.5, 1)
[node name="Text" type="Label" parent="SubtitlePanel/V"]
layout_mode = 2
text = ""
autowrap_mode = 3
[node name="Hint" type="Label" parent="SubtitlePanel/V"]
layout_mode = 2
text = "ЛКМ или ПРОБЕЛ — дальше"
horizontal_alignment = 2
modulate = Color(0.55, 0.55, 0.55, 1)
[node name="NoteOverlay" type="Control" parent="."]
anchor_right = 1.0
anchor_bottom = 1.0
offset_right = 640.0
offset_bottom = 360.0
mouse_filter = 0
[node name="DarkBG" type="ColorRect" parent="NoteOverlay"]
anchor_right = 1.0
anchor_bottom = 1.0
offset_right = 640.0
offset_bottom = 360.0
color = Color(0, 0, 0, 0.75)
[node name="Center" type="CenterContainer" parent="NoteOverlay"]
anchor_right = 1.0
anchor_bottom = 1.0
offset_right = 640.0
offset_bottom = 360.0
[node name="P" type="PanelContainer" parent="NoteOverlay/Center"]
custom_minimum_size = Vector2(420, 180)
layout_mode = 2
[node name="V2" type="VBoxContainer" parent="NoteOverlay/Center/P"]
layout_mode = 2
[node name="Title" type="Label" parent="NoteOverlay/Center/P/V2"]
layout_mode = 2
text = "Записка"
horizontal_alignment = 1
modulate = Color(0.9, 0.8, 0.5, 1)
[node name="Text" type="Label" parent="NoteOverlay/Center/P/V2"]
layout_mode = 2
text = ""
autowrap_mode = 3
horizontal_alignment = 1
[node name="Hint" type="Label" parent="NoteOverlay/Center/P/V2"]
layout_mode = 2
text = "ЛКМ или ПРОБЕЛ — закрыть"
horizontal_alignment = 1
modulate = Color(0.55, 0.55, 0.55, 1)