level.h
640 Bytes
#pragma once
#include <common.h>
//////////////////////////////////////////////////////////////////////////
struct vip_level_cfg_t
{
uint32_t level;
uint32_t exp;
uint32_t exp_end;
float add_item_ret;
float add_vip_ret;
vip_level_cfg_t(){
this->level = 0;
this->exp = 0;
this->exp_end = -1;
this->add_item_ret = 0.000000f;
this->add_vip_ret = 0.000000f;
}
};
struct vip_level_cfg_mgr_t
{
bool load_cfg();
void init();
std::map<uint32_t, vip_level_cfg_t> level_exp_cfg_map;//key:level, val:exp
vip_level_cfg_t* find( uint32_t exp );
bool has_level(uint32_t level);
};
extern vip_level_cfg_mgr_t* g_vip_level_cfg_mgr;