/** @format */ import {card, equip, hero, idNum, popGiftInfo} from '../proto/typedef' import {IRoleConfig} from '../config/RoleConfig' import {PREFAB_TYPE} from '../enums/Enum' import {ICardSkillConfig} from '../config/CardSkillConfig' import {ICardConsumeConfig} from '../config/CardConsumeConfig' import {IArmorConfig} from '../config/ArmorConfig' import {ICastleSkillConfig} from '../config/CastleSkillConfig' /** @format */ //角色基础属性 export interface IBaseAttr { HP: number attack: number spellAttack: number realAttack: number defense: number spellDefense: number attackCrit: number critNum: number hit: number dodge: number attackSpeed: number moveSpeed: number } export interface IRole extends IBaseAttr { cfg: IRoleConfig hero: hero grade: number power: number isAlter: boolean equips: IEquip[] } export interface ICard extends IBaseAttr { cfg: ICardSkillConfig card: card grade: number power: number debrisCfg: ICardConsumeConfig } export interface ICardDebris { cfg: ICardConsumeConfig num: number id: number } export interface IEquip extends IBaseAttr { cfg: IArmorConfig equip: equip grade: number power: number } export interface ICastleSkill extends IBaseAttr { cfg: ICastleSkillConfig lv: number isUse: boolean } //道具需求 export interface needIdNum extends idNum { need: number } //道具检测 export interface IOperateNeed { need: needIdNum[] canUp: boolean isMax: boolean } export interface IGoodShowInfo { id: number quality: number iconUrl: string grade: number stacking: boolean isDebris: boolean name: string goodType: PREFAB_TYPE } export interface ITimeGift extends popGiftInfo { isPop?: boolean } export interface IAdStatus { time: number min: string sec: string isZero: boolean inTime: boolean dailyTimes: number } export interface IServer { server_id: number server_name: string ip: string port: string url: string state: number create: boolean } export type ExtractUFromT = { [K in keyof T & keyof U]: T[K] }