mirror of
https://github.com/godotengine/godot-demo-projects.git
synced 2025-12-16 05:20:06 +01:00
This leads to code that is easier to understand and runs faster thanks to GDScript's typed instructions. The untyped declaration warning is now enabled on all projects where type hints were added. All projects currently run without any untyped declration warnings. Dodge the Creeps and Squash the Creeps demos intentionally don't use type hints to match the documentation, where type hints haven't been adopted yet (given its beginner focus).
12 lines
410 B
GDScript
12 lines
410 B
GDScript
extends VBoxContainer
|
|
|
|
|
|
func _ready() -> void:
|
|
# Don't allow loading files that don't exist yet.
|
|
($SaveLoad/LoadConfigFile as Button).disabled = not FileAccess.file_exists("user://save_config_file.ini")
|
|
($SaveLoad/LoadJSON as Button).disabled = not FileAccess.file_exists("user://save_json.json")
|
|
|
|
|
|
func _on_open_user_data_folder_pressed() -> void:
|
|
OS.shell_open(ProjectSettings.globalize_path("user://"))
|