AccountModelComp.ts 841 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. /*
  2. * @Author: dgflash
  3. * @Date: 2021-11-12 10:02:31
  4. * @LastEditors: mojunshou 1637302775@qq.com
  5. * @LastEditTime: 2025-04-01 18:49:12
  6. */
  7. import { ecs } from "../../../../../extensions/oops-plugin-framework/assets/libs/ecs/ECS";
  8. /**
  9. * 游戏账号数据
  10. */
  11. @ecs.register('AccountModel')
  12. export class AccountModelComp extends ecs.Comp {
  13. /** 账号名 */
  14. AccountName: string = null!;
  15. /**玩家UID */
  16. Uid: number = -1;
  17. /**玩家头像*/
  18. HeadUrl: string = null!
  19. /**当前关卡--默认从0开始*/
  20. CurLevel: number = 0;
  21. /**游戏币*/
  22. GameCoin: number = 0;
  23. /**红包币*/
  24. CashCoin:number = 0;
  25. reset() {
  26. this.AccountName = null!;
  27. this.Uid = -1;
  28. this.HeadUrl = null!;
  29. this.CurLevel = 0;
  30. this.GameCoin = 0;
  31. this.CashCoin = 0;
  32. }
  33. }