diff --git a/scripts/shared/native.js b/scripts/shared/native.js index 82f0005c..224001af 100644 --- a/scripts/shared/native.js +++ b/scripts/shared/native.js @@ -559,4 +559,10 @@ function combine(a, b, c) { return toInteger((a << 20) | (b << 10) | c); } +// =========================================================================== + +function getPercentage(num, per) { + return (num/100)*per; +} + // =========================================================================== \ No newline at end of file