12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- namespace XGame.Database
- {
- public partial class EquipmentDropTableRepo
- {
- public static int[] GetEquipIds(EQualityLevel quality, int playerLv)
- {
- Log.Info("权重随机装备品质:" + quality);
- var dataList = GetAll();
- for (int i = 0; i < dataList.Length; i++)
- {
- if (dataList[i].LevelPeriod[0] <= playerLv && playerLv <= dataList[i].LevelPeriod[1])
- {
- switch (quality)
- {
- case EQualityLevel.White:
- return dataList[i].DropPool1;
- case EQualityLevel.Green:
- return dataList[i].DropPool2;
- case EQualityLevel.Blue:
- return dataList[i].DropPool3;
- case EQualityLevel.Purple:
- return dataList[i].DropPool4;
- case EQualityLevel.Yellow:
- return dataList[i].DropPool5;
- case EQualityLevel.Orange:
- return dataList[i].DropPool6;
- case EQualityLevel.Red:
- return dataList[i].DropPool7;
- case EQualityLevel.Pink:
- return dataList[i].DropPool8;
- case EQualityLevel.BlueDiamond:
- return dataList[i].DropPool9;
- case EQualityLevel.Gilding:
- return dataList[i].DropPool10;
- case EQualityLevel.Bright:
- return dataList[i].DropPool11;
- default:
- return dataList[i].DropPool1;
- }
- }
- }
- return new int[0];
- }
- }
- }
|