支持上传logo

This commit is contained in:
2026-05-19 14:17:46 +08:00
parent 0429e9ebfc
commit c3b80943c2
3 changed files with 26 additions and 1 deletions

View File

@@ -40,6 +40,12 @@ export class PageMain extends BaseView {
/** 游戏名 */
@property(Node)
game_name: Node = null;
/** 奖励icon */
@property(Sprite)
game_logo: Sprite = null!;
/** 奖励icon */
@property(Sprite)
game_logo_bg: Sprite = null!;
/** 是否可以开始游戏 */
private _canStart = true;
@@ -52,6 +58,15 @@ export class PageMain extends BaseView {
this.lab_remain.string = "CHANCE:<color=#ff5656>" + USERDATA.point.toString() + "</color>"
this.initRw()
this.startFloatingAnimation()
// 加载配置的logo
if (USERDATA.logo && this.game_logo) {
Tools.remoteLoadSprite(USERDATA.logo, this.game_logo)
}
if (USERDATA.logo_back && this.game_logo_bg) {
Tools.remoteLoadSprite(USERDATA.logo_back, this.game_logo_bg)
}
}
// 界面关闭时的相关逻辑写在这(已经关闭的界面不会触发onHide)