Commit 788708f8 authored by 范雪寒's avatar 范雪寒

feat: 预加载逻辑

parent 75804d9a
......@@ -137,9 +137,16 @@ cc.Class({
const preloadArr = this._imageResList.concat(this._audioResList).concat(this._animaResList);
cc.assetManager.loadAny(preloadArr, null, null, (err, data) => {
this.loadEnd();
if (window && window["air"]) {
window["air"].hideAirClassLoading();
cc.find('Canvas').opacity = 0;
window.air.onCourseInScreen = (next) => {
cc.find('Canvas').opacity = 255;
this.loadEnd();
next();
}
window.air.hideAirClassLoading();
} else {
this.loadEnd();
}
cc.debug.setDisplayStats(false);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment