-
Notifications
You must be signed in to change notification settings - Fork 1
/
targeting.h
31 lines (23 loc) · 1.3 KB
/
targeting.h
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
#pragma once
#include <vector>
struct mob_entity {
uint64_t GUID;
float distance;
int targetMark;
};
typedef uint64_t(*MOB_SELECTFUNCTION)(uint64_t current, std::vector<mob_entity>& list);
typedef uint64_t(*MOB_SELECTFUNCTION_WITH_MARK)(uint64_t current, std::vector<mob_entity>& list, const std::vector<int>& markPriority);
// Factor which define targeting range cone in front of camera. Minimum 2 is exactly same as FoV. Default is 2.2. Bigger value narrows the cone.
extern float targetingRangeCone;
// Return true when found a target
bool targetNearestEnemy(float distanceLimit);
bool targetWorldBoss(float distanceLimit);
bool targetEnemyConsideringDistance(MOB_SELECTFUNCTION selectFunction);
bool targetEnemyInCycle(MOB_SELECTFUNCTION selectFunction);
bool targetMarkedEnemyInCycle(MOB_SELECTFUNCTION_WITH_MARK selectFunction, string priority);
// Select mobs sorted by GUID
uint64_t selectNext(uint64_t current, vector<struct mob_entity>& list);
uint64_t selectPrevious(uint64_t current, vector<struct mob_entity>& list);
// Select mobs with mark;
uint64_t selectNextMark(const uint64_t current, vector<struct mob_entity>& list, const vector<int>& priority);
uint64_t selectPreviousMark(const uint64_t current, vector<struct mob_entity>& list, const vector<int>& priority);