Class MixinModPlatform
java.lang.Object
net.dillon.dillonlib.platform.mixinsafe.MixinModPlatform
- All Implemented Interfaces:
Loadable
- Direct Known Subclasses:
MixinFabricPlatformImpl
A separate service loader for mixin-safe classes and plugins, to prevent unknown and unexpected crashes when reading other Minecraft files during game initialization and checking mixins. This class should only be used within mixin plugins to ensure stability.
- Since:
- 1.0
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisModLoaded(ModReference mod) abstract StringmodId()booleanSpecifies if factories should be applied.boolean
-
Constructor Details
-
MixinModPlatform
public MixinModPlatform()
-
-
Method Details
-
modId
-
isModLoaded
- Returns:
- if a mod is loaded on a specific platform. You can use this in
MixinPluginUtils, or anywhere else, but callFabricPlatformsor(Neo)ForgePlatformsto get the correct return value of this method!
-
shouldApplyFactories
public boolean shouldApplyFactories()Specifies if factories should be applied. If any instance ofMixinModPlatformreturnstruehere, unless a mixin is manually disabled, factories will be applied.- Returns:
falseby default because not all of Dillon's mods use factories. This returns false by default as a safety feature in order to prevent mod incompatibility with other mods when factories aren't even being used. You mustoverride this to return trueif you plan on usingnet.dillon.dillonlib.factorys!
-
shouldApplyFullBright
public boolean shouldApplyFullBright()- Returns:
- if full bright settings should be applied. This allows for full bright in your mod if you wish to add it.
-