From cd3b8d99deaca8206ef7f5ab3a84f52467ceb67b Mon Sep 17 00:00:00 2001 From: 2youyouo2 <501251991@qq.com> Date: Tue, 27 Sep 2016 10:25:54 +0800 Subject: [PATCH] fixed CCLoader --- cocos2d/core/load-pipeline/CCLoader.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cocos2d/core/load-pipeline/CCLoader.js b/cocos2d/core/load-pipeline/CCLoader.js index 96842fab1a..bb5f609ce1 100644 --- a/cocos2d/core/load-pipeline/CCLoader.js +++ b/cocos2d/core/load-pipeline/CCLoader.js @@ -194,8 +194,9 @@ JS.mixin(CCLoader.prototype, { items.destroy(); if (CC_EDITOR) { - // raw assets are not cached in the CC_EDITOR fix fireball/issues/4158 - self.clear(); + for (var i = 0; i < resources.length; i++) { + self.removeItem(resources[i].id || resources[i]); + } } }); });