This commit is contained in:
Putoo
2026-06-26 18:32:15 +08:00
parent c374f27d16
commit aefd94ccd6
5 changed files with 21 additions and 6 deletions

View File

@@ -364,6 +364,7 @@ public static class GameBus
{
return null;
}
double totalWeight = data.Sum(it => it.random);
int rnd = _randomInstance.Next(Convert.ToInt32(totalWeight) + 1);
double current = 0;
@@ -399,7 +400,7 @@ public static class GameBus
var onAward = result.FindIndex(it => it.code == item.code && it.parameter == item.par);
if (onAward > -1)
{
result[onAward].count += item.count;
result[onAward].count += RandomAssist.GetFormatedNumeric(item.minCount, item.maxCount);
}
else
{
@@ -408,7 +409,7 @@ public static class GameBus
code = item.code,
name = item.name,
parameter = item.par,
count = item.count
count = RandomAssist.GetFormatedNumeric(item.minCount, item.maxCount)
};
result.Add(add);
}