|
@@ -29,7 +29,7 @@ export class home extends Component {
|
|
|
this.node.parent.active = false
|
|
|
})
|
|
|
})
|
|
|
-
|
|
|
+
|
|
|
ClientEvent.on(config.UI_EVENT.GAME_OVER_SETTLE_ACCOUNT,this.onGameOverSettleAccount.bind(this),this)
|
|
|
ClientEvent.on(config.UI_EVENT.GET_NEW_CAR,this.onGetNewCar.bind(this),this)
|
|
|
ClientEvent.on(config.UI_EVENT.UPDATE_USER_DEFAULT_CAR,this.onUpdateUserDefaultCar.bind(this),this)
|
|
@@ -39,6 +39,13 @@ export class home extends Component {
|
|
|
ClientEvent.on(config.UI_EVENT.UPDATE_MAIL_RED_DOT_STATUS,this.onUpdateMailRedDotStatus.bind(this),this)
|
|
|
ClientEvent.on(config.UI_EVENT.UPDATE_ANNOUNCEMENT_RED_DOT_STATUS,this.onUpdateAnnouncementRedDotStatus.bind(this),this)
|
|
|
}
|
|
|
+
|
|
|
+ public init(){
|
|
|
+ this.top.getComponent(home_top).init()
|
|
|
+ this.home_car.getComponent(home_car).updateCar()
|
|
|
+ this.bottom.getComponent(home_bottom).init()
|
|
|
+ this.modules.getComponent(home_modules).init()
|
|
|
+ }
|
|
|
|
|
|
onGameOverSettleAccount(res:user_results){
|
|
|
// 更新本周分数、荣誉
|
|
@@ -99,13 +106,6 @@ export class home extends Component {
|
|
|
onUpdateAnnouncementRedDotStatus(is_show:boolean) {
|
|
|
this.modules.getComponent(home_modules).showRedDotGonggao(is_show)
|
|
|
}
|
|
|
-
|
|
|
- public init(){
|
|
|
- this.top.getComponent(home_top).init()
|
|
|
- this.home_car.getComponent(home_car).updateCar()
|
|
|
- this.bottom.getComponent(home_bottom).init()
|
|
|
- this.modules.getComponent(home_modules).init()
|
|
|
- }
|
|
|
}
|
|
|
|
|
|
|