X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fbattle%2FTargetSelection.cpp;h=876933061528176eebd3837b1fb50605f314fc39;hb=fde7b27297882a7f033641df92e732abd137b532;hp=5fbf78525d21d1318b636b5b63beb6f756c57c5c;hpb=b53c2ec2621ccc654e819cb203dc26e0a482bd41;p=l2e.git diff --git a/src/battle/TargetSelection.cpp b/src/battle/TargetSelection.cpp index 5fbf785..8769330 100644 --- a/src/battle/TargetSelection.cpp +++ b/src/battle/TargetSelection.cpp @@ -27,7 +27,7 @@ TargetSelection::TargetSelection(BattleState *battle, bool multiple, bool atEnem void TargetSelection::ReadMode(const common::TargetingMode &tm) { if (tm.TargetsEnemy()) { - SelectEnemies(); + SelectMonsters(); } else { SelectHeroes(); } @@ -39,8 +39,8 @@ void TargetSelection::ReadMode(const common::TargetingMode &tm) { } -void TargetSelection::SelectEnemies() { - if (TargetsEnemies()) return; +void TargetSelection::SelectMonsters() { + if (TargetsMonsters()) return; enemy = true; UnselectAll(); cursor = 0; @@ -58,23 +58,23 @@ void TargetSelection::SelectHeroes() { void TargetSelection::Reset() { UnselectAll(); cursor = 0; - if (TargetsEnemies()) { + if (TargetsMonsters()) { FindNextEnemy(); } } void TargetSelection::MoveUp() { - if (TargetsEnemies()) return; + if (TargetsMonsters()) return; if (cursor < 2) { - SelectEnemies(); + SelectMonsters(); } else { cursor -= 2; } } void TargetSelection::MoveRight() { - if (TargetsEnemies()) { + if (TargetsMonsters()) { cursor = (cursor + 1) % battle->MaxMonsters(); while (!battle->MonsterPositionOccupied(cursor)) { cursor = (cursor + 1) % battle->MaxMonsters(); @@ -85,7 +85,7 @@ void TargetSelection::MoveRight() { } void TargetSelection::MoveDown() { - if (TargetsEnemies()) { + if (TargetsMonsters()) { SelectHeroes(); return; } @@ -96,7 +96,7 @@ void TargetSelection::MoveDown() { } void TargetSelection::MoveLeft() { - if (TargetsEnemies()) { + if (TargetsMonsters()) { cursor = (cursor + battle->MaxMonsters() - 1) % battle->MaxMonsters(); FindNextEnemy(); } else {