Fix to mirror modifier loading (buffer bounds were exceeded in some cases).

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7945 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
3.0
Kae..pl 14 years ago
parent fbd1cb837b
commit 8de7a5755e
  1. 2
      engine/src/blender/com/jme3/scene/plugins/blender/helpers/v249/ModifierHelper.java

@ -699,7 +699,7 @@ public class ModifierHelper extends AbstractBlenderHelper {
//modifying clone indexes
int vertexIndex = (i - mirrorIndex) / 3;
if (vertexIndex % 3 == 0) {
if (vertexIndex % 3 == 0 && vertexIndex<cloneIndexes.limit()) {
int index = cloneIndexes.get(vertexIndex + 2);
cloneIndexes.put(vertexIndex + 2, cloneIndexes.get(vertexIndex + 1));
cloneIndexes.put(vertexIndex + 1, index);

Loading…
Cancel
Save