fixed CCMesh clear (#3209)

This commit is contained in:
yinkaile
2018-09-10 11:13:50 +08:00
committed by pandamicro
parent 017cef94ae
commit 12ed923b2c
+1 -5
View File
@@ -214,11 +214,7 @@ var Mesh = cc.Class({
* @method clear
*/
clear () {
let subMeshes = this._subMeshes;
for (let i = 0; i < subMeshes.length; i++) {
subMeshes[i].destroy();
}
subMeshes.length = 0;
this._subMeshes.length = 0;
let ibs = this._ibs;
for (let i = 0; i < ibs.length; i++) {