[add] Slot64

This commit is contained in:
建喵 2022-08-09 14:15:42 +08:00
parent aafd91facd
commit f978ffc29d
2 changed files with 167 additions and 152 deletions

View File

@ -5,233 +5,235 @@ import Config from "../Config";
// ======================================================================================= // =======================================================================================
/** 通用回傳SERVER創的帳號 */ /** 通用回傳SERVER創的帳號 */
interface CommonAccountResponse { interface CommonAccountResponse {
a: string; a: string;
pw: string; pw: string;
} }
// ======================================================================================= // =======================================================================================
interface CreateResquest { interface CreateResquest {
p: number; p: number;
} }
/** 直接玩(訪客給SERVER創帳號) */ /** 直接玩(訪客給SERVER創帳號) */
export class AccountCreateRequest extends NetRequest<CreateResquest, CommonAccountResponse> { export class AccountCreateRequest extends NetRequest<CreateResquest, CommonAccountResponse> {
get Method(): string { get Method(): string {
return "account.create"; return "account.create";
} }
constructor() { constructor() {
super(); super();
this.Data = { this.Data = {
p: Config.GetRunDevice(), p: Config.GetRunDevice(),
}; };
} }
} }
// ======================================================================================= // =======================================================================================
interface LoginResquest { interface LoginResquest {
p: number; p: number;
device_info: string[]; device_info: string[];
fcm_token: string; d: string;
a: string; fcm_token: string;
pw: string; a: string;
ver: string; pw: string;
ver: string;
} }
interface LoginResponse { interface LoginResponse {
pr: string; pr: string;
cu: string; cu: string;
} }
/** 通用登入 */ /** 通用登入 */
export class AccountLoginRequest extends NetRequest<LoginResquest, LoginResponse> { export class AccountLoginRequest extends NetRequest<LoginResquest, LoginResponse> {
get Method(): string { get Method(): string {
return "account.login"; return "account.login";
} }
constructor(account: string, password: string) { constructor(account: string, password: string) {
super(); super();
this.Data = { this.Data = {
p: Config.GetRunDevice(), p: Config.GetRunDevice(),
device_info: ["Windows", "Windows"], device_info: ["Windows", "Windows"],
fcm_token: "", d: "JianMiau",
a: account, fcm_token: "",
pw: password, a: account,
ver: BusinessTypeSetting.COMPILE_VERSION pw: password,
}; ver: BusinessTypeSetting.COMPILE_VERSION
} };
}
} }
// ======================================================================================= // =======================================================================================
interface CustomResquest { interface CustomResquest {
a: string; a: string;
pw: string; pw: string;
} }
/** 自定帳號榜定 */ /** 自定帳號榜定 */
export class CustomBindRequest extends NetRequest<CustomResquest, null> { export class CustomBindRequest extends NetRequest<CustomResquest, null> {
get Method(): string { get Method(): string {
return "register.account_bind"; return "register.account_bind";
} }
constructor(account: string, password: string) { constructor(account: string, password: string) {
super(); super();
this.Data = { this.Data = {
a: account, a: account,
pw: password, pw: password,
}; };
} }
} }
/** 自定帳號登入(回傳SERVER帳號) */ /** 自定帳號登入(回傳SERVER帳號) */
export class CustomLoginRequest extends NetRequest<CustomResquest, CommonAccountResponse> { export class CustomLoginRequest extends NetRequest<CustomResquest, CommonAccountResponse> {
get Method(): string { get Method(): string {
return "register.account_login"; return "register.account_login";
} }
constructor(account: string, password: string) { constructor(account: string, password: string) {
super(); super();
this.Data = { this.Data = {
a: account, a: account,
pw: password, pw: password,
}; };
} }
} }
// ======================================================================================= // =======================================================================================
interface FBResquest { interface FBResquest {
t: string; t: string;
} }
/** FB綁定 */ /** FB綁定 */
export class FBBindRequest extends NetRequest<FBResquest, null> { export class FBBindRequest extends NetRequest<FBResquest, null> {
get Method(): string { get Method(): string {
return "register.fb_bind"; return "register.fb_bind";
} }
constructor(token: string) { constructor(token: string) {
super(); super();
this.Data = { this.Data = {
t: token, t: token,
}; };
} }
} }
/** FB登入(回傳SERVER帳號) */ /** FB登入(回傳SERVER帳號) */
export class FBLoginRequest extends NetRequest<FBResquest, CommonAccountResponse> { export class FBLoginRequest extends NetRequest<FBResquest, CommonAccountResponse> {
get Method(): string { get Method(): string {
return "register.fb_login"; return "register.fb_login";
} }
constructor(token: string) { constructor(token: string) {
super(); super();
this.Data = { this.Data = {
t: token, t: token,
}; };
} }
} }
// ======================================================================================= // =======================================================================================
interface GoogleResquest { interface GoogleResquest {
c: string; c: string;
} }
/** GOOGLE綁定 */ /** GOOGLE綁定 */
export class GoogleBindRequest extends NetRequest<GoogleResquest, null> { export class GoogleBindRequest extends NetRequest<GoogleResquest, null> {
get Method(): string { get Method(): string {
return "register.google_bind"; return "register.google_bind";
} }
constructor(token: string) { constructor(token: string) {
super(); super();
this.Data = { this.Data = {
c: token, c: token,
}; };
} }
} }
/** GOOGLE登入(回傳SERVER帳號) */ /** GOOGLE登入(回傳SERVER帳號) */
export class GoogleLoginRequest extends NetRequest<GoogleResquest, CommonAccountResponse> { export class GoogleLoginRequest extends NetRequest<GoogleResquest, CommonAccountResponse> {
get Method(): string { get Method(): string {
return "register.google_login"; return "register.google_login";
} }
constructor(token: string) { constructor(token: string) {
super(); super();
this.Data = { this.Data = {
c: token, c: token,
}; };
} }
} }
// ======================================================================================= // =======================================================================================
interface AppleResquest { interface AppleResquest {
c: string; c: string;
} }
/** APPEL綁定 */ /** APPEL綁定 */
export class AppleBindRequest extends NetRequest<AppleResquest, null> { export class AppleBindRequest extends NetRequest<AppleResquest, null> {
get Method(): string { get Method(): string {
return "register.apple_bind"; return "register.apple_bind";
} }
constructor(token: string) { constructor(token: string) {
super(); super();
this.Data = { this.Data = {
c: token, c: token,
}; };
} }
} }
/** APPLE登入(回傳SERVER帳號) */ /** APPLE登入(回傳SERVER帳號) */
export class AppleLoginRequest extends NetRequest<AppleResquest, CommonAccountResponse> { export class AppleLoginRequest extends NetRequest<AppleResquest, CommonAccountResponse> {
get Method(): string { get Method(): string {
return "register.apple_login"; return "register.apple_login";
} }
constructor(token: string) { constructor(token: string) {
super(); super();
this.Data = { this.Data = {
c: token, c: token,
}; };
} }
} }
// ======================================================================================= // =======================================================================================
/** 電話驗證 */ /** 電話驗證 */
export interface PhoneCodeRequest { export interface PhoneCodeRequest {
p: string; p: string;
} }
export class PhoneGet extends NetRequest<PhoneCodeRequest, string> { export class PhoneGet extends NetRequest<PhoneCodeRequest, string> {
get Method(): string { get Method(): string {
return "register.phone_code"; return "register.phone_code";
} }
constructor(p: string) { constructor(p: string) {
super(); super();
this.Data = { this.Data = {
p: p p: p
}; };
} }
} }
export interface PhoneBindRequest { export interface PhoneBindRequest {
c: string; c: string;
} }
export class PhoneBind extends NetRequest<PhoneBindRequest, string> { export class PhoneBind extends NetRequest<PhoneBindRequest, string> {
get Method(): string { get Method(): string {
return "register.phone_bind"; return "register.phone_bind";
} }
constructor(c: string) { constructor(c: string) {
super(); super();
this.Data = { this.Data = {
c: c c: c
}; };
} }
} }
// ======================================================================================= // =======================================================================================
/** 旗標更新 */ /** 旗標更新 */
export class FlagOpenAdd extends NetRequest<number, string> { export class FlagOpenAdd extends NetRequest<number, string> {
get Method(): string { get Method(): string {
return "flag.open_add"; return "flag.open_add";
} }
constructor(type: number) { constructor(type: number) {
super(); super();
this.Data = type; this.Data = type;
} }
} }
// ======================================================================================== // ========================================================================================
export interface ForgotInfo { export interface ForgotInfo {
a: string; a: string;
p: string; p: string;
} }
/** 忘記密碼 */ /** 忘記密碼 */
export class ForgotPassword extends NetRequest<ForgotInfo, null> { export class ForgotPassword extends NetRequest<ForgotInfo, null> {
get Method(): string { get Method(): string {
return "register.account_forget"; return "register.account_forget";
} }
constructor(account: string, phone: string) { constructor(account: string, phone: string) {
super(); super();
this.Data = { this.Data = {
a: account, a: account,
p: phone, p: phone,
}; };
} }
} }

View File

@ -0,0 +1,13 @@
import SlotBase from "./Base/SlotBase";
export class Slot64 extends SlotBase {
//#region public
public get ID(): number { return 64; }
public get HasRetriggerFreeSpin(): boolean { return true; }
//#endregion
}
export default Slot64;