// 一些通用的interface定义

import { Attribute } from "../domain/roleField/attribute";

export interface RewardInter {
    id: number;
    count: number;
}

export interface EquipInter {
    id: number;
    name: string;
    quality: number;
    suitId: number;
    hole: number;
    randomEffect: Array<number>;
    itid: number;
    hid?: number;
    times?: number;
};


export interface BagInter { id: number, itemName: string, count: number, type: number, hid: number, times?: number };
export interface ItemInter { id?: number, count?: number, seqId?: number, type?: number };

// 百家学宫，布阵武将位置
export interface SclPosInter {
    id: number;
    hid: number;
    isOpen: boolean;
}

// 百家学宫返回
export interface SclResultInter {
    id: number;
    position: SclPosInter[]
}

// pvp对手返回
export interface oppPlayersInter {
    pos: number; // 对手位置
    roleId: string; // 对手玩家id
    roleName: string; // 对手玩家名
    head: number; // 头像
    frame: number; // 相框
    spine: number; // 形象
    pLv: number; // 对手队伍等级
    defCe: number; // 防守阵容战力
    addScore: number; // 战胜后可获军功
    plusScore: number; // 连胜加成军功
    rankLv: number;
}

export interface oppHeroesDefenseInter {
    actorId: number;             // 武将id
    actorName: string;           // 武将名
    dataId: number;              // 出兵表唯一id
    relation: number;            // 地方还是我方
    direction: number;           // 方向
    outIndex: number;            // 玩家设置的出场顺序，即order字段
    x: number;                   // 战场x坐标
    y: number;                   // 战场y坐标
    var: number;                 // 变量
    lv: number;                  // 等级
    hide: number;                // 是否隐藏
    initial_ai: number;          // ai类型
    attribute: Attribute;
    star: number;                     // 星级
    skill: string | number;             // 技能
    seid: string;                     // 技能
    spine: string | number;             // 动画

}

export interface pvpEndParamInter {
    hid: number;
    damage: number;
    heal: number;
    underDamage: number;
}

export interface Uid {
    uid: string;
    sid: string;
}

export interface pushMail {
    route: string;
    data: mailData[];
    uids: Uid[];
}

export interface mailData {
    id: string;
    goods: RewardInter[];
    sendTime: number;
    endTime: number;
    content: string;
    status: number;
    mailType: number;
    sendName: string;
}