Package me.deecaad.weaponmechanics
Class WeaponMechanics
java.lang.Object
me.deecaad.weaponmechanics.WeaponMechanics
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic me.deecaad.core.file.ConfigurationThis method returns ONLY config.yml configurations used by WeaponMechanics.org.bukkit.configuration.Configurationstatic me.deecaad.core.file.ConfigurationThis method returns ALL configurations EXCEPT config.yml used by WeaponMechanics.static @Nullable me.deecaad.core.database.Databasestatic EntityWrappergetEntityWrapper(org.bukkit.entity.LivingEntity entity) This method can't return null because new EntityWrapper is created if not found.static @Nullable EntityWrappergetEntityWrapper(org.bukkit.entity.LivingEntity entity, boolean noAutoAdd) This method will return null if no auto add is set to true and EntityWrapper is not found.getFile()static WeaponMechanicsstatic me.deecaad.core.commands.MainCommandstatic PlayerWrappergetPlayerWrapper(org.bukkit.entity.Player player) This method can't return null because new PlayerWrapper is created if not found.static org.bukkit.plugin.Pluginstatic ProjectilesRunnablestatic WeaponHandlervoidvoidonEnable()voidonLoad()me.deecaad.core.file.TaskChainonReload()static voidremoveEntityWrapper(org.bukkit.entity.LivingEntity entity) Removes entity (and player) wrapper and all of its content.
-
Field Details
-
debug
public static me.deecaad.core.utils.Debugger debug
-
-
Constructor Details
-
WeaponMechanics
public WeaponMechanics(org.bukkit.plugin.java.JavaPlugin javaPlugin)
-
-
Method Details
-
getConfig
public org.bukkit.configuration.Configuration getConfig() -
getLogger
-
getDataFolder
-
getClassLoader
-
getFile
-
onLoad
public void onLoad() -
onEnable
public void onEnable() -
onReload
public me.deecaad.core.file.TaskChain onReload() -
onDisable
public void onDisable() -
getProjectilesRunnable
- Returns:
- The BukkitRunnable holding the projectiles being ticked
-
getPlugin
public static org.bukkit.plugin.Plugin getPlugin()- Returns:
- the WeaponMechanics plugin instance
-
getInstance
-
getEntityWrapper
This method can't return null because new EntityWrapper is created if not found.- Parameters:
entity- the entity wrapper to get- Returns:
- the entity wrapper
-
getEntityWrapper
@Nullable public static @Nullable EntityWrapper getEntityWrapper(org.bukkit.entity.LivingEntity entity, boolean noAutoAdd) This method will return null if no auto add is set to true and EntityWrapper is not found. If no auto add is false then new EntityWrapper is automatically created if not found and returned by this method.- Parameters:
entity- the entitynoAutoAdd- true means that EntityWrapper wont be automatically added if not found- Returns:
- the entity wrapper or null if no auto add is true and EntityWrapper was not found
-
getPlayerWrapper
This method can't return null because new PlayerWrapper is created if not found. Use mainly getEntityWrapper() instead of this unless you especially need something from PlayerWrapper.- Parameters:
player- the player wrapper to get- Returns:
- the player wrapper
-
removeEntityWrapper
public static void removeEntityWrapper(org.bukkit.entity.LivingEntity entity) Removes entity (and player) wrapper and all of its content. Move task is also cancelled.- Parameters:
entity- the entity (or player)
-
getConfigurations
public static me.deecaad.core.file.Configuration getConfigurations()This method returns ALL configurations EXCEPT config.yml used by WeaponMechanics.- Returns:
- the configurations interface
-
getBasicConfigurations
public static me.deecaad.core.file.Configuration getBasicConfigurations()This method returns ONLY config.yml configurations used by WeaponMechanics.- Returns:
- the configurations interface
-
getMainCommand
public static me.deecaad.core.commands.MainCommand getMainCommand()- Returns:
- the main command instance of WeaponMechanics
-
getWeaponHandler
- Returns:
- the current weapon handler
-
getDatabase
@Nullable public static @Nullable me.deecaad.core.database.Database getDatabase()- Returns:
- the database instance if enabled
-