Class IntegrationsManager
java.lang.Object
io.github.thebusybiscuit.slimefun4.integrations.IntegrationsManager
This Service holds all interactions and hooks with third-party
Plugins
that are not necessarily a dependency or a SlimefunAddon
.
Integration with these plugins happens inside Slimefun itself.- Author:
- TheBusyBiscuit
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorDescriptionIntegrationsManager
(Slimefun plugin) This initializes theIntegrationsManager
-
Method Summary
Modifier and TypeMethodDescriptionio.github.bakedlibs.dough.protection.ProtectionManager
This returns out instance of theProtectionManager
.boolean
boolean
isCustomBlock
(Block block) boolean
isCustomItem
(ItemStack item) This checks if one of our third party integrations defines a givenItemStack
as custom.boolean
This method returns whether theIntegrationsManager
was enabled yet.boolean
isEventFaked
(Event event) This checks if one of our third party integrations faked anEvent
.boolean
boolean
boolean
boolean
boolean
protected void
void
This method removes any temporary enchantments from the givenItemStack
.final void
start()
This method initializes all third party integrations.
-
Field Details
-
plugin
This is our instance ofSlimefun
.
-
-
Constructor Details
-
IntegrationsManager
This initializes theIntegrationsManager
- Parameters:
plugin
- Our instance ofSlimefun
-
-
Method Details
-
isEnabled
public boolean isEnabled()This method returns whether theIntegrationsManager
was enabled yet.- Returns:
- Whether this
IntegrationsManager
has been enabled already.
-
start
public final void start()This method initializes all third party integrations. -
logError
-
getProtectionManager
@Nonnull public io.github.bakedlibs.dough.protection.ProtectionManager getProtectionManager()This returns out instance of theProtectionManager
. This bridge is used to hook into any third-party protectionPlugin
.- Returns:
- Our instanceof of the
ProtectionManager
-
isEventFaked
This checks if one of our third party integrations faked anEvent
. FakedEvents
should be ignored in our logic.- Parameters:
event
- TheEvent
to test- Returns:
- Whether this is a fake event
-
isCustomBlock
-
isCustomItem
This checks if one of our third party integrations defines a givenItemStack
as custom. -
removeTemporaryEnchantments
This method removes any temporary enchantments from the givenItemStack
. Some plugins apply enchantments for a short amount of time and remove it later. We don't want these items to be exploited using anAutoDisenchanter
for example, so we want to be able to strip those temporary enchantments in advance.- Parameters:
item
- TheItemStack
-
isPlaceholderAPIInstalled
public boolean isPlaceholderAPIInstalled() -
isWorldEditInstalled
public boolean isWorldEditInstalled() -
isMcMMOInstalled
public boolean isMcMMOInstalled() -
isClearLagInstalled
public boolean isClearLagInstalled() -
isItemsAdderInstalled
public boolean isItemsAdderInstalled() -
isOrebfuscatorInstalled
public boolean isOrebfuscatorInstalled()
-