initial android export experiments

This commit is contained in:
Haze Weathers 2023-03-10 14:12:16 -05:00
parent a2b9da421a
commit 8452ebce66
30 changed files with 755 additions and 1 deletions

View file

@ -0,0 +1,14 @@
extends CanvasLayer
export var opacity = 0.5
func _ready():
if !OS.has_feature("mobile"):
visible = false
$CanvasModulate.color = Color(1.0, 1.0, 1.0, opacity)
_reposition()
get_tree().connect("screen_resized", self, "_reposition")
func _reposition():
$Directions.position = Vector2(0.0, get_viewport().size.y)
$Actions.position = get_viewport().size

View file

@ -0,0 +1,104 @@
[gd_scene load_steps=17 format=2]
[ext_resource path="res://autoloads/touch_controls.gd" type="Script" id=1]
[ext_resource path="res://graphics/hud/touch/touch_left.png" type="Texture" id=2]
[ext_resource path="res://graphics/hud/touch/touch_down_pressed.png" type="Texture" id=3]
[ext_resource path="res://graphics/hud/touch/touch_right_pressed.png" type="Texture" id=4]
[ext_resource path="res://graphics/hud/touch/touch_up.png" type="Texture" id=5]
[ext_resource path="res://graphics/hud/touch/touch_up_pressed.png" type="Texture" id=6]
[ext_resource path="res://graphics/hud/touch/touch_left_pressed.png" type="Texture" id=7]
[ext_resource path="res://graphics/hud/touch/touch_down.png" type="Texture" id=8]
[ext_resource path="res://graphics/hud/touch/touch_right.png" type="Texture" id=9]
[ext_resource path="res://graphics/hud/touch/touch_jump.png" type="Texture" id=10]
[ext_resource path="res://graphics/hud/touch/touch_shoot.png" type="Texture" id=11]
[ext_resource path="res://graphics/hud/touch/touch_jump_pressed.png" type="Texture" id=12]
[ext_resource path="res://graphics/hud/touch/touch_shoot_pressed.png" type="Texture" id=13]
[sub_resource type="RectangleShape2D" id=1]
extents = Vector2( 40, 120 )
[sub_resource type="RectangleShape2D" id=2]
extents = Vector2( 120, 40 )
[sub_resource type="RectangleShape2D" id=3]
extents = Vector2( 40, 40 )
[node name="TouchControls" type="CanvasLayer"]
pause_mode = 2
layer = 128
script = ExtResource( 1 )
[node name="CanvasModulate" type="CanvasModulate" parent="."]
[node name="Directions" type="Node2D" parent="."]
[node name="LeftButton" type="TouchScreenButton" parent="Directions"]
position = Vector2( 0, -160 )
normal = ExtResource( 2 )
pressed = ExtResource( 7 )
shape = SubResource( 1 )
passby_press = true
action = "ui_left"
[node name="RightButton" type="TouchScreenButton" parent="Directions"]
position = Vector2( 160, -160 )
normal = ExtResource( 9 )
pressed = ExtResource( 4 )
shape = SubResource( 1 )
passby_press = true
action = "ui_right"
[node name="UpButton" type="TouchScreenButton" parent="Directions"]
position = Vector2( 80, -240 )
normal = ExtResource( 5 )
pressed = ExtResource( 6 )
shape = SubResource( 2 )
passby_press = true
action = "ui_up"
[node name="DownButton" type="TouchScreenButton" parent="Directions"]
position = Vector2( 80, -80 )
normal = ExtResource( 8 )
pressed = ExtResource( 3 )
shape = SubResource( 2 )
passby_press = true
action = "ui_down"
[node name="Actions" type="Node2D" parent="."]
[node name="JumpButton" type="TouchScreenButton" parent="Actions"]
position = Vector2( -80, -120 )
normal = ExtResource( 10 )
pressed = ExtResource( 12 )
shape = SubResource( 3 )
passby_press = true
action = "jump"
[node name="AcceptButton" type="TouchScreenButton" parent="Actions"]
position = Vector2( -80, -120 )
shape = SubResource( 3 )
passby_press = true
action = "ui_accept"
[node name="ShootButton" type="TouchScreenButton" parent="Actions"]
position = Vector2( -200, -120 )
normal = ExtResource( 11 )
pressed = ExtResource( 13 )
shape = SubResource( 3 )
passby_press = true
action = "shoot"
[node name="CancelButton" type="TouchScreenButton" parent="Actions"]
position = Vector2( -200, -120 )
shape = SubResource( 3 )
passby_press = true
action = "ui_cancel"
[node name="PauseButton" type="TouchScreenButton" parent="Actions"]
position = Vector2( 0, -400 )
rotation = 1.5708
normal = ExtResource( 11 )
pressed = ExtResource( 12 )
shape = SubResource( 3 )
passby_press = true
action = "pause"

View file

@ -83,6 +83,7 @@ margin_top = -72.0
margin_right = 136.0
margin_bottom = 120.0
rect_pivot_offset = Vector2( 128, 96 )
mouse_filter = 1
[node name="Viewport" type="Viewport" parent="ViewportContainer"]
size = Vector2( 256, 192 )
@ -106,7 +107,7 @@ valign = 2
[node name="FadeLayer" type="CanvasLayer" parent="ViewportContainer/Viewport"]
pause_mode = 2
layer = 128
layer = 125
script = ExtResource( 8 )
[node name="TextureRect" type="TextureRect" parent="ViewportContainer/Viewport/FadeLayer"]

View file

@ -100,3 +100,209 @@ progressive_web_app/icon_144x144=""
progressive_web_app/icon_180x180=""
progressive_web_app/icon_512x512=""
progressive_web_app/background_color=Color( 0, 0, 0, 1 )
[preset.3]
name="android"
platform="Android"
runnable=true
custom_features=""
export_filter="all_resources"
include_filter=""
exclude_filter=""
export_path="build/android/hm2.apk"
script_export_mode=1
script_encryption_key=""
[preset.3.options]
custom_template/debug=""
custom_template/release=""
custom_build/use_custom_build=false
custom_build/export_format=0
custom_build/min_sdk=""
custom_build/target_sdk=""
architectures/armeabi-v7a=true
architectures/arm64-v8a=true
architectures/x86=false
architectures/x86_64=false
keystore/debug=""
keystore/debug_user=""
keystore/debug_password=""
keystore/release=""
keystore/release_user=""
keystore/release_password=""
one_click_deploy/clear_previous_install=false
version/code=1
version/name="1.0"
package/unique_name="org.godotengine.$genname"
package/name=""
package/signed=true
package/classify_as_game=true
package/retain_data_on_uninstall=false
package/exclude_from_recents=false
launcher_icons/main_192x192=""
launcher_icons/adaptive_foreground_432x432=""
launcher_icons/adaptive_background_432x432=""
graphics/opengl_debug=false
xr_features/xr_mode=0
xr_features/hand_tracking=0
xr_features/hand_tracking_frequency=0
xr_features/passthrough=0
screen/immersive_mode=true
screen/support_small=true
screen/support_normal=true
screen/support_large=true
screen/support_xlarge=true
user_data_backup/allow=false
command_line/extra_args=""
apk_expansion/enable=false
apk_expansion/SALT=""
apk_expansion/public_key=""
permissions/custom_permissions=PoolStringArray( )
permissions/access_checkin_properties=false
permissions/access_coarse_location=false
permissions/access_fine_location=false
permissions/access_location_extra_commands=false
permissions/access_mock_location=false
permissions/access_network_state=false
permissions/access_surface_flinger=false
permissions/access_wifi_state=false
permissions/account_manager=false
permissions/add_voicemail=false
permissions/authenticate_accounts=false
permissions/battery_stats=false
permissions/bind_accessibility_service=false
permissions/bind_appwidget=false
permissions/bind_device_admin=false
permissions/bind_input_method=false
permissions/bind_nfc_service=false
permissions/bind_notification_listener_service=false
permissions/bind_print_service=false
permissions/bind_remoteviews=false
permissions/bind_text_service=false
permissions/bind_vpn_service=false
permissions/bind_wallpaper=false
permissions/bluetooth=false
permissions/bluetooth_admin=false
permissions/bluetooth_privileged=false
permissions/brick=false
permissions/broadcast_package_removed=false
permissions/broadcast_sms=false
permissions/broadcast_sticky=false
permissions/broadcast_wap_push=false
permissions/call_phone=false
permissions/call_privileged=false
permissions/camera=false
permissions/capture_audio_output=false
permissions/capture_secure_video_output=false
permissions/capture_video_output=false
permissions/change_component_enabled_state=false
permissions/change_configuration=false
permissions/change_network_state=false
permissions/change_wifi_multicast_state=false
permissions/change_wifi_state=false
permissions/clear_app_cache=false
permissions/clear_app_user_data=false
permissions/control_location_updates=false
permissions/delete_cache_files=false
permissions/delete_packages=false
permissions/device_power=false
permissions/diagnostic=false
permissions/disable_keyguard=false
permissions/dump=false
permissions/expand_status_bar=false
permissions/factory_test=false
permissions/flashlight=false
permissions/force_back=false
permissions/get_accounts=false
permissions/get_package_size=false
permissions/get_tasks=false
permissions/get_top_activity_info=false
permissions/global_search=false
permissions/hardware_test=false
permissions/inject_events=false
permissions/install_location_provider=false
permissions/install_packages=false
permissions/install_shortcut=false
permissions/internal_system_window=false
permissions/internet=false
permissions/kill_background_processes=false
permissions/location_hardware=false
permissions/manage_accounts=false
permissions/manage_app_tokens=false
permissions/manage_documents=false
permissions/manage_external_storage=false
permissions/master_clear=false
permissions/media_content_control=false
permissions/modify_audio_settings=false
permissions/modify_phone_state=false
permissions/mount_format_filesystems=false
permissions/mount_unmount_filesystems=false
permissions/nfc=false
permissions/persistent_activity=false
permissions/process_outgoing_calls=false
permissions/read_calendar=false
permissions/read_call_log=false
permissions/read_contacts=false
permissions/read_external_storage=false
permissions/read_frame_buffer=false
permissions/read_history_bookmarks=false
permissions/read_input_state=false
permissions/read_logs=false
permissions/read_phone_state=false
permissions/read_profile=false
permissions/read_sms=false
permissions/read_social_stream=false
permissions/read_sync_settings=false
permissions/read_sync_stats=false
permissions/read_user_dictionary=false
permissions/reboot=false
permissions/receive_boot_completed=false
permissions/receive_mms=false
permissions/receive_sms=false
permissions/receive_wap_push=false
permissions/record_audio=false
permissions/reorder_tasks=false
permissions/restart_packages=false
permissions/send_respond_via_message=false
permissions/send_sms=false
permissions/set_activity_watcher=false
permissions/set_alarm=false
permissions/set_always_finish=false
permissions/set_animation_scale=false
permissions/set_debug_app=false
permissions/set_orientation=false
permissions/set_pointer_speed=false
permissions/set_preferred_applications=false
permissions/set_process_limit=false
permissions/set_time=false
permissions/set_time_zone=false
permissions/set_wallpaper=false
permissions/set_wallpaper_hints=false
permissions/signal_persistent_processes=false
permissions/status_bar=false
permissions/subscribed_feeds_read=false
permissions/subscribed_feeds_write=false
permissions/system_alert_window=false
permissions/transmit_ir=false
permissions/uninstall_shortcut=false
permissions/update_device_stats=false
permissions/use_credentials=false
permissions/use_sip=false
permissions/vibrate=false
permissions/wake_lock=false
permissions/write_apn_settings=false
permissions/write_calendar=false
permissions/write_call_log=false
permissions/write_contacts=false
permissions/write_external_storage=false
permissions/write_gservices=false
permissions/write_history_bookmarks=false
permissions/write_profile=false
permissions/write_secure_settings=false
permissions/write_settings=false
permissions/write_sms=false
permissions/write_social_stream=false
permissions/write_sync_settings=false
permissions/write_user_dictionary=false

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_down.png-f7b3b9d5360093c35208cae627eee0fa.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_down.png"
dest_files=[ "res://.import/touch_down.png-f7b3b9d5360093c35208cae627eee0fa.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.8 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_down_pressed.png-26e3c9959e421a752a92240046513eb6.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_down_pressed.png"
dest_files=[ "res://.import/touch_down_pressed.png-26e3c9959e421a752a92240046513eb6.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_jump.png-d25a25c96ba529fc22922d345cf1f985.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_jump.png"
dest_files=[ "res://.import/touch_jump.png-d25a25c96ba529fc22922d345cf1f985.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_jump_pressed.png-37dc8c2572dc91bc5bf30beb311f19a0.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_jump_pressed.png"
dest_files=[ "res://.import/touch_jump_pressed.png-37dc8c2572dc91bc5bf30beb311f19a0.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 907 B

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_left.png-0d1348fd1f7bc33ef4880e04370b336c.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_left.png"
dest_files=[ "res://.import/touch_left.png-0d1348fd1f7bc33ef4880e04370b336c.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_left_pressed.png-cdb9c23493ebeaf4d533502019100251.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_left_pressed.png"
dest_files=[ "res://.import/touch_left_pressed.png-cdb9c23493ebeaf4d533502019100251.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 910 B

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_right.png-b39574011fcd5ee55b3e373c24167362.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_right.png"
dest_files=[ "res://.import/touch_right.png-b39574011fcd5ee55b3e373c24167362.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_right_pressed.png-816aab9d2892ce2d06d13959d3378255.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_right_pressed.png"
dest_files=[ "res://.import/touch_right_pressed.png-816aab9d2892ce2d06d13959d3378255.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_shoot.png-f3f5c2ac5ce5bd30dda5a011dfa4b49c.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_shoot.png"
dest_files=[ "res://.import/touch_shoot.png-f3f5c2ac5ce5bd30dda5a011dfa4b49c.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_shoot_pressed.png-21478853c80a510d300db9de2d76e41d.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_shoot_pressed.png"
dest_files=[ "res://.import/touch_shoot_pressed.png-21478853c80a510d300db9de2d76e41d.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 879 B

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_up.png-954befe4d1b24b6da3d6f6fe5d9fce88.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_up.png"
dest_files=[ "res://.import/touch_up.png-954befe4d1b24b6da3d6f6fe5d9fce88.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

View file

@ -0,0 +1,35 @@
[remap]
importer="texture"
type="StreamTexture"
path="res://.import/touch_up_pressed.png-0dea60c997753fc151f6488b7d2ed2d1.stex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://graphics/hud/touch/touch_up_pressed.png"
dest_files=[ "res://.import/touch_up_pressed.png-0dea60c997753fc151f6488b7d2ed2d1.stex" ]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_mode=0
compress/bptc_ldr=0
compress/normal_map=0
flags/repeat=0
flags/filter=false
flags/mipmaps=false
flags/anisotropic=false
flags/srgb=2
process/fix_alpha_border=true
process/premult_alpha=false
process/HDR_as_SRGB=false
process/invert_color=false
process/normal_map_invert_y=false
stream=false
size_limit=0
detect_3d=true
svg/scale=1.0

View file

@ -34,11 +34,13 @@ LevelData="*res://autoloads/level_data.tscn"
Save="*res://autoloads/save.gd"
Debug="*res://autoloads/debug.tscn"
Options="*res://autoloads/options.gd"
TouchControls="*res://autoloads/touch_controls.tscn"
[display]
window/size/width=256
window/size/height=192
window/handheld/orientation="sensor_portrait"
[editor_plugins]
@ -223,6 +225,10 @@ ui_reset={
]
}
[input_devices]
pointing/emulate_touch_from_mouse=true
[layer_names]
2d_physics/layer_1="general"
@ -241,4 +247,5 @@ common/enable_pause_aware_picking=true
quality/driver/driver_name="GLES2"
2d/snapping/use_gpu_pixel_snap=true
vram_compression/import_etc=true
environment/default_environment="res://default_env.tres"

View file

@ -18,6 +18,8 @@ func _ready():
get_tree().connect("screen_resized", self, "_on_screen_resized")
root.set_attach_to_screen_rect(root.get_visible_rect())
_on_screen_resized()
#STUPID VIEWPORT GODOT BUG FIX
$ViewportContainer/Viewport.set_deferred("handle_input_locally", true)
func _on_screen_resized():
# VARS