import { Enum, Vec3 } from "cc";

export class model_item_data{
    public id:number = 0
    public name:string = "123"
    public width:number = 1080
    public height:number = 1000
    public list:model_content_item_data[] = [];
}

export class model_content_item_data{
    public x:number = 0;
    public y:number = 0;
    public w:number = 0;
    public h:number = 0;
    public buff_type:number = -1;
    public item_type:number = -1;
    public pos:Vec3 = null
}

export class settingData{
    public isOpenYinYue:boolean = true; //是否开启音乐
    public isOpenYinXiao:boolean = true; //是否开启音效
    public isOpenZhendong:boolean = true; //是否开启震动
}

export class level_data{
    public content:level_item_data[] = []
}

export class level_item_data{
    public content:string = ""
}

export class userInfo{
    public avatarUrl:string = ""
    public nickName:string = ""
    public gender:number = 0
    public city:string = ""
    public province:string = ""
    public country:string = ""
    public language:string = ""
}

export class userData{
    public id:number = 0
    public openid:string = ""
    public avatarUrl:string = ""
    public avatar_id:number = 0 //头像框id
    public photo_frame_img:string = "" //头像框地址
    public nickName:string = ""
    public unionid:string = ""
    public region_pid:number = 0
    public region_id:number = 0
    public license_plate:string = ""
    public ip:string = ""
    public platform:string = ""
    public create_at:string = ""
    public license_code:string = ""
    public token:string = ""
    public province_name:string = ""
    public city_name:string = ""
    public update_region_status:number = 1 //1:本周已经设置 0:本周未设置
    public tt_sidebar_reward_status:number = 0 //1:已经领取 0:未领取
    public free_game_number:number = 0 //今日免费玩游戏次数
    public share_number:number = 0     //今日分享次数
}

export class rankData{
    public score:number = 0 //最大积分
    public number:number = 0 //排名 0 没有分数和排名
    public ranking_desc:string = "" //	排名描述
    public user_id:number = 0 // 用户id
    public avatarUrl:string = "" //	头像
    public avatar_id:number = 0  //头像框id
    public photo_frame_img:string = ""//头像框地址
    public nickName:string = "" //昵称
    public license_code:string = "" //车牌号
    public car_id:number = 1 // 当前汽车图片id
    public car_url:string = "" // 当前汽车图片
    public car_name:string = "" // 当前汽车名字
    public province_code:string = "" //省简称
    public province_name:string = ""//省名字
    public city_name:string = ""//市名字
    public city_badge_status:number = 0 //城市徽章状态 1展示 0不展示
    public province_badge_status:number = 0 //省级徽章状态 1展示 0不展示
    public nationwide_badge_status:number = 0 //全国徽章状态 1展示 0不展示
    public quarter_rank_id:number = 0   //赛季排行id
}

export class guangboData{
    public title:string = ""
}

export class user_car_list{
    public car_list:number[] = []    // 汽车列表
    public default_car_id:number = 0 //	默认车辆
    public max_integral:number = 0   // 最高分
}

export class user_results{
    public unlock_car_list:number[] = [] //所有汽车列表
    public default_car_id:number = 0 //	默认车辆
    public obtain_list:number[] = [] //
    public ratio:string = ""
    public max_integral:number = 0  //最高分
    public city_badge_status:number = 0 //城市徽章状态 1展示 0不展示
    public province_badge_status:number = 0 //省级徽章状态 1展示 0不展示
    public nationwide_badge_status:number = 0 //全国徽章状态 1展示 0不展示
}

export class sysConfig{
    public game_introduction_img:string = ""//游戏介绍
    public free_ads_number:number = 0  //免费广告数量
    public free_game_time:number = 0   //免费游戏时间,单位s
    public free_game_number:number = 0 //今日免费玩游戏次数
    public share_number:number = 0     //今日分享次数
    public share_des:string = ''       //分享描述
    public game_end_prompt:string[] = []     //游戏结束提示
}

export class user_free_ads_data{
    public look_video_count:number = 0
    public start_date_time:number = 0
    public is_free:boolean = false
    public is_look_video_infinite_count_reward:boolean = false //是否看广告的无限次数奖励
}

export class user_red_dot_data {
    public bulletin_red_dot:number = 0    //公告 0:没有 1:红点 
    public sign_red_dot:number = 0        //签到 0:没有 1:红点 
    public mail_unread_number:number = 0  //邮件 未读数量 
}

export enum car_type {
    score = 0,
    suipian = 1,
}

export class car_item_data{
    public id:number = 0;
    public name:string = "";
    public unlock_points:number = 0;
    public cover:string = "";
    public home_cover:string = "";
    public ranking_cover:string = "";
    public stype:number = car_type.score;  // 0:分数车 1:碎片兑换
    public attribute:car_item_attribute_data = new car_item_attribute_data() //属性
    public background_cover:string = "";
    public temp_bag_list_item_data:bag_list_item_data = null //临时-背包列表数据(车库背包碎片)
}

export class car_item_attribute_data {
    public k_oil_number:number = 0   // 开局血量
    public k_sprint_cd:number = 0    // 开局冲刺(秒)
    public n_shield_cd:number = 0    // 游戏中护盾(秒)
    public n_star_cd:number = 0      // 游戏中星星(秒)
    public n_magnet_cd:number = 0    // 游戏中磁铁(秒)
}

export class mail_item_data {
    public id:number = 0
    public title:string = ''
    public create_at:string = ''
    public user_id:number = 0
    public state:number = 0      // 状态 0:未领取 1:已经领取
    public content:string = ''
    public rewards_list:mail_rewards_item_data[] = []  // 奖励列表
}

export class mail_rewards_item_data {
    public name:string = ''
    public icon:string = ''
    public quantity:number = 0 //数量
}

export class bag_type_item_data {
    public id:number = 0
    public name:string = '' 
}

export enum bag_type {
    car_suipian = 1,
    xiangkuang = 2,
    daoju = 3,
}

export class bag_list_item_data {
    public id:number = 0            //背包id
    public item_id:number = 0       //物品id
    public name:string = ''         //名称
    public stype:bag_type = bag_type.car_suipian //物品类型，1=兑换汽车碎片 2=相框 3=道具
    public description:string = ''  //描述
    public icon:string = ''         //图标
    public base_type:number = 0     //物品基础类型，1表示兑换物品，2表示游戏内使用物品
    public car_id:number = 0        //汽车id
    public quantity:number = 0      //数量
    public usage_status:number = 0  //使用状态，1:已经使用
    public user_id:number = 0       //用户id
}

export class sign_reward_data {
    public index:number = 0 //下标 签到时候使用
    public item_id:number = 0
    public name:string = '' //名字
    public icon:string = '' //图标
    public quantity:number = 0 //数量
    public current_sign_status:number = 0 //当前签到状态 1:表示当前签到位置
    public receive_status:number = 0 //领取状态 0:未领取 1:已经领取 
    public repair_sign_status:number = 0//补签状态 0:不可以补签 1:可以补签 
}

export class sign_total_reward_data{
    public index:number = 0 //下标 签到时候使用
    public item_id:number = 0
    public name:string = '' //名字
    public icon:string = '' //图标
    public quantity:number = 0 //数量
    public day_number:number = 0 //天数
    public is_receive_status:number = 0 //是否可以领取
    public receive_status:number = 0 //领取状态 0:未领取 1:已经领取 
}

export class quarter_rank_item_data {
    public ranking_number:string = ''
    public quarter_rank_id:number = 0
    public items_id:number = 0
    public icon:string = ''
    public name:string = ''
}

export class edit_game_config_data{
    public box_list:box_random_data[] = []
    public scores:box_random_data = null
    public car_init_num:number = 3;
    public buff_xing:number = 10;
    public buff_xi:number = 10;
    public buff_dun:number = 10;
    public buff_xi_range:number = 10;

    //
    public car_origin_speed:number = 700;
    public car_add_speed_time:number = 1;
    public car_add_speed_num:number = 0;
    public car_add_speed_max:number = 0;
    //
    public buff_xi_add_speed:number = 0;
    public buff_dun_add_speed:number = 0;
    public buff_xing_add_speed:number = 0;
}

export class box_random_data{
    public min:number = 0;
    public max:number = 0;
    public type:number = 0;
}

export class area_item_data{
    public id:number = -1;
    public name:string = '';
    public pid:number = -1;
    public list:area_item_data[] = []
}

export enum DirType{
    LEFT,
    RIGHT,
    NONE,
}




