game: add godot project
This commit is contained in:
65
scenes/enemies/enemy.tscn
Normal file
65
scenes/enemies/enemy.tscn
Normal file
@@ -0,0 +1,65 @@
|
||||
[gd_scene load_steps=7 format=3 uid="uid://bn8c0cgecvjxl"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://5x5wimok8uw2" path="res://assets/sprites/roguelikeChar_transparent.png" id="1_6xk8f"]
|
||||
[ext_resource type="Script" uid="uid://ctigdofipl4q5" path="res://scenes/enemies/enemy.gd" id="1_8e3ao"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_6xk8f"]
|
||||
radius = 6.7082
|
||||
|
||||
[sub_resource type="Animation" id="Animation_8e3ao"]
|
||||
resource_name = "jump"
|
||||
length = 0.7
|
||||
loop_mode = 1
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("Sprite2D:position")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0, 0.3),
|
||||
"transitions": PackedFloat32Array(1, 1),
|
||||
"update": 0,
|
||||
"values": [Vector2(0, 0), Vector2(0, -7)]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_38ino"]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("Sprite2D:position")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [Vector2(0, 0)]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_38ino"]
|
||||
_data = {
|
||||
&"RESET": SubResource("Animation_38ino"),
|
||||
&"jump": SubResource("Animation_8e3ao")
|
||||
}
|
||||
|
||||
[node name="Enemy" type="CharacterBody2D" groups=["damagable", "enemy"]]
|
||||
collision_layer = 2
|
||||
script = ExtResource("1_8e3ao")
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
texture = ExtResource("1_6xk8f")
|
||||
region_enabled = true
|
||||
region_rect = Rect2(17, 53, 16, 14)
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
shape = SubResource("CircleShape2D_6xk8f")
|
||||
|
||||
[node name="ContactDamageCD" type="Timer" parent="."]
|
||||
one_shot = true
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
&"": SubResource("AnimationLibrary_38ino")
|
||||
}
|
Reference in New Issue
Block a user