更新代码格式
This commit is contained in:
@@ -14,7 +14,7 @@ export class Main extends Laya.Script {
|
||||
StorageManager.getInstance().init()
|
||||
|
||||
const resources: Array<{ url: string, type?: any, lazy?: boolean }> = [
|
||||
{ url: respath.score_add_ui_res()},
|
||||
{ url: respath.score_add_ui_res() },
|
||||
|
||||
{ url: respath.dc_top_bg_normal, type: Laya.Loader.IMAGE },
|
||||
{ url: respath.dc_top_bg_month_finish, type: Laya.Loader.IMAGE },
|
||||
|
||||
@@ -121,9 +121,9 @@ export class UIManager extends Laya.Script {
|
||||
|
||||
public loadDCWtihMonth(year: number, month: number): void {
|
||||
this.closeTrophyUI()
|
||||
if (this.dc_ui) {
|
||||
this.dc_ui.loadWithMonth(year, month)
|
||||
}
|
||||
if (this.dc_ui) {
|
||||
this.dc_ui.loadWithMonth(year, month)
|
||||
}
|
||||
}
|
||||
|
||||
public closeDCUI(): void {
|
||||
|
||||
@@ -64,7 +64,6 @@ export class GameDone extends Laya.Script {
|
||||
}
|
||||
|
||||
onStart(): void {
|
||||
|
||||
// Laya.Tween.to(this.owner, { y: 0 }, 300, Laya.Ease.elasticOut)
|
||||
|
||||
Laya.Tween.to(this.obj_panel, { alpha: 1 }, 400, Laya.Ease.elasticOut, null, 100)
|
||||
|
||||
@@ -164,5 +164,4 @@ export class TopBar extends Laya.Script {
|
||||
sprite.graphics.clear()
|
||||
sprite.graphics.drawRoundRect(0, 0, sprite.width, sprite.height, 12, 12, 12, 12, "#f5f7fb")
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -135,7 +135,6 @@ export class DailyChallenge extends Laya.Script {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
this.btn_left.on(Laya.Event.CLICK, this, this.onClickLeft)
|
||||
this.btn_right.on(Laya.Event.CLICK, this, this.onClickRight)
|
||||
this.btn_left2.on(Laya.Event.CLICK, this, this.onClickLeft)
|
||||
@@ -276,7 +275,6 @@ export class DailyChallenge extends Laya.Script {
|
||||
this.onApplyUnit(unit)
|
||||
}
|
||||
|
||||
|
||||
onClickLeft(): void {
|
||||
if (this.currentIndex > 0) {
|
||||
this.currentIndex--
|
||||
|
||||
@@ -41,8 +41,7 @@ export class TrophyUnit extends Laya.Script {
|
||||
const find = user.get_trophyRecord(info.year, info.month)
|
||||
if (find) {
|
||||
UIManager.getInstance().loadTrophyShowUI(find)
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
UIManager.getInstance().loadDCWtihMonth(info.year, info.month)
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user