Don't enable our own f top command if other plugin that handles it is enabled. Resolves #1066
This commit is contained in:
parent
47eb14c845
commit
055adf2e9e
@ -3,8 +3,10 @@ package com.massivecraft.factions.cmd;
|
|||||||
import com.massivecraft.factions.Conf;
|
import com.massivecraft.factions.Conf;
|
||||||
import com.massivecraft.factions.P;
|
import com.massivecraft.factions.P;
|
||||||
import com.massivecraft.factions.zcore.util.TL;
|
import com.massivecraft.factions.zcore.util.TL;
|
||||||
|
import org.bukkit.Bukkit;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
public class FCmdRoot extends FCommand {
|
public class FCmdRoot extends FCommand {
|
||||||
|
|
||||||
@ -163,7 +165,6 @@ public class FCmdRoot extends FCommand {
|
|||||||
this.addSubCommand(this.cmdModifyPower);
|
this.addSubCommand(this.cmdModifyPower);
|
||||||
this.addSubCommand(this.cmdLogins);
|
this.addSubCommand(this.cmdLogins);
|
||||||
this.addSubCommand(this.cmdClaimLine);
|
this.addSubCommand(this.cmdClaimLine);
|
||||||
this.addSubCommand(this.cmdTop);
|
|
||||||
this.addSubCommand(this.cmdAHome);
|
this.addSubCommand(this.cmdAHome);
|
||||||
this.addSubCommand(this.cmdPerm);
|
this.addSubCommand(this.cmdPerm);
|
||||||
this.addSubCommand(this.cmdPromote);
|
this.addSubCommand(this.cmdPromote);
|
||||||
@ -174,6 +175,11 @@ public class FCmdRoot extends FCommand {
|
|||||||
this.addSubCommand(this.cmdban);
|
this.addSubCommand(this.cmdban);
|
||||||
this.addSubCommand(this.cmdUnban);
|
this.addSubCommand(this.cmdUnban);
|
||||||
this.addSubCommand(this.cmdbanlist);
|
this.addSubCommand(this.cmdbanlist);
|
||||||
|
if (Bukkit.getServer().getPluginManager().isPluginEnabled("FactionsTop")) {
|
||||||
|
P.p.log(Level.INFO, "Found FactionsTop plugin. Disabling our own /f top command.");
|
||||||
|
} else {
|
||||||
|
this.addSubCommand(this.cmdTop);
|
||||||
|
}
|
||||||
if (P.p.isHookedPlayervaults()) {
|
if (P.p.isHookedPlayervaults()) {
|
||||||
P.p.log("Found playervaults hook, adding /f vault and /f setmaxvault commands.");
|
P.p.log("Found playervaults hook, adding /f vault and /f setmaxvault commands.");
|
||||||
this.addSubCommand(new CmdSetMaxVaults());
|
this.addSubCommand(new CmdSetMaxVaults());
|
||||||
|
@ -2,7 +2,7 @@ name: Factions
|
|||||||
version: ${project.version}-b${build.number}
|
version: ${project.version}-b${build.number}
|
||||||
main: com.massivecraft.factions.P
|
main: com.massivecraft.factions.P
|
||||||
authors: [Olof Larsson, Brett Flannigan, drtshock]
|
authors: [Olof Larsson, Brett Flannigan, drtshock]
|
||||||
softdepend: [PlayerVaults, PlaceholderAPI, MVdWPlaceholderAPI, PermissionsEx, Permissions, Essentials, EssentialsChat, HeroChat, iChat, LocalAreaChat, LWC, nChat, ChatManager, CAPI, AuthMe, Vault, Spout, WorldEdit, WorldGuard, AuthDB, CaptureThePoints, CombatTag, dynmap]
|
softdepend: [PlayerVaults, PlaceholderAPI, MVdWPlaceholderAPI, PermissionsEx, Permissions, Essentials, EssentialsChat, HeroChat, iChat, LocalAreaChat, LWC, nChat, ChatManager, CAPI, AuthMe, Vault, Spout, WorldEdit, WorldGuard, AuthDB, CaptureThePoints, CombatTag, dynmap, FactionsTop]
|
||||||
commands:
|
commands:
|
||||||
factions:
|
factions:
|
||||||
description: Reference command for Factions.
|
description: Reference command for Factions.
|
||||||
|
Loading…
Reference in New Issue
Block a user