Global/VectorRand

From Garry's Mod
(Difference between revisions)
Jump to: navigation, search
m (Line number updates)
 
Line 2: Line 2:
 
|Name=VectorRand
 
|Name=VectorRand
 
|Parent=Global
 
|Parent=Global
|Description=Returns a random vector whose components are each between [min, max).
+
|Description=Returns a random vector whose components are each between min(inclusive), max(exclusive).
 
|Realm=Shared and Menu
 
|Realm=Shared and Menu
 
|IsClass=No
 
|IsClass=No
Line 13: Line 13:
 
|default=-1
 
|default=-1
 
|desc=Min bound inclusive.
 
|desc=Min bound inclusive.
 
{{NextUpdate}}
 
 
}}
 
}}
 
{{Arg
 
{{Arg
Line 21: Line 19:
 
|default=1
 
|default=1
 
|desc=Max bound exclusive.
 
|desc=Max bound exclusive.
 
{{NextUpdate}}
 
 
}}
 
}}
 
{{Ret
 
{{Ret

Latest revision as of 17:44, 2 July 2019

 VectorRand( )

Contents

Description

Returns a random vector whose components are each between min(inclusive), max(exclusive).

Arguments

number min=-1

Min bound inclusive.

Arguments

number max=1

Max bound exclusive.

Returns

Vector

The random direction vector.
Personal tools
Navigation