added C#
This commit is contained in:
parent
ab79ace226
commit
00b76b6b25
63 changed files with 1172 additions and 1548 deletions
195
src/creatures/birb/birb.tscn
Normal file
195
src/creatures/birb/birb.tscn
Normal file
|
|
@ -0,0 +1,195 @@
|
|||
[gd_scene format=3 uid="uid://bosbrhc3oprau"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://daowp76saltic" path="res://src/creatures/birb/Birb.cs" id="1_lyo8d"]
|
||||
[ext_resource type="SpriteFrames" uid="uid://cyf7ij04grglc" path="res://src/creatures/birb/birb.aseprite" id="2_ba6cv"]
|
||||
|
||||
[sub_resource type="CapsuleShape2D" id="CapsuleShape2D_feb5d"]
|
||||
radius = 5.0
|
||||
height = 14.0
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_lyo8d"]
|
||||
radius = 52.0
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_ba6cv"]
|
||||
radius = 110.0
|
||||
|
||||
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_lyo8d"]
|
||||
bg_color = Color(0.15, 0.15, 0.15, 0.34509805)
|
||||
|
||||
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_ba6cv"]
|
||||
bg_color = Color(0.73, 0.10949998, 0.14052509, 0.8666667)
|
||||
|
||||
[sub_resource type="Animation" id="Animation_lyo8d"]
|
||||
length = 0.001
|
||||
step = 0.1
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("BodySprite:animation")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [&"idle"]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("BodySprite:frame")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [0]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_ba6cv"]
|
||||
resource_name = "idle"
|
||||
loop_mode = 1
|
||||
step = 0.1
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("BodySprite:animation")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [&"idle"]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("BodySprite:frame")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [0]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_1i6dk"]
|
||||
resource_name = "prepare_attack"
|
||||
step = 0.1
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("BodySprite:animation")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [&"prepare_attack"]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("BodySprite:frame")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [0]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_3ly8m"]
|
||||
resource_name = "stab"
|
||||
step = 0.1
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("BodySprite:animation")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [&"stab"]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("BodySprite:frame")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [0]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_1i6dk"]
|
||||
_data = {
|
||||
&"RESET": SubResource("Animation_lyo8d"),
|
||||
&"idle": SubResource("Animation_ba6cv"),
|
||||
&"prepare_attack": SubResource("Animation_1i6dk"),
|
||||
&"stab": SubResource("Animation_3ly8m")
|
||||
}
|
||||
|
||||
[node name="Birb" type="CharacterBody2D" unique_id=428810294]
|
||||
collision_layer = 4
|
||||
script = ExtResource("1_lyo8d")
|
||||
metadata/_edit_group_ = true
|
||||
|
||||
[node name="BodySprite" type="AnimatedSprite2D" parent="." unique_id=581143480]
|
||||
unique_name_in_owner = true
|
||||
position = Vector2(2, -4)
|
||||
sprite_frames = ExtResource("2_ba6cv")
|
||||
animation = &"idle"
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="." unique_id=1744954023]
|
||||
position = Vector2(0, 1)
|
||||
shape = SubResource("CapsuleShape2D_feb5d")
|
||||
|
||||
[node name="Detection" type="Area2D" parent="." unique_id=151830843]
|
||||
collision_layer = 0
|
||||
collision_mask = 2
|
||||
monitorable = false
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Detection" unique_id=1217467707]
|
||||
shape = SubResource("CircleShape2D_lyo8d")
|
||||
debug_color = Color(0, 0.6, 0.69803923, 0.16862746)
|
||||
|
||||
[node name="Chase" type="Area2D" parent="." unique_id=172000915]
|
||||
collision_layer = 0
|
||||
collision_mask = 2
|
||||
monitorable = false
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="Chase" unique_id=567870323]
|
||||
shape = SubResource("CircleShape2D_ba6cv")
|
||||
debug_color = Color(0, 0.6, 0.69803923, 0)
|
||||
|
||||
[node name="HealthBar" type="ProgressBar" parent="." unique_id=369348156]
|
||||
unique_name_in_owner = true
|
||||
anchors_preset = 5
|
||||
anchor_left = 0.5
|
||||
anchor_right = 0.5
|
||||
offset_left = -10.0
|
||||
offset_top = -12.0
|
||||
offset_right = 10.0
|
||||
offset_bottom = -10.0
|
||||
grow_horizontal = 2
|
||||
theme_override_styles/background = SubResource("StyleBoxFlat_lyo8d")
|
||||
theme_override_styles/fill = SubResource("StyleBoxFlat_ba6cv")
|
||||
value = 50.0
|
||||
show_percentage = false
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="." unique_id=695394949]
|
||||
libraries/ = SubResource("AnimationLibrary_1i6dk")
|
||||
|
||||
[connection signal="body_entered" from="Detection" to="." method="OnDetectionBodyEntered"]
|
||||
[connection signal="body_exited" from="Chase" to="." method="OnChaseBodyExited"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue