[gd_scene load_steps=29 format=3 uid="uid://dvqap2uhcah63"] [ext_resource type="Script" path="res://Items/Weapons/Sword.cs" id="1_mlo73"] [ext_resource type="Script" path="res://Utils/ScenePath.cs" id="2_g8hkw"] [ext_resource type="Script" path="res://Items/ItemMetadata.cs" id="2_gy7e7"] [ext_resource type="Script" path="res://State/Weapon/WeaponStateMachine.cs" id="2_vwirq"] [ext_resource type="Script" path="res://State/Weapon/SwordIdleState.cs" id="3_nw6r0"] [ext_resource type="Texture2D" uid="uid://dp7osg05ip5oo" path="res://Assets/Sprites/sword.png" id="3_r75ni"] [ext_resource type="PackedScene" uid="uid://du5vhccg75nrq" path="res://BoundingBoxes/Hitbox.tscn" id="3_up3ob"] [ext_resource type="Script" path="res://State/Weapon/SwordAnticipateState.cs" id="4_j3cud"] [ext_resource type="PackedScene" uid="uid://cojxmcin13ihm" path="res://Utils/Trail.tscn" id="4_pt6lq"] [ext_resource type="Script" path="res://State/Weapon/SwordAttackState.cs" id="5_hmisb"] [ext_resource type="AudioStream" uid="uid://c4n7ioxpukdwi" path="res://Assets/Sounds/parry.wav" id="6_8nxjm"] [ext_resource type="Material" uid="uid://cbfaqolx1ydvv" path="res://Assets/Sprites/Particles/ParryParticles.tres" id="8_10gir"] [ext_resource type="Texture2D" uid="uid://d75jkoev5v3w" path="res://Assets/Sprites/Particles/circle-64.png" id="9_o34ry"] [ext_resource type="Shape2D" uid="uid://dw4e4r2yxwk1b" path="res://Items/Weapons/SwordCollisionShape.tres" id="9_wsprl"] [ext_resource type="Texture2D" uid="uid://cmvh6pc71ir1m" path="res://Assets/Sprites/sword-swing-large.png" id="10_672jv"] [ext_resource type="AudioStream" uid="uid://qvthq6tppp63" path="res://Assets/Sounds/whoosh.wav" id="10_mfnl7"] [sub_resource type="Resource" id="Resource_qqiwa"] script = ExtResource("2_g8hkw") Path = "res://Items/Weapons/Sword.tscn" [sub_resource type="Resource" id="Resource_advps"] script = ExtResource("2_gy7e7") Instance = SubResource("Resource_qqiwa") Name = "The Fool's Sword" Description = "The Top Right's Sword" [sub_resource type="Environment" id="Environment_72txp"] background_mode = 3 glow_enabled = true glow_hdr_threshold = 1.42 [sub_resource type="Curve" id="Curve_4cxtp"] _data = [Vector2(0.00687286, 1), 0.0, 0.0, 0, 0, Vector2(0.879725, 0.190909), -2.93145, -2.93145, 0, 0, Vector2(1, 0.0454545), 0.0483926, 0.0, 0, 0] point_count = 3 [sub_resource type="Gradient" id="Gradient_2ablm"] offsets = PackedFloat32Array(0.835938, 0.992188) colors = PackedColorArray(1, 1, 1, 0.498039, 1, 1, 1, 0) [sub_resource type="Animation" id="Animation_b7327"] length = 0.001 tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("Anchor:rotation") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [-1.5708] } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true tracks/1/path = NodePath("SwingSprite:frame") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [0] } tracks/2/type = "value" tracks/2/imported = false tracks/2/enabled = true tracks/2/path = NodePath("Anchor:position") tracks/2/interp = 1 tracks/2/loop_wrap = true tracks/2/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [Vector2(0, 0)] } tracks/3/type = "value" tracks/3/imported = false tracks/3/enabled = true tracks/3/path = NodePath("Anchor/Node2D:rotation") tracks/3/interp = 1 tracks/3/loop_wrap = true tracks/3/keys = { "times": PackedFloat32Array(0, 0.0001, 0.0002), "transitions": PackedFloat32Array(1, 1, 1), "update": 1, "values": [0.0, 0.0, 0.0] } tracks/4/type = "value" tracks/4/imported = false tracks/4/enabled = true tracks/4/path = NodePath("SwingSprite:modulate") tracks/4/interp = 1 tracks/4/loop_wrap = true tracks/4/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 0, "values": [Color(2, 2, 2, 1)] } tracks/5/type = "value" tracks/5/imported = false tracks/5/enabled = true tracks/5/path = NodePath("Anchor/Node2D/Sprite2D:visible") tracks/5/interp = 1 tracks/5/loop_wrap = true tracks/5/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [true] } [sub_resource type="Animation" id="Animation_ameas"] resource_name = "anticipate" length = 0.1 tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("Anchor:rotation") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(0.933033), "update": 1, "values": [-2.35619] } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true tracks/1/path = NodePath("Anchor/Node2D/Sprite2D:visible") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [true] } [sub_resource type="Animation" id="Animation_bj2ky"] resource_name = "anticipate_alternate" length = 0.1 tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("Anchor:rotation") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 1, "values": [2.35619] } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true tracks/1/path = NodePath("Anchor/Node2D:rotation") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 0, "values": [3.14159] } [sub_resource type="Animation" id="Animation_b8r8j"] resource_name = "anticipate_bot" [sub_resource type="Animation" id="Animation_6jphj"] resource_name = "attack" step = 0.05 tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("Anchor:rotation") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0, 0.15, 0.35), "transitions": PackedFloat32Array(1, 1, 1), "update": 1, "values": [-1.5708, 1.5708, 1.5708] } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true tracks/1/path = NodePath("SwingSprite:frame") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/keys = { "times": PackedFloat32Array(0.1, 0.3, 0.35), "transitions": PackedFloat32Array(1, 1, 1), "update": 1, "values": [1, 2, 0] } tracks/2/type = "value" tracks/2/imported = false tracks/2/enabled = false tracks/2/path = NodePath("Anchor:position") tracks/2/interp = 1 tracks/2/loop_wrap = true tracks/2/keys = { "times": PackedFloat32Array(0, 0.1, 0.35), "transitions": PackedFloat32Array(1, 1, 1), "update": 1, "values": [Vector2(0, 0), Vector2(0, -4), Vector2(0, 0)] } tracks/3/type = "value" tracks/3/imported = false tracks/3/enabled = true tracks/3/path = NodePath("Anchor/Node2D:rotation") tracks/3/interp = 1 tracks/3/loop_wrap = true tracks/3/keys = { "times": PackedFloat32Array(0, 0.15), "transitions": PackedFloat32Array(1, 1), "update": 1, "values": [0.0, 2.35619] } tracks/4/type = "method" tracks/4/imported = false tracks/4/enabled = true tracks/4/path = NodePath("SwingSound") tracks/4/interp = 1 tracks/4/loop_wrap = true tracks/4/keys = { "times": PackedFloat32Array(0.1), "transitions": PackedFloat32Array(1), "values": [{ "args": [0.0], "method": &"play" }] } tracks/5/type = "value" tracks/5/imported = false tracks/5/enabled = true tracks/5/path = NodePath("Anchor/Node2D/Sprite2D:visible") tracks/5/interp = 1 tracks/5/loop_wrap = true tracks/5/keys = { "times": PackedFloat32Array(0, 0.35), "transitions": PackedFloat32Array(1, 1), "update": 1, "values": [true, false] } [sub_resource type="Animation" id="Animation_pclfs"] resource_name = "attack_alternate" step = 0.05 tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("Anchor:rotation") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0, 0.15, 0.35), "transitions": PackedFloat32Array(1, 1, 1), "update": 1, "values": [1.5708, -1.5708, -1.5708] } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true tracks/1/path = NodePath("SwingSprite:frame") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/keys = { "times": PackedFloat32Array(0.1, 0.3, 0.35), "transitions": PackedFloat32Array(1, 1, 1), "update": 1, "values": [3, 4, 0] } tracks/2/type = "value" tracks/2/imported = false tracks/2/enabled = false tracks/2/path = NodePath("Anchor:position") tracks/2/interp = 1 tracks/2/loop_wrap = true tracks/2/keys = { "times": PackedFloat32Array(0, 0.1, 0.35), "transitions": PackedFloat32Array(1, 1, 1), "update": 1, "values": [Vector2(0, 0), Vector2(0, -4), Vector2(0, 0)] } tracks/3/type = "value" tracks/3/imported = false tracks/3/enabled = true tracks/3/path = NodePath("Anchor/Node2D:rotation") tracks/3/interp = 1 tracks/3/loop_wrap = true tracks/3/keys = { "times": PackedFloat32Array(0, 0.15), "transitions": PackedFloat32Array(1, 1), "update": 1, "values": [3.14159, 0.785398] } [sub_resource type="AnimationLibrary" id="AnimationLibrary_tao4k"] _data = { "RESET": SubResource("Animation_b7327"), "anticipate": SubResource("Animation_ameas"), "anticipate_alternate": SubResource("Animation_bj2ky"), "anticipate_bot": SubResource("Animation_b8r8j"), "attack": SubResource("Animation_6jphj"), "attack_alternate": SubResource("Animation_pclfs") } [node name="Sword" type="Node2D" node_paths=PackedStringArray("Hitbox", "AnimationPlayer", "ParryParticles", "StateMachine", "Anchor", "HandAnchor")] y_sort_enabled = true texture_filter = 3 script = ExtResource("1_mlo73") Hitbox = NodePath("Hitbox") AnimationPlayer = NodePath("AnimationPlayer") AttackTime = 0.2 AttackAnimationDuration = 0.75 ParryParticles = NodePath("Anchor/Node2D/Sprite2D/ParryParticles") NPCAnticipateTime = 0.3 StateMachine = NodePath("State") Anchor = NodePath("Anchor") Damage = 20.0 UseTime = 0.55 Knockback = 64.0 ShouldHideIdle = true PlayerLevelGain = 1.0 HandAnchor = NodePath("Anchor/Node2D/Sprite2D/Hand") Metadata = SubResource("Resource_advps") [node name="State" type="Node" parent="." node_paths=PackedStringArray("InitialState")] script = ExtResource("2_vwirq") InitialState = NodePath("Idle") UsedItemStates = Array[NodePath]([NodePath("Attack")]) DeusedItemStates = Array[NodePath]([NodePath("Idle")]) [node name="Idle" type="Node" parent="State" node_paths=PackedStringArray("UseState", "Sword")] script = ExtResource("3_nw6r0") UseState = NodePath("../Anticipate") Sword = NodePath("../..") [node name="Anticipate" type="Node" parent="State" node_paths=PackedStringArray("Sword", "AttackState")] script = ExtResource("4_j3cud") Sword = NodePath("../..") AttackState = NodePath("../Attack") [node name="Attack" type="Node" parent="State" node_paths=PackedStringArray("Sword", "IdleState")] script = ExtResource("5_hmisb") Sword = NodePath("../..") IdleState = NodePath("../Idle") [node name="WorldEnvironment" type="WorldEnvironment" parent="."] environment = SubResource("Environment_72txp") [node name="Anchor" type="Node2D" parent="."] y_sort_enabled = true rotation = -1.5708 [node name="Trail" parent="Anchor" instance=ExtResource("4_pt6lq")] position = Vector2(2.40734, -0.55655) rotation = 0.945464 width_curve = SubResource("Curve_4cxtp") gradient = SubResource("Gradient_2ablm") [node name="Node2D" type="Node2D" parent="Anchor"] y_sort_enabled = true position = Vector2(8, 0) [node name="Sprite2D" type="Sprite2D" parent="Anchor/Node2D"] y_sort_enabled = true position = Vector2(0, -8) texture = ExtResource("3_r75ni") [node name="Hand" type="Sprite2D" parent="Anchor/Node2D/Sprite2D"] position = Vector2(-2.52724e-05, 7) rotation = 1.5708 [node name="ParryParticles" type="GPUParticles2D" parent="Anchor/Node2D/Sprite2D"] modulate = Color(1.2, 1.2, 1.2, 1) position = Vector2(0, -3) rotation = 0.785398 emitting = false amount = 16 process_material = ExtResource("8_10gir") texture = ExtResource("9_o34ry") lifetime = 2.0 one_shot = true explosiveness = 1.0 fixed_fps = 16 [node name="AnimationPlayer" type="AnimationPlayer" parent="."] libraries = { "": SubResource("AnimationLibrary_tao4k") } [node name="Hitbox" parent="." instance=ExtResource("3_up3ob")] priority = 5 IsDisabled = true [node name="CollisionShape2D" parent="Hitbox" index="0"] position = Vector2(4, 0) rotation = 1.5708 shape = ExtResource("9_wsprl") disabled = true [node name="SwingSprite" type="Sprite2D" parent="."] modulate = Color(2, 2, 2, 1) texture = ExtResource("10_672jv") offset = Vector2(8, 0) hframes = 5 [node name="SwingSound" type="AudioStreamPlayer2D" parent="."] stream = ExtResource("10_mfnl7") [node name="ParrySound" type="AudioStreamPlayer2D" parent="."] stream = ExtResource("6_8nxjm") [editable path="Hitbox"]