pubgv3/assets/scripts/tips/LogoutTip.ts
zhuguoqing ff550d5d6a init
2022-05-22 10:32:02 +08:00

24 lines
438 B
TypeScript

import { UIBase } from '../UI/UIBase';
const { ccclass, property } = cc._decorator;
@ccclass
export class LogoutTip extends UIBase {
public static prefabPath = 'prefabs/tips/pb_logout';
init(data: any) {
// throw new Error('Method not implemented.');
}
onClickOK() {
this.node.destroy();
localStorage.removeItem('walletaccount');
window.hasWallet = false;
cc.game.restart();
}
onClose() {
this.node.destroy();
}
}