mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-28 06:51:54 +08:00
fix(BossAttack): 调整重型紫水晶子弹行为和粒子效果
修改子弹初始速度和加速度方向,移除无用粒子效果代码 调整粒子系统参数并增加粒子数量,优化视觉效果 修复碰撞检测逻辑,确保仅在激活时造成伤害
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=14 format=3 uid="uid://dxd6ikymj0fge"]
|
||||
[gd_scene load_steps=20 format=3 uid="uid://dxd6ikymj0fge"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://crtdkysmnkith" path="res://components/Abstracts/BulletBase.tscn" id="1_mf7ha"]
|
||||
[ext_resource type="Script" path="res://scripts/Statemachine/ShaderStage.gd" id="2_75div"]
|
||||
@@ -109,13 +109,42 @@ point_count = 2
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_inkfe"]
|
||||
curve = SubResource("Curve_g11yl")
|
||||
|
||||
[sub_resource type="Curve" id="Curve_gqowe"]
|
||||
_data = [Vector2(0, 1), 0.0, 0.0, 0, 0, Vector2(1, 0), 0.0, 0.0, 0, 0]
|
||||
point_count = 2
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_0a8st"]
|
||||
curve = SubResource("Curve_gqowe")
|
||||
|
||||
[sub_resource type="Gradient" id="Gradient_52a6a"]
|
||||
colors = PackedColorArray(0.834758, 0.605604, 0.893714, 1, 0.356599, 0.140737, 0.496047, 1)
|
||||
|
||||
[sub_resource type="GradientTexture1D" id="GradientTexture1D_uys4r"]
|
||||
gradient = SubResource("Gradient_52a6a")
|
||||
|
||||
[sub_resource type="Curve" id="Curve_cy4lq"]
|
||||
_data = [Vector2(0, 1), 0.0, 0.0, 0, 0, Vector2(1, 0), 0.0, 0.0, 0, 0]
|
||||
point_count = 2
|
||||
|
||||
[sub_resource type="CurveTexture" id="CurveTexture_4rtxr"]
|
||||
curve = SubResource("Curve_cy4lq")
|
||||
|
||||
[sub_resource type="ParticleProcessMaterial" id="ParticleProcessMaterial_hgwnm"]
|
||||
particle_flag_disable_z = true
|
||||
emission_shape = 1
|
||||
emission_sphere_radius = 10.0
|
||||
angle_min = 1.07288e-05
|
||||
angle_max = 360.0
|
||||
angle_curve = SubResource("CurveTexture_0a8st")
|
||||
direction = Vector3(-1, 0, 0)
|
||||
spread = 0.0
|
||||
initial_velocity_min = 300.0
|
||||
initial_velocity_max = 300.0
|
||||
initial_velocity_min = 200.0
|
||||
initial_velocity_max = 400.0
|
||||
gravity = Vector3(0, 0, 0)
|
||||
scale_min = 3.0
|
||||
scale_max = 6.0
|
||||
scale_curve = SubResource("CurveTexture_4rtxr")
|
||||
color_initial_ramp = SubResource("GradientTexture1D_uys4r")
|
||||
alpha_curve = SubResource("CurveTexture_inkfe")
|
||||
|
||||
[node name="HeavyCrystal" instance=ExtResource("1_mf7ha")]
|
||||
@@ -124,7 +153,7 @@ scale = Vector2(2, 2)
|
||||
script = ExtResource("2_ygemv")
|
||||
displayName = "重型紫水晶"
|
||||
speed = 0.0
|
||||
damage = 20.0
|
||||
damage = 40.0
|
||||
lifeTime = 2000.0
|
||||
autoSpawnAnimation = true
|
||||
|
||||
@@ -133,7 +162,7 @@ unique_name_in_owner = true
|
||||
material = SubResource("ShaderMaterial_1i43q")
|
||||
script = ExtResource("2_75div")
|
||||
size = Vector2(300, 300)
|
||||
color = Color(0.451438, 0.278306, 1.44392e-07, 1)
|
||||
color = Color(0.869998, 0.686414, 0.917359, 1)
|
||||
|
||||
[node name="texture" parent="." index="1"]
|
||||
position = Vector2(145, 0)
|
||||
@@ -148,9 +177,9 @@ libraries = {
|
||||
[node name="trail" type="GPUParticles2D" parent="texture" index="1"]
|
||||
unique_name_in_owner = true
|
||||
z_index = -1
|
||||
amount = 10
|
||||
position = Vector2(10.6667, 0)
|
||||
amount = 400
|
||||
process_material = SubResource("ParticleProcessMaterial_hgwnm")
|
||||
texture = ExtResource("2_ghoc2")
|
||||
local_coords = true
|
||||
|
||||
[node name="hitbox" parent="." index="2"]
|
||||
|
||||
@@ -1,20 +1,19 @@
|
||||
extends BulletBase
|
||||
|
||||
@onready var trail: GPUParticles2D = $"%trail"
|
||||
@onready var track: Node2D = $"%track"
|
||||
|
||||
var readyTime: float = 1000
|
||||
|
||||
func register():
|
||||
speed = -10
|
||||
func spawn():
|
||||
trail.emitting = false
|
||||
speed = 10
|
||||
func ai():
|
||||
if timeLived() < readyTime:
|
||||
PresetBulletAI.lockLauncher(self, launcher, true)
|
||||
rotation = launcher.position.angle_to_point(launcher.currentFocusedBoss.position)
|
||||
hitbox.disabled = true
|
||||
else:
|
||||
damage = speed / 4
|
||||
PresetBulletAI.forward(self, rotation)
|
||||
speed += 2
|
||||
trail.emitting = true
|
||||
speed *= 1.2
|
||||
track.visible = false
|
||||
hitbox.disabled = false
|
||||
|
||||
Reference in New Issue
Block a user