Looking into room collisions we need; set up plastique behavior

This commit is contained in:
2026-01-25 19:40:59 -08:00
parent 865934399d
commit e63a94210c
12 changed files with 1649 additions and 50 deletions

View File

@@ -282,6 +282,7 @@ locale/translations_pot_files=PackedStringArray("res://src/dialog/Dialogue.dialo
3d_physics/layer_11="ItemRescue"
3d_physics/layer_12="EnemyHitbox"
3d_physics/layer_13="UnlockableDoor"
3d_physics/layer_14="ExplodableWall"
3d_physics/layer_32="Navigation"
[navigation]

View File

@@ -22,36 +22,36 @@ public partial class SetItem : RigidBody3D
public void OnReady()
{
_stateMachine = (AnimationNodeStateMachinePlayback)AnimationTree.Get(_parametersPlayback);
ExplosionArea.AreaEntered += ExplosionArea_AreaEntered;
AnimationTree.AnimationFinished += AnimationTree_AnimationFinished;
_stateMachine = (AnimationNodeStateMachinePlayback)AnimationTree.Get(_parametersPlayback);
ExplosionArea.AreaEntered += ExplosionArea_AreaEntered;
AnimationTree.AnimationFinished += AnimationTree_AnimationFinished;
}
private void AnimationTree_AnimationFinished(StringName animName)
{
if (animName == "explode")
QueueFree();
if (animName == "explode")
QueueFree();
}
private void ExplosionArea_AreaEntered(Area3D area)
{
// if (area is IDoor door) etc
// door.Demolish();
if (area.GetOwner() is IEnemy enemy)
enemy.HealthComponent.Damage(10);
if (area.GetOwner() is ExplodableWall wall)
// door.Demolish();
if (area.GetOwner() is IEnemy enemy)
enemy.HealthComponent.Damage(10);
}
public async void Set()
{
AddCollisionExceptionWith((Node)Player);
GlobalPosition = Player.GlobalPosition + Vector3.Up;
ApplyCentralImpulse(-Player.GlobalBasis.Z.Normalized() * 5.0f);
await ToSignal(GetTree().CreateTimer(1), "timeout");
Explode();
AddCollisionExceptionWith((Node)Player);
GlobalPosition = Player.GlobalPosition + Vector3.Up;
ApplyCentralImpulse(-Player.GlobalBasis.Z.Normalized() * 5.0f);
await ToSignal(GetTree().CreateTimer(1), "timeout");
Explode();
}
public void Explode()
{
_stateMachine.Travel("timer");
_stateMachine.Travel("timer");
}
}

View File

@@ -287,7 +287,7 @@ anim_player = NodePath("../AnimationPlayer")
unique_name_in_owner = true
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.00817871, 0)
collision_layer = 0
collision_mask = 2048
collision_mask = 10240
[node name="Radius" type="MeshInstance3D" parent="ExplosionArea"]
transform = Transform3D(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0)

View File

@@ -1,6 +1,7 @@
[gd_scene load_steps=197 format=4 uid="uid://dwy8ud6yblms7"]
[gd_scene load_steps=199 format=4 uid="uid://dwy8ud6yblms7"]
[ext_resource type="Texture2D" uid="uid://2uap1c4royqy" path="res://src/map/assets/Explodable Wall/Wall Explosion_bombable.png" id="1_6rkhk"]
[ext_resource type="Script" uid="uid://cbuxsrtv0vkn3" path="res://src/map/dungeon/code/ExplodableWall.cs" id="1_ovv1n"]
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_10fcu"]
resource_name = "Material.001"
@@ -5125,7 +5126,11 @@ _data = {
&"Animation": SubResource("Animation_g542u")
}
[node name="Node3D" type="Node3D"]
[sub_resource type="BoxShape3D" id="BoxShape3D_ovv1n"]
size = Vector3(5.63403, 5.18176, 2.3139)
[node name="ExplodableWall" type="Node3D"]
script = ExtResource("1_ovv1n")
[node name="Wall Explosion" type="Node3D" parent="."]
@@ -5514,6 +5519,15 @@ mesh = SubResource("ArrayMesh_onvoy")
skeleton = NodePath("")
[node name="AnimationPlayer" type="AnimationPlayer" parent="Wall Explosion"]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_1bpfx")
}
[node name="Area3D" type="Area3D" parent="."]
collision_layer = 8192
collision_mask = 0
[node name="CollisionShape3D" type="CollisionShape3D" parent="Area3D"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.130981, 2.09088, 0.0763245)
shape = SubResource("BoxShape3D_ovv1n")

View File

@@ -0,0 +1,15 @@
using Chickensoft.AutoInject;
using Chickensoft.Introspection;
using Godot;
[Meta(typeof(IAutoNode))]
public partial class ExplodableWall : Node3D
{
[Node] public AnimationPlayer AnimationPlayer { get; set; }
public override void _Notification(int what) => this.Notify(what);
public void Demolish()
{
AnimationPlayer.Play("Animation");
}
}

View File

@@ -0,0 +1 @@
uid://cbuxsrtv0vkn3

View File

@@ -122,7 +122,6 @@ draw_pass_1 = SubResource("QuadMesh_sasor")
[node name="Collision" type="Node3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, 0)
visible = false
[node name="StaticBody3D" type="StaticBody3D" parent="Collision"]

View File

@@ -590,8 +590,9 @@ data = PackedVector3Array(28.5183, 3.42, 10.577, 28.5183, 10.3788, 24.4935, 28.5
[sub_resource type="BoxShape3D" id="BoxShape3D_fbuxi"]
size = Vector3(3.78775, 8.47084, 2.68506)
[sub_resource type="BoxShape3D" id="BoxShape3D_1eua6"]
size = Vector3(4.8399, 8.65698, 5.07953)
[sub_resource type="CylinderShape3D" id="CylinderShape3D_uoixu"]
height = 5.97144
radius = 3.09814
[sub_resource type="BoxShape3D" id="BoxShape3D_jruxb"]
size = Vector3(16, 8, 16)
@@ -727,8 +728,8 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.758601, 63.7703, 12.4486)
shape = SubResource("BoxShape3D_fbuxi")
[node name="CollisionShape3D3" type="CollisionShape3D" parent="Collision/StaticBody3D"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 13.3348, 63.7291, 2.57142)
shape = SubResource("BoxShape3D_1eua6")
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 13.3841, 62.8023, 2.25392)
shape = SubResource("CylinderShape3D_uoixu")
[node name="Spawn Points" type="Node3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, 0)

View File

@@ -1,31 +1,275 @@
[gd_scene load_steps=99 format=4 uid="uid://c5eon2dk4ojua"]
[gd_scene load_steps=148 format=4 uid="uid://c5eon2dk4ojua"]
[ext_resource type="Script" uid="uid://bccyfmj8ikewh" path="res://src/map/dungeon/code/SpecialRoom.cs" id="1_plyiv"]
[ext_resource type="Script" uid="uid://dcqssoikr3pl7" path="res://src/npc/Npc.cs" id="2_xyps6"]
[ext_resource type="Resource" uid="uid://lao0opxww3ib" path="res://src/dialog/Dialogue.dialogue" id="3_7j3th"]
[ext_resource type="Texture2D" uid="uid://b3ypwr2e1o8ip" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_COLUM6N.png" id="3_plyiv"]
[ext_resource type="Texture2D" uid="uid://ct2523slwx30o" path="res://src/npc/Ran/animations/Layer 1.png" id="4_a77lt"]
[ext_resource type="Texture2D" uid="uid://did8sxg3s3cng" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_FLOOR2.jpg" id="4_pps52"]
[ext_resource type="Texture2D" uid="uid://cbigi3n8f6nyr" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_apple.png" id="5_s88wa"]
[ext_resource type="Texture2D" uid="uid://b72fnsmgg1mff" path="res://src/npc/Ran/animations/Layer 2.png" id="5_ud5se"]
[ext_resource type="Texture2D" uid="uid://c01a6i2hmq7nb" path="res://src/npc/Ran/animations/Layer 3.png" id="6_mft23"]
[ext_resource type="Texture2D" uid="uid://bgubp7q81gllm" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_inner_rock2.png" id="6_v8bnr"]
[ext_resource type="Texture2D" uid="uid://dmjvktlr3x132" path="res://src/minimap/textures/Room Maps/mi_rans_room.png" id="6_yve7s"]
[ext_resource type="Texture2D" uid="uid://duc0eufs2j5uc" path="res://src/npc/Ran/animations/Layer 4.png" id="7_8n2sr"]
[ext_resource type="Texture2D" uid="uid://c4nu5jnri7ffu" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_WALL TILE 1.jpg" id="7_hq81s"]
[ext_resource type="Texture2D" uid="uid://b4cibfgd6vpt8" path="res://src/npc/Ran/animations/Layer 5.png" id="8_7koso"]
[ext_resource type="Texture2D" uid="uid://b2tqjwjvs8ui7" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_SNEK TILE.png" id="8_uff53"]
[ext_resource type="Texture2D" uid="uid://251fxmagtweh" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_cadeuceus.png" id="9_ogy42"]
[ext_resource type="Texture2D" uid="uid://btg0gwpya6tjq" path="res://src/npc/Ran/animations/Layer 6.png" id="9_wdwau"]
[ext_resource type="Texture2D" uid="uid://b7we40opnupwv" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_sarape.png" id="10_dprir"]
[ext_resource type="Texture2D" uid="uid://ci2rcyo1we8hp" path="res://src/npc/Ran/animations/Layer 7.png" id="10_qphn6"]
[ext_resource type="Texture2D" uid="uid://b788lgwfb1jdb" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_darkbrick.png" id="11_5mci2"]
[ext_resource type="Texture2D" uid="uid://bmidoemj483kx" path="res://src/npc/Ran/animations/Layer 8.png" id="11_sgns8"]
[ext_resource type="Texture2D" uid="uid://bqt7cqoxtjwnj" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_concrete_0003_color_1k.png" id="12_6q6b3"]
[ext_resource type="Texture2D" uid="uid://codpix3tl2wqy" path="res://src/npc/Ran/animations/Layer 9.png" id="12_450xd"]
[ext_resource type="Texture2D" uid="uid://dry27c437fasg" path="res://src/npc/Ran/animations/Layer 10.png" id="13_78435"]
[ext_resource type="Texture2D" uid="uid://dj825mcpqvy02" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_Alt_Brick.png" id="13_aqn7l"]
[ext_resource type="Texture2D" uid="uid://1lauhmfelw56" path="res://src/npc/Ran/animations/Layer 11.png" id="14_lbv0f"]
[ext_resource type="Texture2D" uid="uid://cqhqa754oaqy1" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_COLUMN3.jpg" id="14_op6ed"]
[ext_resource type="Texture2D" uid="uid://bj3og0xurrtv3" path="res://src/npc/Ran/animations/Layer 12.png" id="15_5n513"]
[ext_resource type="Texture2D" uid="uid://bes4roalxxg4m" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_SA115.png" id="15_e0efo"]
[ext_resource type="Texture2D" uid="uid://b6hxwku7s1228" path="res://src/npc/Ran/animations/Layer 13.png" id="16_3vb32"]
[ext_resource type="Texture2D" uid="uid://bcggbw5i1o3hp" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_STONE_PANEL_1png.png" id="16_du111"]
[ext_resource type="Texture2D" uid="uid://bb5w13xie3rxd" path="res://src/npc/Ran/animations/Layer 14.png" id="17_ebd46"]
[ext_resource type="Texture2D" uid="uid://ds8ekbwjn21rg" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_brick_corridor_corrected.png" id="17_ybjms"]
[ext_resource type="Texture2D" uid="uid://b7ocsn10ercom" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_swirled_column.png" id="18_ikjuq"]
[ext_resource type="Texture2D" uid="uid://c1dbkhd182c10" path="res://src/npc/Ran/animations/Layer 15.png" id="18_q7bsg"]
[ext_resource type="Texture2D" uid="uid://diw3jul5bgorj" path="res://src/npc/Ran/animations/Layer 16.png" id="19_6arhf"]
[ext_resource type="Texture2D" uid="uid://caom5g3md86u2" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_hand-tiile.png" id="19_ix0ff"]
[ext_resource type="Texture2D" uid="uid://bv1i6nmk43au0" path="res://src/npc/Ran/animations/Layer 17.png" id="20_8gttu"]
[ext_resource type="Texture2D" uid="uid://csi5w8mfxy30n" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_mother.png" id="20_iinry"]
[ext_resource type="Texture2D" uid="uid://u1rxhhlia4cm" path="res://src/npc/Ran/animations/Layer 18.png" id="21_7pjor"]
[ext_resource type="Texture2D" uid="uid://c0x5xjelgy20m" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_brick3.png" id="21_ivu3u"]
[ext_resource type="Texture2D" uid="uid://ehurkn25qqtl" path="res://src/npc/Ran/animations/Layer 19.png" id="22_hic27"]
[ext_resource type="Texture2D" uid="uid://nfm0ogwfxnvc" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_reddertex.png" id="22_koan8"]
[ext_resource type="Texture2D" uid="uid://bpynskjwl74h0" path="res://src/npc/Ran/animations/Layer 20.png" id="23_7jktv"]
[ext_resource type="Texture2D" uid="uid://28tm1duewpt" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_yellow_grunge_glass.png" id="23_e0cd2"]
[ext_resource type="Texture2D" uid="uid://rnbpyqhk6j2e" path="res://src/npc/Ran/animations/Layer 21.png" id="24_d3ct6"]
[ext_resource type="Texture2D" uid="uid://c1gpougpbu4ww" path="res://src/map/dungeon/models/Area 1/Ran/ran-fix_FLOOR4.png" id="24_w2vdn"]
[ext_resource type="PackedScene" uid="uid://jds3hr41coal" path="res://src/npc/Ran/Ran.tscn" id="26_8yn83"]
[ext_resource type="Texture2D" uid="uid://bgedfpastg6x" path="res://src/npc/Ran/animations/Layer 22.png" id="25_c24wj"]
[ext_resource type="Texture2D" uid="uid://dnyxfekr8yc85" path="res://src/npc/Ran/animations/Layer 23.png" id="26_w4g0j"]
[ext_resource type="Texture2D" uid="uid://qb3xrhd0gddd" path="res://src/npc/Ran/animations/Layer 24.png" id="27_54xhy"]
[ext_resource type="Texture2D" uid="uid://dw50ys561j8no" path="res://src/map/assets/DUST_1.png" id="27_x1yce"]
[ext_resource type="Texture2D" uid="uid://ccbxaujmt7r1r" path="res://src/npc/Ran/animations/Layer 25.png" id="28_gnf4q"]
[ext_resource type="Texture2D" uid="uid://djv356wp06ljj" path="res://src/npc/Ran/animations/Layer 26.png" id="29_hiuym"]
[ext_resource type="Texture2D" uid="uid://creiryyx7p2co" path="res://src/npc/Ran/animations/Layer 27.png" id="30_4otwj"]
[ext_resource type="Texture2D" uid="uid://dev86mbb2dto6" path="res://src/npc/Ran/animations/Layer 28.png" id="31_utnok"]
[ext_resource type="Texture2D" uid="uid://cloijjhlvl8jf" path="res://src/npc/Ran/animations/Layer 29.png" id="32_uaqch"]
[ext_resource type="Texture2D" uid="uid://bpbajmjdtqrjf" path="res://src/npc/Ran/animations/Layer 30.png" id="33_7c3e1"]
[ext_resource type="Texture2D" uid="uid://dvffqii17usve" path="res://src/npc/Ran/animations/Layer 31.png" id="34_i5vu1"]
[ext_resource type="Texture2D" uid="uid://w8fxe8kw5k71" path="res://src/npc/Ran/animations/Layer 32.png" id="35_rlw2t"]
[ext_resource type="Texture2D" uid="uid://wf1fy2oq6pwu" path="res://src/npc/Ran/animations/Layer 33.png" id="36_33k1p"]
[ext_resource type="Texture2D" uid="uid://dm1jtlih2wgey" path="res://src/npc/Ran/animations/Layer 34.png" id="37_76nwj"]
[ext_resource type="Texture2D" uid="uid://c0e8nly838i80" path="res://src/npc/Ran/animations/Layer 35.png" id="38_6tln7"]
[ext_resource type="Texture2D" uid="uid://d3jn2tx8ifapd" path="res://src/npc/Ran/animations/Layer 36.png" id="39_6yjle"]
[ext_resource type="Texture2D" uid="uid://dafpnwkwcukp4" path="res://src/vfx/shadow_test_1.png" id="40_naa4p"]
[sub_resource type="ViewportTexture" id="ViewportTexture_lx32o"]
viewport_path = NodePath("Sprite/SubViewportContainer/SubViewport")
[sub_resource type="SpriteFrames" id="SpriteFrames_f3624"]
animations = [{
"frames": [{
"duration": 1.0,
"texture": ExtResource("4_a77lt")
}, {
"duration": 1.0,
"texture": ExtResource("5_ud5se")
}, {
"duration": 1.0,
"texture": ExtResource("6_mft23")
}, {
"duration": 1.0,
"texture": ExtResource("7_8n2sr")
}, {
"duration": 1.0,
"texture": ExtResource("8_7koso")
}, {
"duration": 1.0,
"texture": ExtResource("9_wdwau")
}, {
"duration": 1.0,
"texture": ExtResource("10_qphn6")
}, {
"duration": 1.0,
"texture": ExtResource("11_sgns8")
}, {
"duration": 1.0,
"texture": ExtResource("12_450xd")
}, {
"duration": 1.0,
"texture": ExtResource("13_78435")
}, {
"duration": 1.0,
"texture": ExtResource("14_lbv0f")
}, {
"duration": 1.0,
"texture": ExtResource("15_5n513")
}, {
"duration": 1.0,
"texture": ExtResource("16_3vb32")
}, {
"duration": 1.0,
"texture": ExtResource("17_ebd46")
}, {
"duration": 1.0,
"texture": ExtResource("18_q7bsg")
}, {
"duration": 1.0,
"texture": ExtResource("19_6arhf")
}, {
"duration": 1.0,
"texture": ExtResource("20_8gttu")
}, {
"duration": 1.0,
"texture": ExtResource("21_7pjor")
}, {
"duration": 1.0,
"texture": ExtResource("22_hic27")
}, {
"duration": 1.0,
"texture": ExtResource("23_7jktv")
}, {
"duration": 1.0,
"texture": ExtResource("24_d3ct6")
}, {
"duration": 1.0,
"texture": ExtResource("25_c24wj")
}, {
"duration": 1.0,
"texture": ExtResource("26_w4g0j")
}, {
"duration": 1.0,
"texture": ExtResource("27_54xhy")
}, {
"duration": 1.0,
"texture": ExtResource("28_gnf4q")
}, {
"duration": 1.0,
"texture": ExtResource("29_hiuym")
}, {
"duration": 1.0,
"texture": ExtResource("30_4otwj")
}, {
"duration": 1.0,
"texture": ExtResource("31_utnok")
}, {
"duration": 1.0,
"texture": ExtResource("32_uaqch")
}, {
"duration": 1.0,
"texture": ExtResource("33_7c3e1")
}, {
"duration": 1.0,
"texture": ExtResource("34_i5vu1")
}, {
"duration": 1.0,
"texture": ExtResource("35_rlw2t")
}, {
"duration": 1.0,
"texture": ExtResource("36_33k1p")
}, {
"duration": 1.0,
"texture": ExtResource("37_76nwj")
}, {
"duration": 1.0,
"texture": ExtResource("38_6tln7")
}, {
"duration": 1.0,
"texture": ExtResource("39_6yjle")
}],
"loop": true,
"name": &"idle",
"speed": 14.0
}]
[sub_resource type="CylinderShape3D" id="CylinderShape3D_wfhgc"]
height = 3.85352
radius = 7.41504
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_kg3qv"]
radius = 0.837722
height = 2.8375
[sub_resource type="CylinderShape3D" id="CylinderShape3D_nwuwj"]
height = 2.24425
radius = 1.941
[sub_resource type="Animation" id="Animation_jl1c6"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite/SubViewportContainer/SubViewport/AnimatedSprite2D: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("Sprite/SubViewportContainer/SubViewport/AnimatedSprite2D: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_bww12"]
resource_name = "idle"
length = 2.91668
loop_mode = 1
step = 0.0833333
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Sprite/SubViewportContainer/SubViewport/AnimatedSprite2D: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("Sprite/SubViewportContainer/SubViewport/AnimatedSprite2D:frame")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0, 0.0833333, 0.166667, 0.25, 0.333333, 0.416667, 0.5, 0.583333, 0.666667, 0.75, 0.833333, 0.916667, 1, 1.08333, 1.16667, 1.25, 1.33333, 1.41667, 1.5, 1.58333, 1.66667, 1.75, 1.83333, 1.91667, 2, 2.08333, 2.16667, 2.25, 2.33333, 2.41667, 2.5, 2.58333, 2.66667, 2.75, 2.83333),
"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
"update": 1,
"values": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_yx0nu"]
_data = {
&"RESET": SubResource("Animation_jl1c6"),
&"idle": SubResource("Animation_bww12")
}
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_3udpp"]
animation = &"idle"
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_bww12"]
advance_mode = 2
[sub_resource type="AnimationNodeStateMachine" id="AnimationNodeStateMachine_3udpp"]
states/Start/position = Vector2(147, 80)
states/idle/node = SubResource("AnimationNodeAnimation_3udpp")
states/idle/position = Vector2(291, 80)
transitions = ["Start", "idle", SubResource("AnimationNodeStateMachineTransition_bww12")]
[sub_resource type="BoxShape3D" id="BoxShape3D_8yn83"]
size = Vector3(32.1606, 0.1, 36.0168)
@@ -1535,8 +1779,82 @@ script = ExtResource("1_plyiv")
[node name="NPC" type="Node3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -2, 2, 0)
[node name="NPC" parent="NPC" instance=ExtResource("26_8yn83")]
[node name="NPC" type="Node3D" parent="NPC"]
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, -8.85872, 0.900797, -0.0749016)
script = ExtResource("2_xyps6")
Dialogue = ExtResource("3_7j3th")
[node name="Sprite" type="Sprite3D" parent="NPC/NPC"]
unique_name_in_owner = true
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.1, 0)
gi_mode = 0
pixel_size = 0.02
billboard = 2
double_sided = false
alpha_cut = 3
texture_filter = 1
texture = SubResource("ViewportTexture_lx32o")
[node name="SubViewportContainer" type="SubViewportContainer" parent="NPC/NPC/Sprite"]
visibility_layer = 0
offset_left = -44.0
offset_right = 407.0
offset_bottom = 257.0
[node name="SubViewport" type="SubViewport" parent="NPC/NPC/Sprite/SubViewportContainer"]
transparent_bg = true
handle_input_locally = false
render_target_update_mode = 4
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="NPC/NPC/Sprite/SubViewportContainer/SubViewport"]
position = Vector2(279, 214)
sprite_frames = SubResource("SpriteFrames_f3624")
animation = &"idle"
autoplay = "idle"
[node name="DialogueZone" type="Area3D" parent="NPC/NPC"]
unique_name_in_owner = true
collision_layer = 0
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="NPC/NPC/DialogueZone"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.00131226, -0.926758, -0.00723076)
shape = SubResource("CylinderShape3D_wfhgc")
[node name="Collision" type="RigidBody3D" parent="NPC/NPC"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.105047, -0.0490516, 0)
collision_mask = 0
gravity_scale = 0.0
[node name="CollisionShape3D" type="CollisionShape3D" parent="NPC/NPC/Collision"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.169075, 0, 0)
shape = SubResource("CapsuleShape3D_kg3qv")
[node name="Hitbox" type="Area3D" parent="NPC/NPC"]
unique_name_in_owner = true
collision_layer = 0
collision_mask = 2068
[node name="CollisionShape3D" type="CollisionShape3D" parent="NPC/NPC/Hitbox"]
shape = SubResource("CylinderShape3D_nwuwj")
[node name="AnimationPlayer" type="AnimationPlayer" parent="NPC/NPC"]
libraries = {
&"": SubResource("AnimationLibrary_yx0nu")
}
autoplay = "idle"
[node name="AnimationTree" type="AnimationTree" parent="NPC/NPC"]
tree_root = SubResource("AnimationNodeStateMachine_3udpp")
anim_player = NodePath("../AnimationPlayer")
[node name="Shadow" type="Sprite3D" parent="NPC/NPC"]
transform = Transform3D(3.455, 0, 0, 0, -1.51023e-07, 3.455, 0, -3.455, -1.51023e-07, 0.00393164, -1.50972, 0.0077811)
transparency = 0.1
cast_shadow = 0
modulate = Color(1, 1, 1, 0.591)
texture_filter = 0
texture = ExtResource("40_naa4p")
[node name="Collision" type="Node3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -2, 2, 0)

View File

@@ -72,11 +72,8 @@ script = ExtResource("2_7fo8x")
[node name="A2-Pit" parent="." instance=ExtResource("2_ycerh")]
[node name="A2-Pit2" parent="." instance=ExtResource("2_ycerh")]
[node name="Collision" type="Node3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, 0)
visible = false
[node name="CSGCylinder3D" type="CSGCylinder3D" parent="Collision"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.051639, -0.480896, -0.013773)

View File

@@ -1,9 +1,8 @@
[gd_scene load_steps=18 format=3 uid="uid://d1uldtsv8u8vw"]
[gd_scene load_steps=16 format=3 uid="uid://d1uldtsv8u8vw"]
[ext_resource type="PackedScene" uid="uid://82gby88dqm0l" path="res://src/map/dungeon/models/Area 2/Fountain/A2-Fountain.glb" id="2_0wmhg"]
[ext_resource type="Script" uid="uid://dhollu4j3pynq" path="res://src/map/dungeon/code/MonsterRoom.cs" id="2_dp1b6"]
[ext_resource type="Texture2D" uid="uid://dw50ys561j8no" path="res://src/map/assets/DUST_1.png" id="5_vt6li"]
[ext_resource type="Material" uid="uid://b03wrq6l0mi15" path="res://src/map/assets/MinimapTexture.tres" id="14_b3vy3"]
[sub_resource type="BoxShape3D" id="BoxShape3D_beaee"]
size = Vector3(1.49593, 10.3165, 2.18018)
@@ -27,10 +26,6 @@ data = PackedVector3Array(27.7283, 2.9884, 14.2, 27.7283, 9.9474, 23.5664, 27.72
[sub_resource type="BoxShape3D" id="BoxShape3D_oifm3"]
size = Vector3(20, 6, 16)
[sub_resource type="PlaneMesh" id="PlaneMesh_qxc34"]
material = ExtResource("14_b3vy3")
size = Vector2(20, 16)
[sub_resource type="Curve" id="Curve_w6m53"]
_limits = [-2.0, 2.0, 0.0, 1.0]
_data = [Vector2(0.00358423, 0.230769), 0.0, 0.0, 0, 0, Vector2(0.982079, -1.03846), 0.0, 0.0, 0, 0]
@@ -153,14 +148,6 @@ collision_mask = 10
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.04566, -10.6408, -1.19209e-07)
shape = SubResource("BoxShape3D_oifm3")
[node name="Minimap" type="Node3D" parent="."]
[node name="Minimap" type="MeshInstance3D" parent="Minimap"]
unique_name_in_owner = true
layers = 2
mesh = SubResource("PlaneMesh_qxc34")
skeleton = NodePath("")
[node name="OmniLight3D" type="OmniLight3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.310752, 7.26928, -0.0595102)
light_energy = 4.5

File diff suppressed because one or more lines are too long