Merge pull request #77 from santouits/lalala

fixed anchors and renamed move function for window management demo
This commit is contained in:
Rémi Verschelde
2017-10-26 09:41:11 +02:00
committed by GitHub
2 changed files with 154 additions and 76 deletions

View File

@@ -34,7 +34,7 @@ func _physics_process(delta):
dir = dir.normalized()
move(dir * 10 * delta)
move_and_collide(dir * 10 * delta)
var d = delta * 0.1
var yaw = get_transform().rotated(Vector3(0, 1, 0), d * r_pos.x)

View File

@@ -34,8 +34,10 @@ material/0 = null
[node name="Control" type="Control" parent="."]
anchor_right = 1
anchor_bottom = 1
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 1.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 0
@@ -45,6 +47,10 @@ script = ExtResource( 2 )
[node name="Button_Fullscreen" type="Button" parent="Control"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 20.0
margin_top = 20.0
margin_right = 120.0
@@ -63,6 +69,10 @@ flat = false
[node name="Button_FixedSize" type="Button" parent="Control"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 20.0
margin_top = 60.0
margin_right = 120.0
@@ -81,6 +91,10 @@ flat = false
[node name="Button_Minimized" type="Button" parent="Control"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 20.0
margin_top = 100.0
margin_right = 120.0
@@ -99,6 +113,10 @@ flat = false
[node name="Button_Maximized" type="Button" parent="Control"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 20.0
margin_top = 140.0
margin_right = 120.0
@@ -117,6 +135,10 @@ flat = false
[node name="Button_MoveTo" type="Button" parent="Control"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 20.0
margin_top = 178.0
margin_right = 120.0
@@ -135,6 +157,10 @@ flat = false
[node name="Button_Resize" type="Button" parent="Control"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 20.0
margin_top = 218.0
margin_right = 120.0
@@ -153,6 +179,10 @@ flat = false
[node name="Button_Screen0" type="Button" parent="Control"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 20.0
margin_top = 258.0
margin_right = 120.0
@@ -171,6 +201,10 @@ flat = false
[node name="Button_Screen1" type="Button" parent="Control"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 20.0
margin_top = 298.0
margin_right = 120.0
@@ -189,12 +223,14 @@ flat = false
[node name="Button_MouseModeVisible" type="Button" parent="Control"]
anchor_top = 1
anchor_bottom = 1
anchor_left = 0.0
anchor_top = 1.0
anchor_right = 0.0
anchor_bottom = 1.0
margin_left = 20.0
margin_top = 221.0
margin_top = -221.0
margin_right = 225.0
margin_bottom = 196.0
margin_bottom = -196.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 0
@@ -210,12 +246,14 @@ align = 0
[node name="Button_MouseModeHidden" type="Button" parent="Control"]
anchor_top = 1
anchor_bottom = 1
anchor_left = 0.0
anchor_top = 1.0
anchor_right = 0.0
anchor_bottom = 1.0
margin_left = 20.0
margin_top = 186.0
margin_top = -186.0
margin_right = 225.0
margin_bottom = 161.0
margin_bottom = -161.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 0
@@ -231,12 +269,14 @@ align = 0
[node name="Button_MouseModeCaptured" type="Button" parent="Control"]
anchor_top = 1
anchor_bottom = 1
anchor_left = 0.0
anchor_top = 1.0
anchor_right = 0.0
anchor_bottom = 1.0
margin_left = 20.0
margin_top = 151.0
margin_top = -151.0
margin_right = 225.0
margin_bottom = 126.0
margin_bottom = -126.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 0
@@ -252,11 +292,13 @@ align = 0
[node name="Label_Mode" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 140.0
margin_right = 20.0
margin_right = -20.0
margin_bottom = 153.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -270,11 +312,13 @@ max_lines_visible = -1
[node name="Label_Position" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 60.0
margin_right = 20.0
margin_right = -20.0
margin_bottom = 73.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -289,11 +333,13 @@ max_lines_visible = -1
[node name="Label_Size" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 100.0
margin_right = 20.0
margin_right = -20.0
margin_bottom = 113.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -308,11 +354,13 @@ max_lines_visible = -1
[node name="Label_MousePosition" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 220.0
margin_right = 20.0
margin_right = -20.0
margin_bottom = 153.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -326,11 +374,13 @@ max_lines_visible = -1
[node name="Label_Screen_Count" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
margin_top = 300.0
margin_right = 20.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 320.0
margin_right = -20.0
margin_bottom = 317.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -345,11 +395,13 @@ max_lines_visible = -1
[node name="Label_Screen_Current" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 20.0
margin_right = 20.0
margin_right = -20.0
margin_bottom = 40.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -364,11 +416,13 @@ max_lines_visible = -1
[node name="Label_Screen0_Resolution" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 340.0
margin_right = 16.0
margin_right = -16.0
margin_bottom = 353.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -383,11 +437,13 @@ max_lines_visible = -1
[node name="Label_Screen0_Position" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 380.0
margin_right = 16.0
margin_right = -16.0
margin_bottom = 396.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -402,11 +458,13 @@ max_lines_visible = -1
[node name="Label_Screen0_DPI" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 416.0
margin_right = 16.0
margin_right = -16.0
margin_bottom = 432.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -421,11 +479,13 @@ max_lines_visible = -1
[node name="Label_Screen1_Resolution" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 451.0
margin_right = 16.0
margin_right = -16.0
margin_bottom = 467.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -440,11 +500,13 @@ max_lines_visible = -1
[node name="Label_Screen1_Position" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 489.0
margin_right = 16.0
margin_right = -16.0
margin_bottom = 505.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -459,11 +521,13 @@ max_lines_visible = -1
[node name="Label_Screen1_DPI" type="Label" parent="Control"]
anchor_left = 1
anchor_right = 1
margin_left = 140.0
anchor_left = 1.0
anchor_top = 0.0
anchor_right = 1.0
anchor_bottom = 0.0
margin_left = -140.0
margin_top = 524.0
margin_right = 16.0
margin_right = -16.0
margin_bottom = 540.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
@@ -478,12 +542,14 @@ max_lines_visible = -1
[node name="Label_KeyInfo" type="Label" parent="Control"]
anchor_top = 1
anchor_bottom = 1
anchor_left = 0.0
anchor_top = 1.0
anchor_right = 0.0
anchor_bottom = 1.0
margin_left = 20.0
margin_top = 122.0
margin_top = -122.0
margin_right = 286.0
margin_bottom = 63.0
margin_bottom = -63.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 2
@@ -499,12 +565,14 @@ max_lines_visible = -1
[node name="Label_MouseModeCaptured_KeyInfo" type="Label" parent="Control"]
anchor_top = 1
anchor_bottom = 1
anchor_left = 0.0
anchor_top = 1.0
anchor_right = 0.0
anchor_bottom = 1.0
margin_left = 20.0
margin_top = 65.0
margin_top = -65.0
margin_right = 286.0
margin_bottom = 11.0
margin_bottom = -11.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 2
@@ -520,12 +588,14 @@ max_lines_visible = -1
[node name="Label_MouseModes" type="Label" parent="Control"]
anchor_top = 1
anchor_bottom = 1
anchor_left = 0.0
anchor_top = 1.0
anchor_right = 0.0
anchor_bottom = 1.0
margin_left = 20.0
margin_top = 249.0
margin_top = -249.0
margin_right = 286.0
margin_bottom = 227.0
margin_bottom = -227.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 2
@@ -540,6 +610,10 @@ max_lines_visible = -1
[node name="ImplementationDialog" type="AcceptDialog" parent="Control"]
visible = false
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 200.0
margin_top = 100.0
margin_right = 600.0
@@ -556,6 +630,10 @@ dialog_hide_on_ok = true
[node name="Text" type="Label" parent="Control/ImplementationDialog"]
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 8.0
margin_top = 8.0
margin_right = 392.0