skill.cpp
768 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#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;
}