New conf.json option claimsRequireMinFactionMembers (defaults to 1, effectively disabled) which can be increased to prevent small (potentially one player) factions from claiming land until they have more members
This commit is contained in:
parent
080ea3363b
commit
06f8082599
@ -76,6 +76,7 @@ public class Conf {
|
|||||||
|
|
||||||
public static boolean claimsMustBeConnected = false;
|
public static boolean claimsMustBeConnected = false;
|
||||||
public static boolean claimsCanBeUnconnectedIfOwnedByOtherFaction = true;
|
public static boolean claimsCanBeUnconnectedIfOwnedByOtherFaction = true;
|
||||||
|
public static int claimsRequireMinFactionMembers = 1;
|
||||||
|
|
||||||
public static double considerFactionsReallyOfflineAfterXMinutes = 0;
|
public static double considerFactionsReallyOfflineAfterXMinutes = 0;
|
||||||
|
|
||||||
|
@ -476,6 +476,11 @@ public class FPlayer {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (myFaction.getFPlayers().size() < Conf.claimsRequireMinFactionMembers && !Conf.adminBypassPlayers.contains(this.playerName)) {
|
||||||
|
sendMessage("Your faction must have at least "+Conf.claimsRequireMinFactionMembers+" members to claim land.");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (Conf.worldsNoClaiming.contains(flocation.getWorldName())) {
|
if (Conf.worldsNoClaiming.contains(flocation.getWorldName())) {
|
||||||
sendMessage("Sorry, this world has land claiming disabled.");
|
sendMessage("Sorry, this world has land claiming disabled.");
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user