NumToHex

From the Oblivion ConstructionSet Wiki
Jump to navigation Jump to search
< [[::Category:Functions|Category:Functions]]

A function added by the Oblivion Script Extender.

Syntax:

(hex:string) NumToHex num:short width:short

Returns a string representation of an integer in hexadecimal format. An optional width parameter ranging from 0 to 8 specifies the minimum number of digits toinclude; unused digits are padded with zeroes. By default, 8 digits are included.


Take care only to pass real numerics to this function. Passing string values, for example (such as numbers represented by string_var variables), will produce unintended output.