WoW:API RandomRoll: Difference between revisions

From AddOn Studio
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
Performs a random roll between two numbers. This is the same as /roll, so the roll is shown to people around you.
{{wowapi}} __NOTOC__


RandomRoll("low", "high");
Performs a random roll between two numbers.
{{Code/Begin}}
RandomRoll([low, [high]])
{{Code/End}}


----
== Parameters ==
; ''Example:'' :
<big>'''Arguments'''</big>
RandomRoll("1", "100");
:(low, high)


; ''Result:'' : YourNameHere rolls 69. (1-100)
:;low : Integer - lowest number (default 1)
:;high : Integer - highest number (default 100)


----
<big>'''Returns'''</big>
{{template:WoW API}}
:nil
 
== Example ==
 
  RandomRoll(1, 10)
 
'''Result:''' ''<Your name>'' rolls. ''<number>'' (1-10)
 
== Details ==
:*If only ''low'' is provided, it is taken as the highest number
:*Does the same as '''/random low high'''

Revision as of 12:39, 9 November 2006

WoW API < RandomRoll

Performs a random roll between two numbers. Template:Code/Begin RandomRoll([low, [high]]) Template:Code/End

Parameters

Arguments

(low, high)
low
Integer - lowest number (default 1)
high
Integer - highest number (default 100)

Returns

nil

Example

 RandomRoll(1, 10)

Result: <Your name> rolls. <number> (1-10)

Details

  • If only low is provided, it is taken as the highest number
  • Does the same as /random low high