Open main menu

UESPWiki β

Morrowind Mod:XHypot

< Mod / Morrowind: Morrowind Mod: MWSE

A function added by MWSE.

xHypot returns the hypotenuse for sides a and b, c = sqrt(a*a + b*b). Unlike xSqrt this is more efficient than calculating the formula inside the script.

SyntaxEdit

hypotenuse (float): xHypot a (float) b (float)

ExampleEdit

float sideA
float sideB
float result

Setx sideA to 25
Setx sideB to 25
Setx result to xHypot sideA sideB

See AlsoEdit