1
This commit is contained in:
parent
22d4b189a3
commit
9f3f07b50d
@ -335,3 +335,23 @@ float Ability::GetFixedSped()
|
|||||||
{
|
{
|
||||||
return fixed_speed_;
|
return fixed_speed_;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
AttrAdditionHandle Ability::AddAttr(int attr_id, float rate)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void Ability::RemoveAttrAddition(AttrAdditionHandle handler)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
AttrRuduceHandle Ability::DecAttr(int attr_id, float rate)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void Ability::RemoveAttrRuduce(AttrRuduceHandle handler)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
@ -3,6 +3,9 @@
|
|||||||
#include "attrdefine.h"
|
#include "attrdefine.h"
|
||||||
#include "weakptr.h"
|
#include "weakptr.h"
|
||||||
|
|
||||||
|
typedef std::weak_ptr<struct AttrAddition> AttrAdditionHandle;
|
||||||
|
typedef std::weak_ptr<struct AttrRuduce> AttrRuduceHandle;
|
||||||
|
|
||||||
class Room;
|
class Room;
|
||||||
class Human;
|
class Human;
|
||||||
class Ability
|
class Ability
|
||||||
@ -64,10 +67,17 @@ class Ability
|
|||||||
int GetFixedSpeedTimes();
|
int GetFixedSpeedTimes();
|
||||||
float GetFixedSped();
|
float GetFixedSped();
|
||||||
|
|
||||||
|
AttrAdditionHandle AddAttr(int attr_id, float rate);
|
||||||
|
void RemoveAttrAddition(AttrAdditionHandle handler);
|
||||||
|
AttrRuduceHandle DecAttr(int attr_id, float rate);
|
||||||
|
void RemoveAttrRuduce(AttrRuduceHandle handler);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::array<float, kHAT_End> buff_attr_abs_ = {};
|
std::array<float, kHAT_End> buff_attr_abs_ = {};
|
||||||
std::array<float, kHAT_End> buff_attr_rate_ = {};
|
std::array<float, kHAT_End> buff_attr_rate_ = {};
|
||||||
std::array<int, kHAT_End> buff_attr_flag_ = {};
|
std::array<int, kHAT_End> buff_attr_flag_ = {};
|
||||||
|
std::array<std::tuple<float, list_head>, kHAT_End> attr_add_ = {};
|
||||||
|
std::array<std::tuple<float, list_head>, kHAT_End> attr_dec_ = {};
|
||||||
|
|
||||||
int speed_addition_times_ = 0;
|
int speed_addition_times_ = 0;
|
||||||
float speed_addition_rate_ = 0;
|
float speed_addition_rate_ = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user