35 lines
1.2 KiB
C#
35 lines
1.2 KiB
C#
using System.Collections.Generic;
|
|
using ET;
|
|
|
|
namespace Cal.DataTable
|
|
{
|
|
public partial class StarSoulAttributeConfigCategory
|
|
{
|
|
public List<KeyValuePair<AttributeType, long>> viceKeyList = new List<KeyValuePair<AttributeType, long>>(40);
|
|
public List<int> viceWeigt = new List<int>(40);
|
|
private Dictionary<(byte, byte), long> mainAttributeDic = new Dictionary<(byte, byte), long>();
|
|
|
|
public long GetMainValue(Quality quality, int key)
|
|
{
|
|
mainAttributeDic.TryGetValue(((byte, byte)) (quality, key), out long value);
|
|
return value;
|
|
}
|
|
public override void EndInit()
|
|
{
|
|
base.EndInit();
|
|
foreach (var kv in this.dict)
|
|
{
|
|
var config = kv.Value;
|
|
if (config.Type == 2)
|
|
{
|
|
viceKeyList.Add(KeyValuePair.Create<AttributeType, long>((AttributeType) config.Key,config.Id));
|
|
viceWeigt.Add(config.ViceWeight);
|
|
}
|
|
else
|
|
{
|
|
mainAttributeDic.Add((config.Quality,config.Key),kv.Key);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} |