skill.cpp 768 Bytes
#include "skill.h"

eff_cfg_mgr_t* g_eff_cfg_mgr;

skill_t::skill_t()
{
	this->id = 0;
	this->type = 1;
	this->levelRate = 1;
	this->eff = NULL;
	this->priority = 0;
}

bool skill_t::is_kaichang()
{
	return 1 == this->type;
}

bool skill_t::is_xianfa()
{
	return 2 == this->type;
}

bool skill_t::is_zhudong()
{
	return 3 == this->type;
}

bool skill_t::is_beidong()
{
	return 4 == this->type;
}

eff_t* eff_cfg_mgr_t::find( EFF_ID id )
{
	auto it = this->eff_map.find(id);
	if (this->eff_map.end() == it){
		return NULL;
	}
	return &it->second;
}

eff_t::eff_t()
{
	this->id = 0;
	this->func = NULL;
}

buf_t::buf_t()
{
	this->key = 0;//
	this->id = 0;
	this->time = -1;
	this->round = -1;
	this->param1 = 0;
	this->param2 = 0;
	this->param3 = 0;
	this->pet = NULL;
}