import { DadiguziYansuan, ZhenfaChouqu } from "../common/Xyc"
import GameDataCenter from "../data/GameDataCenter"

export default class NetConfig {
    // 某些方法不需要等待回调即可进行下一步,在这里判断
    static needWait(url: string, body: Object): boolean {
        // user: { adok:
        if (url == "user/adok") {
            return false
        }
        if (url == "dongtian/timeOut") {
            return false
        }
        if (url == "player/addClientError") {
            return false
        }
        if (url == 'player/maidian') {
            return false
        }
        //自动打怪
        if (url == 'zhangjie/daguai') {
            return false
        }
        //自动抽命盘-抽取 && 在自动 && 没在阵法界面 → 无需等待
        if (url == DadiguziYansuan.url && GameDataCenter.daDiGuZi.autoStart && !GameDataCenter.daDiGuZi.isInDaDiGuZiMain) {
            return false
        }
        return true
    }
}
