2023-09-12 18:58:10 +00:00
|
|
|
#include "..\script_component.hpp"
|
2015-01-11 16:42:31 +00:00
|
|
|
/*
|
2015-09-17 16:25:02 +00:00
|
|
|
* Author: commy2, esteldunedain
|
|
|
|
* Converts number to hexadecimal number
|
|
|
|
*
|
|
|
|
* Arguments:
|
2023-04-30 21:03:35 +00:00
|
|
|
* 0: A number between 0 and 255 <NUMBER>
|
2015-09-17 16:25:02 +00:00
|
|
|
*
|
|
|
|
* Return Value:
|
2015-09-19 22:55:58 +00:00
|
|
|
* A hexadecimal number as string <STRING>
|
2015-09-17 16:25:02 +00:00
|
|
|
*
|
2017-06-08 13:31:51 +00:00
|
|
|
* Example:
|
|
|
|
* [154] call ace_common_fnc_toHex
|
|
|
|
*
|
2015-09-17 16:25:02 +00:00
|
|
|
* Public: Yes
|
|
|
|
*/
|
2015-01-11 16:42:31 +00:00
|
|
|
|
2015-09-19 22:55:58 +00:00
|
|
|
params ["_number"];
|
2015-03-23 15:16:50 +00:00
|
|
|
|
2015-09-19 22:55:58 +00:00
|
|
|
_number = ((round abs _number) max 0) min 255;
|
2015-03-23 15:16:50 +00:00
|
|
|
|
2015-09-19 22:55:58 +00:00
|
|
|
GVAR(hexArray) select _number // return
|