fix: trial avatar cannot enter battle

This commit is contained in:
letheriver2007
2025-04-21 22:11:14 +08:00
parent 49677c0f2f
commit 2bf2904844
2 changed files with 3 additions and 1 deletions

View File

@@ -15,6 +15,7 @@ public class AvatarConfigExcel : ExcelResource
[JsonIgnore] public List<AvatarSkillTreeConfigExcel> SkillTree = [];
public int AvatarID { get; set; } = 0;
public int AdventurePlayerID { get; set; }
public HashName AvatarName { get; set; } = new();
public int ExpGroup { get; set; } = 0;
public int MaxPromotion { get; set; } = 0;

View File

@@ -63,7 +63,8 @@ public class SceneSkillManager(PlayerInstance player) : BasePlayerManager(player
return GameData.AdventureAbilityConfigListData.GetValueOrDefault(monster.MonsterData.ID);
if (entity is AvatarSceneInfo avatar)
return GameData.AdventureAbilityConfigListData.GetValueOrDefault(avatar.AvatarInfo.GetAvatarId());
if (GameData.AvatarConfigData.TryGetValue(avatar.AvatarInfo.GetAvatarId(), out var excel))
return GameData.AdventureAbilityConfigListData.GetValueOrDefault(excel.AdventurePlayerID);
return null;
}