• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Main repository of MikuMikuStudio


Commit MetaInfo

修订版d737a67d69a0311d4f9f7b1575ffa0ec40b11b05 (tree)
时间2013-06-07 03:11:27
作者ZeroSeparation@gmail.com <ZeroSeparation@gmai...>
CommiterZeroSeparation@gmail.com

Log Message

Fixed a bug where attempting to collide with an empty mesh (0 vertices) would throw an exception rather than returning 0 results.

git-svn-id: http://jmonkeyengine.googlecode.com/svn/trunk@10643 75d07b2b-3a1a-0410-a2c5-0572b91ccdca

更改概述

差异

--- a/engine/src/core/com/jme3/scene/Mesh.java
+++ b/engine/src/core/com/jme3/scene/Mesh.java
@@ -896,6 +896,10 @@ public class Mesh implements Savable, Cloneable {
896896 BoundingVolume worldBound,
897897 CollisionResults results){
898898
899+ if (getVertexCount() == 0) {
900+ return 0;
901+ }
902+
899903 if (collisionTree == null){
900904 createCollisionData();
901905 }