1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-05-28 06:51:54 +08:00

feat(游戏机制): 调整掉落物品数量和添加错误提示

增加boss和非boss敌人死亡时掉落水晶的数量范围
为武器镶嵌/移除灵魂操作添加错误提示
移除Starter场景中不必要的属性设置
新增CharacterCardBase基础组件
This commit is contained in:
2026-05-04 18:14:21 +08:00
parent c23d0355fe
commit e8ee2932bb
4 changed files with 51 additions and 3 deletions
@@ -0,0 +1,44 @@
[gd_scene format=3 uid="uid://m8a4nay1pmmg"]
[ext_resource type="Texture2D" uid="uid://dwwpkn4q07ja2" path="res://icon.svg" id="1_5td0u"]
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_dt83t"]
content_margin_left = 20.0
content_margin_top = 20.0
content_margin_right = 20.0
content_margin_bottom = 20.0
bg_color = Color(0, 0, 0, 0.70000005)
border_width_top = 10
border_width_bottom = 10
border_color = Color(1, 1, 1, 1)
border_blend = true
corner_radius_top_left = 15
corner_radius_bottom_right = 15
corner_detail = 1
[node name="CharacterCardBase" type="Control" unique_id=2051062087]
layout_mode = 3
anchors_preset = 0
offset_right = 200.0
offset_bottom = 300.0
[node name="panel" type="PanelContainer" parent="." unique_id=1046363300]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
theme_override_styles/panel = SubResource("StyleBoxFlat_dt83t")
[node name="wrapper" type="VBoxContainer" parent="panel" unique_id=2023039659]
layout_mode = 2
[node name="TextureRect" type="TextureRect" parent="panel/wrapper" unique_id=1334645594]
custom_minimum_size = Vector2(100, 100)
layout_mode = 2
size_flags_horizontal = 4
size_flags_vertical = 4
texture = ExtResource("1_5td0u")
expand_mode = 1
stretch_mode = 5
@@ -243,7 +243,6 @@ theme_override_constants/separation = 6
[node name="diffs" type="HBoxContainer" parent="content/wrapper/layout/startGameWrapper/start/starter/singleplayer/playConfig" index="0" unique_id=526058063]
layout_mode = 2
alignment = 1
[node name="tip" type="Label" parent="content/wrapper/layout/startGameWrapper/start/starter/singleplayer/playConfig/diffs" index="0" unique_id=1507689450]
layout_mode = 2
@@ -338,7 +337,6 @@ theme = ExtResource("4_lfxcn")
text = "多人游戏"
[node name="multiplayer" type="VBoxContainer" parent="content/wrapper/layout/startGameWrapper/start/starter" index="1" unique_id=2010516457]
visible = false
layout_mode = 2
theme_override_constants/separation = 15
alignment = 1
+1 -1
View File
@@ -419,7 +419,7 @@ func tryDie(by: BulletBase = null):
fields[FieldStore.Entity.MAX_HEALTH] * randf_range(1 - GameRule.beachballOffset, 1 + GameRule.beachballOffset),
position + MathTool.sampleInCircle(GameRule.itemDroppedSpawnOffset)
)
for i in randi_range(0, 10 if isBoss else 3):
for i in randi_range(0, 20 if isBoss else 5):
ItemDropped.generate(
ItemStore.ItemType.CRYSTAL,
5 if isBoss else 1,
+6
View File
@@ -87,6 +87,8 @@ func _ready():
soulLevel -= 1
updateStore(level, UIState.player)
rebuildInfo()
else:
UIState.showTip("[b]%s[/b]还未镶嵌任何灵魂!" % displayName, TipBox.MessageType.ERROR)
)
inlayBtn.pressed.connect(
func():
@@ -97,6 +99,10 @@ func _ready():
soulLevel += 1
updateStore(level, UIState.player)
rebuildInfo()
else:
UIState.showTip("持有的灵魂数量不足!", TipBox.MessageType.ERROR)
else:
UIState.showTip("[b]%s[/b]的灵魂槽位已满!" % displayName, TipBox.MessageType.ERROR)
)
moveLeftBtn.pressed.connect(
func():