December 2014 files
This commit is contained in:
@@ -1,9 +1,26 @@
|
||||
#pragma once
|
||||
|
||||
#include "TargetGoal.h"
|
||||
#include "EntitySelector.h"
|
||||
|
||||
class NearestAttackableTargetGoal;
|
||||
|
||||
// Anonymous class from NearestAttackableTargetGoal
|
||||
class SubselectEntitySelector : public EntitySelector
|
||||
{
|
||||
private:
|
||||
EntitySelector *m_subselector;
|
||||
NearestAttackableTargetGoal *m_parent;
|
||||
|
||||
public:
|
||||
SubselectEntitySelector(NearestAttackableTargetGoal *parent, EntitySelector *subselector);
|
||||
~SubselectEntitySelector();
|
||||
bool matches(shared_ptr<Entity> entity) const;
|
||||
};
|
||||
|
||||
class NearestAttackableTargetGoal : public TargetGoal
|
||||
{
|
||||
friend class SubselectEntitySelector;
|
||||
public:
|
||||
class DistComp
|
||||
{
|
||||
@@ -17,18 +34,15 @@ public:
|
||||
};
|
||||
|
||||
private:
|
||||
weak_ptr<Mob> target;
|
||||
const type_info& targetType;
|
||||
int randomInterval;
|
||||
DistComp *distComp;
|
||||
EntitySelector *selector;
|
||||
weak_ptr<LivingEntity> target;
|
||||
|
||||
public:
|
||||
//public NearestAttackableTargetGoal(Mob mob, const type_info& targetType, float within, int randomInterval, bool mustSee)
|
||||
//{
|
||||
// this(mob, targetType, within, randomInterval, mustSee, false);
|
||||
//}
|
||||
NearestAttackableTargetGoal(PathfinderMob *mob, const type_info& targetType, int randomInterval, bool mustSee, bool mustReach = false, EntitySelector *entitySelector = NULL);
|
||||
|
||||
NearestAttackableTargetGoal(Mob *mob, const type_info& targetType, float within, int randomInterval, bool mustSee, bool mustReach = false);
|
||||
virtual ~NearestAttackableTargetGoal();
|
||||
|
||||
virtual bool canUse();
|
||||
|
||||
Reference in New Issue
Block a user