-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
54 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 46 additions & 0 deletions
46
src/main/java/cn/stevei5mc/NewTipsVariables/command/sub/CheckStateCommand.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
package cn.stevei5mc.NewTipsVariables.command.sub; | ||
|
||
import cn.stevei5mc.NewTipsVariables.command.BaseSubCommand; | ||
import cn.nukkit.command.CommandSender; | ||
import cn.nukkit.command.data.CommandParameter; | ||
import cn.stevei5mc.NewTipsVariables.utils.PluginsState; | ||
|
||
/** | ||
* @author LT_Name | ||
*/ | ||
public class CheckStateCommand extends BaseSubCommand { | ||
|
||
public CheckStateCommand(String name) { | ||
super(name); | ||
} | ||
|
||
@Override | ||
public boolean canUser(CommandSender sender) { | ||
return sender.hasPermission("newtipsariables.admin.checkstate"); | ||
} | ||
|
||
@Override | ||
public String[] getAliases() { | ||
return new String[0]; | ||
} | ||
|
||
@Override | ||
public boolean execute(CommandSender sender, String label, String[] args) { | ||
PluginsState ps = PluginsState.getInstance(); | ||
sender.sendMessage("Plugins status"); | ||
sender.sendMessage("playerPoints plugin = " + ps.playerPoints); | ||
sender.sendMessage("EconomyAPI status = " + ps.economyAPI); | ||
sender.sendMessage("OreArea status = " + ps.oreArea); | ||
sender.sendMessage("RSTask status = " + ps.rSTask); | ||
sender.sendMessage("HealthAPI status = " + ps.healthAPI); | ||
sender.sendMessage("LevelAwakenSystem status = " + ps.levelAwakenSystem); | ||
sender.sendMessage("RSWeapon status = " + ps.rSWeapon); | ||
sender.sendMessage("LuckPerms status = " + ps.luckPerms); | ||
return true; | ||
} | ||
|
||
@Override | ||
public CommandParameter[] getParameters() { | ||
return new CommandParameter[0]; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3312eab
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
更正
增加受支持插件的状态检查的功能