inching towards better class inheritence and multiplayer compatibility
This commit is contained in:
54
Scenes/Weapons/weapon.tscn
Normal file
54
Scenes/Weapons/weapon.tscn
Normal file
@ -0,0 +1,54 @@
|
||||
[gd_scene load_steps=5 format=3 uid="uid://b7nargdyg28fj"]
|
||||
|
||||
[ext_resource type="Script" path="res://Scripts/Weapons/weapon.gd" id="1_yo2gh"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_5krlx"]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("Sprite3D:texture:region")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [Rect2(0, 0, 64, 64)]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_0rgpe"]
|
||||
resource_name = "shoot"
|
||||
length = 0.15
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("Sprite3D:texture:region")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0, 0.15),
|
||||
"transitions": PackedFloat32Array(0, 0),
|
||||
"update": 0,
|
||||
"values": [Rect2(64, 0, 64, 64), Rect2(0, 0, 64, 64)]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_fs82p"]
|
||||
_data = {
|
||||
"RESET": SubResource("Animation_5krlx"),
|
||||
"shoot": SubResource("Animation_0rgpe")
|
||||
}
|
||||
|
||||
[node name="Weapon" type="Node3D" node_paths=PackedStringArray("animator")]
|
||||
script = ExtResource("1_yo2gh")
|
||||
animator = NodePath("AnimationPlayer")
|
||||
|
||||
[node name="Sprite3D" type="Sprite3D" parent="."]
|
||||
layers = 2
|
||||
billboard = 1
|
||||
texture_filter = 0
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
libraries = {
|
||||
"": SubResource("AnimationLibrary_fs82p")
|
||||
}
|
Reference in New Issue
Block a user