herobody
herobody() Function
Generates random numbers to emulate dice rolls; this is the partner function to herostun(). The parameters used when calling this function must be exactly the same as the parameters used when calling herostun(), and it must be called during the same macro as herostun() or an error will result. Refer to herostun() for full usage details.
Usage
<Has Sight lang="mtmacro" line> herobody(times, sides) </Has Sight> Parameters
times
- The sametimes
parameter that was used when calling herostun().sides
- The samesides
parameter that was used when calling herostun().
Examples
Roll a twenty-sided dice, and return the herobody() result as well.
<Has Sight lang="mtmacro" line>
[t: herostun(1, 20)] - [t: herobody(1, 20)
</Has Sight>
Returns a number that is between 1
and 20
for the herostun roll, and a number between 0
and 2
for the herobody roll.
Roll five ten-sided dice, and return the herobody() result as well, using variables. <Has Sight lang="mtmacro" line> [h: DiceTimes = 5] [h: DiceSides = 10] [t: herostun(DiceTimes, DiceSides)] - [t: herobody(DiceTimes, DiceSides)] </Has Sight>
Returns a number than is between5
and 50
for the herostun roll, and a number between 0
and 10
for the herobody roll.