Files
DanhengServer-OpenSource/Common/Data/Excel/AvatarExpItemConfigExcel.cs
Somebody 87d228eb79 Feature:Asynchronous Operation & Formatting Code
- Now the async operation is enabled!
- Code formatted by Resharper plugin <3
2024-07-22 17:12:03 +08:00

25 lines
604 B
C#

namespace EggLink.DanhengServer.Data.Excel;
[ResourceEntity("AvatarExpItemConfig.json")]
public class AvatarExpItemConfigExcel : ExcelResource
{
public int ItemID { get; set; }
public int Exp { get; set; }
public override int GetId()
{
return ItemID;
}
public override void Loaded()
{
if (Exp > 0) GameData.AvatarExpItemConfigData.Add(GetId(), this);
}
public override void AfterAllDone()
{
GameData.ItemConfigData.TryGetValue(ItemID, out var itemConfig);
if (itemConfig == null) return;
itemConfig.Exp = Exp;
}
}