ICommandManager
Link to icommandmanager
ICommandManage 用于管理命令。 因此你可以用它来获取和执行命令。
你可以从 IServer 对象获取它。
导入相关包
Link to 导入相关包
It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import.
import crafttweaker.command.ICommandManager;
ZenGetters
Link to zengetters
Copy<th>
类型
</th>
Copy<td>
Map<String, <a href="/Vanilla/Commands/ICommand/">ICommand</a>\>
</td>
ZenGetter |
---|
commands |
ZenMethods
Link to zenmethods
- int executeCommand(ICommandSender sender, String rawCommand);
- List<String> getTabCompletions(ICommandSender sender, String input, @Optional IBlockPos pos);
- List<ICommand> getPossibleCommands(ICommandSender sender);
额外信息
Link to 额外信息
关于添加新命令,参见 CommandEvent