From 9f82b7f9fa6c3ea3d357ce368563150e4b2495d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=A8=E8=90=BD=E5=9F=BA=E5=9B=B4=E8=99=BE?= <3161880837@qq.com> Date: Sun, 21 Sep 2025 12:46:32 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E5=AD=90=E5=BC=B9):=20=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E9=93=BE=E6=9E=AA=E5=AD=90=E5=BC=B9=E8=B5=84=E6=BA=90=E4=B8=8E?= =?UTF-8?q?=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 添加链枪子弹的图片资源、脚本和场景文件 为RainbowCat子弹添加穿透属性和生命周期 在子弹AI预设中添加面向鼠标的功能 --- components/Bullets/ChainGun.tscn | 20 +++++++++++ components/Bullets/RainbowCat.tscn | 1 + resources/bullets/chain-gun/Chain_Gun.webp | Bin 0 -> 334 bytes .../bullets/chain-gun/Chain_Gun.webp.import | 34 ++++++++++++++++++ scripts/Contents/AIPresets/Bullet.gd | 2 ++ scripts/Contents/Bullets/ChainGun.gd | 6 ++++ scripts/Contents/Bullets/RainbowCat.gd | 2 ++ 7 files changed, 65 insertions(+) create mode 100644 components/Bullets/ChainGun.tscn create mode 100644 resources/bullets/chain-gun/Chain_Gun.webp create mode 100644 resources/bullets/chain-gun/Chain_Gun.webp.import create mode 100644 scripts/Contents/Bullets/ChainGun.gd diff --git a/components/Bullets/ChainGun.tscn b/components/Bullets/ChainGun.tscn new file mode 100644 index 0000000..a490f04 --- /dev/null +++ b/components/Bullets/ChainGun.tscn @@ -0,0 +1,20 @@ +[gd_scene load_steps=5 format=3 uid="uid://bgt6dok3wc7qs"] + +[ext_resource type="PackedScene" uid="uid://crtdkysmnkith" path="res://components/Abstracts/BulletBase.tscn" id="1_0gg4y"] +[ext_resource type="Texture2D" uid="uid://ccxdfsg5071t4" path="res://resources/bullets/chain-gun/Chain_Gun.webp" id="2_4hyk3"] +[ext_resource type="Script" path="res://scripts/Contents/Bullets/ChainGun.gd" id="2_l7jtn"] + +[sub_resource type="SpriteFrames" id="SpriteFrames_cl70o"] + +[node name="ChainGun" instance=ExtResource("1_0gg4y")] +script = ExtResource("2_l7jtn") + +[node name="texture" parent="." index="0"] +sprite_frames = SubResource("SpriteFrames_cl70o") + +[node name="node" type="Sprite2D" parent="texture" index="1"] +position = Vector2(74, 0) +texture = ExtResource("2_4hyk3") + +[node name="hitbox" parent="." index="1"] +disabled = true diff --git a/components/Bullets/RainbowCat.tscn b/components/Bullets/RainbowCat.tscn index 1463dc9..b01cf22 100644 --- a/components/Bullets/RainbowCat.tscn +++ b/components/Bullets/RainbowCat.tscn @@ -51,6 +51,7 @@ alpha_curve = SubResource("CurveTexture_pwojl") [node name="RainbowCat" instance=ExtResource("1_vvwmq")] script = ExtResource("2_4c1xc") +lifeTime = 3000.0 [node name="texture" parent="." index="0"] rotation = 1.5708 diff --git a/resources/bullets/chain-gun/Chain_Gun.webp b/resources/bullets/chain-gun/Chain_Gun.webp new file mode 100644 index 0000000000000000000000000000000000000000..3cbe692bcea97ce936c7009fc0eb85744a777f2e GIT binary patch literal 334 zcmV-U0kQs4Nk&FS0RRA3MM6+kP&iCE0RR9mGr$KBhrlKPfHV|v_}t~A8_{i&L`?t? zk_=WOs}xdyK{VhlfSHYL+pKiDoGG);#4RH-2Ngdw^B(|!duO@q^Z^U`-*5TWv9Z!M z)`mg<1d=?4jL>Dy5dLIT;1({M{tHd9vJS=l^{N$98-kI`_=1-D#N=#mS{W=eUO zEoizS$x$xGJX}*YQ&wHGN9m{+kHs|&Lke9