feat(游戏数据): 添加天赋和技能收集记录功能

在SingletonModuleComp中添加collection字段记录天赋和技能获取情况
新增addTalentRecord和addSkillRecord方法用于记录获取次数
修改getGameDate方法返回收集记录数据
在MissionCardComp中调用记录方法
新增MissionGetsComp组件文件
This commit is contained in:
panw
2026-01-05 16:39:34 +08:00
parent d1409770d6
commit 801659c33a
4 changed files with 84 additions and 2 deletions

View File

@@ -318,8 +318,10 @@ export class MissionCardComp extends CCComp {
.call(() => {
// 根据类型发送不同事件
if (this.curCardType === CardType.Talent) {
smc.addTalentRecord(selectedData.uuid);
oops.message.dispatchEvent(GameEvent.UseTalentCard, selectedData.uuid);
} else if (this.curCardType === CardType.Skill) {
smc.addSkillRecord(selectedData.uuid);
oops.message.dispatchEvent(GameEvent.UseSkillCard, selectedData.uuid);
}
// 后续扩展其他类型事件