[gd_scene load_steps=23 format=2] [ext_resource path="res://src/StateMachines/FlyerStateMachine.gd" type="Script" id=1] [ext_resource path="res://src/Actors/Enemies/Flyer.gd" type="Script" id=2] [ext_resource path="res://assets/meta/new_dynamicfont.tres" type="DynamicFont" id=3] [ext_resource path="res://assets/enemy/flyer-sheet.png" type="Texture" id=4] [sub_resource type="Animation" id=33] length = 0.001 tracks/0/type = "value" tracks/0/path = NodePath(".:frame") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/imported = false tracks/0/enabled = true tracks/0/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 0, "values": [ 0 ] } [sub_resource type="Animation" id=36] resource_name = "hunting" length = 1.62 loop = true step = 0.01 tracks/0/type = "value" tracks/0/path = NodePath(".:frame") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/imported = false tracks/0/enabled = true tracks/0/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ 0 ] } tracks/1/type = "value" tracks/1/path = NodePath(".:scale") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/imported = false tracks/1/enabled = true tracks/1/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ Vector2( -1, 1 ) ] } [sub_resource type="Animation" id=38] resource_name = "huntingLeft" length = 0.042 loop = true tracks/0/type = "value" tracks/0/path = NodePath(".:frame") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/imported = false tracks/0/enabled = true tracks/0/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ 0 ] } tracks/1/type = "value" tracks/1/path = NodePath(".:scale") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/imported = false tracks/1/enabled = true tracks/1/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ Vector2( 1, 1 ) ] } [sub_resource type="Animation" id=35] resource_name = "searching" length = 1.62 loop = true step = 0.01 tracks/0/type = "value" tracks/0/path = NodePath(".:frame") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/imported = false tracks/0/enabled = true tracks/0/keys = { "times": PoolRealArray( 0.02 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ 1 ] } tracks/1/type = "value" tracks/1/path = NodePath(".:scale") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/imported = false tracks/1/enabled = true tracks/1/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ Vector2( -1, 1 ) ] } [sub_resource type="Animation" id=34] resource_name = "searchingLeft" length = 1.62 loop = true step = 0.01 tracks/0/type = "value" tracks/0/path = NodePath(".:frame") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/imported = false tracks/0/enabled = true tracks/0/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ 1 ] } tracks/1/type = "value" tracks/1/path = NodePath(".:scale") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/imported = false tracks/1/enabled = true tracks/1/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ Vector2( 1, 1 ) ] } [sub_resource type="AnimationNodeAnimation" id=46] animation = "huntingLeft" [sub_resource type="AnimationNodeAnimation" id=47] animation = "hunting" [sub_resource type="AnimationNodeBlendSpace1D" id=23] blend_point_0/node = SubResource( 46 ) blend_point_0/pos = -1.0 blend_point_1/node = SubResource( 47 ) blend_point_1/pos = 1.0 min_space = -1.18 max_space = 1.15 [sub_resource type="AnimationNodeAnimation" id=42] animation = "searchingLeft" [sub_resource type="AnimationNodeAnimation" id=43] animation = "searching" [sub_resource type="AnimationNodeBlendSpace1D" id=9] blend_point_0/node = SubResource( 42 ) blend_point_0/pos = -1.0 blend_point_1/node = SubResource( 43 ) blend_point_1/pos = 1.0 min_space = -2.0 max_space = 2.0 snap = 1.0 [sub_resource type="AnimationNodeStateMachineTransition" id=27] [sub_resource type="AnimationNodeStateMachineTransition" id=32] [sub_resource type="AnimationNodeStateMachine" id=50] states/hunting/node = SubResource( 23 ) states/hunting/position = Vector2( 184.952, -12 ) states/searching/node = SubResource( 9 ) states/searching/position = Vector2( -52.0952, 102.762 ) transitions = [ "searching", "hunting", SubResource( 27 ), "hunting", "searching", SubResource( 32 ) ] start_node = "searching" graph_offset = Vector2( -333, -104 ) [sub_resource type="AnimationNodeStateMachinePlayback" id=51] [sub_resource type="RectangleShape2D" id=1] extents = Vector2( 10, 7.5 ) [sub_resource type="RectangleShape2D" id=2] extents = Vector2( 11.4286, 5.12039 ) [sub_resource type="RectangleShape2D" id=52] extents = Vector2( 15.7143, 12.1429 ) [node name="Flyer" type="KinematicBody2D" groups=["frogfood", "harmful"]] collision_layer = 258 collision_mask = 25 script = ExtResource( 2 ) vision_distance = 8.0 loose_target_seconds = 5.0 patrolling = true acceleration = 70 max_speed = 80 weight = 0.3 [node name="Statemachine" type="Node2D" parent="."] script = ExtResource( 1 ) [node name="StateLabel" type="Label" parent="."] visible = false show_behind_parent = true margin_left = -36.0 margin_top = -30.0 margin_right = 37.0 margin_bottom = -16.0 custom_colors/font_color = Color( 1, 1, 1, 1 ) custom_colors/font_outline_modulate = Color( 0, 0, 0, 1 ) custom_fonts/font = ExtResource( 3 ) text = "Ihre Werbung" align = 1 valign = 1 [node name="FlyerSprite" type="Sprite" parent="."] unique_name_in_owner = true scale = Vector2( -1, 1 ) texture = ExtResource( 4 ) hframes = 2 [node name="AnimationPlayer" type="AnimationPlayer" parent="FlyerSprite"] anims/RESET = SubResource( 33 ) anims/hunting = SubResource( 36 ) anims/huntingLeft = SubResource( 38 ) anims/searching = SubResource( 35 ) anims/searchingLeft = SubResource( 34 ) [node name="AnimationTree" type="AnimationTree" parent="FlyerSprite"] tree_root = SubResource( 50 ) anim_player = NodePath("../AnimationPlayer") active = true root_motion_track = NodePath(".") parameters/playback = SubResource( 51 ) parameters/hunting/blend_position = -1.04288 parameters/searching/blend_position = 1.2903 [node name="VisibilityEnabler2D" type="VisibilityEnabler2D" parent="."] visible = false position = Vector2( 954, 0 ) scale = Vector2( 10.84, 0.899 ) rect = Rect2( -89, -10, 2, 20 ) process_parent = true physics_process_parent = true [node name="FeelerRayCast" type="RayCast2D" parent="."] visible = false enabled = true cast_to = Vector2( 0, -1 ) collision_mask = 56 collide_with_areas = true [node name="EnemyBody" type="CollisionShape2D" parent="." groups=["harmful"]] position = Vector2( 0, -0.5 ) shape = SubResource( 1 ) [node name="NavigationAgent2D" type="NavigationAgent2D" parent="."] path_desired_distance = 8.0 target_desired_distance = 8.0 [node name="cshape" type="Node2D" parent="."] visible = false position = Vector2( 0, -3.8147e-06 ) scale = Vector2( 0.1, 0.1 ) [node name="pjoint" type="PinJoint2D" parent="cshape"] scale = Vector2( 0.3, 0.3 ) bias = 0.108 softness = 0.1 [node name="StompDetector" type="Area2D" parent="." groups=["weakpoint"]] modulate = Color( 0, 0.0392157, 1, 1 ) position = Vector2( 0, -1.90735e-06 ) scale = Vector2( 0.7, 0.7 ) collision_layer = 2 input_pickable = false [node name="CollisionShape2D" type="CollisionShape2D" parent="StompDetector"] position = Vector2( 6.81196e-07, 1.56134 ) shape = SubResource( 2 ) [node name="DangerousBlockArea" type="Node2D" parent="."] scale = Vector2( 0.7, 0.7 ) [node name="Area2D" type="Area2D" parent="DangerousBlockArea" groups=["frogfood", "harmful"]] collision_layer = 2 collision_mask = 0 monitoring = false [node name="CollisionShape2D" type="CollisionShape2D" parent="DangerousBlockArea/Area2D"] position = Vector2( 5.10897e-07, -0.714285 ) shape = SubResource( 52 ) [node name="PatrolPath" type="Node2D" parent="."] [node name="Position2D2" type="Position2D" parent="PatrolPath"] position = Vector2( 72, 0 ) [node name="Position2D3" type="Position2D" parent="PatrolPath"] position = Vector2( -72, 0 ) [node name="Orientation" type="RayCast2D" parent="."] cast_to = Vector2( -1, 0 ) collision_mask = 0 collide_with_bodies = false [node name="VisionRayCast" type="RayCast2D" parent="."] enabled = true cast_to = Vector2( 0, -1 ) collision_mask = 9 collide_with_areas = true [connection signal="body_entered" from="StompDetector" to="." method="_on_StompDetector_body_entered"]