Fix crashing II.

This commit is contained in:
UnknownShadow200 2015-04-26 09:01:02 +10:00
parent 99bb316001
commit 8d68ebc3de

View File

@ -50,16 +50,16 @@ namespace ClassicalSharp {
vCount = ( iCount / 6 ) * 4;
vCount1 = Math.Min( vCount, maxIndices );
iCount1 = ( vCount1 / 4 ) * 6;
if( vCount1 > vertices1.Length ) {
vertices1 = new VertexPos3fTex2fCol4b[vCount1];
iCount1 = ( vCount1 / 4 ) * 6;
indices1 = new ushort[iCount1];
}
vCount2 = Math.Max( 0, vCount - maxIndices );
iCount2 = ( vCount2 / 4 ) * 6;
if( vCount2 > vertices2.Length ) {
vertices2 = new VertexPos3fTex2fCol4b[vCount2];
iCount2 = ( vCount2 / 4 ) * 6;
indices2 = new ushort[iCount2];
}
vertices = vertices1;