天梯派遣功能
fix:
天梯挂机等bug修复
This commit is contained in:
liangtongchuan
2020-10-15 23:17:01 +08:00
parent 85940779d2
commit 31c1190e2c
7 changed files with 245 additions and 45 deletions
+1 -1
View File
@@ -174,7 +174,7 @@ export function getRandEelm(source: Array<any> = [], cnt = 1): Array<any> {
if (cnt > source.length) return null;
if (cnt === source.length) return source;
let idxs = new Set();
for (let i = 1; i < cnt; ++i) {
for (let i = 0; i < cnt; ++i) {
let rand = Math.floor(Math.random() * source.length);
idxs.add(rand);
if (idxs.size == cnt) {