mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-04 14:24:53 +08:00
14 lines
232 B
Haxe
14 lines
232 B
Haxe
package spine;
|
|
|
|
class ArrayUtils {
|
|
public static function resize<T>(array:Array<T>, count:Int, value:T) {
|
|
if (count < 0)
|
|
count = 0;
|
|
array.resize(count);
|
|
for (i in 0...count) {
|
|
array[i] = value;
|
|
}
|
|
return array;
|
|
}
|
|
}
|