fix: fk target number + update passion default
This commit is contained in:
parent
ae3a1be106
commit
c42e315a45
12
index.js
12
index.js
@ -101,7 +101,7 @@ const avgDiff = (arr) => {
|
||||
// FUN value: Fluctuating Unfairness Normalization value
|
||||
// PASSION: Player Ability/Skill Separation Index Offset Number
|
||||
let funInput = 4; // 1-10
|
||||
let passionInput = 2; // 1-5
|
||||
let passionInput = 1; // 1-5
|
||||
|
||||
// balance attempt counter, not modifiable
|
||||
let attempts = 0;
|
||||
@ -428,7 +428,7 @@ client.on("interactionCreate", async (interaction) => {
|
||||
);
|
||||
}
|
||||
|
||||
const targetPlayerCount = 3;
|
||||
const targetPlayerCount = 18;
|
||||
if (pickingPlayers.length + addupPlayers.length < targetPlayerCount) {
|
||||
return await interaction.followUp(
|
||||
`Can't find enough total players, expected ${targetPlayerCount} (found ${
|
||||
@ -468,13 +468,13 @@ client.on("interactionCreate", async (interaction) => {
|
||||
}
|
||||
fkAttempts++;
|
||||
const idx = Math.floor(Math.random() * pickingPlayers.length);
|
||||
let fk = await pickingPlayers.splice(idx, 1)[0];
|
||||
let fk = pickingPlayers[idx]
|
||||
if (protectedFk.includes(fk.id)) {
|
||||
protectedStr += `${fk.id}, `;
|
||||
pickingPlayers.push(fk);
|
||||
continue;
|
||||
} else {
|
||||
pickingPlayers.splice(idx, 1);
|
||||
fatkids.push(fk);
|
||||
}
|
||||
fatkids.push(fk);
|
||||
}
|
||||
if (protectedStr.length > 0) {
|
||||
console.log(`Protected fks: ${protectedStr}`);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user