ACE3/addons/core/functions/fnc_interpolateFromArray.sqf
2015-01-12 05:14:15 -06:00

13 lines
269 B
Plaintext

// by commy2
#include "\z\ace\addons\core\script_component.hpp"
private ["_array", "_value", "_min", "_max"];
_array = _this select 0;
_value = _this select 1;
_min = _array select floor _value;
_max = _array select ceil _value;
_min + (_max - _min) * (_value % 1)