1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-05-27 22:41:56 +08:00

feat: 添加多个召唤物的displayName并调整相关参数

refactor: 统一测试BOSS的wave配置
fix: 修正Parrier.gd中的launcher判断条件
perf: 调整MTY的攻击冷却时间和技能范围
style: 移除部分调试标记和冗余代码
This commit is contained in:
2026-04-25 13:17:17 +08:00
parent 3a8c48dae7
commit 7120eaa79e
12 changed files with 53 additions and 45 deletions
+1 -1
View File
@@ -29,7 +29,7 @@ func succeedToHit(_dmg: float, entity: EntityBase):
eff.shot()
entity.impluse((effSpawn - position).normalized() * 450)
func hitBullet(bullet: BulletBase): # 当前子弹与其他子弹相撞
if !is_instance_valid(bullet.launcher): return
if !is_instance_valid(launcher): return
if BulletTool.canDamage(bullet, launcher): # 其他子弹可以使当前子弹的发射者受伤吗?
if parryiedTimes < maxParryTimes && MathTool.rate(parryRate): # 一个刀光最多格挡多少个敌方子弹?
parryiedTimes += 1
+4 -4
View File
@@ -4,9 +4,9 @@ class_name MTY
func register():
fields[FieldStore.Entity.MAX_HEALTH] = 400
fields[FieldStore.Entity.MOVEMENT_SPEED] = 0.9
attackCooldownMap[0] = 2000
attackCooldownMap[1] = 750
attackCooldownMap[2] = 450
attackCooldownMap[0] = 4000
attackCooldownMap[1] = 1500
attackCooldownMap[2] = 500
sprintMultiplier = 5
func spawn():
texture.play("walk")
@@ -19,7 +19,7 @@ func attack(type: int):
trySprint()
elif type == 1:
var track = getTrackingAnchor()
var bullet = BulletTool.findClosetBulletCanDamage(track, get_tree(), self , 400)
var bullet = BulletTool.findClosetBulletCanDamage(track, get_tree(), self , 450)
if is_instance_valid(bullet):
BulletBase.generate(ComponentManager.getBullet("Parrier"), self , track, track.angle_to_point(bullet.position))
elif type == 2:
+5 -14
View File
@@ -31,7 +31,7 @@ static var WAVE_NORMAL = [
Wave.create("KukeMC", 0, 0, true, 19, INF, 20),
Wave.create("Bear", 0, 0, true, 29, INF, 23),
]
static var WAVE_TESTBOSS_ALL = [
static var WAVE_TESTBOSS = [
Wave.create("Deepsea", 0, 0, true, 0, INF, 6),
Wave.create("Kernyr", 0, 0, true, 1, INF, 6),
Wave.create("CyberCat", 0, 0, true, 2, INF, 6),
@@ -39,18 +39,9 @@ static var WAVE_TESTBOSS_ALL = [
Wave.create("KukeMC", 0, 0, true, 4, INF, 6),
Wave.create("Bear", 0, 0, true, 5, INF, 6),
]
static var WAVE_TESTBOSS_KUKE = [
Wave.create("KukeMC", 0, 0, true, 0, INF, 1),
]
static var WAVE_TESTBOSS_BEAR = [
Wave.create("Bear", 0, 0, true, 0, INF, 1),
]
static var WAVE_TESTBOSS_CHICK = [
Wave.create("Chick", 0, 0, true, 0, INF, 1),
]
static var WAVE_JUSTJOKE = [
# Wave.create("Kernyr", 0, 0, true, 0, INF, 1),
# Wave.create("CyberCat", 0, 0, true, 0, INF, 1),
Wave.create("Kernyr", 0, 0, true, 0, INF, 1),
Wave.create("CyberCat", 0, 0, true, 0, INF, 1),
Wave.create("Deepsea", 0, 0, true, 0, INF, 1)
]
static var WAVE_MOWING = [
@@ -60,10 +51,10 @@ static var WAVE_MOWING = [
Wave.create("MTY", 1, 5, false, 0, INF, 1),
]
static var WAVE_TESTMOB = [
Wave.create("MTY", 1, 1, false, 0, INF, 1)
Wave.create("MTY", 1, 10, false, 0, INF, 1)
]
static var WAVE_EMPTY = []
static var waveReleaseConfig = [WAVE_TESTBOSS_ALL, 1]
static var waveReleaseConfig = [WAVE_TESTBOSS, 1]
static var waveDebugConfig = [WAVE_TESTMOB, 1]
static var current: int = startWith(waveReleaseConfig[1]) if WorldManager.isRelease() else startWith(waveDebugConfig[1])
+2 -2
View File
@@ -200,8 +200,8 @@ func _physics_process(_delta: float) -> void:
ai()
elif isSummon():
ai()
velocity += inertia
inertia *= 0.9
velocity += inertia
inertia *= 0.9
move_and_slide()
var collision = get_last_slide_collision()
if is_instance_valid(collision):
+5
View File
@@ -2,11 +2,16 @@ extends CanvasItem
class_name EntityStateBar
@export var entity: EntityBase
@export var longer: bool = false
@onready var healthBar: ColorBar = $"%health"
@onready var levelLabel: Label = $"%level"
@onready var levelLabels: HBoxContainer = $"%levelLabel"
func _ready():
if longer:
healthBar.size.x *= 2
healthBar.position.x *= 2
func forceSync():
healthBar.maxValue = entity.fields[FieldStore.Entity.MAX_HEALTH]
healthBar.currentValue = entity.health