LlSqrt
From Second Life Wiki
(Redirected from LSL llSqrt)
| LSL Portal | | | Functions | | | Events | | | Types | | | Operators | | | Constants | | | Flow Control | | | Script Library | | | Tutorials |
Description
Function: float llSqrt( float val );| 4 | Function ID |
| 0.0 | Delay |
| 10.0 | Energy |
Returns a float that is the square root of val.
| • float | val | – | positive number (val >= 0.0) |
Triggers a Math Error for imaginary results (val < 0.0)
Examples
default { state_entry() { float num1 = llFrand(100.0); llOwnerSay("The square root of " + (string)num1 + " is " + (string)llSqrt(num1)); } }

