Interaction wheel

do interaction
This commit is contained in:
2024-03-01 14:39:48 -06:00
parent 50093e5937
commit abde90e75f
13 changed files with 216 additions and 90 deletions

View File

@@ -1,51 +1,95 @@
[gd_scene load_steps=7 format=3 uid="uid://dkvcye4mhvshd"]
[gd_scene load_steps=12 format=3 uid="uid://dkvcye4mhvshd"]
[ext_resource type="Script" path="res://scripts/player.gd" id="1_j0htm"]
[ext_resource type="Texture2D" uid="uid://n806c03hgaq1" path="res://assets/scifi_tilesheet@2.png" id="1_vqdy1"]
[sub_resource type="AtlasTexture" id="AtlasTexture_8yvc7"]
[sub_resource type="AtlasTexture" id="AtlasTexture_rbmjr"]
atlas = ExtResource("1_vqdy1")
region = Rect2(640, 192, 64, 64)
region = Rect2(832, 640, 64, 64)
[sub_resource type="AtlasTexture" id="AtlasTexture_xx5oc"]
atlas = ExtResource("1_vqdy1")
region = Rect2(832, 640, 64, 64)
[sub_resource type="AtlasTexture" id="AtlasTexture_2ckq3"]
atlas = ExtResource("1_vqdy1")
region = Rect2(896, 704, 64, 64)
[sub_resource type="AtlasTexture" id="AtlasTexture_vet2c"]
atlas = ExtResource("1_vqdy1")
region = Rect2(960, 704, 64, 64)
[sub_resource type="AtlasTexture" id="AtlasTexture_fqxfq"]
atlas = ExtResource("1_vqdy1")
region = Rect2(832, 640, 64, 64)
[sub_resource type="AtlasTexture" id="AtlasTexture_03ery"]
atlas = ExtResource("1_vqdy1")
region = Rect2(896, 640, 64, 64)
[sub_resource type="AtlasTexture" id="AtlasTexture_ix8o6"]
atlas = ExtResource("1_vqdy1")
region = Rect2(960, 640, 64, 64)
[sub_resource type="SpriteFrames" id="SpriteFrames_tj1nq"]
animations = [{
"frames": [{
"duration": 1.0,
"texture": SubResource("AtlasTexture_rbmjr")
}],
"loop": true,
"name": &"default",
"speed": 5.0
}, {
"frames": [{
"duration": 1.0,
"texture": SubResource("AtlasTexture_xx5oc")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_2ckq3")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_xx5oc")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_vet2c")
}],
"loop": true,
"name": &"interact",
"speed": 5.0
}, {
"frames": [{
"duration": 1.0,
"texture": SubResource("AtlasTexture_fqxfq")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_03ery")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_fqxfq")
}, {
"duration": 1.0,
"texture": SubResource("AtlasTexture_ix8o6")
}],
"loop": true,
"name": &"walk",
"speed": 5.0
}]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_jav3v"]
size = Vector2(40, 45)
[sub_resource type="Animation" id="Animation_47lv4"]
resource_name = "walk"
length = 1.2
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.2, 0.4, 0.6, 0.8, 1, 1.2),
"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1),
"update": 0,
"values": [Vector2(0, 0), Vector2(0, -1), Vector2(0, -2), Vector2(0, -1), Vector2(0, 0), Vector2(0, 1), Vector2(0, 0)]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_ditnu"]
_data = {
"walk": SubResource("Animation_47lv4")
}
[node name="Player" type="CharacterBody2D"]
motion_mode = 1
script = ExtResource("1_j0htm")
[node name="Sprite2D" type="Sprite2D" parent="."]
texture = SubResource("AtlasTexture_8yvc7")
[node name="Sprite" type="AnimatedSprite2D" parent="."]
sprite_frames = SubResource("SpriteFrames_tj1nq")
frame_progress = 0.850199
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
shape = SubResource("RectangleShape2D_jav3v")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
libraries = {
"": SubResource("AnimationLibrary_ditnu")
}
[node name="Camera2D" type="Camera2D" parent="."]
[node name="InteractionTimer" type="Timer" parent="."]