2
0
Nicolas Cannasse 8 жил өмнө
parent
commit
27eedc3f6d

+ 2 - 1
hxd/FloatBuffer.hx

@@ -46,7 +46,8 @@ abstract FloatBuffer(InnerData) {
 		#if flash
 		#if flash
 		if( v > this.length ) this.length = v;
 		if( v > this.length ) this.length = v;
 		#elseif js
 		#elseif js
-		while( v < this.length ) this.push(0.);
+		for( i in this.length...v )
+			this.push(0.);
 		#else
 		#else
 		if( v > this.length ) this[v - 1] = 0.;
 		if( v > this.length ) this[v - 1] = 0.;
 		#end
 		#end