GameMap其他初始化

//其他初始化
init_prop();//初始化道具
init_ornamemtal();//初始化装饰物
init_monster_type_info();//初始化怪物基本信息
这个比较重要在加载NPC时会用到这些基本信息的储存在m_monster_type_infos[mo_type_info.nBodyID] = mo_type_info;
貌似战斗模拟器也要用到这些数值
init_region();//具体的区域有安全区,战斗区,摆摊区...
init_skill_info();初始化技能等级信息这个也很有用
init_dropinfo();初始化怪物掉落信息
init_player_droprule();初始化人物物品掉落信息
init_pet_attribute();初始化宠物的等级信息

//NPC的加载
m_spNPCmgr = NEWSP(NPCmgr); //NPC加载,如怪物等
m_spNPCmgr->setFT(m_spTimerFactory.get()); //共享Map中的定时器,让Map线程来驱动。
m_spNPCmgr->init(this); //一定要先调用地图
m_spNPCmgr->initNPC();

//罪恶(玩家有白名,红名,灰名)
m_spSinMgr.reset(new SinMgr);
m_spSinMgr->setFT(m_spTimerFactory.get());
m_spSinMgr->init(this);

//初始化人物信息
InitMission();

//这两个不知干啥的
m_sendBuffer = new char[1024 * 1000];    

m_status_opt = new StatusOpt(this, m_spTimerFactory.get());

start();//开启线程,驱动定时器运行程序
void thrTransData::start()
{
    m_thr.reset(new std::thread(std::bind(&thrTransData::thread, this)));
}

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值