act1: fix WASD + 3D pixelation (canvas_items stretch)
Some checks failed
Godot CI / Import + smoke test (push) Failing after 13s

1. stretch/mode: viewport → canvas_items + aspect=keep
   3D теперь рендерится в native window resolution (1920×1080), а 2D UI
   остаётся в 640×360 logical coords с nearest-фильтрацией — гибрид
   smooth 3D + pixel-art UI.

2. [input] map: добавлены move_forward/back/left/right на WASD +
   стрелки (physical_keycode для layout-независимости). Дефолтные
   ui_left/right/up/down в Godot 4 биндятся только на стрелки —
   поэтому WASD ничего не делал.

3. HUD-подсказка обновлена: «WASD ходить · мышь смотреть · ЛКМ
   взаимодействие».

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Dmitrii Bykov 2026-05-24 17:17:43 +03:00
parent d1b3afd006
commit 3975a28ed1
3 changed files with 31 additions and 3 deletions

View file

@ -61,7 +61,7 @@ func _physics_process(delta: float) -> void:
move_and_slide()
_update_focus()
return
var input_dir: Vector2 = Input.get_vector("ui_left", "ui_right", "ui_up", "ui_down")
var input_dir: Vector2 = Input.get_vector("move_left", "move_right", "move_forward", "move_back")
var direction: Vector3 = (transform.basis * Vector3(input_dir.x, 0.0, input_dir.y)).normalized()
velocity.x = direction.x * move_speed
velocity.z = direction.z * move_speed

View file

@ -21,7 +21,7 @@ func _ready() -> void:
player.interactable_focused.connect(_on_player_focused)
player.interactable_unfocused.connect(_on_player_unfocused)
DialogManager.set_hud("Акт 1 — Подарок · ЛКМ/ПРОБЕЛ — дальше · ESC — мышь · Q — выход")
DialogManager.set_hud("Акт 1 — Подарок · WASD ходить · мышь смотреть · ЛКМ взаимодействие · ESC мышь · Q выход")
await get_tree().create_timer(0.8).timeout
await DialogManager.say("ОТЕЦ", "Ну? Чё стоишь. Распаковывай давай. Сам собирал, между прочим — полночи не спал.")