Difference between revisions of "Abs"
Jump to navigation
Jump to search
imported>Geckbot m (Robot: Automated text replacement (-\[\[Category:(.*?)\(GECK 1.0\)\]\] +Category:\1(GECK 1.1))) |
imported>Ez0n3 |
||
Line 1: | Line 1: | ||
== | {{Function | ||
|origin = GECK1 | |||
|summary = When given a number, returns the absolute value of the number. | |||
|name = Abs | |||
== | |returnType = int | ||
|arguments = | |||
{{FunctionArgument | |||
|Name = x | |||
|Type = int | |||
}} | |||
|example = abs x | |||
Will return the absolute value of x. | |||
}} | |||
==Notes== | ==Notes== |
Latest revision as of 23:29, 12 January 2011
< [[::Category:Functions|Category:Functions]]
A function included in the GECK version 1.1.0.36.
Description
When given a number, returns the absolute value of the number.
Syntax
(int) Abs x:int
Example
abs x
Will return the absolute value of x.
Notes
- Sin, cos, tan, pow, log, and abs (particularly pow and log) are extremely slow. Do not use them in script blocks that get executed every frame.
- This function is new in the GECK, and was not available in the TES4 Construction Set. However, it was available through the OBSE script extender.