1
This commit is contained in:
parent
63a3cfa766
commit
568e52a485
@ -309,14 +309,12 @@ void Creature::SelectSkillTargets(Skill* skill, const a8::Vec2& target_pos, std:
|
||||
target_list.insert(this);
|
||||
TouchAllLayerHumanList
|
||||
(
|
||||
[this, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
[this, skill, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
{
|
||||
#if 0
|
||||
if ((hum == this || hum->team_id == team_id) &&
|
||||
hum->GetPos().Distance(target_pos) < skill->meta->i->skill_distance()) {
|
||||
target_list.insert(hum);
|
||||
}
|
||||
#endif
|
||||
});
|
||||
}
|
||||
break;
|
||||
@ -324,42 +322,38 @@ void Creature::SelectSkillTargets(Skill* skill, const a8::Vec2& target_pos, std:
|
||||
{
|
||||
TouchAllLayerHumanList
|
||||
(
|
||||
[this, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
[this, skill, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
{
|
||||
#if 0
|
||||
if ((hum != this && hum->team_id == team_id) &&
|
||||
hum->GetPos().Distance(target_pos) < skill->i->skill_distance()) {
|
||||
hum->GetPos().Distance(target_pos) < skill->meta->i->skill_distance()) {
|
||||
target_list.insert(hum);
|
||||
}
|
||||
#endif
|
||||
});
|
||||
}
|
||||
break;
|
||||
case kST_EnemySingle:
|
||||
{
|
||||
#if 0
|
||||
Entity* entity = room->GetEntityByUniId(skill_target_id_);
|
||||
if (entity && entity->IsEntityType(ET_Player)) {
|
||||
Human* hum = (Human*)entity;
|
||||
#if 0
|
||||
if (IsEnemy(hum)) {
|
||||
target_list.insert(hum);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
}
|
||||
break;
|
||||
case kST_EnemyGroup:
|
||||
{
|
||||
TouchAllLayerHumanList
|
||||
(
|
||||
[this, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
[this, skill, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
{
|
||||
#if 0
|
||||
if ((hum->team_id != team_id) &&
|
||||
hum->GetPos().Distance(target_pos) < skill->i->skill_distance()) {
|
||||
hum->GetPos().Distance(target_pos) < skill->meta->i->skill_distance()) {
|
||||
target_list.insert(hum);
|
||||
}
|
||||
#endif
|
||||
});
|
||||
}
|
||||
break;
|
||||
@ -367,14 +361,12 @@ void Creature::SelectSkillTargets(Skill* skill, const a8::Vec2& target_pos, std:
|
||||
{
|
||||
TouchAllLayerHumanList
|
||||
(
|
||||
[this, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
[this, skill, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
{
|
||||
#if 0
|
||||
if ((hum->team_id != team_id) &&
|
||||
hum->GetPos().Distance(target_pos) < skill->i->skill_distance()) {
|
||||
hum->GetPos().Distance(target_pos) < skill->meta->i->skill_distance()) {
|
||||
target_list.insert(hum);
|
||||
}
|
||||
#endif
|
||||
});
|
||||
}
|
||||
break;
|
||||
@ -382,14 +374,12 @@ void Creature::SelectSkillTargets(Skill* skill, const a8::Vec2& target_pos, std:
|
||||
{
|
||||
TouchAllLayerHumanList
|
||||
(
|
||||
[this, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
[this, skill, &target_pos, &target_list] (Human* hum, bool& stop)
|
||||
{
|
||||
#if 0
|
||||
if ((hum == this || this->IsEnemy(hum)) &&
|
||||
hum->GetPos().Distance(target_pos) < skill->i->skill_distance()) {
|
||||
hum->GetPos().Distance(target_pos) < skill->meta->i->skill_distance()) {
|
||||
target_list.insert(hum);
|
||||
}
|
||||
#endif
|
||||
});
|
||||
}
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user