Separate Stele concept from Npc

This commit is contained in:
2026-06-04 23:38:59 -07:00
parent d8b99e07de
commit bb46f0dcd9
11 changed files with 420 additions and 52 deletions
@@ -1,7 +1,7 @@
[gd_scene load_steps=13 format=4 uid="uid://b3owhc620qisb"] [gd_scene load_steps=16 format=4 uid="uid://b3owhc620qisb"]
[ext_resource type="Script" uid="uid://dcqssoikr3pl7" path="res://src/npc/Npc.cs" id="1_c03g6"]
[ext_resource type="Texture2D" uid="uid://dcodsa21o3syb" path="res://src/map/assets/Steles/Steles_C024_C.jpg" id="1_o7s11"] [ext_resource type="Texture2D" uid="uid://dcodsa21o3syb" path="res://src/map/assets/Steles/Steles_C024_C.jpg" id="1_o7s11"]
[ext_resource type="Script" uid="uid://bee0bhxtd4r8s" path="res://src/npc/Stele.cs" id="1_xkojd"]
[ext_resource type="Texture2D" uid="uid://c8nvb5jn8f6k1" path="res://src/map/assets/Steles/Steles_Untitled-1.png" id="2_u6crp"] [ext_resource type="Texture2D" uid="uid://c8nvb5jn8f6k1" path="res://src/map/assets/Steles/Steles_Untitled-1.png" id="2_u6crp"]
[ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="4_xkojd"] [ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="4_xkojd"]
@@ -91,8 +91,44 @@ radius = 1.16748
height = 5.2554 height = 5.2554
radius = 1.941 radius = 1.941
[sub_resource type="Animation" id="Animation_hrxn4"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [1.0]
}
[sub_resource type="Animation" id="Animation_flixp"]
resource_name = "fade_in"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1, 1),
"update": 0,
"values": [1.0, 0.0]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6ihe1"]
_data = {
&"RESET": SubResource("Animation_hrxn4"),
&"fade_in": SubResource("Animation_flixp")
}
[node name="SteleA" type="Node3D"] [node name="SteleA" type="Node3D"]
script = ExtResource("1_c03g6") script = ExtResource("1_xkojd")
[node name="Steles_" type="Node3D" parent="."] [node name="Steles_" type="Node3D" parent="."]
@@ -144,6 +180,12 @@ shape = SubResource("CylinderShape3D_hrxn4")
[node name="FLOWER" type="Sprite3D" parent="."] [node name="FLOWER" type="Sprite3D" parent="."]
transform = Transform3D(0.363695, 0.343112, 1.17177e-08, -0.212973, 0.225749, 0.39202, 0.269014, -0.285151, 0.310355, 0, 0.0524253, 0.964599) transform = Transform3D(0.363695, 0.343112, 1.17177e-08, -0.212973, 0.225749, 0.39202, 0.269014, -0.285151, 0.310355, 0, 0.0524253, 0.964599)
visible = false transparency = 1.0
shaded = true shaded = true
texture = ExtResource("4_xkojd") texture = ExtResource("4_xkojd")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_6ihe1")
}
@@ -1,7 +1,7 @@
[gd_scene load_steps=15 format=4 uid="uid://r5d74jsx8tq6"] [gd_scene load_steps=18 format=4 uid="uid://r5d74jsx8tq6"]
[ext_resource type="Script" uid="uid://bee0bhxtd4r8s" path="res://src/npc/Stele.cs" id="1_4nuqd"]
[ext_resource type="Texture2D" uid="uid://35g2bx4vh3wd" path="res://src/map/assets/Steles/Steles_IMG0031.png" id="1_6obim"] [ext_resource type="Texture2D" uid="uid://35g2bx4vh3wd" path="res://src/map/assets/Steles/Steles_IMG0031.png" id="1_6obim"]
[ext_resource type="Script" uid="uid://dcqssoikr3pl7" path="res://src/npc/Npc.cs" id="1_ochsp"]
[ext_resource type="Texture2D" uid="uid://c8nvb5jn8f6k1" path="res://src/map/assets/Steles/Steles_Untitled-1.png" id="2_ochsp"] [ext_resource type="Texture2D" uid="uid://c8nvb5jn8f6k1" path="res://src/map/assets/Steles/Steles_Untitled-1.png" id="2_ochsp"]
[ext_resource type="Texture2D" uid="uid://bwelhd4sx7mkw" path="res://src/map/assets/Steles/Steles_COPPEROX.jpg" id="3_4nuqd"] [ext_resource type="Texture2D" uid="uid://bwelhd4sx7mkw" path="res://src/map/assets/Steles/Steles_COPPEROX.jpg" id="3_4nuqd"]
[ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="5_4nuqd"] [ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="5_4nuqd"]
@@ -120,8 +120,44 @@ radius = 1.21191
height = 4.34136 height = 4.34136
radius = 1.941 radius = 1.941
[sub_resource type="Animation" id="Animation_hrxn4"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [1.0]
}
[sub_resource type="Animation" id="Animation_flixp"]
resource_name = "fade_in"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1, 1),
"update": 0,
"values": [1.0, 0.0]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6ihe1"]
_data = {
&"RESET": SubResource("Animation_hrxn4"),
&"fade_in": SubResource("Animation_flixp")
}
[node name="SteleB" type="Node3D"] [node name="SteleB" type="Node3D"]
script = ExtResource("1_ochsp") script = ExtResource("1_4nuqd")
[node name="Steles_" type="Node3D" parent="."] [node name="Steles_" type="Node3D" parent="."]
@@ -171,6 +207,12 @@ shape = SubResource("CylinderShape3D_jdh7s")
[node name="FLOWER" type="Sprite3D" parent="."] [node name="FLOWER" type="Sprite3D" parent="."]
transform = Transform3D(0.363695, 0.343112, 3.26848e-08, -0.137431, 0.145675, 0.458139, 0.314387, -0.333246, 0.200271, 0, 0.36902, 0.90642) transform = Transform3D(0.363695, 0.343112, 3.26848e-08, -0.137431, 0.145675, 0.458139, 0.314387, -0.333246, 0.200271, 0, 0.36902, 0.90642)
visible = false transparency = 1.0
shaded = true shaded = true
texture = ExtResource("5_4nuqd") texture = ExtResource("5_4nuqd")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_6ihe1")
}
@@ -1,7 +1,7 @@
[gd_scene load_steps=15 format=4 uid="uid://btjwytsymvxiv"] [gd_scene load_steps=18 format=4 uid="uid://btjwytsymvxiv"]
[ext_resource type="Script" uid="uid://bee0bhxtd4r8s" path="res://src/npc/Stele.cs" id="1_1uk4s"]
[ext_resource type="Texture2D" uid="uid://35g2bx4vh3wd" path="res://src/map/assets/Steles/Steles_IMG0031.png" id="1_mtjg5"] [ext_resource type="Texture2D" uid="uid://35g2bx4vh3wd" path="res://src/map/assets/Steles/Steles_IMG0031.png" id="1_mtjg5"]
[ext_resource type="Script" uid="uid://dcqssoikr3pl7" path="res://src/npc/Npc.cs" id="1_t14ca"]
[ext_resource type="Texture2D" uid="uid://br8l5h7n6t41d" path="res://src/map/assets/Steles/Steles_eye.png" id="2_t14ca"] [ext_resource type="Texture2D" uid="uid://br8l5h7n6t41d" path="res://src/map/assets/Steles/Steles_eye.png" id="2_t14ca"]
[ext_resource type="Texture2D" uid="uid://c8nvb5jn8f6k1" path="res://src/map/assets/Steles/Steles_Untitled-1.png" id="3_1uk4s"] [ext_resource type="Texture2D" uid="uid://c8nvb5jn8f6k1" path="res://src/map/assets/Steles/Steles_Untitled-1.png" id="3_1uk4s"]
[ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="5_1uk4s"] [ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="5_1uk4s"]
@@ -127,8 +127,44 @@ height = 2.8375
height = 2.24425 height = 2.24425
radius = 1.941 radius = 1.941
[sub_resource type="Animation" id="Animation_hrxn4"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [1.0]
}
[sub_resource type="Animation" id="Animation_flixp"]
resource_name = "fade_in"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1, 1),
"update": 0,
"values": [1.0, 0.0]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6ihe1"]
_data = {
&"RESET": SubResource("Animation_hrxn4"),
&"fade_in": SubResource("Animation_flixp")
}
[node name="SteleC" type="Node3D"] [node name="SteleC" type="Node3D"]
script = ExtResource("1_t14ca") script = ExtResource("1_1uk4s")
[node name="Steles_" type="Node3D" parent="."] [node name="Steles_" type="Node3D" parent="."]
@@ -176,6 +212,12 @@ shape = SubResource("CylinderShape3D_wx556")
[node name="FLOWER" type="Sprite3D" parent="."] [node name="FLOWER" type="Sprite3D" parent="."]
transform = Transform3D(0.363695, 0.343112, 1.17177e-08, -0.212973, 0.225749, 0.39202, 0.269014, -0.285151, 0.310355, 0, 0.0524253, 0.645126) transform = Transform3D(0.363695, 0.343112, 1.17177e-08, -0.212973, 0.225749, 0.39202, 0.269014, -0.285151, 0.310355, 0, 0.0524253, 0.645126)
visible = false transparency = 1.0
shaded = true shaded = true
texture = ExtResource("5_1uk4s") texture = ExtResource("5_1uk4s")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_6ihe1")
}
@@ -1,7 +1,7 @@
[gd_scene load_steps=17 format=4 uid="uid://0aqllfpimgq"] [gd_scene load_steps=20 format=4 uid="uid://0aqllfpimgq"]
[ext_resource type="Texture2D" uid="uid://dcodsa21o3syb" path="res://src/map/assets/Steles/Steles_C024_C.jpg" id="1_eu5gg"] [ext_resource type="Texture2D" uid="uid://dcodsa21o3syb" path="res://src/map/assets/Steles/Steles_C024_C.jpg" id="1_eu5gg"]
[ext_resource type="Script" uid="uid://dcqssoikr3pl7" path="res://src/npc/Npc.cs" id="1_xe50d"] [ext_resource type="Script" uid="uid://bee0bhxtd4r8s" path="res://src/npc/Stele.cs" id="1_q5wc4"]
[ext_resource type="Texture2D" uid="uid://dj2upntyeqryx" path="res://src/map/assets/Steles/Steles_COPPWIR.jpg" id="2_xe50d"] [ext_resource type="Texture2D" uid="uid://dj2upntyeqryx" path="res://src/map/assets/Steles/Steles_COPPWIR.jpg" id="2_xe50d"]
[ext_resource type="Texture2D" uid="uid://bwelhd4sx7mkw" path="res://src/map/assets/Steles/Steles_COPPEROX.jpg" id="3_q5wc4"] [ext_resource type="Texture2D" uid="uid://bwelhd4sx7mkw" path="res://src/map/assets/Steles/Steles_COPPEROX.jpg" id="3_q5wc4"]
[ext_resource type="Texture2D" uid="uid://c8nvb5jn8f6k1" path="res://src/map/assets/Steles/Steles_Untitled-1.png" id="4_fpef4"] [ext_resource type="Texture2D" uid="uid://c8nvb5jn8f6k1" path="res://src/map/assets/Steles/Steles_Untitled-1.png" id="4_fpef4"]
@@ -149,8 +149,44 @@ height = 3.0
height = 2.24425 height = 2.24425
radius = 1.941 radius = 1.941
[sub_resource type="Animation" id="Animation_hrxn4"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [1.0]
}
[sub_resource type="Animation" id="Animation_flixp"]
resource_name = "fade_in"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1, 1),
"update": 0,
"values": [1.0, 0.0]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6ihe1"]
_data = {
&"RESET": SubResource("Animation_hrxn4"),
&"fade_in": SubResource("Animation_flixp")
}
[node name="SteleD" type="Node3D"] [node name="SteleD" type="Node3D"]
script = ExtResource("1_xe50d") script = ExtResource("1_q5wc4")
[node name="Steles_" type="Node3D" parent="."] [node name="Steles_" type="Node3D" parent="."]
@@ -200,6 +236,12 @@ shape = SubResource("CylinderShape3D_w60kl")
[node name="FLOWER" type="Sprite3D" parent="."] [node name="FLOWER" type="Sprite3D" parent="."]
transform = Transform3D(0.363695, 0.343112, 3.26848e-08, -0.180433, 0.191257, 0.425282, 0.291839, -0.309346, 0.262936, 0.0436658, 1.33738, 0.480269) transform = Transform3D(0.363695, 0.343112, 3.26848e-08, -0.180433, 0.191257, 0.425282, 0.291839, -0.309346, 0.262936, 0.0436658, 1.33738, 0.480269)
visible = false transparency = 1.0
shaded = true shaded = true
texture = ExtResource("6_q5wc4") texture = ExtResource("6_q5wc4")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_6ihe1")
}
@@ -1,7 +1,7 @@
[gd_scene load_steps=11 format=4 uid="uid://cn13lho2so7sr"] [gd_scene load_steps=14 format=4 uid="uid://cn13lho2so7sr"]
[ext_resource type="Texture2D" uid="uid://bwelhd4sx7mkw" path="res://src/map/assets/Steles/Steles_COPPEROX.jpg" id="1_2erh4"] [ext_resource type="Texture2D" uid="uid://bwelhd4sx7mkw" path="res://src/map/assets/Steles/Steles_COPPEROX.jpg" id="1_2erh4"]
[ext_resource type="Script" uid="uid://dcqssoikr3pl7" path="res://src/npc/Npc.cs" id="1_kuew0"] [ext_resource type="Script" uid="uid://bee0bhxtd4r8s" path="res://src/npc/Stele.cs" id="1_yvxj1"]
[ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="3_yvxj1"] [ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="3_yvxj1"]
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_f3mmc"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_f3mmc"]
@@ -60,9 +60,45 @@ radius = 2.05713
height = 2.24425 height = 2.24425
radius = 1.941 radius = 1.941
[sub_resource type="Animation" id="Animation_hrxn4"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [1.0]
}
[sub_resource type="Animation" id="Animation_flixp"]
resource_name = "fade_in"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1, 1),
"update": 0,
"values": [1.0, 0.0]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6ihe1"]
_data = {
&"RESET": SubResource("Animation_hrxn4"),
&"fade_in": SubResource("Animation_flixp")
}
[node name="SteleE" type="Node3D"] [node name="SteleE" type="Node3D"]
transform = Transform3D(0.43, 0, 0, 0, 0.43, 0, 0, 0, 0.43, 0, 0.0391899, 0) transform = Transform3D(0.43, 0, 0, 0, 0.43, 0, 0, 0, 0.43, 0, 0.0391899, 0)
script = ExtResource("1_kuew0") script = ExtResource("1_yvxj1")
[node name="Steles_" type="Node3D" parent="."] [node name="Steles_" type="Node3D" parent="."]
@@ -111,6 +147,12 @@ shape = SubResource("CylinderShape3D_m1n1c")
[node name="FLOWER" type="Sprite3D" parent="."] [node name="FLOWER" type="Sprite3D" parent="."]
transform = Transform3D(0.730989, 0.682377, 0.00417087, -0.425947, 0.451498, 0.78404, 0.533128, -0.574901, 0.620696, -0.121022, 0.0524253, 2.25571) transform = Transform3D(0.730989, 0.682377, 0.00417087, -0.425947, 0.451498, 0.78404, 0.533128, -0.574901, 0.620696, -0.121022, 0.0524253, 2.25571)
visible = false transparency = 1.0
shaded = true shaded = true
texture = ExtResource("3_yvxj1") texture = ExtResource("3_yvxj1")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_6ihe1")
}
@@ -1,7 +1,7 @@
[gd_scene load_steps=14 format=4 uid="uid://d6pjtdg6wh38"] [gd_scene load_steps=17 format=4 uid="uid://d6pjtdg6wh38"]
[ext_resource type="Script" uid="uid://dcqssoikr3pl7" path="res://src/npc/Npc.cs" id="1_38s7d"]
[ext_resource type="Texture2D" uid="uid://br0vjonsyq32m" path="res://src/map/assets/Steles/Steles_ALUMPLAT.jpg" id="1_hc3bc"] [ext_resource type="Texture2D" uid="uid://br0vjonsyq32m" path="res://src/map/assets/Steles/Steles_ALUMPLAT.jpg" id="1_hc3bc"]
[ext_resource type="Script" uid="uid://bee0bhxtd4r8s" path="res://src/npc/Stele.cs" id="1_y65cn"]
[ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="3_y65cn"] [ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="3_y65cn"]
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_a85ng"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_a85ng"]
@@ -123,8 +123,44 @@ radius = 0.709473
height = 2.24425 height = 2.24425
radius = 1.941 radius = 1.941
[sub_resource type="Animation" id="Animation_hrxn4"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [1.0]
}
[sub_resource type="Animation" id="Animation_flixp"]
resource_name = "fade_in"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1, 1),
"update": 0,
"values": [1.0, 0.0]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6ihe1"]
_data = {
&"RESET": SubResource("Animation_hrxn4"),
&"fade_in": SubResource("Animation_flixp")
}
[node name="SteleF" type="Node3D"] [node name="SteleF" type="Node3D"]
script = ExtResource("1_38s7d") script = ExtResource("1_y65cn")
[node name="Steles_" type="Node3D" parent="."] [node name="Steles_" type="Node3D" parent="."]
@@ -179,6 +215,12 @@ shape = SubResource("CylinderShape3D_sma6b")
[node name="FLOWER" type="Sprite3D" parent="."] [node name="FLOWER" type="Sprite3D" parent="."]
transform = Transform3D(0.363695, 0.343112, 1.17177e-08, -0.212973, 0.225749, 0.39202, 0.269014, -0.285151, 0.310355, 0, 0.0524253, 0.687786) transform = Transform3D(0.363695, 0.343112, 1.17177e-08, -0.212973, 0.225749, 0.39202, 0.269014, -0.285151, 0.310355, 0, 0.0524253, 0.687786)
visible = false transparency = 1.0
shaded = true shaded = true
texture = ExtResource("3_y65cn") texture = ExtResource("3_y65cn")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_6ihe1")
}
@@ -1,7 +1,7 @@
[gd_scene load_steps=13 format=4 uid="uid://bxjcnuf2g8iox"] [gd_scene load_steps=16 format=4 uid="uid://bxjcnuf2g8iox"]
[ext_resource type="Script" uid="uid://bee0bhxtd4r8s" path="res://src/npc/Stele.cs" id="1_dkr3t"]
[ext_resource type="Texture2D" uid="uid://35g2bx4vh3wd" path="res://src/map/assets/Steles/Steles_IMG0031.png" id="1_nj8pm"] [ext_resource type="Texture2D" uid="uid://35g2bx4vh3wd" path="res://src/map/assets/Steles/Steles_IMG0031.png" id="1_nj8pm"]
[ext_resource type="Script" uid="uid://dcqssoikr3pl7" path="res://src/npc/Npc.cs" id="1_ts7fn"]
[ext_resource type="Texture2D" uid="uid://jdweu6rj63e5" path="res://src/map/assets/Steles/Steles_Swirld.png" id="2_ts7fn"] [ext_resource type="Texture2D" uid="uid://jdweu6rj63e5" path="res://src/map/assets/Steles/Steles_Swirld.png" id="2_ts7fn"]
[ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="4_dkr3t"] [ext_resource type="Texture2D" uid="uid://cqcjbeoghy70" path="res://src/items/special/textures/Flower.png" id="4_dkr3t"]
@@ -93,8 +93,44 @@ radius = 1.13965
height = 3.80425 height = 3.80425
radius = 1.941 radius = 1.941
[sub_resource type="Animation" id="Animation_hrxn4"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [1.0]
}
[sub_resource type="Animation" id="Animation_flixp"]
resource_name = "fade_in"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("FLOWER:transparency")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1, 1),
"update": 0,
"values": [1.0, 0.0]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6ihe1"]
_data = {
&"RESET": SubResource("Animation_hrxn4"),
&"fade_in": SubResource("Animation_flixp")
}
[node name="SteleG" type="Node3D"] [node name="SteleG" type="Node3D"]
script = ExtResource("1_ts7fn") script = ExtResource("1_dkr3t")
[node name="Steles_" type="Node3D" parent="."] [node name="Steles_" type="Node3D" parent="."]
@@ -146,6 +182,12 @@ shape = SubResource("CylinderShape3D_feicv")
[node name="FLOWER" type="Sprite3D" parent="."] [node name="FLOWER" type="Sprite3D" parent="."]
transform = Transform3D(0.363695, 0.343112, 1.17177e-08, -0.212973, 0.225749, 0.39202, 0.269014, -0.285151, 0.310355, 0, 0.0524253, 1.0407) transform = Transform3D(0.363695, 0.343112, 1.17177e-08, -0.212973, 0.225749, 0.39202, 0.269014, -0.285151, 0.310355, 0, 0.0524253, 1.0407)
visible = false transparency = 1.0
shaded = true shaded = true
texture = ExtResource("4_dkr3t") texture = ExtResource("4_dkr3t")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_6ihe1")
}
@@ -2794,11 +2794,9 @@ transform = Transform3D(-0.267765, 0, 0.351913, 0, 0.4422, 0, -0.351913, 0, -0.2
[node name="Rat" parent="Actors" instance=ExtResource("75_322om")] [node name="Rat" parent="Actors" instance=ExtResource("75_322om")]
transform = Transform3D(1, 0, 1.19209e-07, 0, 1, 0, -1.19209e-07, 0, 1, -36.8943, 3.78707, 44.3599) transform = Transform3D(1, 0, 1.19209e-07, 0, 1, 0, -1.19209e-07, 0, 1, -36.8943, 3.78707, 44.3599)
ID = null
[node name="Clalo" parent="Actors" instance=ExtResource("76_nfcfh")] [node name="Clalo" parent="Actors" instance=ExtResource("76_nfcfh")]
transform = Transform3D(-1.15777, 0, -1.52161, 0, 1.912, 0, 1.52161, 0, -1.15777, -244.949, 1.16958, 117.235) transform = Transform3D(-1.15777, 0, -1.52161, 0, 1.912, 0, 1.52161, 0, -1.15777, -244.949, 1.16958, 117.235)
ID = null
[node name="AnimatedSprite3D" parent="Actors/Clalo" index="0"] [node name="AnimatedSprite3D" parent="Actors/Clalo" index="0"]
transform = Transform3D(1.11, 0, 0, 0, 1.11, 0, 0, 0, 1.11, 0, 0.179583, 0) transform = Transform3D(1.11, 0, 0, 0, 1.11, 0, 0, 0, 1.11, 0, 0.179583, 0)
@@ -2806,7 +2804,6 @@ frame_progress = 0.120696
[node name="Caretaker of Saints" parent="Actors" instance=ExtResource("80_8isf0")] [node name="Caretaker of Saints" parent="Actors" instance=ExtResource("80_8isf0")]
transform = Transform3D(-1.42252, 0, -3.28851, 0, 3.583, 0, 3.28851, 0, -1.42252, -245.674, 3.22781, 272.252) transform = Transform3D(-1.42252, 0, -3.28851, 0, 3.583, 0, 3.28851, 0, -1.42252, -245.674, 3.22781, 272.252)
ID = null
[node name="AnimatedSprite3D" parent="Actors/Caretaker of Saints" index="0"] [node name="AnimatedSprite3D" parent="Actors/Caretaker of Saints" index="0"]
texture_filter = 0 texture_filter = 0
@@ -2823,28 +2820,22 @@ surface_material_override/0 = SubResource("StandardMaterial3D_gdgdy")
[node name="SteleA" parent="Actors" instance=ExtResource("61_v60tm")] [node name="SteleA" parent="Actors" instance=ExtResource("61_v60tm")]
transform = Transform3D(-2.02763, 0, -1.00137, 0, 2.26142, 0, 1.00137, 0, -2.02763, -269.604, -2.12242, 368.855) transform = Transform3D(-2.02763, 0, -1.00137, 0, 2.26142, 0, 1.00137, 0, -2.02763, -269.604, -2.12242, 368.855)
Dialogue = ExtResource("60_1b363") Dialogue = ExtResource("60_1b363")
ID = null
[node name="SteleA2" parent="Actors" instance=ExtResource("61_v60tm")] [node name="SteleA2" parent="Actors" instance=ExtResource("61_v60tm")]
transform = Transform3D(-1.0882, 0, 1.98238, 0, 2.26142, 0, -1.98238, 0, -1.0882, 109.541, -2.96568, -125.703) transform = Transform3D(-1.0882, 0, 1.98238, 0, 2.26142, 0, -1.98238, 0, -1.0882, 109.541, -2.96568, -125.703)
ID = null
[node name="Stele B Test" parent="Actors" instance=ExtResource("32_xqf5a")] [node name="Stele B Test" parent="Actors" instance=ExtResource("32_xqf5a")]
transform = Transform3D(1.76809, 0, -1.40993, 0, 2.26142, 0, 1.40993, 0, 1.76809, -221.316, -2.14605, 87.2701) transform = Transform3D(1.76809, 0, -1.40993, 0, 2.26142, 0, 1.40993, 0, 1.76809, -221.316, -2.14605, 87.2701)
Dialogue = ExtResource("60_1b363") Dialogue = ExtResource("60_1b363")
ID = null
[node name="SteleA3" parent="Actors" instance=ExtResource("61_v60tm")] [node name="SteleA3" parent="Actors" instance=ExtResource("61_v60tm")]
transform = Transform3D(-1.36936, 0, -1.79969, 0, 2.26142, 0, 1.79969, 0, -1.36936, -152.306, -2.54626, 264.978) transform = Transform3D(-1.36936, 0, -1.79969, 0, 2.26142, 0, 1.79969, 0, -1.36936, -152.306, -2.54626, 264.978)
ID = null
[node name="SteleE" parent="Actors" instance=ExtResource("62_o5pdk")] [node name="SteleE" parent="Actors" instance=ExtResource("62_o5pdk")]
transform = Transform3D(0.868668, 0, -0.723823, 0, 1.13071, 0, 0.723823, 0, 0.868668, -301.766, -2.71211, 324.165) transform = Transform3D(0.868668, 0, -0.723823, 0, 1.13071, 0, 0.723823, 0, 0.868668, -301.766, -2.71211, 324.165)
ID = null
[node name="SteleA4" parent="Actors" instance=ExtResource("61_v60tm")] [node name="SteleA4" parent="Actors" instance=ExtResource("61_v60tm")]
transform = Transform3D(2.24285, 0, 0.289188, 0, 2.26142, 0, -0.289188, 0, 2.24285, -158.475, -2.35288, 110.031) transform = Transform3D(2.24285, 0, 0.289188, 0, 2.26142, 0, -0.289188, 0, 2.24285, -158.475, -2.35288, 110.031)
ID = null
[node name="Lighting And Environment" type="Node3D" parent="."] [node name="Lighting And Environment" type="Node3D" parent="."]
transform = Transform3D(0.66, 0, 0, 0, 0.66, 0, 0, 0, 0.66, -293.644, -2.57557, 69.8565) transform = Transform3D(0.66, 0, 0, 0, 0.66, 0, 0, 0, 0.66, -293.644, -2.57557, 69.8565)
-15
View File
@@ -1,7 +1,6 @@
using Chickensoft.AutoInject; using Chickensoft.AutoInject;
using Chickensoft.Introspection; using Chickensoft.Introspection;
using Godot; using Godot;
using System.Threading.Tasks;
namespace Zennysoft.Game.Ma; namespace Zennysoft.Game.Ma;
[Meta(typeof(IAutoNode))] [Meta(typeof(IAutoNode))]
@@ -23,8 +22,6 @@ public partial class Npc : Node3D
private bool _isInDialogueZone = false; private bool _isInDialogueZone = false;
private bool _isIntroductionComplete = false; private bool _isIntroductionComplete = false;
public int ID { get; private set; } = 0;
public void OnReady() public void OnReady()
{ {
SetPhysicsProcess(true); SetPhysicsProcess(true);
@@ -32,7 +29,6 @@ public partial class Npc : Node3D
DialogueZone.BodyExited += DialogueZone_BodyExited; DialogueZone.BodyExited += DialogueZone_BodyExited;
DialogueExitZone.BodyExited += DialogueExitZone_BodyExited; DialogueExitZone.BodyExited += DialogueExitZone_BodyExited;
Hitbox.AreaEntered += Hitbox_AreaEntered; Hitbox.AreaEntered += Hitbox_AreaEntered;
ID = GetHashCode();
} }
private void Hitbox_AreaEntered(Area3D area) private void Hitbox_AreaEntered(Area3D area)
@@ -67,15 +63,6 @@ public partial class Npc : Node3D
} }
} }
public async Task EndDialogue()
{
if (!_game.NpcData.SteleDiscovered.Contains(ID))
{
_game.NpcData.SteleDiscovered.Add(ID);
await _game.Save();
}
}
public void OnExitTree() public void OnExitTree()
{ {
DialogueZone.BodyEntered -= DialogueZone_BodyEntered; DialogueZone.BodyEntered -= DialogueZone_BodyEntered;
@@ -83,6 +70,4 @@ public partial class Npc : Node3D
DialogueExitZone.BodyExited -= DialogueExitZone_BodyExited; DialogueExitZone.BodyExited -= DialogueExitZone_BodyExited;
Hitbox.AreaEntered -= Hitbox_AreaEntered; Hitbox.AreaEntered -= Hitbox_AreaEntered;
} }
public override int GetHashCode() => GetPath().GetHashCode();
} }
+97
View File
@@ -0,0 +1,97 @@
using Chickensoft.AutoInject;
using Chickensoft.Introspection;
using DialogueManagerRuntime;
using Godot;
using System.Threading.Tasks;
namespace Zennysoft.Game.Ma;
[Meta(typeof(IAutoNode))]
public partial class Stele : Node3D
{
public override void _Notification(int what) => this.Notify(what);
[Dependency] public IGame _game => this.DependOn<IGame>();
[Node] public AnimationPlayer AnimationPlayer { get; set; }
[Node] public Area3D DialogueZone { get; set; } = default!;
[Node] public Area3D DialogueExitZone { get; set; } = default!;
[Node] public Area3D Hitbox { get; set; } = default!;
[Export] public Resource Dialogue { get; set; } = default!;
public int ID { get; private set; } = 0;
private bool _isInDialogueZone = false;
public void OnReady()
{
SetPhysicsProcess(true);
DialogueZone.BodyEntered += DialogueZone_BodyEntered;
DialogueZone.BodyExited += DialogueZone_BodyExited;
DialogueExitZone.BodyExited += DialogueExitZone_BodyExited;
Hitbox.AreaEntered += Hitbox_AreaEntered;
}
public void OnResolved()
{
ID = GetHashCode();
if (_game.NpcData.SteleDiscovered.Contains(ID))
AnimationPlayer.Play("fade_in");
}
public override void _Input(InputEvent @event)
{
if (Dialogue != null && @event.IsActionPressed(GameInputs.Interact) && _isInDialogueZone)
{
DialogueController.ShowDialogue(Dialogue, "general", [this]);
}
}
private void Hitbox_AreaEntered(Area3D area)
{
if (area.GetOwner() is ThrownItem thrownItem)
{
DialogueController.ShowDialogue(Dialogue, "get_item");
thrownItem.QueueFree();
}
}
private void DialogueZone_BodyExited(Node3D body)
{
_isInDialogueZone = false;
}
private void DialogueExitZone_BodyExited(Node3D body)
{
DialogueController.Interrupt();
}
private void DialogueZone_BodyEntered(Node3D body)
{
_isInDialogueZone = true;
}
public async Task EndDialogue()
{
if (!_game.NpcData.SteleDiscovered.Contains(ID))
{
_game.NpcData.SteleDiscovered.Add(ID);
await _game.Save();
AnimationPlayer.Play("fade_in");
}
}
public override int GetHashCode() => GetPath().GetHashCode();
public void OnExitTree()
{
DialogueZone.BodyEntered -= DialogueZone_BodyEntered;
DialogueZone.BodyExited -= DialogueZone_BodyExited;
DialogueExitZone.BodyExited -= DialogueExitZone_BodyExited;
Hitbox.AreaEntered -= Hitbox_AreaEntered;
}
}
+1
View File
@@ -0,0 +1 @@
uid://bee0bhxtd4r8s