Package studio.magemonkey.codex
Class CodexEngine
java.lang.Object
org.bukkit.plugin.PluginBase
org.bukkit.plugin.java.JavaPlugin
- All Implemented Interfaces:
org.bukkit.command.CommandExecutor,org.bukkit.command.TabCompleter,org.bukkit.command.TabExecutor,org.bukkit.event.Listener,org.bukkit.plugin.Plugin,studio.magemonkey.codex.manager.api.Loggable
-
Field Summary
Fields inherited from class studio.magemonkey.codex.CodexPlugin
commandManager, configManager, editorHandler, moduleManager -
Constructor Summary
ConstructorsConstructorDescriptionCodexEngine(org.bukkit.plugin.java.JavaPluginLoader loader, org.bukkit.plugin.PluginDescriptionFile description, File dataFolder, File file) -
Method Summary
Modifier and TypeMethodDescriptioncfg()voiddisable()voidenable()static CodexEngineget()Set<CodexPlugin<?>> Retrieves the message to be shown when a command is on cooldowngetConfigFile(org.bukkit.plugin.java.JavaPlugin plugin, String file) Retrieves the configuration file for a pluginstudio.magemonkey.codex.util.craft.CraftManagerstudio.magemonkey.codex.manager.api.menu.MenuManagerstudio.magemonkey.codex.util.messages.AbstractMessageUtilorg.bukkit.plugin.PluginManagergetVault()booleanChecks whether Codex's chat management is enabledbooleanlang()voidonHookLate(org.bukkit.event.server.PluginEnableEvent e) voidregisterCommands(IGeneralCommand<CodexEngine> mainCommand) voidregisterConfig(Config config) Registers the Config with Codex for auto saving.voidprotected voidvoidvoidMethods inherited from class studio.magemonkey.codex.CodexPlugin
error, getAuthor, getClazzLoader, getCommandManager, getConfigManager, getEditorHandler, getEngine, getHook, getHook, getHooks, getLabel, getLabels, getMainCommand, getModuleManager, getNameRaw, hasEditor, info, isEngine, isHooked, isHooked, isSpigot, onDisable, onEnable, openEditor, registerHook, reload, warnMethods inherited from class org.bukkit.plugin.java.JavaPlugin
getClassLoader, getCommand, getConfig, getDataFolder, getDefaultBiomeProvider, getDefaultWorldGenerator, getDescription, getFile, getLogger, getPlugin, getPluginLoader, getProvidingPlugin, getResource, getServer, getTextResource, isEnabled, isNaggable, onCommand, onLoad, onTabComplete, reloadConfig, saveConfig, saveDefaultConfig, saveResource, setEnabled, setNaggable, toStringMethods inherited from class org.bukkit.plugin.PluginBase
equals, getName, hashCode
-
Constructor Details
-
CodexEngine
public CodexEngine() -
CodexEngine
-
-
Method Details
-
get
-
registerEvents
protected void registerEvents() -
enable
public void enable()- Specified by:
enablein classCodexPlugin<CodexEngine>
-
disable
public void disable()- Specified by:
disablein classCodexPlugin<CodexEngine>
-
setConfig
public void setConfig()- Specified by:
setConfigin classCodexPlugin<CodexEngine>
-
registerHooks
public void registerHooks()- Specified by:
registerHooksin classCodexPlugin<CodexEngine>
-
registerCommands
- Specified by:
registerCommandsin classCodexPlugin<CodexEngine>
-
registerEditor
public void registerEditor()- Specified by:
registerEditorin classCodexPlugin<CodexEngine>
-
cfg
- Specified by:
cfgin classCodexPlugin<CodexEngine>
-
lang
- Specified by:
langin classCodexPlugin<CodexEngine>
-
getChildPlugins
-
onHookLate
public void onHookLate(org.bukkit.event.server.PluginEnableEvent e) -
getConfigFile
Retrieves the configuration file for a plugin
If the config file hasn't been loaded yet, this will load the file first.
Configs retrieved via this method are handled by Codex and automatically saved when Codex disables.
This should not be used for settings configs that admins may want to edit while the server is running as the auto save will overwrite any changes they make.
- Parameters:
file- file name- Returns:
- config manager for the file
-
registerConfig
Registers the Config with Codex for auto saving.
If the Config was already registered, this method will not do anything.
- Parameters:
config- config to register
-
getPluginManager
public org.bukkit.plugin.PluginManager getPluginManager()- Overrides:
getPluginManagerin classCodexPlugin<CodexEngine>
-
getPacketManager
- Overrides:
getPacketManagerin classCodexPlugin<CodexEngine>
-
getActionsManager
- Overrides:
getActionsManagerin classCodexPlugin<CodexEngine>
-
getCraftManager
public studio.magemonkey.codex.util.craft.CraftManager getCraftManager()- Overrides:
getCraftManagerin classCodexPlugin<CodexEngine>
-
getMenuManager
public studio.magemonkey.codex.manager.api.menu.MenuManager getMenuManager() -
getVault
- Overrides:
getVaultin classCodexPlugin<CodexEngine>
-
getCitizens
- Overrides:
getCitizensin classCodexPlugin<CodexEngine>
-
getWorldGuard
- Overrides:
getWorldGuardin classCodexPlugin<CodexEngine>
-
getMythicMobs
- Overrides:
getMythicMobsin classCodexPlugin<CodexEngine>
-
getHooksManager
-
getItemManager
-
getMessageUtil
public studio.magemonkey.codex.util.messages.AbstractMessageUtil getMessageUtil() -
isChatEnabled
public boolean isChatEnabled()Checks whether Codex's chat management is enabled- Returns:
- true if enabled, false otherwise
-
getCommandMessage
Retrieves the message to be shown when a command is on cooldown- Returns:
- command cooldown message
-
isScoreboardsEnabled
public boolean isScoreboardsEnabled()
-