-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathswipe_areas_example.tscn
136 lines (108 loc) · 3.62 KB
/
swipe_areas_example.tscn
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
[gd_scene load_steps=10 format=2]
[ext_resource path="res://examples/example.tscn" type="PackedScene" id=1]
[ext_resource path="res://examples/swipe-areas/swipe_areas_example.gd" type="Script" id=2]
[ext_resource path="res://addons/swipe-detector/swipe_detector.gd" type="Script" id=3]
[ext_resource path="res://addons/swipe-detector/icon.png" type="Texture" id=4]
[ext_resource path="res://examples/resources/theme.tres" type="Theme" id=5]
[ext_resource path="res://examples/resources/Trail.tscn" type="PackedScene" id=6]
[ext_resource path="res://examples/resources/spot_green.png" type="Texture" id=7]
[ext_resource path="res://examples/resources/spot_red.png" type="Texture" id=8]
[sub_resource type="RectangleShape2D" id=1]
custom_solver_bias = 0.0
extents = Vector2( 253, 313 )
[node name="SwipeAreasExample" instance=ExtResource( 1 )]
script = ExtResource( 2 )
_sections_unfolded = [ "Pause" ]
[node name="SwipeDetector" type="Node" parent="."]
script = ExtResource( 3 )
__meta__ = {
"_editor_icon": ExtResource( 4 )
}
detect_gesture = true
process_method = "Idle"
distance_threshold = 0.01
duration_threshold = 0.05
limit_duration = false
maximum_duration = -1.0
minimum_points = 2
limit_points = false
maximum_points = -1
pattern_detection_score_threshold = 80
debug_mode = false
[node name="Red" type="Area2D" parent="SwipeDetector"]
input_pickable = true
gravity_vec = Vector2( 0, 1 )
gravity = 98.0
linear_damp = 0.1
angular_damp = 1.0
audio_bus_override = false
audio_bus_name = "Master"
[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="SwipeDetector/Red"]
build_mode = 0
polygon = PoolVector2Array( 960, 0, 512, 0, 512, 640, 960, 640 )
_sections_unfolded = [ "Transform" ]
[node name="Green" type="Area2D" parent="SwipeDetector"]
input_pickable = true
gravity_vec = Vector2( 0, 1 )
gravity = 98.0
linear_damp = 0.1
angular_damp = 1.0
audio_bus_override = false
audio_bus_name = "Master"
[node name="CollisionShape2D" type="CollisionShape2D" parent="SwipeDetector/Green"]
position = Vector2( 256, 316 )
shape = SubResource( 1 )
_sections_unfolded = [ "Transform" ]
[node name="Label1" type="Label" parent="."]
modulate = Color( 0.909804, 0.290196, 0.372549, 1 )
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 672.0
margin_top = 297.0
margin_right = 824.0
margin_bottom = 348.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 2
size_flags_horizontal = 2
size_flags_vertical = 0
theme = ExtResource( 5 )
text = "Red
Area"
align = 1
percent_visible = 1.0
lines_skipped = 0
max_lines_visible = -1
_sections_unfolded = [ "Theme", "Visibility" ]
[node name="Label2" type="Label" parent="."]
modulate = Color( 0.6, 0.721569, 0.596078, 1 )
anchor_left = 0.0
anchor_top = 0.0
anchor_right = 0.0
anchor_bottom = 0.0
margin_left = 175.0
margin_top = 284.0
margin_right = 327.0
margin_bottom = 335.0
rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false
mouse_filter = 2
size_flags_horizontal = 2
size_flags_vertical = 0
theme = ExtResource( 5 )
text = "Green
Area"
align = 1
percent_visible = 1.0
lines_skipped = 0
max_lines_visible = -1
_sections_unfolded = [ "Material", "Theme", "Visibility" ]
[node name="GreenTrail" parent="." instance=ExtResource( 6 )]
texture = ExtResource( 7 )
[node name="RedTrail" parent="." instance=ExtResource( 6 )]
texture = ExtResource( 8 )
[connection signal="swipe_ended" from="SwipeDetector" to="." method="_on_SwipeDetector_swipe_ended"]
[connection signal="swipe_started" from="SwipeDetector" to="." method="_on_SwipeDetector_swipe_started"]
[connection signal="swipe_updated" from="SwipeDetector" to="." method="_on_SwipeDetector_swipe_updated"]