window.gd script

minimum window size & window title
main
Just Dzhi 2023-09-30 19:56:06 +04:00
parent 06d789f9b2
commit acf4fd005b
2 changed files with 12 additions and 0 deletions

View File

@ -19,11 +19,15 @@ config/icon="res://icon.png"
[autoload]
Global="*res://src/global.gd"
Window="*res://src/window.gd"
[display]
window/size/width=320
window/size/height=180
window/size/test_width=1280
window/size/test_height=720
window/handheld/orientation="sensor_landscape"
window/stretch/mode="viewport"
window/stretch/aspect="keep"

8
src/window.gd Normal file
View File

@ -0,0 +1,8 @@
extends Node
func _ready():
_change_window_title("Hello World!")
OS.min_window_size = Vector2(320, 180)
func _change_window_title(_title):
OS.set_window_title(ProjectSettings.get_setting("application/config/name") + " - " + _title)