Skip to content

$random

$random will generate a random number between your chosen span.

Usage

$random[num1;num2;allow?;random?]

Parameters

FieldTypeDescriptionRequired
num1numberStart of the span.true
num2numberEnd of the span.true
allow?booleanAllows returning of decimal numbers.false
random?booleanIf the returned number will be random.false

Example(s)

This will return a random number between 20 and 250:

1
client.command({
2
name: "random",
3
code: `
4
$random[20;250]
5
`
6
});

Advanced Example

This will return a random decimal number between 25 and 50:

1
client.command({
2
name: "random",
3
code: `
4
$random[25;50;true]
5
`
6
});

This will return a random number between 45 and 64 and the second $random will be random as well:

1
client.command({
2
name: "random",
3
code: `
4
$random[45;65;false;true]
5
$random[45;65;false;true]
6
`
7
});