Merge pull request #787 from PZ157/PR-Branch

修复统率无法选将的严重bug
This commit is contained in:
Spmario233 2024-01-14 12:42:01 +08:00 committed by GitHub
commit 009ab0a43d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -7135,14 +7135,14 @@ export class Game extends Uninstantable {
event.avatars[i].classList.add('selecting');
}
}
let rand2 = [];
let rand = [];
for (let i = 0; i < event.config.width; i++) {
for (let j = 0; j < event.config.width - i; j++) {
rand2.push(i);
rand.push(i);
}
}
for (let i = 0; i < event.config.num; i++) {
let rand2 = rand2.randomGet();
let rand2 = rand.randomGet();
for (let j = 0; j < rand2.length; j++) {
if (rand2[j] == rand2) {
rand2.splice(j--, 1);