本文整理汇总了Java中org.bukkit.plugin.java.JavaPlugin.getPlugin方法的典型用法代码示例。如果您正苦于以下问题:Java JavaPlugin.getPlugin方法的具体用法?Java JavaPlugin.getPlugin怎么用?Java JavaPlugin.getPlugin使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.bukkit.plugin.java.JavaPlugin
的用法示例。
在下文中一共展示了JavaPlugin.getPlugin方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onEnable
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public void onEnable() {
// Console sender
getServer().getConsoleSender().sendMessage(ChatColor.GREEN + "|----------|");
getServer().getConsoleSender().sendMessage(ChatColor.AQUA + "Starting Mortuus Terra chat.");
core = JavaPlugin.getPlugin(MortuusTerraCore.class);
frequencyManager = new FrequencyManager();
fileManager = new FileManager();
playerManager = new PlayerManager();
textMessageManager = new TextMessageManager();
messageScrambler = new MessageScrambler();
getFileManager().loadFiles();
registerCommands();
registerListeners();
// Console sender
getServer().getConsoleSender().sendMessage(ChatColor.AQUA + "Mortuus Terra chat ready.");
getServer().getConsoleSender().sendMessage(ChatColor.GREEN + "|----------|");
}
示例2: SCommandExecutor
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public SCommandExecutor() {
super();
this.plugin = JavaPlugin.getPlugin(BlockBallPlugin.class);
if (this.plugin == null)
throw new IllegalArgumentException("Pluginloader failed to load " + this.getClass().getSimpleName() + '.');
this.plugin.getCommand(this.getCommand()).setExecutor(this);
}
示例3: reload
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public static void reload(Class<?> cls) {
final Plugin plugin = JavaPlugin.getPlugin(BlockBallPlugin.class);
if (plugin == null)
throw new IllegalArgumentException("Pluginloader failed to load " + SLanguage.class.getSimpleName() + '.');
final File file = new File(plugin.getDataFolder(), "lang.yml");
if (!file.exists())
buildFile(cls, file);
loadFile(cls, file);
}
示例4: GameController
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public GameController() {
super(JavaPlugin.getPlugin(BlockBallPlugin.class));
this.arenaManager = ArenaController.createArenaController(this);
new EventCommandExecutor(this);
if (Config.getInstance().getGlobalJoinCommand().isEnabled())
new GlobalJoinCommandExecutor(this);
if (Config.getInstance().getGlobalLeaveCommand().isEnabled())
new GlobalLeaveCommandExecutor(this);
new GameListener(this);
this.run();
}
示例5: ArenaController
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
private ArenaController(GameController manager) {
super();
this.fileManager = new ArenaFileManager(JavaPlugin.getPlugin(BlockBallPlugin.class));
this.manager = manager;
new ArenaCommandExecutor(this);
new BlockBallCommandExecutor();
Factory.initialize(JavaPlugin.getPlugin(BlockBallPlugin.class));
}
示例6: getInstance
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public static CustomRecipesPlugin getInstance() {
return JavaPlugin.getPlugin(CustomRecipesPlugin.class);
}
示例7: createEngineController
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public static EngineController createEngineController() {
return new EngineConfiguration(JavaPlugin.getPlugin(PetBlocksPlugin.class));
}
示例8: createCostumesController
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public static CostumeController createCostumesController(String category) {
return new CostumeConfiguration(category, JavaPlugin.getPlugin(PetBlocksPlugin.class));
}
示例9: createMinecraftHeadsCostumesController
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public static CostumeController createMinecraftHeadsCostumesController() {
return new MinecraftHeadConfiguration(JavaPlugin.getPlugin(PetBlocksPlugin.class));
}
示例10: createGUIItemsController
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public static OtherGUIItemsController createGUIItemsController() {
return new FixedItemConfiguration(JavaPlugin.getPlugin(PetBlocksPlugin.class));
}
示例11: getPlugin
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
private static Plugin getPlugin() {
return JavaPlugin.getPlugin(AstralEditPlugin.class);
}
示例12: reload
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
/**
* Reloads the config
*/
public void reload() {
this.plugin = JavaPlugin.getPlugin(PetBlocksPlugin.class);
this.plugin.reloadConfig();
}
示例13: PetDataCommandExecutor
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public PetDataCommandExecutor(PetBlockManager petDataManager) throws Exception {
super(((MemorySection) JavaPlugin.getPlugin(PetBlocksPlugin.class).getConfig().get("petblocks-gui")).getValues(false)
, JavaPlugin.getPlugin(PetBlocksPlugin.class));
this.manager = petDataManager;
this.plugin = JavaPlugin.getPlugin(PetBlocksPlugin.class);
}
示例14: SChatMenuManager
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
public SChatMenuManager() {
super(JavaPlugin.getPlugin(BlockBallPlugin.class));
}
示例15: Config
import org.bukkit.plugin.java.JavaPlugin; //导入方法依赖的package包/类
private Config() {
super();
this.plugin = JavaPlugin.getPlugin(BlockBallPlugin.class);
this.reload();
}