1
1
mirror of https://github.com/kokonect-link/cherrypick synced 2024-11-28 14:58:29 +09:00
This commit is contained in:
syuilo 2019-05-05 20:16:05 +09:00
parent 7aa66f438f
commit 17b373ac07
No known key found for this signature in database
GPG Key ID: BDC4C49D06AB9D69
3 changed files with 4 additions and 4 deletions

View File

@ -2059,8 +2059,8 @@ pages:
_seedRandomPick:
arg1: "シード"
arg2: "リスト"
dailyRPWPM: "確率付きリストからランダムに選択 (ユーザーごとに日替わり)"
_ddailyRPWPM:
DRPWPM: "確率付きリストからランダムに選択 (ユーザーごとに日替わり)"
_DRPWPM:
arg1: "テキストのリスト"
number: "数値"
stringToNumber: "テキストを数値に"

View File

@ -178,7 +178,7 @@ export class ASEvaluator {
seedRandom: (seed: any, probability: number) => Math.floor(seedrandom(seed)() * 100) < probability,
seedRannum: (seed: any, min: number, max: number) => min + Math.floor(seedrandom(seed)() * (max - min + 1)),
seedRandomPick: (seed: any, list: any[]) => list[Math.floor(seedrandom(seed)() * list.length)],
dailyRPWPM: (list: string[]) => {
DRPWPM: (list: string[]) => {
const xs = [];
let totalFactor = 0;
for (const x of list) {

View File

@ -81,7 +81,7 @@ export const funcDefs: Record<string, { in: any[]; out: any; category: string; i
randomPick: { in: [0], out: 0, category: 'random', icon: faDice, },
dailyRandomPick: { in: [0], out: 0, category: 'random', icon: faDice, },
seedRandomPick: { in: [null, 0], out: 0, category: 'random', icon: faDice, },
dailyRPWPM: { in: ['stringArray'], out: 'string', category: 'random', icon: faDice, }, // dailyRandomPickWithProbabilityMapping
DRPWPM: { in: ['stringArray'], out: 'string', category: 'random', icon: faDice, }, // dailyRandomPickWithProbabilityMapping
};
export const literalDefs: Record<string, { out: any; category: string; icon: any; }> = {