made some window management changes

This commit is contained in:
2022-11-12 01:06:57 +01:00
parent 8058f3d4eb
commit 906738514b
3 changed files with 11 additions and 7 deletions

View File

@@ -27,6 +27,12 @@ common/drop_mouse_on_gui_input_disabled=true
[input]
fullscreen={
"deadzone": 0.5,
"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777254,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":true,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777221,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
]
}
move_left={
"deadzone": 0.5,
"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":65,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
@@ -63,12 +69,6 @@ move_down={
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777234,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
]
}
fullscreen={
"deadzone": 0.5,
"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777254,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":true,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777221,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
]
}
[mono]

View File

@@ -5,6 +5,7 @@
[ext_resource path="res://src/Main.cs" type="Script" id=3]
[node name="Main" type="Node2D"]
position = Vector2( 4, 0 )
script = ExtResource( 3 )
[node name="World" parent="." instance=ExtResource( 2 )]

View File

@@ -1,5 +1,6 @@
using Godot;
using System;
using System.Diagnostics;
public class Main : Node2D
{
@@ -10,7 +11,9 @@ public class Main : Node2D
// Called when the node enters the scene tree for the first time.
public override void _Ready()
{
//window management
OS.WindowMaximized = OS.IsDebugBuild();
OS.WindowFullscreen = !OS.IsDebugBuild();
}
public override async void _Process(float delta)