[agent:claude-cli] feat(save): save/load automatique (30s + mort) — user://save.json, persist XP/level/inventory/achievements/position, autoload SaveManager

This commit is contained in:
2026-04-21 08:40:22 +00:00
parent 2c49e0c9db
commit 6cb5925da8
4 changed files with 148 additions and 0 deletions

View File

@@ -86,6 +86,12 @@ func _spawn_local_dolphin() -> void:
dolphin.add_to_group("player")
# Save system
var save_mgr: Node = get_node_or_null("/root/SaveManager")
if save_mgr != null:
save_mgr.register_player(dolphin)
save_mgr.load_game()
var ui_scene: PackedScene = load("res://scenes/InventoryUI.tscn")
if ui_scene != null:
_inventory_ui = ui_scene.instantiate() as CanvasLayer