Class RulesManager

java.lang.Object
me.lokka30.levelledmobs.rules.RulesManager

public class RulesManager extends Object
Manages all rules that are parsed from rules.yml and applied to various defined mobs
Since:
3.0.0
  • Field Details

    • rulesInEffect

      @NotNull public final @NotNull SortedMap<Integer,List<RuleInfo>> rulesInEffect
    • biomeGroupMappings

      @NotNull public final @NotNull Map<String,List<String>> biomeGroupMappings
    • anyRuleHasChance

      public boolean anyRuleHasChance
    • hasAnyWGCondition

      public boolean hasAnyWGCondition
  • Constructor Details

  • Method Details

    • getRuleIsWorldAllowedInAnyRule

      public boolean getRuleIsWorldAllowedInAnyRule(@Nullable @Nullable org.bukkit.World world)
    • getCurrentRulesHash

      @NotNull public @NotNull String getCurrentRulesHash()
    • addCustomRule

      public void addCustomRule(@Nullable @Nullable RuleInfo ri)
    • getRuleNbtData

      @NotNull public @NotNull List<String> getRuleNbtData(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleSunlightBurnIntensity

      public double getRuleSunlightBurnIntensity(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleMaxRandomVariance

      @Nullable public @Nullable Integer getRuleMaxRandomVariance(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleCheckIfNoDropMultiplierEntitiy

      public boolean getRuleCheckIfNoDropMultiplierEntitiy(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleUseCustomDropsForMob

      @NotNull public @NotNull CustomDropsRuleSet getRuleUseCustomDropsForMob(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleDoLockEntity

      public boolean getRuleDoLockEntity(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleIsMobAllowedInEntityOverride

      public boolean getRuleIsMobAllowedInEntityOverride(@NotNull @NotNull LivingEntityInterface lmInterface)
    • getFineTuningAttributes

      @Nullable public @Nullable FineTuningAttributes getFineTuningAttributes(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleExternalCompatibility

      @NotNull public @NotNull Map<ExternalCompatibilityManager.ExternalCompatibility,Boolean> getRuleExternalCompatibility(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • isPlayerLevellingEnabled

      public boolean isPlayerLevellingEnabled()
    • getRuleCreeperMaxBlastRadius

      public int getRuleCreeperMaxBlastRadius(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleLevellingStrategy

      @Nullable public @Nullable LevellingStrategy getRuleLevellingStrategy(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleMobLevelInheritance

      public boolean getRuleMobLevelInheritance(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleMobCustomNameStatus

      public MobCustomNameStatus getRuleMobCustomNameStatus(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleMobTamedStatus

      public MobTamedStatus getRuleMobTamedStatus(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleMobMinLevel

      public int getRuleMobMinLevel(@NotNull @NotNull LivingEntityInterface lmInterface)
    • getRuleMobMaxLevel

      public int getRuleMobMaxLevel(@NotNull @NotNull LivingEntityInterface lmInterface)
    • getRulePlayerLevellingOptions

      @Nullable public @Nullable PlayerLevellingOptions getRulePlayerLevellingOptions(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleNametag

      @NotNull public @NotNull String getRuleNametag(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleNametagPlaceholder

      @Nullable public @Nullable String getRuleNametagPlaceholder(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleNametagCreatureDeath

      @NotNull public @NotNull String getRuleNametagCreatureDeath(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleNametagIndicator

      @Nullable public @Nullable HealthIndicator getRuleNametagIndicator(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleCreatureNametagVisbility

      @NotNull public @NotNull List<NametagVisibilityEnum> getRuleCreatureNametagVisbility(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleNametagVisibleTime

      public long getRuleNametagVisibleTime(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleTieredPlaceholder

      @Nullable public @Nullable String getRuleTieredPlaceholder(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRulePassengerMatchLevel

      public boolean getRulePassengerMatchLevel(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getRuleEntityOverriddenName

      @Nullable public @Nullable String getRuleEntityOverriddenName(@NotNull @NotNull LivingEntityWrapper lmEntity, boolean forceCustomName)
    • getSpawnerParticle

      @Nullable public @Nullable org.bukkit.Particle getSpawnerParticle(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getSpawnerParticleCount

      public int getSpawnerParticleCount(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getAllowedVanillaBonuses

      @NotNull public @NotNull CachedModalList<VanillaBonusEnum> getAllowedVanillaBonuses(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getMaximumDeathInChunkThreshold

      public int getMaximumDeathInChunkThreshold(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getMaxChunkCooldownTime

      public int getMaxChunkCooldownTime(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getAdjacentChunksToCheck

      public int getAdjacentChunksToCheck(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getDeathMessage

      @Nullable public @Nullable String getDeathMessage(@NotNull @NotNull LivingEntityWrapper lmEntity)
    • getApplicableRules

      @NotNull public @NotNull ApplicableRulesResult getApplicableRules(LivingEntityInterface lmInterface)
    • buildBiomeGroupMappings

      public void buildBiomeGroupMappings(Map<String,Set<String>> customBiomeGroups)
    • clearTempDisabledRulesCounts

      public void clearTempDisabledRulesCounts()
    • showTempDisabledRules

      @NotNull public @NotNull String showTempDisabledRules(boolean isFromConsole)