优化若干代码
This commit is contained in:
@@ -1,25 +1,31 @@
|
||||
import { _decorator, Component } from 'cc'
|
||||
const { ccclass, property } = _decorator
|
||||
|
||||
import AdapterHelper from '../../engine/utils/AdapterHelper'
|
||||
import PrefabLoader from '../../engine/utils/PrefabLoader'
|
||||
import { Logger } from '../../engine/utils/Logger'
|
||||
import ResourcePrefab from '../prefab/ResourcePrefab'
|
||||
|
||||
const { ccclass, property } = _decorator
|
||||
|
||||
@ccclass('SceneBase')
|
||||
export default class SceneBase extends Component {
|
||||
public static scriptName: string = 'SceneBase'
|
||||
onLoad() {
|
||||
AdapterHelper.fixApdater()
|
||||
this.onLoadMe()
|
||||
}
|
||||
onLoadMe() {}
|
||||
start() {
|
||||
this.onStartMe()
|
||||
}
|
||||
onStartMe() {}
|
||||
onDestroy() {
|
||||
this.onDestroyMe()
|
||||
}
|
||||
onDestroyMe() {}
|
||||
public static scriptName: string = 'SceneBase'
|
||||
|
||||
onLoad() {
|
||||
AdapterHelper.fixApdater()
|
||||
this.onLoadMe()
|
||||
}
|
||||
|
||||
onLoadMe() {
|
||||
}
|
||||
|
||||
start() {
|
||||
this.onStartMe()
|
||||
}
|
||||
|
||||
onStartMe() {
|
||||
}
|
||||
|
||||
onDestroy() {
|
||||
this.onDestroyMe()
|
||||
}
|
||||
|
||||
onDestroyMe() {
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user