Skip to content

Commit

Permalink
wx open data context no need to load builtins (cocos#3782)
Browse files Browse the repository at this point in the history
  • Loading branch information
knoxHuang authored and pandamicro committed Jan 23, 2019
1 parent c167bf4 commit fe5e0e8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cocos2d/core/platform/CCAssetLibrary.js
Original file line number Diff line number Diff line change
Expand Up @@ -414,6 +414,10 @@ function loadBuiltins (name, type, cb) {
}

AssetLibrary._loadBuiltins = function (cb) {
if (cc.game.renderType === cc.game.RENDER_TYPE_CANVAS) {
return cb && cb();
}

loadBuiltins('effect', cc.EffectAsset, () => {
loadBuiltins('material', cc.Material, cb);
});
Expand Down

0 comments on commit fe5e0e8

Please sign in to comment.