OpenFusion/src/Abilities.hpp

54 lines
921 B
C++
Raw Normal View History

#pragma once
#include "Entities.hpp"
2022-07-20 16:15:01 +00:00
#include "Player.hpp"
#include <map>
#include <vector>
2022-05-17 00:28:27 +00:00
enum class SkillEffectTarget {
POINT = 1,
SELF = 2,
CONE = 3,
WEAPON = 4,
AREA_SELF = 5,
AREA_TARGET = 6
};
enum class SkillTargetType {
MOBS = 1,
2022-05-18 14:04:28 +00:00
SELF = 2,
GROUP = 3
2022-05-17 00:28:27 +00:00
};
enum class SkillDrainType {
ACTIVE = 1,
PASSIVE = 2
};
struct SkillData {
2022-07-19 08:09:25 +00:00
int skillType; // eST
2022-05-17 00:28:27 +00:00
SkillEffectTarget effectTarget;
int effectType; // always 1?
SkillTargetType targetType;
SkillDrainType drainType;
int effectArea;
2022-05-16 20:47:30 +00:00
int batteryUse[4];
int durationTime[4];
2022-05-16 20:47:30 +00:00
int valueTypes[3];
int values[3][4];
};
namespace Abilities {
extern std::map<int32_t, SkillData> SkillTable;
2022-05-16 20:47:30 +00:00
2022-05-17 00:28:27 +00:00
std::vector<EntityRef> matchTargets(SkillData*, int, int32_t*);
2022-07-20 16:15:01 +00:00
int getCSTBFromST(int eSkillType);
bool usePassiveNanoSkill(SkillData*, Player*, int);
2022-05-18 14:04:28 +00:00
2022-05-16 20:47:30 +00:00
void init();
}