Use of AltCommandChannelFriends configuration at Player isAutoAttackable method.

Contributed by Enryu.
This commit is contained in:
MobiusDevelopment
2022-06-12 12:08:06 +00:00
parent df44eccf01
commit 0c4c85f3b6
23 changed files with 138 additions and 0 deletions
@@ -8261,6 +8261,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8264,6 +8264,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8266,6 +8266,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8261,6 +8261,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8278,6 +8278,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8278,6 +8278,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8279,6 +8279,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8294,6 +8294,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8396,6 +8396,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8422,6 +8422,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8459,6 +8459,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8487,6 +8487,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8171,6 +8171,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8171,6 +8171,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8157,6 +8157,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8184,6 +8184,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8184,6 +8184,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8138,6 +8138,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8149,6 +8149,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8290,6 +8290,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8357,6 +8357,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8537,6 +8537,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();
@@ -8574,6 +8574,12 @@ public class Player extends Playable
return false;
}
// Same Command Channel are friends.
if (Config.ALT_COMMAND_CHANNEL_FRIENDS && (isInParty() && (getParty().getCommandChannel() != null) && attacker.isInParty() && (attacker.getParty().getCommandChannel() != null) && (getParty().getCommandChannel() == attacker.getParty().getCommandChannel())))
{
return false;
}
// Get Player
final Player attackerPlayer = attacker.getActingPlayer();
final Clan clan = getClan();